OpenSceneGraph 3.6.5
CameraViewSwitchManipulator
Go to the documentation of this file.
1/* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2006 Robert Osfield
2 *
3 * This library is open source and may be redistributed and/or modified under
4 * the terms of the OpenSceneGraph Public License (OSGPL) version 0.0 or
5 * (at your option) any later version. The full license is in LICENSE file
6 * included with this distribution, and on the openscenegraph.org website.
7 *
8 * This library is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * OpenSceneGraph Public License for more details.
12*/
13
14#ifndef OSGGA_VIEWLISTMANIPULATOR
15#define OSGGA_VIEWLISTMANIPULATOR 1
16
18#include <osg/Quat>
19#include <osg/CameraView>
20
21namespace osgGA{
22
24{
25 public:
27
28 virtual const char* className() const { return "CameraViewSwitcher"; }
29
31 virtual void setByMatrix(const osg::Matrixd& /*matrix*/) {}
32
34 virtual void setByInverseMatrix(const osg::Matrixd& /*matrix*/) {}
35
37 virtual osg::Matrixd getMatrix() const;
38
41
42
47 virtual void setNode(osg::Node*);
48
50 virtual const osg::Node* getNode() const { return _node.get();}
51
53 virtual osg::Node* getNode() { return _node.get();}
54
56 virtual void init(const GUIEventAdapter& /*ea*/,GUIActionAdapter& /*aa*/) { _currentView = 0; }
57
59 virtual bool handle(const GUIEventAdapter& ea,GUIActionAdapter& us);
60
62 virtual void getUsage(osg::ApplicationUsage& usage) const;
63
64 typedef std::vector< osg::ref_ptr<osg::CameraView> > CameraViewList;
65
66 protected:
67
69
71
73 unsigned int _currentView;
74};
75
76}
77
78#endif
79
The 'GA' in osgGA stands for 'GUI Abstraction'; the osgGA namespace provides facilities to help devel...
Definition Callback:21
Definition ApplicationUsage:26
Definition Matrixd:27
Base class for all internal nodes in the scene graph.
Definition Node:72
Smart pointer for handling referenced counted objects.
Definition ref_ptr:32
virtual void init(const GUIEventAdapter &, GUIActionAdapter &)
Start/restart the manipulator.
Definition CameraViewSwitchManipulator:56
virtual const char * className() const
return the name of the object's class type.
Definition CameraViewSwitchManipulator:28
virtual osg::Node * getNode()
Return node if attached.
Definition CameraViewSwitchManipulator:53
osg::ref_ptr< osg::Node > _node
Definition CameraViewSwitchManipulator:70
virtual bool handle(const GUIEventAdapter &ea, GUIActionAdapter &us)
handle events, return true if handled, false otherwise.
virtual void setByMatrix(const osg::Matrixd &)
set the position of the matrix manipulator using a 4x4 Matrix.
Definition CameraViewSwitchManipulator:31
virtual ~CameraViewSwitchManipulator()
Definition CameraViewSwitchManipulator:68
unsigned int _currentView
Definition CameraViewSwitchManipulator:73
virtual void setByInverseMatrix(const osg::Matrixd &)
set the position of the matrix manipulator using a 4x4 Matrix.
Definition CameraViewSwitchManipulator:34
virtual osg::Matrixd getInverseMatrix() const
get the position of the manipulator as a inverse matrix of the manipulator, typically used as a model...
virtual const osg::Node * getNode() const
Return node if attached.
Definition CameraViewSwitchManipulator:50
CameraViewList _cameraViews
Definition CameraViewSwitchManipulator:72
virtual osg::Matrixd getMatrix() const
get the position of the manipulator as 4x4 Matrix.
CameraViewSwitchManipulator()
Definition CameraViewSwitchManipulator:26
virtual void getUsage(osg::ApplicationUsage &usage) const
Get the keyboard and mouse usage of this manipulator.
virtual void setNode(osg::Node *)
Attach a node to the manipulator.
std::vector< osg::ref_ptr< osg::CameraView > > CameraViewList
Definition CameraViewSwitchManipulator:64
Definition GUIActionAdapter:62
Event class for storing Keyboard, mouse and window events.
Definition GUIEventAdapter:82
#define OSGGA_EXPORT
Definition Export:40

osg logo
Generated at Wed Jul 23 2025 00:00:00 for the OpenSceneGraph by doxygen 1.14.0.