//select projection matrix
GlMatrixMode (GL_PROJECTION);
GlLoadIdentity ();
GluPerspective (60.0, w/h, 1.0, 100.0);//
perspective projection matrix was establishedGlMatrixMode (GL_MODELVIEW);
GlLoadIdentity ();

CodePudding user response:
The bosses, can try open the depth test: glEnable (GL_DEPTH_TEST), and in a loop use glClear (GL_DEPTH_BUFFER) refresh the depth buffer,CodePudding user response:
Thank you, have the test pass