Use of Stencil Buffer

Hi everyone!
I’m having some trouble with the use of stencil-buffer.
My problem is that we aquaired an autostereoscopic Display and I wanted to test, if future applications written in jogl will be able to supprt the needed nesting of the renderings. To better explain: These Displays have some prisms on them that split a picture so that you can watch scenes in “true 3D” on them without any glasses or stuff like that. The Display we have is working with “vertical Interlace” which means that the information of the left-eye-picture is in every odd column while the right-eye-picture is in the even columns of the picture. The idea is to set up a stencil buffer filled with alternating columns of 1’s and 0’s. Then I could render the left-eye-picture using the stencil-Buffer-mode “equal” and after that turning the stencil-buffer-mode to “notequal” and render the right-eye-picture. I do have an example of that written in C++ but it uses pointer-arithmetics to calculate the stencil-buffer… :frowning:
Anyone has some experience with that topic? Any help is appreciated.

Thanks in advance…

…Hoschi_S

Hello,

Xith3D has support for stencil buffer writing/testing. There is also test for stencil buffer available. Maybe this will help a bit…

Yuri

Sorry for the late reply. The Xith-source-code helped a little and that together with some Red-book-reading and trial-and-error helped me in the end. I have it now. Thanks for the tip, Yun!

Greetz…

…Hoschi_S