Texture colour bleeding

Started by
2 comments, last by lodi 20 years, 1 month ago
Hi, I am having problems texture mapping. The meshes are textured but the texture is coloured with the current drawing colour. Any ideas? Many thanks
Advertisement
if you dont want your textures colored call
glColor3f(1.0, 1.0, 1.0); right before you bind the texture.
If your texture color is bleeding off onto other things, try Disabling textures just after drawing them, enabling them just before drawing them.


glEnable(GL_TEXTURE_2D);

...
draw textured stuff

glDisable(GL_TEXTURE_2D);
"The meshes are textured but the texture is coloured with the current drawing colour."
------------------------

That''s OpenGL''s default behavior. Texture colours are multiplied by the drawing colour. If you want the texture''s colour to replace the drawing colour, use

glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_REPLACE);

after binding the texture.
______________________________________________There are only 10 types of people in the world: Those who understand binary, and those who don't.

This topic is closed to new replies.

Advertisement