Archived

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

glEnable(GL_DEPTH_TEST)

This topic is 5584 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''m using glut to handle my window operations but when I enable depth testing nothing appears on the screen. The window is created with the GLUT_RGB|GLUT_DOUBLE|GLUT_DEPTH. I''ve tried to take of depth testing but it doesn''t make a difference. Any help would b e great.

Share this post


Link to post
Share on other sites
Make sure whatever you''re drawing is in your clip range (set in gluPerspective. Also, make sure your object isn''t being culled by being drawn in the wrong order. You might want to disable backface culling to test this.

Your depthfunc should be GL_LESS or GL_LEQUAL BTW.

____________________________________________________________
www.elf-stone.com

Share this post


Link to post
Share on other sites
Thanks a ton for the replys. You''d be amazed how much of a difference one letter can make. I wrote it GL_EQUAL instead of GL_LEQUAL. Thanks a lot.

Share this post


Link to post
Share on other sites