TIFF and LibTiff Mail List Archive


2004.05.20 11:05 "[Tiff] Extra samples handling", by
2004.05.20 23:42 "Re: [Tiff] Extra samples handling", by Chris Cox
2004.05.21 09:05 "Re: [Tiff] Extra samples handling", by
2004.05.21 19:22 "Re: [Tiff] Extra samples handling", by Chris Cox

2004.05.21 19:22 "Re: [Tiff] Extra samples handling", by Chris Cox

At 9:05 AM +0000 5/21/04, wrote:

Hi chris,
thanks for the reply,

i still have this doubt whether multiple associated alpha channels are possible? if yes, the how do you un-premultiply the color values, for each of the associated alpha channels?

Multiple associated alphas are possible in theory - and there are no guidelines for how to handle that case.

I suspect it would depend on the application that generated the file, and what it intended the extra associated alpha channels to do (act as additional masks, or act as additional transparency). This boils down to: do you screen or multiply the associated alphas to create a final alpha?


Quoting Chris Cox <>:

At 11:05 AM +0000 5/20/04, wrote:

Please confirm if i am correct with the extra samples handling in TIFF images.


Type as 1(associated alpha): then the color values have to be taken as it is. also the number of extra channels will always be one only.

No, associated alpha means that it is transparency, and images will have to be un-premultiplied.

Type as 2(unassociated alpha): then all the color values have to be multiplied by the alpha channel value.

No - unassociated means that it is NOT transparency. And in no case would you multiply values when reading a TIFF -- the values in the TIFF file are premultiplied only if they have an associated alpha (transparency) channel.

Question 1: Are multiple unassociated alpha channels possible? If yes, then how are the final color values calculated?

Yes - unassociated alpha channels don't contribute anything to the color or transparency.

Type as 0(unspecified data): then the extra channels have to be simply ignored.

No, they can be loaded (as in Photoshop).

Question 2: Are combinations of Type 2 and Type 0 possible for a particular TIFF image?

Yes, of course.

You could even have all 3 types.

If yes, do we need to ignore the alpha channel/multilply the color values with the vaues of the color channel accordingly?

See above.