View Full Version : Dunno if I'm being daft (textures)

04-09-2008, 12:43 PM

New here and fairly new to opengl...

Dunno if I'm being daft but there seems to be little information about how to change a texture once its loaded in.

Just wondered if there was any way to brighten or darken a texture.
glTexEnv seemed to be heading in sort of the right direction, where you can apply effects based on the underlying colour of the polygon but i don't think that's what I am after...

Any help really would be greatly appreciated,



04-09-2008, 01:31 PM
You're almost there. The texture env mode is set to GL_MODULATE by default. So if you change the color value using glColor the texture lookup will modulate this color.

e.g. If you set glColor(0.5,0.5,0.5,1.0), the result will be half as bright.