Public Member Functions | Protected Attributes | List of all members
gazebo::rendering::ViewController Class Referenceabstract

Base class for view controllers. More...

#include <rendering/rendering.hh>

Inheritance diagram for gazebo::rendering::ViewController:
Inheritance graph
[legend]

Public Member Functions

 ViewController (UserCameraPtr _camera)
 Constructor. More...
 
virtual ~ViewController ()
 Destructor. More...
 
std::string GetTypeString () const
 Get the type of view controller. More...
 
virtual void HandleKeyPressEvent (const std::string &_key)=0
 Handle a key press event. More...
 
virtual void HandleKeyReleaseEvent (const std::string &_key)=0
 Handle a key release event. More...
 
virtual void HandleMouseEvent (const common::MouseEvent &_event)=0
 Handle a mouse event. More...
 
virtual void Init ()=0
 Initialize the view controller. More...
 
virtual void Init (const math::Vector3 &_focalPoint)
 Initialize with a focus point. More...
 
void SetEnabled (bool _value)
 Set whether the controller is enabled. More...
 
virtual void Update ()=0
 Update the controller, which should update the position of the Camera. More...
 

Protected Attributes

UserCameraPtr camera
 Pointer to the camera to control. More...
 
bool enabled
 True if enabled. More...
 
std::string typeString
 Type of view controller. More...
 

Detailed Description

Base class for view controllers.

Constructor & Destructor Documentation

gazebo::rendering::ViewController::ViewController ( UserCameraPtr  _camera)

Constructor.

Parameters
[in]_cameraThe user camera to controll.
virtual gazebo::rendering::ViewController::~ViewController ( )
virtual

Destructor.

Member Function Documentation

std::string gazebo::rendering::ViewController::GetTypeString ( ) const

Get the type of view controller.

Returns
The view controller type string.
virtual void gazebo::rendering::ViewController::HandleKeyPressEvent ( const std::string &  _key)
pure virtual

Handle a key press event.

Parameters
[in]_keyThe key that was pressed.

Implemented in gazebo::rendering::OrbitViewController, and gazebo::rendering::FPSViewController.

virtual void gazebo::rendering::ViewController::HandleKeyReleaseEvent ( const std::string &  _key)
pure virtual

Handle a key release event.

Parameters
[in]_keyThe key that was released.

Implemented in gazebo::rendering::OrbitViewController, and gazebo::rendering::FPSViewController.

virtual void gazebo::rendering::ViewController::HandleMouseEvent ( const common::MouseEvent _event)
pure virtual

Handle a mouse event.

Parameters
[in]_eventThe mouse position.

Implemented in gazebo::rendering::OrbitViewController, and gazebo::rendering::FPSViewController.

virtual void gazebo::rendering::ViewController::Init ( )
pure virtual

Initialize the view controller.

Implemented in gazebo::rendering::OrbitViewController, and gazebo::rendering::FPSViewController.

virtual void gazebo::rendering::ViewController::Init ( const math::Vector3 _focalPoint)
virtual

Initialize with a focus point.

Parameters
[in]_focalPointThe point to look at.

Reimplemented in gazebo::rendering::OrbitViewController.

void gazebo::rendering::ViewController::SetEnabled ( bool  _value)

Set whether the controller is enabled.

Parameters
[in]_valueTrue if the controller is enabled.
virtual void gazebo::rendering::ViewController::Update ( )
pure virtual

Update the controller, which should update the position of the Camera.

Implemented in gazebo::rendering::OrbitViewController, and gazebo::rendering::FPSViewController.

Member Data Documentation

UserCameraPtr gazebo::rendering::ViewController::camera
protected

Pointer to the camera to control.

bool gazebo::rendering::ViewController::enabled
protected

True if enabled.

std::string gazebo::rendering::ViewController::typeString
protected

Type of view controller.


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