Page 1 of 1

How to convert transparent backgrounds to black color backgrounds?

Posted: Mon Sep 23, 2024 9:08 am
by xinni
Hello my helping friends :-)

I'm trying to batch convert some pngs with transparent background to jpeg format with black background color, but XNViewMP only converts them to white background files.

I only found this posting, which is from 2018, telling me, there might be an option to select the background color, but I don't know all the terminology to find that specific option.

I asked chat-gpt too, but after 20 minutes of hallucinating answers, I did not had a solution. :-(

I think this must be too simple so I cannot find it...

Re: How to convert transparent backgrounds to black color backgrounds?

Posted: Mon Sep 23, 2024 10:07 am
by user0
if you convert:
- 32bit image - run as is
- indexed - also enable "Transparent color" action (any color/any tolerance, no idea why :D )

batch_convert_to_24bit.png
batch_convert_to_24bit.png (9.08 KiB) Viewed 1632 times

related
General - canvas background color - improve consistency of use

Re: How to convert transparent backgrounds to black color backgrounds?

Posted: Mon Sep 23, 2024 12:14 pm
by cday
xinni wrote: Mon Sep 23, 2024 9:08 am I'm trying to batch convert some pngs with transparent background to JPEG format with black background color...
... then set Output tab format to JPEG with your desired saving settings.

Re: How to convert transparent backgrounds to black color backgrounds?

Posted: Wed Oct 30, 2024 7:50 am
by xinni
cday wrote: Mon Sep 23, 2024 12:14 pm
xinni wrote: Mon Sep 23, 2024 9:08 am I'm trying to batch convert some pngs with transparent background to JPEG format with black background color...
... then set Output tab format to JPEG with your desired saving settings.
Out of curiosity and because your solution reads so easy, where would I do that?

This is what I see:
Batch convert.png

Re: How to convert transparent backgrounds to black color backgrounds?

Posted: Wed Oct 30, 2024 7:54 am
by xinni
user0 wrote: Mon Sep 23, 2024 10:07 am if you convert:
- 32bit image - run as is
- indexed - also enable "Transparent color" action (any color/any tolerance, no idea why :D )
Thank you,
"run as is" did not work, or I can't figure out what you mean by that.

The only way, I could get it to work (for 32Bit images) is this:
32bit_works.png
That seems odd to me, when I read both of your "easy" ways to do it.