[IMAGE-SIG] ImagePalette

David Ascher da@skivs.ski.org
Mon, 26 Jan 1998 15:27:20 -0800 (PST)

I'm confused about the ImagePalette stuff.  I want to create a P mode
image from data.  What I'm doing is something like:

	image = Image.new('P', (500,500))
	imagedraw = ImageDraw.ImageDraw(image)
	image.palette = ImagePalette.wedge()

the save fails because of the palette not having a properly defined

	Traceback (innermost last):
	  File "C:\Program Files\Python\imaging\ImageDraw.py", line 23, in
	  File "C:\Program Files\Python\imaging\Image.py", line 300, in load
	    if self.im and self.palette and self.palette.rawmode:
	AttributeError: rawmode

I'll use 'L' images for now, but I'd like to understand 'P' mode images


PS: Any hope that PIL 0.N+1 will support arrays in addition to lists, for
e.g. the ImageDraw.point operations?

IMAGE-SIG - SIG on Image Processing with Python

send messages to: image-sig@python.org
administrivia to: image-sig-request@python.org