problems converting 32bit bmp with alpha to 32bit tga

Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Post Reply
ricgreen1

problems converting 32bit bmp with alpha to 32bit tga

Post by ricgreen1 »

Whenever I try to convert a 32bit bmp with alpha to a 32bit tga with alpha, the alpha channel gets set to white instead of the alpha channel that is present in the source bmp. I tried all kinds of settings including

convert -matte -depth 32 c:\photo.bmp c:\photo.tga

and nothing seems to work :(

The bmp was created using photoshop cs3

Thanks!
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: problems converting 32bit bmp with alpha to 32bit tga

Post by fmw42 »

try

convert <inputimage> -channel RGBA -matte <outputimage>
ricgreen1

Re: problems converting 32bit bmp with alpha to 32bit tga

Post by ricgreen1 »

Unfortunately that gave me a white (blank) alpha as well. none of the alpha info ended up in the tga. :(
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: problems converting 32bit bmp with alpha to 32bit tga

Post by fmw42 »

The only other thing I can think of is to use -compose copy_opacity -composite

see
http://www.imagemagick.org/Usage/compose/#copyopacity
Post Reply