MCPcopy Create free account
hub / github.com/KumarRobotics/sloam / DecodeImage

Function DecodeImage

sloam/src/viz/vizTools.cpp:317–331  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

315 }
316
317 cv::Mat DecodeImage(const sensor_msgs::ImageConstPtr &image_msg)
318 {
319 cv::Mat image;
320 cv_bridge::CvImagePtr input_bridge;
321 try
322 {
323 input_bridge = cv_bridge::toCvCopy(image_msg, image_msg->encoding);
324 image = input_bridge->image;
325 }
326 catch (cv_bridge::Exception &ex)
327 {
328 ROS_ERROR("Failed to convert depth image");
329 }
330 return image;
331 }
332
333} // namespace sloam

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected