Skip to content

Commit

Permalink
Support MONO16 image encodings: point_cloud_xyz (#868)
Browse files Browse the repository at this point in the history
Related with this change in ROS 1
#630

Signed-off-by: Alejandro Hernández Cordero <ahcorde@gmail.com>
  • Loading branch information
ahcorde committed Jan 19, 2024
1 parent 6d5edd8 commit d9f8dff
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion depth_image_proc/src/point_cloud_xyz.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ void PointCloudXyzNode::depthCb(
model_.fromCameraInfo(info_msg);

// Convert Depth Image to Pointcloud
if (depth_msg->encoding == enc::TYPE_16UC1) {
if (depth_msg->encoding == enc::TYPE_16UC1 || depth_msg->encoding == enc::MONO16) {
convertDepth<uint16_t>(depth_msg, cloud_msg, model_);
} else if (depth_msg->encoding == enc::TYPE_32FC1) {
convertDepth<float>(depth_msg, cloud_msg, model_);
Expand Down

0 comments on commit d9f8dff

Please sign in to comment.