Alpha problems when loading B3D

BlitzMax Forums/MiniB3D Module/Alpha problems when loading B3D

Hezkore(Posted 2008) [#1]
I'm having some alpha problems when loading my B3D level.



As you can see the transparent part is just black.
Is this my fault?, do I have to enable alpha on the model or something?
I've tried to save the PNG in Photoshop and GIMP, both have the same result.


GfK(Posted 2008) [#2]
You need to set up TextureFlags to load textures with alpha/masking flags set.

I assume MiniB3D has TextureFlags like BB3D does.


Hezkore(Posted 2008) [#3]
But the B3D model of the level itself loads the textures, I have no LoadTexture fuction in my code, only LoadMesh.


simonh(Posted 2008) [#4]
You need to use the TextureFilter command. Change your alpha texture names to include a tag (say _alpha), and then use this tag with the flag 3, like so:

TextureFilter,"_alpha",3

Use this after the Graphics3D command, but before you load your model.


GfK(Posted 2008) [#5]
TextureFilter! That's what I meant!


Hezkore(Posted 2008) [#6]
Yep, works great... Cheers everyone!