Transparent Areas on models

Blitz3D Forums/Blitz3D Programming/Transparent Areas on models

cash(Posted 2004) [#1]
I have seen some posts relating to this but have not been able to sort it out.

heres the question..

I have a .b3d model created and exported from milkshape..

I want the black areas of the texture to appear transparent when loaded. The texture is loaded from a single bmp file associated and exported with the model, therefore it is mot actually loaded in the game separately from the loadmesh command.


mearrin69(Posted 2004) [#2]
I don't know if this will work or not, but you *could* reload the texture and reapply it - then you can try out the texture flags to see if they give you the transparency. I've never tried this so I don't know if it works or not.
M


Ross C(Posted 2004) [#3]
Don't apply the textures in your modeeler, and then load them in using the mask or alpha flag, as mearinn says. That should work :)


jfk EO-11110(Posted 2004) [#4]
you can always use the Texturefilter, also with Textures which are loaded automaticly. try this:

CLearTexturefilters
texturefilter "",2 or 9

load whatever you need to load with alphaflag on

cleartexturefilters
texturefilter "",9 ; reset to default mode


cash(Posted 2004) [#5]
Perfet JFK thanks


cash(Posted 2004) [#6]
Or even Perfect....

Thanks Jfk


jfk EO-11110(Posted 2004) [#7]
N/P


cash(Posted 2004) [#8]
Now heres another related question...

Using blitz itself I am using texturefilter,4 to make black transparent. Works fine without any modification to the alpha mapping on the model.

Now, without changing the model in any way, is there a way to tell blitz to use another colour rather than black to make transparent.

Like I said a value of 4 defaults to black transparent. can this be changed ?


Ross C(Posted 2004) [#9]
You need to write this using readpixel/write pixel. Read the colour from the texture pixels, then write them back, putting the alpha colour in as well.