View Full Version : QBS and the depthbuffer

05-27-2011, 04:34 AM

This question may sound stupid, but it occured to me today for the first time: is it right that in quadbuffered stereo mode, there exist left and right color buffers, but both share the same depthbuffer? So, in order to render left/right eye stuff, I have to clear the depthbuffer when switching to the other eye...

05-27-2011, 05:46 AM
Have a look at this link Quad Buffer stero example (http://www.orthostereo.com/geometryopengl.html)
Here the GL_BACK buffer is cleared and rendering occurs to GL_BACK_LEFT then GL_BACK_RIGHT buffers independantly.
So it does look as if there is 1 depth buffer for both left and right back buffer.

05-27-2011, 08:28 AM
No. Depth buffer can not be shared between eyes.

05-27-2011, 08:35 AM
No. Depth buffer can not be shared between eyes.

Please explain. I do not get the point of this statement. My current understanding is: GL_BACK_LEFT anf GL_BACK_RIGHT both use the same depthbuffer and that is why you have to clear the depthbuffer after finishing with one eye and before starting with the other.