OpenSceneGraph 2.8.4
Public Member Functions | Protected Member Functions | Protected Attributes
osgViewer::Viewer Class Reference

Viewer holds a single view on to a single scene. More...

Inheritance diagram for osgViewer::Viewer:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 Viewer ()
 Viewer (osg::ArgumentParser &arguments)
 Viewer (const osgViewer::Viewer &viewer, const osg::CopyOp &copyop=osg::CopyOp::SHALLOW_COPY)
virtual ~Viewer ()
 META_Object (osgViewer, Viewer)
virtual void take (View &rhs)
 Take all the settings, Camera and Slaves from the passed in view(er), leaving it empty.
virtual void setViewerStats (osg::Stats *stats)
 Set the Stats object used for collect various frame related timing and scene graph stats.
virtual osg::StatsgetViewerStats ()
 Get the Viewers Stats object.
virtual const osg::StatsgetViewerStats () const
 Get the Viewers Stats object.
virtual bool readConfiguration (const std::string &filename)
 read the viewer configuration from a configuration file.
virtual bool isRealized () const
 Get whether at least of one of this viewers windows are realized.
virtual void realize ()
 set up windows and associated threads.
virtual void setStartTick (osg::Timer_t tick)
void setReferenceTime (double time=0.0)
virtual void setSceneData (osg::Node *node)
 Set the sene graph data that viewer with view.
virtual GraphicsWindowEmbeddedsetUpViewerAsEmbeddedInWindow (int x, int y, int width, int height)
 Convenience method for setting up the viewer so it can be used embedded in an external managed window.
virtual double elapsedTime ()
virtual osg::FrameStampgetViewerFrameStamp ()
virtual int run ()
 Execute a main frame loop.
virtual void advance (double simulationTime=USE_REFERENCE_TIME)
virtual void eventTraversal ()
virtual void updateTraversal ()
void setCameraWithFocus (osg::Camera *camera)
osg::CameragetCameraWithFocus ()
const osg::CameragetCameraWithFocus () const
virtual void getCameras (Cameras &cameras, bool onlyActive=true)
virtual void getContexts (Contexts &contexts, bool onlyValid=true)
virtual void getAllThreads (Threads &threads, bool onlyActive=true)
virtual void getOperationThreads (OperationThreads &threads, bool onlyActive=true)
virtual void getScenes (Scenes &scenes, bool onlyValid=true)
virtual void getViews (Views &views, bool onlyValid=true)
virtual void getUsage (osg::ApplicationUsage &usage) const
 Get the keyboard and mouse usage of this viewer.

Protected Member Functions

void constructorInit ()
virtual void viewerInit ()

Protected Attributes

osg::observer_ptr< osg::Camera_cameraWithFocus

Detailed Description

Viewer holds a single view on to a single scene.


Constructor & Destructor Documentation

osgViewer::Viewer::Viewer ( )
osgViewer::Viewer::Viewer ( osg::ArgumentParser arguments)
osgViewer::Viewer::Viewer ( const osgViewer::Viewer viewer,
const osg::CopyOp copyop = osg::CopyOp::SHALLOW_COPY 
)
virtual osgViewer::Viewer::~Viewer ( ) [virtual]

Member Function Documentation

virtual void osgViewer::Viewer::advance ( double  simulationTime = USE_REFERENCE_TIME) [virtual]

Implements osgViewer::ViewerBase.

void osgViewer::Viewer::constructorInit ( ) [protected]
virtual double osgViewer::Viewer::elapsedTime ( ) [virtual]

Implements osgViewer::ViewerBase.

virtual void osgViewer::Viewer::eventTraversal ( ) [virtual]

Implements osgViewer::ViewerBase.

virtual void osgViewer::Viewer::getAllThreads ( Threads threads,
bool  onlyActive = true 
) [virtual]

Implements osgViewer::ViewerBase.

virtual void osgViewer::Viewer::getCameras ( Cameras cameras,
bool  onlyActive = true 
) [virtual]

Implements osgViewer::ViewerBase.

