PDA

View Full Version : Problem of depth buffer



pongkm
07-29-2001, 03:08 AM
I have a proble to draw complex object
the surface is incorrect z buffer in opengl.
Have any solution for fix it?.

Bob
07-29-2001, 04:33 AM
You must give us more information that just saying something is wrong. It can be a whole lot of stuff. Did you ask for a depthbuffer? Did you enable it? What depthfunction do you use? What values did you pass as near and far clipping planes?

pongkm
07-30-2001, 02:03 AM
// draw Model;

glDepthMask(GL_FALSE);
glDepthFunc(GL_EQUAL);

glEnable(GL_BLEND);
glBlendFunc(GL_ZERO, GL_SRC_COLOR);
// draw Model;
glDisable(GL_BLEND);

glDepthMask(GL_TRUE);
glDepthFunc(GL_LESS);

Bob
07-30-2001, 07:44 AM
What is suppose to happen in your program, and what is happening now? I still don't know whats wrong and therefore can't help much.