Re: PIL problem: IOError: cannot identify image file

2006-08-20 Thread Fredrik Lundh
[EMAIL PROTECTED] wrote: > Doh! Apparently Image.open() wants a path, not a file. So > > i = Image.open('c:\\image2.png') > > works fine. it works fine on files too, if you open them in *binary* mode. -- http://mail.python.org/mailman/listinfo/python-list

Re: PIL problem: IOError: cannot identify image file

2006-08-20 Thread h112211
Doh! Apparently Image.open() wants a path, not a file. So i = Image.open('c:\\image2.png') works fine. -- http://mail.python.org/mailman/listinfo/python-list

PIL problem: IOError: cannot identify image file

2006-08-20 Thread h112211
Hi, I installed the newest available PIL (1.1.5 for Python 2.4) from their site, but cannot seem to open any files. The following from PIL import Image i = Image.open(file('c:\\image2.png')) results in File "C:\Program Files\Python24\lib\site-packages\PIL\Image.py", line 1745, in open ra