Quote:Original post by AAAP
I don't know... I've never seen a Targa image with any greater than on/off alpha layers... Photoshop CS 2 won't write targas with 32bit RGBA... probably you're thinking of some spinoff of targa that's not directly in line with the targa specification... a 32bit targa has 1 byte for rgb and A is true, but in the specification, the "A" (attribute, btw) is meant to be an on/off. You can even have 16 bit targas with an alpha channel.. where the alpha is defined as on or off by 1 single bit.
I think you're confusing the TGA format with GIF, which has indeed only a boolean alpha channel (or better, a transparent colour). TGA has not. In fact, 32bit TGAs (A8B8G8R8) are very common in graphics programming as an intermediate format. Photoshop has no problems writing 32bit TGA, and neither have Gimp, 3DSMax, Maya, and pretty much every other application that can read or write TGAs.
In the very first versions of the format, there was a way to specify the number of alpha bits in the attribute layer: bit0 - 3 of the last header byte. So you could have anything from 0 to 15 bits for the alpha channel. This field was later reassigned to another use, so the number of alpha bits is now deduced from the pixel depth field. A pixel depth of 32 means the common A8B8G8R8 format.
Later on, when TGA was extended with additional (optional) footers, support for things like premultiplied alpha was added (see field 24 of the specs).