Public Member Functions | Private Types | Private Member Functions | Private Attributes | List of all members
rsm::PlantWaypointTool Class Reference

Serves as a Tool plugin for RViz which enables planting waypoints on a desired location with an adjustable orientation. More...

#include <PlantWaypointTool.h>

Inheritance diagram for rsm::PlantWaypointTool:
Inheritance graph
[legend]

Public Member Functions

void activate ()
 
void deactivate ()
 
void load (const rviz::Config &config)
 
void onInitialize ()
 
 PlantWaypointTool ()
 
int processMouseEvent (rviz::ViewportMouseEvent &event)
 
void save (rviz::Config config) const
 
 ~PlantWaypointTool ()
 
- Public Member Functions inherited from rviz::Tool
bool accessAllKeys ()
 
virtual QString getClassId () const
 
const QCursor & getCursor ()
 
QString getDescription () const
 
const QIcon & getIcon ()
 
QString getName () const
 
virtual PropertygetPropertyContainer () const
 
char getShortcutKey ()
 
void initialize (DisplayContext *context)
 
virtual int processKeyEvent (QKeyEvent *event, RenderPanel *panel)
 
virtual void setClassId (const QString &class_id)
 
void setCursor (const QCursor &cursor)
 
void setDescription (const QString &description)
 
void setIcon (const QIcon &icon)
 
void setName (const QString &name)
 
void setStatus (const QString &message)
 
 Tool ()
 
virtual void update (float wall_dt, float ros_dt)
 
virtual ~Tool ()
 

Private Types

enum  State { Moving, Position, Orientation }
 

Private Member Functions

void makeFlag (const Ogre::Vector3 &position, double angle)
 

Private Attributes

ros::ServiceClient _add_waypoint_client
 
rviz::VectorPropertycurrent_flag_property_
 
std::vector< Ogre::SceneNode * > flag_nodes_
 
std::string flag_resource_
 
Ogre::SceneNode * moving_flag_node_
 
Ogre::Vector3 pos_
 
State state_
 

Additional Inherited Members

- Signals inherited from rviz::Tool
void close ()
 
- Public Attributes inherited from rviz::Tool
 Finished
 
 Render
 
- Protected Attributes inherited from rviz::Tool
bool access_all_keys_
 
DisplayContextcontext_
 
QCursor cursor_
 
QIcon icon_
 
Ogre::SceneManager * scene_manager_
 
char shortcut_key_
 

Detailed Description

Serves as a Tool plugin for RViz which enables planting waypoints on a desired location with an adjustable orientation.

Definition at line 42 of file PlantWaypointTool.h.

Member Enumeration Documentation

Enumerator
Moving 
Position 
Orientation 

Definition at line 99 of file PlantWaypointTool.h.

Constructor & Destructor Documentation

rsm::PlantWaypointTool::PlantWaypointTool ( )

Constructor

Definition at line 5 of file PlantWaypointTool.cpp.

rsm::PlantWaypointTool::~PlantWaypointTool ( )

Destructor

Definition at line 13 of file PlantWaypointTool.cpp.

Member Function Documentation

void rsm::PlantWaypointTool::activate ( )
virtual

Called when tool is activated

Implements rviz::Tool.

Definition at line 35 of file PlantWaypointTool.cpp.

void rsm::PlantWaypointTool::deactivate ( )
virtual

Called when tool is deactivated

Implements rviz::Tool.

Definition at line 48 of file PlantWaypointTool.cpp.

void rsm::PlantWaypointTool::load ( const rviz::Config config)
virtual

Load config (not used)

Parameters
config

Reimplemented from rviz::Tool.

Definition at line 118 of file PlantWaypointTool.cpp.

void rsm::PlantWaypointTool::makeFlag ( const Ogre::Vector3 position,
double  angle 
)
private

Calls AddWaypoint service with the desired position and orientation for the new waypoint

Parameters
positionPosition of the new waypoint
angleYaw angle of the new waypoint

Definition at line 100 of file PlantWaypointTool.cpp.

void rsm::PlantWaypointTool::onInitialize ( )
virtual

Initializes plugin

Reimplemented from rviz::Tool.

Definition at line 19 of file PlantWaypointTool.cpp.

int rsm::PlantWaypointTool::processMouseEvent ( rviz::ViewportMouseEvent event)
virtual

Processing mouse events in RViz while tool is active

Parameters
eventMouse event in RViz
Returns
Render or Finished

Reimplemented from rviz::Tool.

Definition at line 56 of file PlantWaypointTool.cpp.

void rsm::PlantWaypointTool::save ( rviz::Config  config) const
virtual

Save config (not used)

Parameters
config

Reimplemented from rviz::Tool.

Definition at line 115 of file PlantWaypointTool.cpp.

Member Data Documentation

ros::ServiceClient rsm::PlantWaypointTool::_add_waypoint_client
private

Definition at line 97 of file PlantWaypointTool.h.

rviz::VectorProperty* rsm::PlantWaypointTool::current_flag_property_
private

Definition at line 95 of file PlantWaypointTool.h.

std::vector<Ogre::SceneNode*> rsm::PlantWaypointTool::flag_nodes_
private

Definition at line 92 of file PlantWaypointTool.h.

std::string rsm::PlantWaypointTool::flag_resource_
private

Definition at line 94 of file PlantWaypointTool.h.

Ogre::SceneNode* rsm::PlantWaypointTool::moving_flag_node_
private

Definition at line 93 of file PlantWaypointTool.h.

Ogre::Vector3 rsm::PlantWaypointTool::pos_
private

Definition at line 103 of file PlantWaypointTool.h.

State rsm::PlantWaypointTool::state_
private

Definition at line 102 of file PlantWaypointTool.h.


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


rsm_rviz_plugins
Author(s): Marco Steinbrink
autogenerated on Tue Mar 16 2021 02:44:40