ASPN ActiveState Programmer Network
ActiveState
/ Home / Perl / PHP / Python / Tcl / XSLT /
/ Safari / My ASPN /
Cookbooks | Documentation | Mailing Lists | Modules | News Feeds | Products | User Groups


Recent Messages
List Archives
About the List
List Leaders
Subscription Options

View Subscriptions
Help

View by Topic
ActiveState
.NET Framework
Open Source
Perl
PHP
Python
Tcl
Web Services
XML & XSLT

View by Category
Database
General
SOAP
System Administration
Tools
User Interfaces
Web Programming
XML Programming


MyASPN >> Mail Archive >> image-sig
image-sig
[Image-SIG] Handling of signed 16-bit TIFF images seems not to work...
by David Izraelevitz other posts by this author
Jul 13 2004 10:16PM messages near this date
Re: [Image-SIG] PIL && JPG => cannot identify image file PROBLEM | [Image-SIG] convoultion
First, the context:

 > >> sys.platform
'win32'
 > >> sys.version
'2.3.3 (#51, Dec 18 2003, 20:22:39) [MSC v.1200 32 bit (Intel)]'

and running PIL 1.1.4

I have a TIFF image with mode 'I;16S' that loads  i.e.:
 > >>import Image
 > >>im = Image.open("image.tif")

but then
 > >>im_data = im.getdata()
fails:
Traceback (most recent call last):
   File "<pyshell#14> ", line 1, in ?
     im2_data = im2.getdata()
   File "C:\Python23\Lib\site-packages\PIL\Image.py", line 741, in getdata
     self.load()
   File "C:\Python23\Lib\site-packages\PIL\ImageFile.py", line 151, in load
     self.load_prepare()
   File "C:\Python23\Lib\site-packages\PIL\ImageFile.py", line 206, in 
load_prepare
     self.im = Image.core.new(self.mode, self.size)
ValueError: unrecognized mode


When I inquire about the image mode:

 > >> im.mode
'I;16S'

I have looked a the C-code in my Unix installation and it is unclear 
whether this mode is handled correctly. Any pointers?

Thanks.



_______________________________________________
Image-SIG maillist  -  Image-SIG@[...].org
http://mail.python.org/mailman/listinfo/image-sig

Privacy Policy | Email Opt-out | Feedback | Syndication
© ActiveState Software Inc. All rights reserved