7

We have been considering buying a 3D-ready LCD monitor along with a machine with a 3D-stereoscopic vision capable graphics card (ATI Radeon 5870 or better). This is for displaying some scientific data that we are rendering in 3D using OpenGL. Now can we expect the GPU, Monitor and shutter-glasses to take care of the stereoscopic display or do we need to modify the rendering program? If there are specific techniques for graphics programming for 3D stereoscopic displays, some tutorial links will be much appreciated.

subhacom
  • 774
  • 8
  • 24

1 Answers1

9

Techically OpenGL provisions for stereoscopic display. The keyword is "Quad Buffered Stereo". You can switch left-right eye rendering with glDrawBuffer(GL_BACK_LEFT); /* render left eye view */; glDrawBuffer(GL_BACK_RIGHT); /* render right eye view */;.

Unfortunately Quadbuffer stereo is considered a professional feature by GPU vendors. So you need either a NVidia Quadro or a AMD/ATI FireGL graphics card to get support for it.

Stereoscopic rendering is not done by tilting the eyes, but by applying a "lens shift" in the projection matrix. The details are a bit tricky, though. I did a talk last year about it, but apparently the link with my presentation slides went down.

The key diagram is this one (it's from my notes of my patch to Blender to directly support stereoscopic rendering) Stereoscopy parameters

datenwolf
  • 149,702
  • 12
  • 167
  • 273
  • That was very useful information. The Radeon HD5870 spec: "3D stereoscopic display/glasses support" confused me. After googling around for opengl quad buffer on linux, I suspect this may not even possible on linux. On the other hand [this](http://www.gali-3d.com/archive/articles/StereoOpenGL/StereoscopicOpenGLTutorial.php) talks about some way to display stereo without quad buffer. Any idea if this is possible on consumer grade GPUs? – subhacom Sep 20 '11 at 11:39
  • What about render buffers? How to swap them in synch with the monitor? The only solution for this case is the use of 2 projectors? – Luca Sep 20 '11 at 11:48
  • @Luca Piccioni: Quadbuffer stereo delegates the swapping/shutter work to the driver; synching to the shutter in one own's code is possible, but unreliable. – datenwolf Sep 20 '11 at 11:59
  • 4
    @subhacom: There are several way to display stereo without quadbuffers. The probably easiest is to open two OpenGL windows on a dualscreen system and use passive stereo, i.e. polarizing filters in front of two carefully aligned video projectors projecting onto a polarization-preserving screen, also called silver screen. Another method, but this requires some electronics skills, is using a Matrox DualHead2Go, which splits a 2048×768 picture in two 1024×768 and delivers it to two displays in sync - add a circuit that switches between outputs every frame, and deliver the sync to shutter flasses. – datenwolf Sep 20 '11 at 12:03