Classes | Signals | Public Member Functions | Protected Types | Protected Slots | Protected Member Functions | Protected Attributes | List of all members
rviz::InteractiveMarker Class Reference

#include <interactive_marker.h>

Inheritance diagram for rviz::InteractiveMarker:
Inheritance graph
[legend]

Classes

struct  MenuNode
 

Signals

void statusUpdate (StatusProperty::Level level, const std::string &name, const std::string &text)
 
void userFeedback (visualization_msgs::InteractiveMarkerFeedback &feedback)
 

Public Member Functions

boost::shared_ptr< QMenu > getMenu ()
 
const std::string & getName ()
 
const Ogre::Quaternion & getOrientation ()
 
const Ogre::Vector3getPosition ()
 
const std::string & getReferenceFrame ()
 
float getSize ()
 
bool handle3DCursorEvent (ViewportMouseEvent &event, const Ogre::Vector3 &cursor_pos, const Ogre::Quaternion &cursor_rot, const std::string &control_name)
 
bool handleMouseEvent (ViewportMouseEvent &event, const std::string &control_name)
 
bool hasMenu ()
 
 InteractiveMarker (Ogre::SceneNode *scene_node, DisplayContext *context)
 
bool processMessage (const visualization_msgs::InteractiveMarker &message)
 
void processMessage (const visualization_msgs::InteractiveMarkerPose &message)
 
void publishFeedback (visualization_msgs::InteractiveMarkerFeedback &feedback, bool mouse_point_valid=false, const Ogre::Vector3 &mouse_point_rel_world=Ogre::Vector3(0, 0, 0))
 
void requestPoseUpdate (Ogre::Vector3 position, Ogre::Quaternion orientation)
 
void rotate (Ogre::Quaternion delta_orientation, const std::string &control_name)
 
void setPose (Ogre::Vector3 position, Ogre::Quaternion orientation, const std::string &control_name)
 
void setShowAxes (bool show)
 
void setShowDescription (bool show)
 
void setShowVisualAids (bool show)
 
void showMenu (ViewportMouseEvent &event, const std::string &control_name, const Ogre::Vector3 &three_d_point, bool valid_point)
 
void startDragging ()
 
void stopDragging ()
 
void translate (Ogre::Vector3 delta_position, const std::string &control_name)
 
void update (float wall_dt)
 
virtual ~InteractiveMarker ()
 

Protected Types

typedef boost::shared_ptr< InteractiveMarkerControlInteractiveMarkerControlPtr
 
typedef std::map< std::string, InteractiveMarkerControlPtrM_ControlPtr
 

Protected Slots

void handleMenuSelect (int menu_item_id)
 

Protected Member Functions

QString makeMenuString (const std::string &entry)
 
void populateMenu (QMenu *menu, std::vector< uint32_t > &ids)
 
void publishPose ()
 
void reset ()
 
void updateReferencePose ()
 

Protected Attributes

Axesaxes_
 
std::string client_id_
 
DisplayContextcontext_
 
M_ControlPtr controls_
 
std::string description_
 
InteractiveMarkerControlPtr description_control_
 
bool dragging_
 
bool frame_locked_
 
bool got_3d_point_for_menu_
 
bool has_menu_
 
double heart_beat_t_
 
std::string last_control_name_
 
boost::shared_ptr< QMenu > menu_
 
std::map< uint32_t, MenuNodemenu_entries_
 
boost::recursive_mutex mutex_
 
std::string name_
 
Ogre::Quaternion orientation_
 
bool pose_changed_
 
bool pose_update_requested_
 
Ogre::Vector3 position_
 
std::string reference_frame_
 
Ogre::SceneNode * reference_node_
 
ros::Time reference_time_
 
Ogre::Quaternion requested_orientation_
 
Ogre::Vector3 requested_position_
 
float scale_
 
bool show_visual_aids_
 
boost::shared_ptr< boost::thread > sys_thread_
 
Ogre::Vector3 three_d_point_for_menu_
 
double time_since_last_feedback_
 
std::vector< uint32_t > top_level_menu_ids_
 
std::string topic_ns_
 

Detailed Description

Definition at line 67 of file interactive_marker.h.

Member Typedef Documentation

Definition at line 191 of file interactive_marker.h.

typedef std::map<std::string, InteractiveMarkerControlPtr> rviz::InteractiveMarker::M_ControlPtr
protected

Definition at line 192 of file interactive_marker.h.

Constructor & Destructor Documentation

rviz::InteractiveMarker::InteractiveMarker ( Ogre::SceneNode *  scene_node,
DisplayContext context 
)

Definition at line 59 of file interactive_marker.cpp.

rviz::InteractiveMarker::~InteractiveMarker ( )
virtual

Definition at line 72 of file interactive_marker.cpp.

Member Function Documentation

