[OS X TeX] EPS to PDF conversion fails in graphicx (but not in preview)
Siep Kroonenberg
siepo at cybercomm.nl
Sat Dec 4 04:07:28 EST 2010
On Sat, Dec 04, 2010 at 01:02:53AM +0100, Peter Dyballa wrote:
>
> Am 03.12.2010 um 23:13 schrieb Siep Kroonenberg:
>
> >There is no need for guesswork or inspection: according to Adobe's
> >eps specification, for an eps with preview the first 4 bytes should
> >be #c5d0d3c6, the next 4 bytes indicate the start of the postscript
> >code and the 4 bytes after that the length of the postscript
> >section. This makes it trivially easy in almost any scripting
> >language to extract the actual postscript code.
>
>
> The file starts with the hex c5d0d3c6 (or ≈–”Δ as string). Then
> comes a SPACE (or 20) followed by three ASCII NUL. So the number is
> 20,000 hex or 131,072 dec. This leads into the middle of some
> PostScript code. Then follows 7B50 hex (^G^K^E^@) or 31,568 dec. The
> "scrappy" last 327,759 bytes then are a TIFF image of the EPS
> image...
Byte order. Postscript start is 0x00000020, Postscript length is
0x00045ac7. The byte order of these numbers is always little-endian.
>
> And 5002.EPSF_Spec describes this header as "DOS EPS Binary File
> Header" – why is it produced on a Mac in a Mac-Roman encoding?
Just try it. It works.
--
Siep Kroonenberg
More information about the MacOSX-TeX
mailing list