Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037 #ifndef MOVEIT_ROBOT_INTERACTION_INTERACTION_
00038 #define MOVEIT_ROBOT_INTERACTION_INTERACTION_
00039
00040 #include <visualization_msgs/InteractiveMarkerFeedback.h>
00041 #include <visualization_msgs/InteractiveMarker.h>
00042 #include <interactive_markers/menu_handler.h>
00043 #include <moveit/robot_state/robot_state.h>
00044 #include <boost/function.hpp>
00045 #include <boost/thread.hpp>
00046 #include <tf/tf.h>
00047
00048 namespace moveit
00049 {
00050 namespace core
00051 {
00052 class RobotState;
00053 }
00054 }
00055
00056 namespace robot_interaction
00057 {
00058
00059 namespace InteractionStyle
00060 {
00063 enum InteractionStyle
00064 {
00065 POSITION_ARROWS = 1,
00066 ORIENTATION_CIRCLES = 2,
00067 POSITION_SPHERE = 4,
00068 ORIENTATION_SPHERE = 8,
00069 POSITION_EEF = 16,
00070 ORIENTATION_EEF = 32,
00071 FIXED = 64,
00072
00073 POSITION = POSITION_ARROWS |
00074 POSITION_SPHERE |
00075 POSITION_EEF,
00076 ORIENTATION = ORIENTATION_CIRCLES |
00077 ORIENTATION_SPHERE |
00078 ORIENTATION_EEF,
00079 SIX_DOF = POSITION |
00080 ORIENTATION,
00081 SIX_DOF_SPHERE = POSITION_SPHERE |
00082 ORIENTATION_SPHERE,
00083 POSITION_NOSPHERE = POSITION_ARROWS |
00084 POSITION_EEF,
00085 ORIENTATION_NOSPHERE = ORIENTATION_CIRCLES |
00086 ORIENTATION_EEF,
00087 SIX_DOF_NOSPHERE = POSITION_NOSPHERE |
00088 ORIENTATION_NOSPHERE
00089 };
00090 }
00091
00099 typedef boost::function<bool(
00100 const robot_state::RobotState& state,
00101 visualization_msgs::InteractiveMarker& marker)>
00102 InteractiveMarkerConstructorFn;
00103
00115 typedef boost::function<bool(
00116 robot_state::RobotState& state,
00117 const visualization_msgs::InteractiveMarkerFeedbackConstPtr & feedback)>
00118 ProcessFeedbackFn;
00119
00129 typedef boost::function<bool(
00130 const robot_state::RobotState&,
00131 geometry_msgs::Pose&)>
00132 InteractiveMarkerUpdateFn;
00133
00136 struct GenericInteraction
00137 {
00138
00139
00140 InteractiveMarkerConstructorFn construct_marker;
00141
00142
00143
00144 ProcessFeedbackFn process_feedback;
00145
00146
00147
00148 InteractiveMarkerUpdateFn update_pose;
00149
00150
00151
00152 std::string marker_name_suffix;
00153 };
00154
00157 struct EndEffectorInteraction
00158 {
00160 std::string parent_group;
00161
00163 std::string parent_link;
00164
00166 std::string eef_group;
00167
00169 InteractionStyle::InteractionStyle interaction;
00170
00172 double size;
00173
00174 };
00175
00178 struct JointInteraction
00179 {
00181 std::string connecting_link;
00182
00184 std::string parent_frame;
00185
00187 std::string joint_name;
00188
00190 unsigned int dof;
00191
00193 double size;
00194 };
00195
00196 }
00197
00198 #endif