30 #ifndef RVIZ_INTERACTIVE_MARKER_DISPLAY_H 31 #define RVIZ_INTERACTIVE_MARKER_DISPLAY_H 36 #include <visualization_msgs/InteractiveMarker.h> 37 #include <visualization_msgs/InteractiveMarkerUpdate.h> 38 #include <visualization_msgs/InteractiveMarkerInit.h> 55 class RosTopicProperty;
59 typedef std::pair<std::string, int32_t>
MarkerID;
73 void update(
float wall_dt,
float ros_dt)
override;
77 void reset()
override;
91 void publishFeedback(visualization_msgs::InteractiveMarkerFeedback& feedback);
101 void initCb(visualization_msgs::InteractiveMarkerInitConstPtr msg);
102 void updateCb(visualization_msgs::InteractiveMarkerUpdateConstPtr msg);
104 void resetCb(std::string server_id);
107 const std::string& server_id,
108 const std::string& msg);
111 const std::vector<visualization_msgs::InteractiveMarker>& markers);
114 const std::vector<visualization_msgs::InteractiveMarkerPose>& marker_poses);
116 void eraseMarkers(
const std::string& server_id,
const std::vector<std::string>& names);
119 void processMarkerChanges(
const std::vector<visualization_msgs::InteractiveMarker>* markers =
nullptr,
120 const std::vector<visualization_msgs::InteractiveMarkerPose>* poses =
nullptr,
121 const std::vector<std::string>* erases =
nullptr);
128 M_StringToIMPtr&
getImMap(std::string server_id);
void updateShowVisualAids()
void updateMarkers(const std::string &server_id, const std::vector< visualization_msgs::InteractiveMarker > &markers)
void setTopic(const QString &topic, const QString &datatype) override
Set the ROS topic to listen to for this display.
void initCb(visualization_msgs::InteractiveMarkerInitConstPtr msg)
M_StringToIMPtr & getImMap(std::string server_id)
void fixedFrameChanged() override
Called by setFixedFrame(). Override to respond to changes to fixed_frame_.
void eraseMarkers(const std::string &server_id, const std::vector< std::string > &names)
void updateCb(visualization_msgs::InteractiveMarkerUpdateConstPtr msg)
void onEnable() override
Derived classes override this to do the actual work of enabling themselves.
BoolProperty * show_descriptions_property_
void onDisable() override
Derived classes override this to do the actual work of disabling themselves.
BoolProperty * enable_transparency_property_
boost::shared_ptr< interactive_markers::InteractiveMarkerClient > im_client_
void statusCb(interactive_markers::InteractiveMarkerClient::StatusT status, const std::string &server_id, const std::string &msg)
void updatePoses(const std::string &server_id, const std::vector< visualization_msgs::InteractiveMarkerPose > &marker_poses)
std::pair< std::string, int32_t > MarkerID
std::map< std::string, IMPtr > M_StringToIMPtr
void publishFeedback(visualization_msgs::InteractiveMarkerFeedback &feedback)
BoolProperty * show_axes_property_
void processMarkerChanges(const std::vector< visualization_msgs::InteractiveMarker > *markers=nullptr, const std::vector< visualization_msgs::InteractiveMarkerPose > *poses=nullptr, const std::vector< std::string > *erases=nullptr)
std::map< std::string, M_StringToIMPtr > M_StringToStringToIMPtr
void updateShowDescriptions()
BoolProperty * show_visual_aids_property_
RosTopicProperty * marker_update_topic_property_
Displays Interactive Markers.
void reset() override
Called to tell the display to clear its state.
boost::shared_ptr< MarkerBase > MarkerBasePtr
void updateEnableTransparency()
Property specialized to provide getter for booleans.
ros::Publisher feedback_pub_
M_StringToStringToIMPtr interactive_markers_
void update(float wall_dt, float ros_dt) override
Called periodically by the visualization manager.
void onStatusUpdate(StatusProperty::Level level, const std::string &name, const std::string &text)
void resetCb(std::string server_id)
boost::shared_ptr< InteractiveMarker > IMPtr
void onInitialize() override
Override this function to do subclass-specific initialization.
InteractiveMarkerDisplay()