How are you checking the DPI of your output image? The PSD writer use the Density of the first image in the collection. I am getting the correct output when I execute the following code:
My output is below, are you using the latest version of Magick.NET?
using (MagickImageCollection psd = new MagickImageCollection()) { MagickImage logo = new MagickImage("logo:"); logo.Density = new PointD(300); psd.Add(logo); byte[] data = psd.ToByteArray(MagickFormat.Psd); using (MagickImage result = new MagickImage(data)) { Console.WriteLine(result.ToString()); Console.WriteLine(result.Density.X + "x" + result.Density.Y); } }
Psd 640x480 8-bit sRGB 300.82kB
300x300