How to record values within a vector of type cv::Point2f?

asked 2015-05-28 18:21:07 -0500

215 gravatar image

I was thinking of publishing the data on topic, and then use Rosbag to record the data being published on the topic. The problem is though my Publisher doesn't seem tip accept the message type

data_pub = nh.advertise<cv::Point2f>("/data,1)

It says that the message type doesn't fit.. which doesn't make sense?

Error message:

No math for call to (Ros::publisher) (cv::Point_<float>&)' 
data_pub(point_final[i])

How do i fix this issue?

edit retag flag offensive close merge delete

Comments

Have you tried publishing it through ROS as a geometry_msgs::Point ? I think you can only publish using ROS messages. http://docs.ros.org/api/geometry_msgs... Or try a different message type.

frankb gravatar image frankb  ( 2015-05-28 20:18:15 -0500 )edit