Page 1 of 1

Black in back of opengl cube example,how do u get rid of it?

Posted: Mon Aug 23, 2004 4:56 am
by coderchris
In the opengl cube example, when the cube is at a cirtain angle, cirtain parts of the cube that are past a cirtain z-point will disapear...why is this and how can i get rid of it?

The disapearing im talking about is circled in red:

Image

Posted: Mon Aug 23, 2004 1:43 pm
by DarkDragon
download the glwrapperlibrary at purearea.net and try this code before the main-loop:

Code: Select all

glMatrixMode_(#GL_PROJECTION)
glLoadIdentity_()
gluPerspective__(0.0, WindowWidth()/WindowHeight(), 0.001, 10.0) ;The last param is the seeing range.
glMatrixMode_(#GL_MODELVIEW)

Posted: Mon Aug 23, 2004 6:36 pm
by coderchris
Thanks a ton :D :D