Hi Anthony, Thanks for your information. > By default IM treats transparent and semi-transparent colors > as just another color. However two years ago a change was > may so as to make full-transparent any-color mean the same > thing. EG transparent-black is also transparnet white.
OK, that's what I'm looking for :) > See IM Examples, Quantization and transparency. > http://www.imagemagick.org/Usage/quantize/#color_trans Yes, that's concrete proof of what you said. It's doing exactly what I want, but with PNGs. > As for TGA. No one has reported in the list or forums what > IM does for these images, and if or how it handles 'indexed TGA'. My experience is that when IM saves a TGA, it saves one of the following: 1) 32 bit 2) 24 bit 3) 8 bit indecies into a 24 bit palette Taking alpha_gradient.png from the example page you gave me: $ convert alpha_gradient.png alpha_gradient.tga produces a 32 bit TGA which looks exactly like the PNG $ convert alpha_gradient.png +matte alpha_gradient.tga produces a 24 bit TGA, discarding the alpha channel $convert alpha_gradient.png -colors 256 alpha_gradient.tga produces a 8 bit index / 24 bit palette TGA. The image is opaque Up until now, one of the three above has always been what I've needed, so I've never had a problem before. But what I'm trying to persuade it to do now is to save 8 bit indexed into a 32 bit palette. I've been reading through the TGA format spec http://www.dca.fee.unicamp.br/~martino/disciplinas/ea978/tgaffs.pdf and it sounds like it ought to be possible (see "Color Map Specification"). Do you think that's worthy of a bug report / feature request? If not, what I'll end up doing is the following: convert {source} -colors 256 -type TrueColor output.tga (which produces a 32 bit TGA with alpha values, up to 256 unique 32-bit values in the image) ... and then write my own code to move the colors from the image into the palette. Do you have any opinions? Thanks, Peter Pimley __________________________________________________________________________________________________________________________________________ Information contained in this e-mail is intended for the use of the addressee only, and is confidential and may be the subject of Legal Professional Privilege. Any dissemination, distribution, copying or use of this communication without prior permission of the addressee is strictly prohibited.The views of the author may not necessarily constitute the views of Kuju Entertainment Ltd. Nothing in this email shall bind Kuju Entertainment Ltd in any contract or obligation. The contents of an attachment to this e-mail may contain software viruses which could damage your own computer system. While Kuju Entertainment has taken every reasonable precaution to minimise this risk, we cannot accept liability for any damage which you sustain as a result of software viruses. You should carry out your own virus checks before opening the attachment. Kuju Entertainment Ltd trading as Zoe Mode Registered Office : 10 Woodside Park, Catteshall Lane, Godalming, Surrey, UK, GU7 1LG. Company Number : 3481384. Company Registered in England. __________________________________________________________________________________________________________________________________________ This email has been scanned by the MessageLabs Email Security System. For more information please visit http://www.messagelabs.com/email _________________________________________________________________________________________________________________________________________ _______________________________________________ Magick-users mailing list [email protected] http://studio.imagemagick.org/mailman/listinfo/magick-users
