glEnable(GL_DEPTH_TEST)

Started by
2 comments, last by Jonbca 21 years, 7 months ago
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.
Advertisement
You try setting a depth test function like GL_LEQUILS.
------------------------------------------------------------I wrote the best video game ever, then I woke up...
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

____________________________________________________________www.elf-stone.com | Automated GL Extension Loading: GLee 5.00 for Win32 and Linux

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.

This topic is closed to new replies.

Advertisement