const osg::Camera* osgViewer::Viewer::getCameraWithFocus ( ) const [inline]
osg::Camera* osgViewer::Viewer::getCameraWithFocus ( ) [inline]
virtual void osgViewer::Viewer::getContexts ( Contexts contexts,
bool  onlyValid = true 
) [virtual]

Implements osgViewer::ViewerBase.

virtual void osgViewer::Viewer::getOperationThreads ( OperationThreads threads,
bool  onlyActive = true 
) [virtual]

Implements osgViewer::ViewerBase.

virtual void osgViewer::Viewer::getScenes ( Scenes scenes,
bool  onlyValid = true 
) [virtual]

Implements osgViewer::ViewerBase.

virtual void osgViewer::Viewer::getUsage ( osg::ApplicationUsage usage) const [virtual]

Get the keyboard and mouse usage of this viewer.

Implements osgViewer::ViewerBase.

virtual osg::FrameStamp* osgViewer::Viewer::getViewerFrameStamp ( ) [inline, virtual]

Implements osgViewer::ViewerBase.

virtual const osg::Stats* osgViewer::Viewer::getViewerStats ( ) const [inline, virtual]

Get the Viewers Stats object.

Implements osgViewer::ViewerBase.

virtual osg::Stats* osgViewer::Viewer::getViewerStats ( ) [inline, virtual]

Get the Viewers Stats object.

Implements osgViewer::ViewerBase.

virtual void osgViewer::Viewer::getViews ( Views views,
bool  onlyValid = true 
) [virtual]

Implements osgViewer::ViewerBase.

virtual bool osgViewer::Viewer::isRealized ( ) const [virtual]

Get whether at least of one of this viewers windows are realized.

Implements osgViewer::ViewerBase.

osgViewer::Viewer::META_Object ( osgViewer  ,
Viewer   
)
virtual bool osgViewer::Viewer::readConfiguration ( const std::string &  filename) [virtual]

read the viewer configuration from a configuration file.

Implements osgViewer::ViewerBase.

virtual void osgViewer::Viewer::realize ( ) [virtual]

set up windows and associated threads.

Implements osgViewer::ViewerBase.

virtual int osgViewer::Viewer::run ( ) [virtual]

Execute a main frame loop.

Equivalent to while (!viewer.done()) viewer.frame(); Also calls realize() if the viewer is not already realized, and installs trackball manipulator if one is not already assigned.

Implements osgViewer::ViewerBase.

void osgViewer::Viewer::setCameraWithFocus ( osg::Camera camera) [inline]
void osgViewer::Viewer::setReferenceTime ( double  time = 0.0)
virtual void osgViewer::Viewer::setSceneData ( osg::Node node) [virtual]

Set the sene graph data that viewer with view.

Reimplemented from osgViewer::View.

virtual void osgViewer::Viewer::setStartTick ( osg::Timer_t  tick) [virtual]

Reimplemented from osgViewer::View.

virtual GraphicsWindowEmbedded* osgViewer::Viewer::setUpViewerAsEmbeddedInWindow ( int  x,
int  y,
int  width,
int  height 
) [virtual]

Convenience method for setting up the viewer so it can be used embedded in an external managed window.

Returns the GraphicsWindowEmbedded that can be used by applications to pass in events to the viewer.

virtual void osgViewer::Viewer::setViewerStats ( osg::Stats stats) [inline, virtual]

Set the Stats object used for collect various frame related timing and scene graph stats.

Implements osgViewer::ViewerBase.

virtual void osgViewer::Viewer::take ( View rhs) [virtual]

Take all the settings, Camera and Slaves from the passed in view(er), leaving it empty.

virtual void osgViewer::Viewer::updateTraversal ( ) [virtual]

Implements osgViewer::ViewerBase.

virtual void osgViewer::Viewer::viewerInit ( ) [inline, protected, virtual]

Implements osgViewer::ViewerBase.


Member Data Documentation


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

osg logo
Generated at Sun Jan 8 2012 13:17:05 for the OpenSceneGraph by doxygen 1.7.4.