EPS images loosing data when opening in ImageMagick display

Post any defects you find in the released or beta versions of the ImageMagick software here. Include the ImageMagick version, OS, and any command-line required to reproduce the problem. Got a patch for a bug? Post it here.
Post Reply
Carter J
Posts: 116
Joined: 2013-12-19T02:20:09-07:00
Authentication code: 6789

EPS images loosing data when opening in ImageMagick display

Post by Carter J »

We have a set of EPS images and when we are trying to use ImageMagick to do the conversion its loosing the background colors, not sure if they are background colors or some clipping path

When we open the same EPS image using IMDisplay, EPS viewer or Preview appication its still not showing the background. When tried opening the EPS image with Photoshop application it shows the exact image.

Please find the images/screenshots below

When opened in Photoshop - https://www.dropbox.com/s/n0kfg6s6ew79s ... PSFile.jpg
When opened in IM (or) EPS viewer - https://www.dropbox.com/s/g806szrsux70ely/IM.jpg
Original EPS - https://www.dropbox.com/s/1kbam01vaz8ix ... PSFile.eps

ImageMagick - 6.8.8-5
Operating Systems - Windows 7

Please advice what's causing this
User avatar
dlemstra
Posts: 1570
Joined: 2013-05-04T15:28:54-07:00
Authentication code: 6789
Contact:

Re: EPS images loosing data when opening in ImageMagick disp

Post by dlemstra »

This looks like a missing feature in Ghostscript. At some point we execute something that looks like the following command:

Code: Select all

"C:/Program Files (x86)/gs/gs9.10/bin/gswin32c.exe" -q -dQUIET -dSAFER -dBATCH -dNOPAUSE -dNOPROMPT -dMaxBitmap=500000000 -dAlignToPixels=0 -dGridFitTT=2 "-sDEVICE=pngalpha" -dTextAlphaBits=4 -dGraphicsAlphaBits=4 "-r72x72" -g612x792 -dEPSCrop  "-sOutputFile=test.png" "-fInputEPSFile.eps"
This results in a png without the background you see in Photoshop.
.NET + ImageMagick = Magick.NET https://github.com/dlemstra/Magick.NET, @MagickNET, Donate
Carter J
Posts: 116
Joined: 2013-12-19T02:20:09-07:00
Authentication code: 6789

Re: EPS images loosing data when opening in ImageMagick disp

Post by Carter J »

dlemstra wrote:This looks like a missing feature in Ghostscript. At some point we execute something that looks like the following command:

Code: Select all

"C:/Program Files (x86)/gs/gs9.10/bin/gswin32c.exe" -q -dQUIET -dSAFER -dBATCH -dNOPAUSE -dNOPROMPT -dMaxBitmap=500000000 -dAlignToPixels=0 -dGridFitTT=2 "-sDEVICE=pngalpha" -dTextAlphaBits=4 -dGraphicsAlphaBits=4 "-r72x72" -g612x792 -dEPSCrop  "-sOutputFile=test.png" "-fInputEPSFile.eps"
This results in a png without the background you see in Photoshop.
But if you open the EPS file using IM, the EPS file itself is loosing the backgroun when trying to open in "IMDisplay". The same EPS when opened in Photoshop is preserving the background color

So when we execute a convert command on the EPS its loosing the background when you tried to save it as PNG.

Photoshop is able to preserve the background, so can we make something here so GS and IM can preserve the same
User avatar
dlemstra
Posts: 1570
Joined: 2013-05-04T15:28:54-07:00
Authentication code: 6789
Contact:

Re: EPS images loosing data when opening in ImageMagick disp

Post by dlemstra »

I think this is a problem within Ghostscript. Maybe you should contact them to see if they can resolve the problem?
.NET + ImageMagick = Magick.NET https://github.com/dlemstra/Magick.NET, @MagickNET, Donate
Post Reply