1 #ifndef ROBOTVISIONINTERFACE_H 2 #define ROBOTVISIONINTERFACE_H 6 #include <tf/transform_listener.h> 7 #include <geometry_msgs/Twist.h> 8 #include <image_transport/image_transport.h> 9 #include <opencv2/imgcodecs.hpp> 10 #include <opencv2/calib3d.hpp> 11 #include <opencv2/highgui.hpp> 12 #include <opencv2/imgproc/imgproc.hpp> 13 #include <cv_bridge/cv_bridge.h> 17 #include "../../support/header/conversions.h" 18 #include "../../support/header/defines.h" 32 int getwTv(Eigen::Matrix4d* wTv_eigen);
33 int sendyDot(std::vector<double> yDot);
37 int getRightImage(cv::Mat *imageCV);
38 int getRangeRightImage(cv::Mat *imageCV);
40 void imageRightCallback(
const sensor_msgs::ImageConstPtr& msg);
41 void imageRangeRightCallback(
const sensor_msgs::ImageConstPtr& msg);
45 std::string robotName;
46 std::string topicRoot;
47 tf::TransformListener tfListener;
48 ros::Publisher pubTwist;
50 image_transport::Subscriber subLeftImage;
51 image_transport::Subscriber subRightImage;
52 image_transport::Subscriber subRangeRightImage;
54 sensor_msgs::ImageConstPtr leftImage;
55 sensor_msgs::ImageConstPtr rightImage;
56 sensor_msgs::ImageConstPtr rangeRightImage;
63 #endif // ROBOTVISIONINTERFACE_H void imageLeftCallback(const sensor_msgs::ImageConstPtr &msg)
RobotVisionInterface::imageLeftCallback store in member class the image arrived, process it only when...
int getLeftImage(cv::Mat *imageCV)
RobotVisionInterface::getLeftImage for now convert in 8bit grayscale image.
robotInterface: a ros node responsible of taken info from simulator and robot sensors, and of given commands back. It is the intermiate layer between robot and mission manager ("main") This "Vision" Version is specialized for a robot with no arm and horizontal cameras used to detect hole and help the insertion phase.
RobotVisionInterface(ros::NodeHandle nh, std::string robotName)
RobotVisionInterface::RobotInterfaceVision Constructor.