[Image-SIG] parameters for Image.fromstring function in pil

Fredrik Lundh fredrik at pythonware.com
Sat Feb 16 09:24:43 CET 2008

bharath venkatesh wrote:

> but i  can't apply resize operation on cached_image as it a str object
> but i found out that Image.formstring(mode, size, data, decoder, 
> parameters) Creates an image memory from pixel data in a string so i did 
> the following

raw pixel data and data in image interchange formats are two different 
things.  in your case, you should use StringIO on the way in:

      im = Image.open(StringIO(data))


More information about the Image-SIG mailing list