OpenSGApplicationBase Class Reference

#include <OpenSGApplicationBase.h>

Inherits ApplicationBase.

Inherited by GoingImmersive, GoingImmersive, GoingImmersive, GoingImmersive, GoingImmersive, GoingImmersive, MedievalTownAppBase, MedievalTownPhysics, MedievalTownPhysics, MedievalTownPhysics, MedievalTownPhysics, MedievalTownPhysics, and MedievalTownPhysics.

Collaboration diagram for OpenSGApplicationBase:

List of all members.


Public Member Functions

 OpenSGApplicationBase ()
virtual ~OpenSGApplicationBase ()
void setRootNode (OSG::NodePtr root)
void setStatistics (bool onOff)
void setWireframe (bool onOff)
void setHeadlight (bool onOff)
bool setBackgroundImage (std::string imageUrl, int windowIndex=-1)
void activateShadows (OSG::NodePtr lightNode)
void activateShadows (const std::vector< OSG::NodePtr > &lightNodes)
void setPhysicalToWorldScale (float scale)
void setNearClippingPlane (float nearPlane)
void setFarClippingPlane (float farPlane)
void setEyeSeparation (float eyeSeparation)
float getEyeSeparation ()

Protected Member Functions

virtual std::string getConfigFile (const CommandLineArgumentWrapper &args)=0
virtual bool preInitialize (const CommandLineArgumentWrapper &args)
virtual bool initialize (const CommandLineArgumentWrapper &args)=0
virtual void initCoreComponentCallback (CoreComponents comp)
virtual void initInputInterfaceCallback (ModuleInterface *moduleInterface)
virtual void initOutputInterfaceCallback (ModuleInterface *moduleInterface)
virtual void initModuleCallback (ModuleInterface *module)
virtual void display (float dt)=0
virtual void cleanup ()=0
virtual void cbGlutSetWindowSize (int w, int h)
virtual void cbGlutMouse (int button, int state, int x, int y)
virtual void cbGlutMouseMove (int x, int y)
virtual void cbGlutKeyboard (unsigned char k, int x, int y)
virtual void cbGlutKeyboardUp (unsigned char k, int x, int y)

Private Member Functions

bool preInit (const CommandLineArgumentWrapper &args)
bool init (const CommandLineArgumentWrapper &args)
void run ()
void _initializeOpenSGNodes ()
void _setupCamera ()
void _cleanup ()
int _setupGLUT (const CommandLineArgumentWrapper &args)

Static Private Member Functions

static void _setWindowSize (int w, int h)
static void _display ()
static void _mouse (int button, int state, int x, int y)
static void _mouseMove (int x, int y)
static void _keyboard (unsigned char k, int x, int y)
static void _keyboardUp (unsigned char k, int x, int y)

Private Attributes

bool _preInitCalled
 Variable for checking if preInit was called correctly.
bool _initCalled
 Variable for checking if init was called correctly.
bool _mouseInterrupt
 Defines if mouse is warped into window or not.
bool _showStatistics
 Defines if statistics of SceneManager are displayed.
bool _useSensorMouse
 Defines if sensor-emulation is used or not.
bool _useShadows
 Defines if Shadows are activated or not.
bool _rootNodeSet
 Defines if the root-node was already set.
OSG::NodePtr _appRootNode
 Root node of application.
OSG::MaterialGroupPtr _appWireframeCore
 Alternative core for wireframe rendering.
std::vector< OSG::NodePtr > _lightNodes
 Stores light nodes for shadow calculation.
OSG::SimpleSceneManager * _smgr
 SceneManager for desktop / single display systems.
int _winid
 ID of GLUT window.
OSG::GLUTWindowPtr _gwin
 Pointer to GLUT window.
OSG::MultiDisplayWindowPtr _mwin
 Pointer to Multi-display window.
OSG::CAVESceneManager * _csmgr
 CAVESceneManager instance.
OSG::CAVEConfig _caveCfg
 Configuration for CAVESceneManager.
bool _useCSM
 Define if CAVESceneManager is used or not.
bool _useControlWindowImage
 Defines if a image for the control window is used.
float _farClippingPlane
 Defines farClippingPlane.
float _nearClippingPlane
 Defines farClippingPlane.
OpenSGSceneGraphInterface_osgSGIF
 Pointer to OpenSGSceneGraphInterface.

Static Private Attributes

static OpenSGApplicationBase_instance = NULL
 Single instance of OpenSGApplicationBase.

Constructor & Destructor Documentation

OpenSGApplicationBase::OpenSGApplicationBase (  ) 

OpenSGApplicationBase::~OpenSGApplicationBase (  )  [virtual]


Member Function Documentation

void OpenSGApplicationBase::_cleanup (  )  [private]

void OpenSGApplicationBase::_display (  )  [static, private]

void OpenSGApplicationBase::_initializeOpenSGNodes (  )  [private]

void OpenSGApplicationBase::_keyboard ( unsigned char  k,
int  x,
int  y 
) [static, private]

