lesson05 and diffuse light
so how can i render one of the object with diffuse light and the other without that, till now if i add glEnable(GL_LIGHT0),glEnable(GL_LIGHTING),glEnable(GL_COLOR_MATERIAL) to InitGL, i affect everything, so how would i go if i only want to affect the cube or the pyramid.
Move the glEnable(GL_LIGHTING) to just before the code that draws the object to be affected, and then put a glDisable(GL_LIGHTING) just after.
www.flashbang.se | www.thegeekstate.com | nehe.gamedev.net | glAux fix for lesson 6 | [twitter]thegeekstate[/twitter]
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement