Hello, I need get the correct 'transparency' value when using DecodeImage, correct means the source format does has alpha channel, but now for BMP files I always get PIXEL_FORMAT__BGRA_NONPREMUL even for 24bpp non-alpha files.
In SelectPixfmt, I use ic.pixcfg.pixel_format().transparency(), which comment as "the image file's natural pixel format", does this pixel_format mean to have the correct transparency value or is there another way to get what I want?
Hello, I need get the correct 'transparency' value when using
DecodeImage
, correct means the source format does has alpha channel, but now for BMP files I always getPIXEL_FORMAT__BGRA_NONPREMUL
even for 24bpp non-alpha files.My example code can be found here: https://github.com/iyzsong/onscripter-libretro/blob/main/sdl-libretro/SDL_image.cpp
In
SelectPixfmt
, I useic.pixcfg.pixel_format().transparency()
, which comment as "the image file's natural pixel format", does this pixel_format mean to have the correct transparency value or is there another way to get what I want?Thanks.