I would like to use Png images while working in C++ Builder RAD Studio XE6. I am using graphics32 lib and I managed to install runtime and designtime packages. I can put the TImage32 component on my form, then I load the png image in TImage32, but instead of transparency, I get white color on the background. I just cant see what do I have to do, to get transparent png image on my form.
I would be very thankful for your help.
Out of the box Graphics32 does not support any other format than Bitmap (BMP). In order to use the PNG format its necessary to use an additional library, especially when you want to maintain full transparency information.
One of these libraries that was meant to work hand in hand with Graphics32 is GR32PNG. However, this library is not meant to be used at design time for various reasons. One of these is the fact that even with an available design time package, Graphics32 was never designed to support any other format than Bitmap (*.bmp). Thus, it would be required to rewrite parts of Graphics32 to support other formats (which hasn't been done so far).
Alternatively, it should be possible to use the built-in support of XE6 to load PNG files. This won't be design time either (for the same reasons) and sometimes it doesn't handle transparency properly. Not to mention the fact that it converts the image to TImage before, which typically doubles the required amount of memory during loading.