boost::shared_ptr<QMenu> rviz::InteractiveMarker::getMenu ( )
inline
Returns
A shared_ptr to the QMenu owned by this InteractiveMarker.

Definition at line 147 of file interactive_marker.h.

const std::string& rviz::InteractiveMarker::getName ( )
inline

Definition at line 103 of file interactive_marker.h.

const Ogre::Quaternion& rviz::InteractiveMarker::getOrientation ( )
inline

Definition at line 99 of file interactive_marker.h.

const Ogre::Vector3& rviz::InteractiveMarker::getPosition ( )
inline

Definition at line 98 of file interactive_marker.h.

const std::string& rviz::InteractiveMarker::getReferenceFrame ( )
inline

Definition at line 102 of file interactive_marker.h.

float rviz::InteractiveMarker::getSize ( )
inline

Definition at line 101 of file interactive_marker.h.

bool rviz::InteractiveMarker::handle3DCursorEvent ( ViewportMouseEvent event,
const Ogre::Vector3 cursor_pos,
const Ogre::Quaternion &  cursor_rot,
const std::string &  control_name 
)

Supports selection and menu events from a 3D cursor.

Parameters
eventA struct holding certain event data (see full description InteractiveMarkerControl::handle3DCursorEvent)
cursor_posThe world-relative position of the 3D cursor.
cursor_rotThe world-relative orientation of the 3D cursor.
control_nameThe name of the child InteractiveMarkerControl calling this function.
Returns
true if the cursor event was intercepted, false if it was ignored

Definition at line 490 of file interactive_marker.cpp.

void rviz::InteractiveMarker::handleMenuSelect ( int  menu_item_id)
protectedslot

Definition at line 595 of file interactive_marker.cpp.

bool rviz::InteractiveMarker::handleMouseEvent ( ViewportMouseEvent event,
const std::string &  control_name 
)

Definition at line 537 of file interactive_marker.cpp.

bool rviz::InteractiveMarker::hasMenu ( )
inline

Definition at line 144 of file interactive_marker.h.

QString rviz::InteractiveMarker::makeMenuString ( const std::string &  entry)
protected

Definition at line 278 of file interactive_marker.cpp.

void rviz::InteractiveMarker::populateMenu ( QMenu *  menu,
std::vector< uint32_t > &  ids 
)
protected

Definition at line 252 of file interactive_marker.cpp.

bool rviz::InteractiveMarker::processMessage ( const visualization_msgs::InteractiveMarker &  message)

Definition at line 98 of file interactive_marker.cpp.

void rviz::InteractiveMarker::processMessage ( const visualization_msgs::InteractiveMarkerPose &  message)

Definition at line 78 of file interactive_marker.cpp.

void rviz::InteractiveMarker::publishFeedback ( visualization_msgs::InteractiveMarkerFeedback &  feedback,
bool  mouse_point_valid = false,
const Ogre::Vector3 mouse_point_rel_world = Ogre::Vector3(0,0,0) 
)

Definition at line 634 of file interactive_marker.cpp.

void rviz::InteractiveMarker::publishPose ( )
protected

Definition at line 385 of file interactive_marker.cpp.

void rviz::InteractiveMarker::requestPoseUpdate ( Ogre::Vector3  position,
Ogre::Quaternion  orientation 
)

Definition at line 395 of file interactive_marker.cpp.

void rviz::InteractiveMarker::reset ( )
protected
void rviz::InteractiveMarker::rotate ( Ogre::Quaternion  delta_orientation,
const std::string &  control_name 
)

Definition at line 465 of file interactive_marker.cpp.

void rviz::InteractiveMarker::setPose ( Ogre::Vector3  position,
Ogre::Quaternion  orientation,
const std::string &  control_name 
)

Definition at line 411 of file interactive_marker.cpp.

void rviz::InteractiveMarker::setShowAxes ( bool  show)

Definition at line 442 of file interactive_marker.cpp.

void rviz::InteractiveMarker::setShowDescription ( bool  show)

Definition at line 433 of file interactive_marker.cpp.

void rviz::InteractiveMarker::setShowVisualAids ( bool  show)

Definition at line 448 of file interactive_marker.cpp.

void rviz::InteractiveMarker::showMenu ( ViewportMouseEvent event,
const std::string &  control_name,
const Ogre::Vector3 three_d_point,
bool  valid_point 
)

Pop up the context menu for this marker.

Parameters
eventA struct holding certain event data (see full description on InteractiveMarkerControl::handle3DCursorEvent)
control_nameThe name of the InteractiveMarkerControl that was selected.
three_d_pointThe world-relative position associated with this mouse-click or cursor event.
valid_pointTrue if three_d_point is valid (e.g. if the mouse ray was successfully intersected with marker geometry).

Definition at line 584 of file interactive_marker.cpp.

void rviz::InteractiveMarker::startDragging ( )

Definition at line 471 of file interactive_marker.cpp.

