24 qRegisterMetaType<Eigen::Matrix4d>(
"Eigen::Matrix4d");
25 qRegisterMetaType<std::string>(
"std::string");
28 client_GetRecognizer = nh.serviceClient<asr_aruco_marker_recognition::GetRecognizer>(
"/asr_aruco_marker_recognition/get_recognizer");
29 client_ReleaseRecognizer = nh.serviceClient<asr_aruco_marker_recognition::ReleaseRecognizer>(
"/asr_aruco_marker_recognition/release_recognizer");
34 ROS_INFO_STREAM(
"Marker Recognition: Early Abort = " << earlyabort_timeout);
35 if (timeout-earlyabort_timeout <= 0.0)
37 ROS_ERROR(
"Marker Recognition: Early Abort was invalid");
38 earlyabort_timeout = 0.0;
55 ROS_INFO(
"No Marker found -> Early abort.");
71 ROS_ERROR(
"Could not start recognition.");
77 asr_msgs::AsrObject o = *object;
79 std::string ID = o.type;
80 Eigen::Affine3d transform;
81 if(o.sampledPoses.size() > 0)
83 tf::poseMsgToEigen(o.sampledPoses.at(0).pose, transform);
91 asr_aruco_marker_recognition::ReleaseRecognizer release;
98 asr_aruco_marker_recognition::GetRecognizer
get;
Subscriber subscribe(const std::string &topic, uint32_t queue_size, void(T::*fp)(M), T *obj, const TransportHints &transport_hints=TransportHints())
bool call(MReq &req, MRes &res)
ROSCPP_DECL const std::string & getName()
void markerRecognitionCallback(const asr_msgs::AsrObject::ConstPtr object)
Marker_Manager(double timeout, double earlyabort_timeout, QObject *parent=0)
ros::ServiceClient client_ReleaseRecognizer
double earlyabort_timeout
void markerFound(std::string markerNumber, const Eigen::Matrix4d &transformation)
#define ROS_INFO_STREAM(args)
ros::ServiceClient client_GetRecognizer