Problem with MaxGUI drag n drop.
BlitzMax Forums/BlitzMax Beginners Area/Problem with MaxGUI drag n drop.
| ||
I'm trying to adapt the drag and drop MaxGui image example and it doesn't do transparency correctly. It wants to use a mask color AND the native alpha channels. So anything black is transparent and the normal alpha channel is also transparent. I just want images with alpha channels transparent not a alpha mask color in addition. |
| ||
You might want to post your adapted code. |
| ||
I assume you talk of canvas. Within those you either have alpha OR mask color. not both as the blend modes disables the other effect. The only way to have both is to use alphablend and preproprocess the pixmap by rewriting all black pixels to be black with alpha 0 |
| ||
You need to use LoadImage("Filename.png",0) or LoadImage("Filename.png",FILTEREDIMAGE). LoadImage defaults to MASKEDIMAGED|FILTEREDIMAGE which will set all the alpha bits to 0 wherever the mask color is in the image. |
| ||
I sort of fixed it. For some reason it wanted to make non alpha images have an alpha channel. It now just sets the blend mode to solid if the image is not a png. |