PDA

View Full Version : Problem with blending



Hertsog
12-21-2004, 04:39 PM
I want to draw textured polygons, which have holes in it, using blending (Alpha 0). The problem is that I want that the other areas, all but the holes, would not mix up with the colours behind it. Which parameters do I have to use on glBlendFunc and glTexEnvf and wherever else needed?

CrazyButcher
12-22-2004, 02:04 AM
if its a non-transparent object then its cheaper/faster using alphatest/alphafunc for this
else for the blendfunc it would be
GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA

Hertsog
12-22-2004, 04:01 AM
Many Thanks! Using AlphaTest now, works fine :)