EPS to JPG becomes black and white

Magick.NET is an object-oriented C# interface to ImageMagick. Use this forum to discuss, make suggestions about, or report bugs concerning Magick.NET
Post Reply
garrethx
Posts: 3
Joined: 2014-09-23T01:24:53-07:00
Authentication code: 6789

EPS to JPG becomes black and white

Post by garrethx »

Hi,

I am using ImageMagick version 6.8.8.901 and GhostScript 9.15.

When I convert an EPS (DCS 1.0), the resulting JPG is correct.

However, when I convert DCS 2.0, the resulting JPG is in black and white.

I tried using ColorSpace sRGB, scRGB, RGB and CMYK

Below is the code snippet

MagickReadSettings settings = new MagickReadSettings();
using (MagickImage image = new MagickImage(fileName))
{
image.ColorSpace = ColorSpace.sRGB;
image.Quality = 100;
image.CompressionMethod = ImageMagick.CompressionMethod.LosslessJPEG;
image.Write(JpgFileName);
image.Dispose();
}

Let me know what needs to be changed in the code.

Thanks in advance.
User avatar
dlemstra
Posts: 1570
Joined: 2013-05-04T15:28:54-07:00
Authentication code: 6789
Contact:

Re: EPS to JPG becomes black and white

Post by dlemstra »

I have moved your post because it might be a Magick.NET issue. Can you upgrade to the latest version of Magick.NET and try again?
.NET + ImageMagick = Magick.NET https://github.com/dlemstra/Magick.NET, @MagickNET, Donate
garrethx
Posts: 3
Joined: 2014-09-23T01:24:53-07:00
Authentication code: 6789

Re: EPS to JPG becomes black and white

Post by garrethx »

Hi,

I downloaded the latest version of Magick.Net (v7) as suggested.

However, the converted JPG is still in black and white.

Regards
User avatar
dlemstra
Posts: 1570
Joined: 2013-05-04T15:28:54-07:00
Authentication code: 6789
Contact:

Re: EPS to JPG becomes black and white

Post by dlemstra »

Can you add a link to the source file that converts incorrectly and a link to the source file that converts properly? Feel free to send me a PM if you don't want to publicly share your image.
.NET + ImageMagick = Magick.NET https://github.com/dlemstra/Magick.NET, @MagickNET, Donate
User avatar
dlemstra
Posts: 1570
Joined: 2013-05-04T15:28:54-07:00
Authentication code: 6789
Contact:

Re: EPS to JPG becomes black and white

Post by dlemstra »

Thank you for providing your image but I think you should report a bug at 'http://bugs.ghostscript.com/' if you know for sure the image should not be grayscale. You can include the following command in your bug report :

Code: Select all

D:\Images\eps>"C:/Program Files/gs/gs9.15/bin/gswin64c.exe" -q -DQUIET -dSAFER -
dBATCH -dNOPAUSE -dNOPROMPT -dMaxBitmap=500000000 -dAlignToPixels=0 -dGridFitTT=
2 "-sDEVICE=pamcmyk32" -dTextAlphaBits=4 -dGraphicsAlphaBits=4 "-r72x72" -g245x3
26 -dEPSCrop -sOutputFile=BecomesBlackNWhite.pam -fBecomesBlackNWhite.eps
You probably also need to provide your image.
.NET + ImageMagick = Magick.NET https://github.com/dlemstra/Magick.NET, @MagickNET, Donate
garrethx
Posts: 3
Joined: 2014-09-23T01:24:53-07:00
Authentication code: 6789

Re: EPS to JPG becomes black and white

Post by garrethx »

Thanks!
Post Reply