Page 1 of 1
Converting PNG with transparency to TGA with transparency
Posted: 2014-01-24T12:20:22-07:00
by WGH
Hello.
I might be missing some obvious option, but I'm having trouble converting PNG with transparency to TGA with transparency.
Calling 'convert test.png test.tga' gives some weird image. I tried to convert it to GIF, just to be sure, and ImageMagick gave me correct result.
png-tga-gif comparison screenshot
test.png
Re: Converting PNG with transparency to TGA with transparenc
Posted: 2014-01-24T12:59:17-07:00
by fmw42
this seems to work for me on IM 6.8.8.2 Q16 Mac OSX
convert 1390591139-nO.png -alpha on -channel rgba 1390591139-nO.tga
Re: Converting PNG with transparency to TGA with transparenc
Posted: 2014-01-24T13:22:27-07:00
by WGH
My apologies. It was Photoshop not supporting it. ImageMagick was doing it right (even without additional options).
Re: Converting PNG with transparency to TGA with transparenc
Posted: 2014-01-24T13:44:01-07:00
by fmw42
The difference is that PS interprets the PNG transparency as Background transparency. But it interprets the TGA transparency as an alpha channel. If you look at the channels in both images in PS you will see that both have transparency, just different kinds. I suspect that TGA does not support background transparency, but does support alpha channel transparency. However, I am no expert on either PS or TGA format.
Re: Converting PNG with transparency to TGA with transparenc
Posted: 2014-01-24T14:28:17-07:00
by WGH
You're right.
Honestly though, I don't really get the difference between alpha channel and transparency here. In both PNG and TGA there's only one one alpha channel - it's just RGBA color space after all. Why does Photoshop interpret them differently? I have no idea.
I guess alpha channel (as opposed to transparency) makes sense in more complex formats, where there can be many of them.
Re: Converting PNG with transparency to TGA with transparenc
Posted: 2014-01-24T15:05:09-07:00
by fmw42
Pretty much only PS uses background transparency.