|
openscenegraph
|
Public Types | |
| typedef std::list < osg::ref_ptr < osgGA::GUIEventHandler > > | EventHandlers |
Public Types inherited from osg::View | |
| enum | LightingMode { NO_LIGHT, HEADLIGHT, SKY_LIGHT } |
Public Types inherited from osg::Object | |
| enum | DataVariance { DYNAMIC, STATIC, UNSPECIFIED } |
Public Member Functions | |
| View () | |
| View (const osgViewer::View &view, const osg::CopyOp ©op=osg::CopyOp::SHALLOW_COPY) | |
| META_Object (osgViewer, View) | |
| virtual osg::View * | asView () |
| ViewerBase * | getViewerBase () |
| virtual void | take (osg::View &rhs) |
| virtual void | setStartTick (osg::Timer_t tick) |
| osg::Timer_t | getStartTick () const |
| Scene * | getScene () |
| const Scene * | getScene () const |
| virtual void | setSceneData (osg::Node *node) |
| osg::Node * | getSceneData () |
| const osg::Node * | getSceneData () const |
| void | setDatabasePager (osgDB::DatabasePager *dp) |
| osgDB::DatabasePager * | getDatabasePager () |
| const osgDB::DatabasePager * | getDatabasePager () const |
| void | setImagePager (osgDB::ImagePager *ip) |
| osgDB::ImagePager * | getImagePager () |
| const osgDB::ImagePager * | getImagePager () const |
| void | setEventQueue (osgGA::EventQueue *eventQueue) |
| osgGA::EventQueue * | getEventQueue () |
| const osgGA::EventQueue * | getEventQueue () const |
| void | setCameraManipulator (osgGA::CameraManipulator *manipulator, bool resetPosition=true) |
| osgGA::CameraManipulator * | getCameraManipulator () |
| const osgGA::CameraManipulator * | getCameraManipulator () const |
| void | home () |
| void | addEventHandler (osgGA::GUIEventHandler *eventHandler) |
| void | removeEventHandler (osgGA::GUIEventHandler *eventHandler) |
| EventHandlers & | getEventHandlers () |
| const EventHandlers & | getEventHandlers () const |
| void | setCoordinateSystemNodePath (const osg::NodePath &nodePath) |
| osg::NodePath | getCoordinateSystemNodePath () const |
| void | computeActiveCoordinateSystemNodePath () |
| void | setDisplaySettings (osg::DisplaySettings *ds) |
| osg::DisplaySettings * | getDisplaySettings () |
| const osg::DisplaySettings * | getDisplaySettings () const |
| void | setFusionDistance (osgUtil::SceneView::FusionDistanceMode mode, float value=1.0f) |
| osgUtil::SceneView::FusionDistanceMode | getFusionDistanceMode () const |
| float | getFusionDistanceValue () const |
| void | setUpViewAcrossAllScreens () |
| void | setUpViewInWindow (int x, int y, int width, int height, unsigned int screenNum=0) |
| void | setUpViewOnSingleScreen (unsigned int screenNum=0) |
| void | setUpViewFor3DSphericalDisplay (double radius=1.0, double collar=0.45, unsigned int screenNum=0, osg::Image *intensityMap=0, const osg::Matrixd &projectorMatrix=osg::Matrixd()) |
| void | setUpViewForPanoramicSphericalDisplay (double radius=1.0, double collar=0.45, unsigned int screenNum=0, osg::Image *intensityMap=0, const osg::Matrixd &projectorMatrix=osg::Matrixd()) |
| void | setUpViewForWoWVxDisplay (unsigned int screenNum, unsigned char wow_content, unsigned char wow_factor, unsigned char wow_offset, float wow_disparity_Zd, float wow_disparity_vz, float wow_disparity_M, float wow_disparity_C) |
| bool | setUpDepthPartitionForCamera (osg::Camera *cameraToPartition, DepthPartitionSettings *dps=0) |
| bool | setUpDepthPartition (DepthPartitionSettings *dsp=0) |
| bool | containsCamera (const osg::Camera *camera) const |
| const osg::Camera * | getCameraContainingPosition (float x, float y, float &local_x, float &local_y) const |
| bool | computeIntersections (float x, float y, osgUtil::LineSegmentIntersector::Intersections &intersections, osg::Node::NodeMask traversalMask=0xffffffff) |
| bool | computeIntersections (float x, float y, const osg::NodePath &nodePath, osgUtil::LineSegmentIntersector::Intersections &intersections, osg::Node::NodeMask traversalMask=0xffffffff) |
| virtual void | requestRedraw () |
| virtual void | requestContinuousUpdate (bool needed=true) |
| virtual void | requestWarpPointer (float x, float y) |
| void | assignSceneDataToCameras () |
| void | init () |
Public Member Functions inherited from osg::View | |
| View () | |
| View (const osg::View &view, const osg::CopyOp ©op=CopyOp::SHALLOW_COPY) | |
| META_Object (osg, View) | |
| void | setStats (osg::Stats *stats) |
| osg::Stats * | getStats () |
| const osg::Stats * | getStats () const |
| void | setLightingMode (LightingMode lightingMode) |
| LightingMode | getLightingMode () const |
| void | setLight (osg::Light *light) |
| osg::Light * | getLight () |
| const osg::Light * | getLight () const |
| void | setCamera (osg::Camera *camera) |
| osg::Camera * | getCamera () |
| const osg::Camera * | getCamera () const |
| void | setFrameStamp (osg::FrameStamp *fs) |
| osg::FrameStamp * | getFrameStamp () |
| const osg::FrameStamp * | getFrameStamp () const |
| bool | addSlave (osg::Camera *camera, bool useMastersSceneData=true) |
| bool | addSlave (osg::Camera *camera, const osg::Matrix &projectionOffset, const osg::Matrix &viewOffset, bool useMastersSceneData=true) |
| bool | removeSlave (unsigned int pos) |
| unsigned int | getNumSlaves () const |
| Slave & | getSlave (unsigned int pos) |
| const Slave & | getSlave (unsigned int pos) const |
| unsigned int | findSlaveIndexForCamera (osg::Camera *camera) const |
| Slave * | findSlaveForCamera (osg::Camera *camera) |
| void | updateSlaves () |
Public Member Functions inherited from osg::Object | |
| Object () | |
| Object (bool threadSafeRefUnref) | |
| Object (const Object &, const CopyOp ©op=CopyOp::SHALLOW_COPY) | |
| virtual Object * | cloneType () const =0 |
| virtual Object * | clone (const CopyOp &) const =0 |
| virtual bool | isSameKindAs (const Object *) const |
| virtual const char * | libraryName () const =0 |
| virtual const char * | className () const =0 |
| virtual void | setThreadSafeRefUnref (bool threadSafe) |
| virtual void | setName (const std::string &name) |
| void | setName (const char *name) |
| const std::string & | getName () const |
| void | setDataVariance (DataVariance dv) |
| DataVariance | getDataVariance () const |
| virtual void | computeDataVariance () |
| void | setUserDataContainer (osg::UserDataContainer *udc) |
| osg::UserDataContainer * | getUserDataContainer () |
| const osg::UserDataContainer * | getUserDataContainer () const |
| osg::UserDataContainer * | getOrCreateUserDataContainer () |
| virtual void | setUserData (Referenced *obj) |
| virtual Referenced * | getUserData () |
| virtual const Referenced * | getUserData () const |
| template<typename T > | |
| bool | getUserValue (const std::string &name, T &value) const |
| template<typename T > | |
| void | setUserValue (const std::string &name, const T &value) |
| virtual void | resizeGLObjectBuffers (unsigned int) |
| virtual void | releaseGLObjects (osg::State *=0) const |
| template<typename T > | |
| BoolValueObject UCharValueObject UShortValueObject UIntValueObject DoubleValueObject Vec3fValueObject Vec2dValueObject Vec4dValueObject PlaneValueObject MatrixdValueObject bool | getUserValue (const std::string &name, T &value) const |
Public Member Functions inherited from osg::Referenced | |
| Referenced () | |
| Referenced (bool threadSafeRefUnref) | |
| Referenced (const Referenced &) | |
| Referenced & | operator= (const Referenced &) |
| bool | getThreadSafeRefUnref () const |
| OpenThreads::Mutex * | getRefMutex () const |
| int | ref () const |
| int | unref () const |
| int | unref_nodelete () const |
| int | referenceCount () const |
| ObserverSet * | getObserverSet () const |
| ObserverSet * | getOrCreateObserverSet () const |
| void | addObserver (Observer *observer) const |
| void | removeObserver (Observer *observer) const |
Public Member Functions inherited from osgGA::GUIActionAdapter | |
| virtual | ~GUIActionAdapter () |
Protected Member Functions | |
| virtual | ~View () |
| virtual osg::GraphicsOperation * | createRenderer (osg::Camera *camera) |
Protected Attributes | |
| osg::observer_ptr< ViewerBase > | _viewerBase |
| osg::Timer_t | _startTick |
| osg::ref_ptr< osgViewer::Scene > | _scene |
| osg::ref_ptr< osgGA::EventQueue > | _eventQueue |
| osg::ref_ptr < osgGA::CameraManipulator > | _cameraManipulator |
| EventHandlers | _eventHandlers |
| osg::ObserverNodePath | _coordinateSystemNodePath |
| osg::ref_ptr < osg::DisplaySettings > | _displaySettings |
| osgUtil::SceneView::FusionDistanceMode | _fusionDistanceMode |
| float | _fusionDistanceValue |
Protected Attributes inherited from osg::View | |
| osg::ref_ptr< osg::Stats > | _stats |
| LightingMode | _lightingMode |
| osg::ref_ptr< osg::Light > | _light |
| osg::ref_ptr< osg::Camera > | _camera |
| Slaves | _slaves |
| osg::ref_ptr< osg::FrameStamp > | _frameStamp |
Protected Attributes inherited from osg::Object | |
| std::string | _name |
| DataVariance | _dataVariance |
| osg::UserDataContainer * | _userDataContainer |
Protected Attributes inherited from osg::Referenced | |
| OpenThreads::AtomicPtr | _observerSet |
| OpenThreads::Atomic | _refCount |
Friends | |
| class | CompositeViewer |
Additional Inherited Members | |
Static Public Member Functions inherited from osg::Referenced | |
| static OpenThreads::Mutex * | getGlobalReferencedMutex () |
| static void | setThreadSafeReferenceCounting (bool enableThreadSafeReferenceCounting) |
| static bool | getThreadSafeReferenceCounting () |
| static void | setDeleteHandler (DeleteHandler *handler) |
| static DeleteHandler * | getDeleteHandler () |
Protected Types inherited from osg::View | |
| typedef std::vector< Slave > | Slaves |
View holds a single view on a scene, this view may be composed of one or more slave cameras.
| typedef std::list< osg::ref_ptr<osgGA::GUIEventHandler> > osgViewer::View::EventHandlers |
| osgViewer::View::View | ( | ) |
| osgViewer::View::View | ( | const osgViewer::View & | view, |
| const osg::CopyOp & | copyop = osg::CopyOp::SHALLOW_COPY |
||
| ) |
|
protectedvirtual |
Reimplemented from osg::View.
| void osgViewer::View::addEventHandler | ( | osgGA::GUIEventHandler * | eventHandler | ) |
Add an EventHandler that adds handling of events to the View.
| void osgViewer::View::assignSceneDataToCameras | ( | ) |
|
inlinevirtual |
Provide a mechanism for getting the osg::View associated from the GUIActionAdapter. One would use this to case view to osgViewer::View(er) if supported by the subclass.
Reimplemented from osgGA::GUIActionAdapter.
| void osgViewer::View::computeActiveCoordinateSystemNodePath | ( | ) |
Compute the NodePath to any active CoordinateSystemNode present in the Scene.
| bool osgViewer::View::computeIntersections | ( | float | x, |
| float | y, | ||
| osgUtil::LineSegmentIntersector::Intersections & | intersections, | ||
| osg::Node::NodeMask | traversalMask = 0xffffffff |
||
| ) |
Compute intersections between a ray through the specified master cameras window/eye coords and a specified node. Note, when a master cameras has slaves and no viewport itself its coordinate frame will be in clip space i.e. -1,-1 to 1,1, while if its has a viewport the coordintates will be relative to its viewport dimensions. Mouse events handled by the view will automatically be attached into the master camera window/clip coords so can be passed directly on to the computeIntersections method.
| bool osgViewer::View::computeIntersections | ( | float | x, |
| float | y, | ||
| const osg::NodePath & | nodePath, | ||
| osgUtil::LineSegmentIntersector::Intersections & | intersections, | ||
| osg::Node::NodeMask | traversalMask = 0xffffffff |
||
| ) |
Compute intersections between a ray through the specified master cameras window/eye coords and a specified nodePath's subgraph.
| bool osgViewer::View::containsCamera | ( | const osg::Camera * | camera | ) | const |
Return true if this view contains a specified camera.
|
protectedvirtual |
Reimplemented from osg::View.
| const osg::Camera* osgViewer::View::getCameraContainingPosition | ( | float | x, |
| float | y, | ||
| float & | local_x, | ||
| float & | local_y | ||
| ) | const |
Get the camera which contains the pointer position x,y specified master cameras window/eye coords. Also passes back the local window coords for the graphics context associated with the camera passed back.
|
inline |
Get the View's CameraManipulator.
|
inline |
Get the const View's CameraManipulator.
| osg::NodePath osgViewer::View::getCoordinateSystemNodePath | ( | ) | const |
Get the NodePath to any active CoordinateSystemNode present in the Scene.
| osgDB::DatabasePager* osgViewer::View::getDatabasePager | ( | ) |
Get the View's database pager.
| const osgDB::DatabasePager* osgViewer::View::getDatabasePager | ( | ) | const |
Get the const View's database pager.
|
inline |
Set the DisplaySettings object associated with this view.
|
inline |
Set the DisplaySettings object associated with this view.
|
inline |
Get the View's list of EventHandlers.
|
inline |
Get the const View's list of EventHandlers.
|
inline |
|
inline |
|
inline |
Get the FusionDistanceMode.
|
inline |
Get the FusionDistanceValue. Note, only used for USE_FUSION_DISTANCE_VALUE & PROPORTIONAL_TO_SCREEN_DISTANCE modes.
| osgDB::ImagePager* osgViewer::View::getImagePager | ( | ) |
Get the View's image pager.
| const osgDB::ImagePager* osgViewer::View::getImagePager | ( | ) | const |
Get the const View's image pager.
|
inline |
|
inline |
|
inline |
|
inline |
Provide a mechanism for getting the viewer object from this osgViewer::View. In the case of a osgViewer::Viewer the ViewerBase will effectively point to this object as Viewer subclasses from View. In the case of a osgViewer::CompsoiteViewer the ViewerBase will point to the CompositeViewer that owns this View.
| void osgViewer::View::home | ( | ) |
Set the view to the CameraManipulator's home position, if non is attached home() is does nothing. Note, to set the home position use getCamaraManipulator()->setHomePosition(...).
| void osgViewer::View::init | ( | ) |
| osgViewer::View::META_Object | ( | osgViewer | , |
| View | |||
| ) |
| void osgViewer::View::removeEventHandler | ( | osgGA::GUIEventHandler * | eventHandler | ) |
Remove an EventHandler from View.
|
virtual |
requestContinousUpdate(bool) is for en/disabling a throw or idle callback to be requested by a GUIEventHandler (typically a MatrixManipulator, though other GUIEventHandler's may also provide functionality). GUI toolkits can respond to this immediately by registering an idle/timed callback, or can delay setting the callback and update at their own leisure.
Implements osgGA::GUIActionAdapter.
|
virtual |
requestRedraw() requests a single redraw.
Implements osgGA::GUIActionAdapter.
|
virtual |
requestWarpPointer(int,int) is requesting a repositioning of the mouse pointer to a specified x,y location on the window. This is used by some camera manipulators to initialise the mouse pointer when mouse position relative to a controls neutral mouse position is required, i.e when mimicking a aircrafts joystick.
Implements osgGA::GUIActionAdapter.
| void osgViewer::View::setCameraManipulator | ( | osgGA::CameraManipulator * | manipulator, |
| bool | resetPosition = true |
||
| ) |
Set the CameraManipulator that moves the View's master Camera position in response to events. The parameter resetPosition determines whether manipulator is set to its home position.
| void osgViewer::View::setCoordinateSystemNodePath | ( | const osg::NodePath & | nodePath | ) |
Set the NodePath to any active CoordinateSystemNode present in the Scene. The CoordinateSystemNode path is used to help applications and CamaraManipualtors handle geocentric coordinates systems, such as known which way is the local up at any position on the a whole earth.
| void osgViewer::View::setDatabasePager | ( | osgDB::DatabasePager * | dp | ) |
Set the View's database pager.
|
inline |
Set the DisplaySettings object associated with this view.
|
inline |
|
inline |
Set the FusionDistanceMode and Value. Note, is used only when working in stereo.
| void osgViewer::View::setImagePager | ( | osgDB::ImagePager * | ip | ) |
Set the View's image pager.
|
virtual |
Set the scene graph that the View will use.
Reimplemented in osgViewer::Viewer.
|
virtual |
Reimplemented in osgViewer::Viewer.
| bool osgViewer::View::setUpDepthPartition | ( | DepthPartitionSettings * | dsp = 0 | ) |
Convenience method for setting up multiple slave cameras that depth partition each of the view's active cameras.
| bool osgViewer::View::setUpDepthPartitionForCamera | ( | osg::Camera * | cameraToPartition, |
| DepthPartitionSettings * | dps = 0 |
||
| ) |
Convenience method for setting up multiple slave cameras that depth partition the specified camera.
| void osgViewer::View::setUpViewAcrossAllScreens | ( | ) |
Convenience method for creating slave Cameras and associated GraphicsWindows across all screens.
| void osgViewer::View::setUpViewFor3DSphericalDisplay | ( | double | radius = 1.0, |
| double | collar = 0.45, |
||
| unsigned int | screenNum = 0, |
||
| osg::Image * | intensityMap = 0, |
||
| const osg::Matrixd & | projectorMatrix = osg::Matrixd() |
||
| ) |
Convenience method for spherical display using 6 slave cameras rendering the 6 sides of a cube map, and 7th camera doing distortion correction to present on a spherical display.
| void osgViewer::View::setUpViewForPanoramicSphericalDisplay | ( | double | radius = 1.0, |
| double | collar = 0.45, |
||
| unsigned int | screenNum = 0, |
||
| osg::Image * | intensityMap = 0, |
||
| const osg::Matrixd & | projectorMatrix = osg::Matrixd() |
||
| ) |
Convenience method for spherical display by rendering main scene to as panoramic 2:1 texture and then doing distortion correction to present onto a spherical display.
| void osgViewer::View::setUpViewForWoWVxDisplay | ( | unsigned int | screenNum, |
| unsigned char | wow_content, | ||
| unsigned char | wow_factor, | ||
| unsigned char | wow_offset, | ||
| float | wow_disparity_Zd, | ||
| float | wow_disparity_vz, | ||
| float | wow_disparity_M, | ||
| float | wow_disparity_C | ||
| ) |
Convenience method for autostereoscopic Philips WoWvx display.
| void osgViewer::View::setUpViewInWindow | ( | int | x, |
| int | y, | ||
| int | width, | ||
| int | height, | ||
| unsigned int | screenNum = 0 |
||
| ) |
Convenience method for a single camera on a single window.
| void osgViewer::View::setUpViewOnSingleScreen | ( | unsigned int | screenNum = 0 | ) |
Convenience method for a single camera associated with a single full screen GraphicsWindow.
|
virtual |
Take all the settings, Camera and Slaves from the passed in view, leaving it empty.
Reimplemented from osg::View.
Reimplemented in osgViewer::Viewer.
|
friend |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
1.8.3.1