void rviz::InteractiveMarker::statusUpdate ( StatusProperty::Level  level,
const std::string &  name,
const std::string &  text 
)
signal
void rviz::InteractiveMarker::stopDragging ( )

Definition at line 478 of file interactive_marker.cpp.

void rviz::InteractiveMarker::translate ( Ogre::Vector3  delta_position,
const std::string &  control_name 
)

Definition at line 459 of file interactive_marker.cpp.

void rviz::InteractiveMarker::update ( float  wall_dt)

Definition at line 350 of file interactive_marker.cpp.

void rviz::InteractiveMarker::updateReferencePose ( )
protected

Definition at line 297 of file interactive_marker.cpp.

void rviz::InteractiveMarker::userFeedback ( visualization_msgs::InteractiveMarkerFeedback &  feedback)
signal

Member Data Documentation

Axes* rviz::InteractiveMarker::axes_
protected

Definition at line 230 of file interactive_marker.h.

std::string rviz::InteractiveMarker::client_id_
protected

Definition at line 235 of file interactive_marker.h.

DisplayContext* rviz::InteractiveMarker::context_
protected

Definition at line 173 of file interactive_marker.h.

M_ControlPtr rviz::InteractiveMarker::controls_
protected

Definition at line 193 of file interactive_marker.h.

std::string rviz::InteractiveMarker::description_
protected

Definition at line 196 of file interactive_marker.h.

InteractiveMarkerControlPtr rviz::InteractiveMarker::description_control_
protected

Definition at line 232 of file interactive_marker.h.

bool rviz::InteractiveMarker::dragging_
protected

Definition at line 198 of file interactive_marker.h.

bool rviz::InteractiveMarker::frame_locked_
protected

Definition at line 178 of file interactive_marker.h.

bool rviz::InteractiveMarker::got_3d_point_for_menu_
protected

Definition at line 241 of file interactive_marker.h.

bool rviz::InteractiveMarker::has_menu_
protected

Definition at line 208 of file interactive_marker.h.

double rviz::InteractiveMarker::heart_beat_t_
protected

Definition at line 226 of file interactive_marker.h.

std::string rviz::InteractiveMarker::last_control_name_
protected

Definition at line 224 of file interactive_marker.h.

boost::shared_ptr<QMenu> rviz::InteractiveMarker::menu_
protected

Definition at line 207 of file interactive_marker.h.

std::map< uint32_t, MenuNode > rviz::InteractiveMarker::menu_entries_
protected

Definition at line 218 of file interactive_marker.h.

boost::recursive_mutex rviz::InteractiveMarker::mutex_
protected

Definition at line 237 of file interactive_marker.h.

std::string rviz::InteractiveMarker::name_
protected

Definition at line 195 of file interactive_marker.h.

Ogre::Quaternion rviz::InteractiveMarker::orientation_
protected

Definition at line 185 of file interactive_marker.h.

bool rviz::InteractiveMarker::pose_changed_
protected

Definition at line 188 of file interactive_marker.h.

bool rviz::InteractiveMarker::pose_update_requested_
protected

Definition at line 201 of file interactive_marker.h.

Ogre::Vector3 rviz::InteractiveMarker::position_
protected

Definition at line 184 of file interactive_marker.h.

std::string rviz::InteractiveMarker::reference_frame_
protected

Definition at line 176 of file interactive_marker.h.

Ogre::SceneNode* rviz::InteractiveMarker::reference_node_
protected

Definition at line 181 of file interactive_marker.h.

ros::Time rviz::InteractiveMarker::reference_time_
protected

Definition at line 177 of file interactive_marker.h.

Ogre::Quaternion rviz::InteractiveMarker::requested_orientation_
protected

Definition at line 203 of file interactive_marker.h.

Ogre::Vector3 rviz::InteractiveMarker::requested_position_
protected

Definition at line 202 of file interactive_marker.h.

float rviz::InteractiveMarker::scale_
protected

Definition at line 205 of file interactive_marker.h.

bool rviz::InteractiveMarker::show_visual_aids_
protected

Definition at line 244 of file interactive_marker.h.

boost::shared_ptr< boost::thread > rviz::InteractiveMarker::sys_thread_
protected

Definition at line 239 of file interactive_marker.h.

Ogre::Vector3 rviz::InteractiveMarker::three_d_point_for_menu_
protected

Definition at line 242 of file interactive_marker.h.

double rviz::InteractiveMarker::time_since_last_feedback_
protected

Definition at line 189 of file interactive_marker.h.

std::vector<uint32_t> rviz::InteractiveMarker::top_level_menu_ids_
protected

Definition at line 221 of file interactive_marker.h.

std::string rviz::InteractiveMarker::topic_ns_
protected

Definition at line 234 of file interactive_marker.h.


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


rviz
Author(s): Dave Hershberger, David Gossow, Josh Faust
autogenerated on Wed Aug 28 2019 04:01:53