version 3.3

VRS::StereoRendererGL Class Reference

Class for specifying the parameters for stereo rendering. More...

#include <vrs/opengl/stereorenderergl.h>

Inheritance diagram for VRS::StereoRendererGL:

VRS::MultiSceneRenderer VRS::SharedObj VRS::Visitable

List of all members.

Public Types

enum  ColorMode { CM_HardwareStereo, CM_RedCyan }

Public Member Functions

 VRS_SERIALIZABLE_CLASS_ENUM (ColorMode)
 StereoRendererGL (double eyeDistance=0.3, ColorMode colorMode=CM_HardwareStereo, const Vector &eyeDirection=Vector(1.0, 0.0, 0.0))
 Scene Renderer for synthesizing stereo images.
void setEyeDistance (double eyeDistance)
double getEyeDistance () const
void setEyeDirection (const Vector &eyeDirection)
Vector getEyeDirection () const
void setColorMode (ColorMode colorMode)
ColorMode getColorMode () const
virtual void start (Engine *)
 Starts stereo frame rendering.
virtual void stop (Engine *)
 Stops stereo frame rendering.
virtual bool needSceneEvaluation (Engine *)
 Stereo rendering requires one evaluation for the left and one for the right eye.
virtual void preEvaluateScene (Engine *)
 Sets the appropriate draw buffer in OpenGL.
virtual void postEvaluateScene (Engine *)
 Resets the draw buffer.
 VRS_TYPEINFO (StereoRendererGL, MultiSceneRenderer)
 VRS_SERIALIZABLE (StereoRendererGL)


Detailed Description

Class for specifying the parameters for stereo rendering.

Member Enumeration Documentation

Enumerator:
CM_HardwareStereo 
CM_RedCyan 


Constructor & Destructor Documentation

VRS::StereoRendererGL::StereoRendererGL ( double  eyeDistance = 0.3,
ColorMode  colorMode = CM_HardwareStereo,
const Vector eyeDirection = Vector(1.0, 0.0, 0.0) 
)

Scene Renderer for synthesizing stereo images.

Stereo rendering requires two evaluations of the scene graph: one for rendering into the right back buffer, the other for rendering into the left back buffer. A StereoRendererGL cares about that. It also pushed a Stereo attributes onto the engine as hint for the camera from which eye the current scene is rendered. The eyeDirection specifies the direction from the left eye to the right eye with respect to the viewing device and therefore defaults to from left to right.


Member Function Documentation

VRS::StereoRendererGL::VRS_SERIALIZABLE_CLASS_ENUM ( ColorMode   ) 

void VRS::StereoRendererGL::setEyeDistance ( double  eyeDistance  ) 

double VRS::StereoRendererGL::getEyeDistance (  )  const

Eye distance adjusts the view to the left or right eye respectively.

void VRS::StereoRendererGL::setEyeDirection ( const Vector eyeDirection  ) 

Vector VRS::StereoRendererGL::getEyeDirection (  )  const

Eye direction specifies the left to right eye direction with respect to the viewing device.

void VRS::StereoRendererGL::setColorMode ( ColorMode  colorMode  ) 

ColorMode VRS::StereoRendererGL::getColorMode (  )  const

The color mode is used; if the hardware does not support stereo viewing, it will automatically switches to red/cyan mode.

virtual void VRS::StereoRendererGL::start ( Engine  )  [virtual]

Starts stereo frame rendering.

Implements VRS::MultiSceneRenderer.

virtual void VRS::StereoRendererGL::stop ( Engine  )  [virtual]

Stops stereo frame rendering.

Implements VRS::MultiSceneRenderer.

virtual bool VRS::StereoRendererGL::needSceneEvaluation ( Engine  )  [virtual]

Stereo rendering requires one evaluation for the left and one for the right eye.

Implements VRS::MultiSceneRenderer.

virtual void VRS::StereoRendererGL::preEvaluateScene ( Engine  )  [virtual]

Sets the appropriate draw buffer in OpenGL.

Implements VRS::MultiSceneRenderer.

virtual void VRS::StereoRendererGL::postEvaluateScene ( Engine  )  [virtual]

Resets the draw buffer.

Implements VRS::MultiSceneRenderer.

VRS::StereoRendererGL::VRS_TYPEINFO ( StereoRendererGL  ,
MultiSceneRenderer   
)

VRS::StereoRendererGL::VRS_SERIALIZABLE ( StereoRendererGL   ) 


The documentation for this class was generated from the following file:

Generated on Wed May 23 06:00:22 2012 by Doxygen 1.5.6
© 2001-2010 Hasso-Plattner-Institut | Impressum | Contact