Problem with convert eps3 and latex command

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
thomkris
Posts: 7
Joined: 2011-12-20T13:10:24-07:00
Authentication code: 8675308

Problem with convert eps3 and latex command

Post by thomkris »

I am using ImageMagick 6.7.2-7 2011-10-19 presently. (One of old version worked with eps3 earlier, but not now)

I am trying to either convert or combine 4 png files to one eps file. I have to compress the final eps format file. I then use the eps file in LaTEx to build pdf. I get following error when reading with Latex. I can open in ghost view fine. I am not sure if the filepp.eps file is corrupted or I am not using correct options. This flow works fine with no eps3. Thanks for your suggestion.

Command: convert -page A4 filepp.gif -compress zip eps3:filepp.eps

Error: /undefined in ÃK
Operand stack:

Execution stack:
%interp_exit .runexec2 --nostringval-- --nostringval-- --nostringval-- 2 %s
topped_push --nostringval-- --nostringval-- --nostringval-- false 1 %stopped_p
ush 1 3 %oparray_pop 1 3 %oparray_pop 1 3 %oparray_pop 1 3 %oparra
y_pop .runexec2 --nostringval-- --nostringval-- --nostringval-- 2 %stopped_pus
h --nostringval-- --nostringval-- --nostringval--
Dictionary stack:
--dict:1046/1123(ro)(G)-- --dict:0/20(G)-- --dict:90/200(L)-- --dict:195/300(L)--
--dict:64/200(L)-- --dict:90/200(L)--
Current allocation mode is local
Last OS error: 2
Current file position is 60650
User avatar
magick
Site Admin
Posts: 11064
Joined: 2003-05-31T11:32:55-07:00

Re: Problem with convert eps3 and latex command

Post by magick »

ImageMagick depends on Ghostscript to render Postscript / PDF files. You may need to upgrade your release of Ghostscript. Its currently @ 9.04. You might consider upgrading ImageMagick as well. Its currently @ ImageMagick 6.7.4-0.
thomkris
Posts: 7
Joined: 2011-12-20T13:10:24-07:00
Authentication code: 8675308

Re: Problem with convert eps3 and latex command

Post by thomkris »

thanks for the suggestion. I will give it a try and let you know outcome.
thomkris
Posts: 7
Joined: 2011-12-20T13:10:24-07:00
Authentication code: 8675308

Re: Problem with convert eps3 and latex command

Post by thomkris »

magik,

I tried with latest ghostscript 9.04 and using convert version of 6.7.2-7. The problem still persists and across aix and linux. I believe its a bug with both eps2 and ep3.

Can someone try a small example at your side.
User avatar
magick
Site Admin
Posts: 11064
Joined: 2003-05-31T11:32:55-07:00

Re: Problem with convert eps3 and latex command

Post by magick »

We're using Ghostscript 9.04 and ImageMagick 6.7.6-0:
  • -> convert -page A4 filepp.gif -compress zip eps3:filepp.eps

    -> gs filepp.eps
    GPL Ghostscript 9.04 (2011-08-05)
    Copyright (C) 2011 Artifex Software, Inc. All rights reserved.
    This software comes with NO WARRANTY: see the file PUBLIC for details.
    >>showpage, press <return> to continue<<
The Postscript rendering matches that of the original image and no exceptions are generated.

Post a URL to your original image and the converted EPS. We'll compare it to what we generate and see if can identify some difference that is causing the exception.
User avatar
magick
Site Admin
Posts: 11064
Joined: 2003-05-31T11:32:55-07:00

Re: Problem with convert eps3 and latex command

Post by magick »

Ghostscript seems to complain when the EPS includes a HiResBoundingBox statement. Remove it and all is fine. You can also use the ps2eps program to generate a bounding box that stops the complaints. Recall you're trying to display an EPS on a Postscript canvas so the bounding box may need adjusting. Note, if the input image is less than the Postscript canvas size (typically 612x792), no bounding box complaints are issued (e.g. convert rose: eps3:rose.eps).
thomkris
Posts: 7
Joined: 2011-12-20T13:10:24-07:00
Authentication code: 8675308

Re: Problem with convert eps3 and latex command

Post by thomkris »

Admin,

I have tried removing HiResBoundingBox (hand removal) and the resulting file didn't help. I have uploaded the set of files at the link below. Let me know your suggestions.

http://www.mediafire.com/?hdfjkd302ht67ar

The eps files are created using eps3 compression. Try opening them in ghostscript. The ps2pdf output yield nothing due to the ghostscript problem.
thomkris
Posts: 7
Joined: 2011-12-20T13:10:24-07:00
Authentication code: 8675308

Re: Problem with convert eps3 and latex command

Post by thomkris »

Admin, Is there an update on this problem? Do you want me to try anything at my side?
Post Reply