-
-
Notifications
You must be signed in to change notification settings - Fork 437
Closed
Description
Magick.NET version
14.8.0
Environment (Operating system, version and so on)
Windows
Description
I am creating gif image from 2 source images. Source images are overlapping in the result gif:
Steps to Reproduce
This is my .Net 8 code snippet:
using (var collection = new MagickImageCollection())
{
var gifAdded = false;
List<string> sourceFiles = [@"C:\Users\petku\Downloads\GifImages\619971-1E.png", @"C:\Users\petku\Downloads\GifImages\619971-2E.png"];
foreach (var conversionSourceFile in sourceFiles)
{
collection.AddRange(conversionSourceFile);
}
foreach (var image in collection)
{
if (Conversion.ToBoolean(ImageParameter.PersistAnimation()) && gifAdded)
{
}
else
{
image.AnimationIterations = 0;
image.AnimationDelay = 100;
}
var imageResolution = 200;
var height = 0;
var width = 0;
var scaleImage = false;
var scaleProportions = true;
var scaleIfLarger = false;
image.Density = new Density(imageResolution, imageResolution, DensityUnit.PixelsPerInch);
}
collection.Coalesce();
collection.Optimize();
collection.OptimizeTransparency();
using (var fs = File.Create(Conversion.DestinationLocation + @"\result.gif"))
{
collection.Write(fs, MagickFormat.Gif);
}
}Images

Metadata
Metadata
Assignees
Labels
No labels