Convert indexed PNG with transparency to RGBA?

Discussions on NConvert - the command line tool for image conversion and manipulation

Moderators: XnTriq, helmut, xnview

Post Reply
rkwright
Posts: 6
Joined: Mon Mar 16, 2009 2:51 pm

Convert indexed PNG with transparency to RGBA?

Post by rkwright »

I have an indexed PNG, where index 25 is transparent.

Using nconvert, is there a way to convert this to RGBA, where the alpha for the pixels that were index 25 now have an alpha of zero?
-- basically just the image/32bits menu option from XnView
rkwright
Posts: 6
Joined: Mon Mar 16, 2009 2:51 pm

Re: Convert indexed PNG with transparency to RGBA?

Post by rkwright »

In writing the post I answered my own question - use the -32bits flag...

"C:\Program Files (x86)\XnView\nconvert.exe" -overwrite -add_alpha 255 -merge_alpha -ctype rgba -32bits -out png -clevel 8 -o out.png in.png
Post Reply