Question

I attempted to use imageresizer and the animated gif plugin to resize an animated gif. It did resize but I lost the animation in the process. I did set the format to gif even after following the example given on the site. Any help would be appreciated.

Thanks for the response. I should first point out that I am building a desktop application. Here is the code I am using:

var fileName = ofdChiImage.FileName;
Dictionary<string, string> versions = new Dictionary<string, string>();
versions.Add("_thumb1", "maxwidth=200&maxheight=200&format=gif");
string basepath = ImageResizer.Util.PathUtils.RemoveExtension(fileName);
foreach (string suffix in versions.Keys)
{
    ImageBuilder.Current.Build(fileName, basepath + suffix, new ResizeSettings(versions[suffix]), false, true);
}
Was it helpful?

Solution

in .NET4+, Console and desktop applications do not automatically load DLLs that are not explicitly referenced through code (even if they are referenced within App.config). Thus for these types of applications we always recommend the code-based (instead of xml-based) installation method for ImageResizer plugins.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top