[Image-SIG] Where is the indexed PNG alpha table ?

Douglas Bagnall douglas at paradise.net.nz
Thu Jan 27 01:58:18 CET 2005

Ray Pasco wrote:
> I am wondering how to get at the alpha layer table that goes along
> with an indexed PNG image.

I believe that alpha in an indexed PNG is not stored as a channel, but 
as indexed colours.  In other words, the index is not of RGB values, but 
of RGBA values.  If you only have full transparancy, there'll only be 
one index value for it, and PIL will probably do the right thing with

 >>> im = Image.open('indexed.png').convert('RGBA')

but I'm not sure how it would cope with multiple semi-transparent values 
-- I don't know how to make such an image to test with.


More information about the Image-SIG mailing list