🎉 Celebrating 25 Years of GameDev.net! 🎉

Not many can claim 25 years on the Internet! Join us in celebrating this milestone. Learn more about our history, and thank you for being a part of our community!

Problem with Texture Lighting

Started by
1 comment, last by FireViper 18 years, 3 months ago
I was trying to add lighting to my game engine, but it seems that all the objects with texture aren't affected by it. If I remove the texture, then it works just fine. Its probably something simple, but I'm not really sure what I'm doing wrong. Anyone have an idea?
Advertisement
To use textures with lighting you'll need to let OpenGL know that you want them blending together with:
glEnable(GL_COLOR_MATERIAL);
Hope that sorts it for you. [smile]
--
Cheers,
Darren Clark
I've tried enabling GL_COLOR_MATERIAL, but still dosen't work.

This topic is closed to new replies.

Advertisement