DART
6.10.1
|
#include <Viewer.hpp>
Public Member Functions | |
ViewerAttachment () | |
Default constructor. More... | |
virtual | ~ViewerAttachment () |
Virtual destructor. More... | |
virtual void | refresh ()=0 |
This function will get called each time the Viewer is refreshed. More... | |
Viewer * | getViewer () |
const Viewer * | getViewer () const |
Protected Member Functions | |
virtual void | customAttach (Viewer *newViewer) |
This function will be called by attach(Viewer*) so you can do customized setup when the Viewer changes. More... | |
virtual void | attach (Viewer *newViewer) |
This function will get called when the visual is attached to a new Viewer. More... | |
Private Attributes | |
Viewer * | mViewer |
Friends | |
class | Viewer |
dart::gui::osg::ViewerAttachment::ViewerAttachment | ( | ) |
Default constructor.
|
virtual |
Virtual destructor.
|
protectedvirtual |
This function will get called when the visual is attached to a new Viewer.
It adds this node as a child to the root node of the Viewer so the refresh() function will be called at each update cycle. It will also call customAttach(Viewer*) so you can do customized setup.
|
protectedvirtual |
This function will be called by attach(Viewer*) so you can do customized setup when the Viewer changes.
By default this function does nothing, so overriding it is completely safe.
Viewer * dart::gui::osg::ViewerAttachment::getViewer | ( | ) |
const Viewer * dart::gui::osg::ViewerAttachment::getViewer | ( | ) | const |
|
pure virtual |
This function will get called each time the Viewer is refreshed.
Override it to have your attachment update with each refresh cycle.
Implemented in dart::gui::osg::SupportPolygonVisual, and dart::gui::osg::GridVisual.
|
friend |
|
private |