16 #include <cv_bridge/cv_bridge.h>    18 #include <sensor_msgs/Image.h>    19 #include <sensor_msgs/image_encodings.h>    40     cv_bridge::CvImage img_bridge;
    42     sensor_msgs::Image msg;
    43     img_bridge = CvImage(msg.header, sensor_msgs::image_encodings::BGR8, cvImg);
    45     img_bridge.toImageMsg(msg);
    47     msg.encoding = 
"bgr8";
    48     msg.header = msg_header;
 cv::Mat & asCvMatRef()
Get a reference to the internal cv::Mat, which can be resized, etc. 
 
size_t getHeight() const override
Returns the height of the image in pixels. 
 
size_t getWidth() const override
Returns the width of the image in pixels. 
 
bool toROS(const mrpt::obs::CObservationGPS &obj, const std_msgs::Header &msg_header, sensor_msgs::NavSatFix &msg)
Convert mrpt::obs::CObservationGPS -> sensor_msgs/NavSatFix The user must supply the "msg_header" fie...
 
ROS message: http://docs.ros.org/api/sensor_msgs/html/msg/NavSatFix.html MRPT message: https://github...
 
Deep copy: the copied object has a duplicate of all data, becoming independent. 
 
bool fromROS(const sensor_msgs::NavSatFix &msg, mrpt::obs::CObservationGPS &obj)
Convert sensor_msgs/NavSatFix -> mrpt::obs::CObservationGPS. 
 
A class for storing images as grayscale or RGB bitmaps.