C
cocobear
This two png file has their own palette
False
I can use this code to merge two png pic together:
Map = Image.new("RGB", (x,y))
Map.paste(im, box)
Map.paste(im1,box)
Map = Map.convert("L", optimize=True, palette=Image.ADAPTIVE)
But if the two png pic is too big , or if I have to merge more pic
together, I will get MemoryError:
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/lib/python2.5/site-packages/PIL/Image.py", line 1710, in
new
return Image()._new(core.fill(mode, size, color))
MemoryError
How can I directly merge two pic to a ‘P' mode png with palette.
False
I can use this code to merge two png pic together:
Map = Image.new("RGB", (x,y))
Map.paste(im, box)
Map.paste(im1,box)
Map = Map.convert("L", optimize=True, palette=Image.ADAPTIVE)
But if the two png pic is too big , or if I have to merge more pic
together, I will get MemoryError:
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/lib/python2.5/site-packages/PIL/Image.py", line 1710, in
new
return Image()._new(core.fill(mode, size, color))
MemoryError
How can I directly merge two pic to a ‘P' mode png with palette.