PDA

View Full Version : create depth texture , nearplane, question



lobbel
08-11-2009, 01:59 AM
Hello,
how can I render the depth values of the near plane into
a depth texture ? i need the z values to compare with
geometry.

regards,
lobbel

kolja
08-11-2009, 06:29 AM
You can use an FBO, and attach a texture to the depth attachment point (glFramebufferTexture2DEXT(GL_FRAMEBUFFER_EXT, GL_DEPTH_ATTACHMENT_EXT, ...).