#define S_DOCUMENTATION #define S_DOCUMENTATION_DEVELOPER #define PAGE Documentation #define SUBPAGE Developer #define TITLE Stereo and Head Tracking #include "header.shtml"

Author: eilemann@gmail.com
State: Implemented in 0.2

Overview

For stereo viewing, typically two different views are rendered, one for each eye. The display setup ensures that each eye sees the correct view, either by time-multiplexing the left/right images (active stereo) or by using polarization filters (passive stereo). Some autostereoscopic or holographic displays require more than two views, since the project to multiple viewer positions in space.

Head tracking is often used with stereo rendering. The viewer position is tracked, and the rendering is adapted to give the observer the illusion of a fixed scene in 3D space.

Stereo Rendering

View frustum for monoscopic rendering
Monoscopic View Frustum

Equalizer uses the notion of an eye pass in the compound specification. If nothing is specified, the compound renders one view for monoscopic viewing, for the CYCLOP eye, as shown on the right. With the compound's eye field the eye passes are specified. The eye passes are inherited to children, unless the children overwrite the eye field.

View frustra for stereo rendering
Stereoscopic View Frustra

To use active stereo, the window has to have a stereo visual and the compound has to specify the left and right eye using eye [ LEFT RIGHT ]. Equalizer then executes two rendering passes, and uses the eye base to adjust the view frustra as shown on the left.

For passive stereo, two output channels are used and projected onto the same surface. Typically two compounds would be used, one rendering the left eye using the channel connected to the left projector, and the other rendering the right eye using the same wall description.

The window attribute hint_stereo can be used to request a quad-buffered stereo visual. The distance between the left and right eye is specified using the config attribute eye_base.

Immersive Visualization

Head Tracking with stereo frustra
Stereo Frustra with Head Tracking

For immersive installations, the head position is tracked and view frustra are adapted to the viewers position and orientation, as shown on the right. The head position is reported by the application using Config::setHeadMatrix, which is used by the server to compute the eye positions (cyclop, left, right). These eye positions, together with the wall description, are used to compute an OpenGL frustum and the head transformation to position the frustum. The default head matrix is an identity matrix, thus the default eye positions are ( +-eye_base/2, 0, 0 ), as show above in the stereoscopic view frustra.

Eye compounds

Eye compounds parallelize the rendering of the eye passes, by assigning each eye pass to a different channel and recombining the result. For passive stereo, where the channels are separated for display, parallelization can be achieved by using a different pipe (graphics card) for each channel. For active stereo, one of the eyes can be rendered on a different pipe and transferred to the correct draw buffer using the compound output and input frames. The Equalizer distribution contains example config files.

API

  void Config::setHeadMatrix( const vmml::Matrix4f& matrix );

File Format

    global
    {
        EQ_CONFIG_FATTR_EYE_BASE            float
        EQ_WINDOW_IATTR_HINT_STEREO         OFF | ON | AUTO
    }
    config // 1-n times, currently only the first one is used by the server
    {
        attributes
        {
             eye_base float // distance between left and right eye
        }
    }
    window
    {
        attributes
        {
            hint_stereo         off | on | auto
        }
    }
    compound
    {
        eye      [ CYCLOP LEFT RIGHT ]   // monoscopic or stereo view
    }

Open Issues

Autostereoscopic displays with multiple views - define new eye passes?

#include "footer.shtml"