PDA

View Full Version : let there be LIGHT.



psybases
01-08-2003, 02:48 PM
Hi.

Imagine a torus and a icosahedron on a 3d scene. Say ,for example, that each facet of the above objects is rendered with a slightly different color so that the torus
is colored with shades of blue and the icosahedron with shades of green.
When i enable lighting on OpenGL , both objects look different from what they were colored.They are colored in a shade of gray.
Is it possible to have lighting enabled and both objects be colored with their original color shades ?

Bob
01-08-2003, 03:17 PM
When lighting is enabled, you use materials to set the color of the objects. Have a look at glMaterial.