Skip to content

Converting a DCX page to PNG results wrong color #1965

@victor8hpy

Description

@victor8hpy

Magick.NET version

MagicK.NET-Q16-AnyCPU v14.10.3

Environment (Operating system, version and so on)

Windows 11

Description

I try to convert a DCX page 0, to a PNG image. The converted PNG shows bad color.

Steps to Reproduce

using ImageMagick;

namespace DcxToPng
{
internal class Program
{
static void Main(string[] args)
{
var inputFilePath = @"C:\Temp\Input\DCX1.DCX";
var outputFilePath = @"C:\Temp\Output\DCX1.png";

        using MagickImageCollection collection = new(inputFilePath);

        collection[0].Write(outputFilePath, MagickFormat.Png);
    }
}

}

Run the above console application, using the following DCX1.DCX from zip file.

DCX1.zip

Images

Bad result:
Image

Good as it should be:
Image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions