Opening Photoshop EPS with PIL?

oliver at obeattie.com oliver at obeattie.com
Sat Mar 31 16:12:24 CEST 2007


Hey Everyone,

I am trying to get PIL to open some EPS files I have (Photoshop EPS,
whatever the difference is). I'm trying to use PIL to do this, but
when I run it, the following happens:

>>> from PIL import Image, ImageOps
>>> Image.open('/flora.eps')
Traceback (most recent call last):
  File "<console>", line 1, in ?
  File "/opt/local/lib/python2.4/site-packages/PIL/Image.py", line
1741, in open
    return factory(fp, filename)
  File "/opt/local/lib/python2.4/site-packages/PIL/ImageFile.py", line
82, in __init__
    self._open()
  File "/opt/local/lib/python2.4/site-packages/PIL/EpsImagePlugin.py",
line 206, in _open
    raise IOError, "bad EPS header"

I've never had any real trouble with PIL before (never used it for EPS
though). Can anyone offer any advice on this one? I'd be most
grateful.

Many Thanks Everyone,
Oliver Beattie




More information about the Python-list mailing list