void OpenSGApplicationBase::_keyboardUp ( unsigned char  k,
int  x,
int  y 
) [static, private]

void OpenSGApplicationBase::_mouse ( int  button,
int  state,
int  x,
int  y 
) [static, private]

void OpenSGApplicationBase::_mouseMove ( int  x,
int  y 
) [static, private]

void OpenSGApplicationBase::_setupCamera (  )  [private]

int OpenSGApplicationBase::_setupGLUT ( const CommandLineArgumentWrapper args  )  [private]

void OpenSGApplicationBase::_setWindowSize ( int  w,
int  h 
) [static, private]

void OpenSGApplicationBase::activateShadows ( const std::vector< OSG::NodePtr > &  lightNodes  ) 

void OpenSGApplicationBase::activateShadows ( OSG::NodePtr  lightNode  ) 

void OpenSGApplicationBase::cbGlutKeyboard ( unsigned char  k,
int  x,
int  y 
) [protected, virtual]

void OpenSGApplicationBase::cbGlutKeyboardUp ( unsigned char  k,
int  x,
int  y 
) [protected, virtual]

void OpenSGApplicationBase::cbGlutMouse ( int  button,
int  state,
int  x,
int  y 
) [protected, virtual]

void OpenSGApplicationBase::cbGlutMouseMove ( int  x,
int  y 
) [protected, virtual]

void OpenSGApplicationBase::cbGlutSetWindowSize ( int  w,
int  h 
) [protected, virtual]

float OpenSGApplicationBase::getEyeSeparation (  ) 

bool OpenSGApplicationBase::init ( const CommandLineArgumentWrapper args  )  [private, virtual]

Implements ApplicationBase.

void OpenSGApplicationBase::initCoreComponentCallback ( CoreComponents  comp  )  [protected, virtual]

void OpenSGApplicationBase::initInputInterfaceCallback ( ModuleInterface moduleInterface  )  [protected, virtual]

void OpenSGApplicationBase::initModuleCallback ( ModuleInterface module  )  [protected, virtual]

void OpenSGApplicationBase::initOutputInterfaceCallback ( ModuleInterface moduleInterface  )  [protected, virtual]

Reimplemented from ApplicationBase.

bool OpenSGApplicationBase::preInit ( const CommandLineArgumentWrapper args  )  [private, virtual]

Reimplemented from ApplicationBase.

bool OpenSGApplicationBase::preInitialize ( const CommandLineArgumentWrapper args  )  [protected, virtual]

void OpenSGApplicationBase::run (  )  [private, virtual]

Implements ApplicationBase.

bool OpenSGApplicationBase::setBackgroundImage ( std::string  imageUrl,
int  windowIndex = -1 
)

void OpenSGApplicationBase::setEyeSeparation ( float  eyeSeparation  ) 

void OpenSGApplicationBase::setFarClippingPlane ( float  farPlane  ) 

void OpenSGApplicationBase::setHeadlight ( bool  onOff  ) 

void OpenSGApplicationBase::setNearClippingPlane ( float  nearPlane  ) 

void OpenSGApplicationBase::setPhysicalToWorldScale ( float  scale  ) 

void OpenSGApplicationBase::setRootNode ( OSG::NodePtr  root  ) 

void OpenSGApplicationBase::setStatistics ( bool  onOff  ) 

void OpenSGApplicationBase::setWireframe ( bool  onOff  ) 


Member Data Documentation

OSG::NodePtr OpenSGApplicationBase::_appRootNode [private]

Root node of application.

OSG::MaterialGroupPtr OpenSGApplicationBase::_appWireframeCore [private]

Alternative core for wireframe rendering.

OSG::CAVEConfig OpenSGApplicationBase::_caveCfg [private]

Configuration for CAVESceneManager.

OSG::CAVESceneManager* OpenSGApplicationBase::_csmgr [private]

CAVESceneManager instance.

Defines farClippingPlane.

OSG::GLUTWindowPtr OpenSGApplicationBase::_gwin [private]

Pointer to GLUT window.

Variable for checking if init was called correctly.

Single instance of OpenSGApplicationBase.

Reimplemented from ApplicationBase.

std::vector<OSG::NodePtr> OpenSGApplicationBase::_lightNodes [private]

Stores light nodes for shadow calculation.

Defines if mouse is warped into window or not.

OSG::MultiDisplayWindowPtr OpenSGApplicationBase::_mwin [private]

Pointer to Multi-display window.

Defines farClippingPlane.

Variable for checking if preInit was called correctly.

Defines if the root-node was already set.

Defines if statistics of SceneManager are displayed.

OSG::SimpleSceneManager* OpenSGApplicationBase::_smgr [private]

SceneManager for desktop / single display systems.

Defines if a image for the control window is used.

Define if CAVESceneManager is used or not.

Defines if sensor-emulation is used or not.

Defines if Shadows are activated or not.

ID of GLUT window.


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

Generated on Wed Oct 20 16:11:58 2010 for inVRs by doxygen 1.5.8