diff --git a/depth_image_proc/src/point_cloud_xyzrgb.cpp b/depth_image_proc/src/point_cloud_xyzrgb.cpp index f5d3c0380..2f3daec81 100644 --- a/depth_image_proc/src/point_cloud_xyzrgb.cpp +++ b/depth_image_proc/src/point_cloud_xyzrgb.cpp @@ -267,6 +267,10 @@ void PointCloudXyzrgbNode::imageCb( convertRgb(rgb_msg, cloud_msg, red_offset, green_offset, blue_offset, color_step); } else if (rgb_msg->encoding == sensor_msgs::image_encodings::BGR8) { convertRgb(rgb_msg, cloud_msg, red_offset, green_offset, blue_offset, color_step); + } else if (rgb_msg->encoding == sensor_msgs::image_encodings::BGRA8) { + convertRgb(rgb_msg, cloud_msg, red_offset, green_offset, blue_offset, color_step); + } else if (rgb_msg->encoding == sensor_msgs::image_encodings::RGBA8) { + convertRgb(rgb_msg, cloud_msg, red_offset, green_offset, blue_offset, color_step); } else if (rgb_msg->encoding == sensor_msgs::image_encodings::MONO8) { convertRgb(rgb_msg, cloud_msg, red_offset, green_offset, blue_offset, color_step); } else { diff --git a/depth_image_proc/src/point_cloud_xyzrgb_radial.cpp b/depth_image_proc/src/point_cloud_xyzrgb_radial.cpp index 55e0e23d3..ec76889c8 100644 --- a/depth_image_proc/src/point_cloud_xyzrgb_radial.cpp +++ b/depth_image_proc/src/point_cloud_xyzrgb_radial.cpp @@ -265,6 +265,10 @@ void PointCloudXyzrgbRadialNode::imageCb( convertRgb(rgb_msg, cloud_msg, red_offset, green_offset, blue_offset, color_step); } else if (rgb_msg->encoding == sensor_msgs::image_encodings::BGR8) { convertRgb(rgb_msg, cloud_msg, red_offset, green_offset, blue_offset, color_step); + } else if (rgb_msg->encoding == sensor_msgs::image_encodings::BGRA8) { + convertRgb(rgb_msg, cloud_msg, red_offset, green_offset, blue_offset, color_step); + } else if (rgb_msg->encoding == sensor_msgs::image_encodings::RGBA8) { + convertRgb(rgb_msg, cloud_msg, red_offset, green_offset, blue_offset, color_step); } else if (rgb_msg->encoding == sensor_msgs::image_encodings::MONO8) { convertRgb(rgb_msg, cloud_msg, red_offset, green_offset, blue_offset, color_step); } else {