• Advertisement

Archived

This topic is now archived and is closed to further replies.

GL Lights from Tutorials

This topic is 6253 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I can''t seem to get the lights to work properly in my program. When I do the tutorial it works but in my program when lighting is enabled it is very dark and won''t change no matter what I do.

Share this post


Link to post
Share on other sites
Advertisement
Guest Anonymous Poster
It can be anything but a common problem is to set the normals correct.

Share this post


Link to post
Share on other sites
I just learned about lighting myself, and I had that same problem. It was fixed as soon as I defined materials for my vertices. Look up glMaterialfv and it may fix your problem.

Share this post


Link to post
Share on other sites
try this
float amb[] = {10,10,10,10};
glLightfv(...,GL_AMBIENT,amb);

http://members.xoom.com/myBollux

Share this post


Link to post
Share on other sites

  • Advertisement