-
-
Notifications
You must be signed in to change notification settings - Fork 437
Description
Magick.NET version
Magick.NET-Q8-AnyCPU 13.10.0
Environment (Operating system, version and so on)
Windows 10, .NET Framework 4.8
Description
I have encountered 3 PNG images with transparent background which are corrupted when they are loaded by IM and then written to a new path with the JPG extension instead of PNG. This is how we normally change the output filetype when processing a file with IM, and I am not aware of a different method to make IM output the same file with a different filetype. We have not been able to reproduce this with any other PNGs with transparent background so far, and it's unclear to me what might be unique about these files that is causing the corruption.
The attached ZIP contains the original PNG files and the resaved JPG files which display the corruption. The first one becomes visibly blurred around the edges of the original image, and the background becomes white. The other two have their background become black instead of the expected white.
Can this be resolved with a code change on our end, or can it be fixed in Magick.NET / ImageMagick?
AffectedPNGsWithTransparentBackground.zip
Steps to Reproduce
MagickImage image = new MagickImage();
image.Read(pngPath);
image.Write(jpgPath);