Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

depth_image_proc/point_cloud_xyzi_radial Add intensity conversion (copy) for float #336

Merged
merged 2 commits into from
Nov 4, 2019

Conversation

madsherlock
Copy link

@madsherlock madsherlock commented May 15, 2018

This commit enables the generation of xyzi point clouds from 32-bit floating point intensity images.
The destination data type for intensity storage is 32-bit float, so all that is required is a data copy.
The change in this commit is simply an extension of the if-else statement to include the TYPE_32FC1 type and apply the usual convert_intensity() method.

This applies to the depth_image_proc/point_cloud_xyzi_radial and depth_image_proc/point_cloud_xyzi nodelets.

PS: I do have a 3D camera with a manufacturer-supported ROS driver providing me with 32-bit float intensity images.

This commit enables the generation of xyzi point clouds from 32-bit floating point intensity images.
The destination data type for intensity storage is 32-bit float, so all that is required is a data copy.
The change in this commit is simply an extension of the if-else statement to include the TYPE_32FC1 type and apply the usual convert_intensity() method.
@k-okada
Copy link
Contributor

k-okada commented May 17, 2018 via email

@madsherlock
Copy link
Author

I would love to, but I don't understand your request.

I added a minor feature to the depth processing node.

Do you want to see the error message that would be generated if I tried using the unmodified node on my incompatible data?

@k-okada
Copy link
Contributor

k-okada commented May 24, 2018

Do you want to see the error message

yes, error message and how the node behavies.

@madsherlock
Copy link
Author

madsherlock commented May 25, 2018

I will try and generate such an error later.
In the meantime, I can tell you the error that would be produced in the image callback of the point_cloud_xyzi_radial node:
Intensity image has unsupported encoding [32FC1]
This error would be thrown by a call to NODELET_ERROR_THROTTLE() at a maximum rate of 5 Hz and the image callback would return without publishing a point cloud.

A similar error message would be produced in the image callback of the point_cloud_xyzi node:
Depth image has unsupported encoding [32FC1]
And otherwise the exact same behaviour would be observed.

To produce these error messages, you need the nodes to subscribe to an intensity image with the TYPE_32FC1 data type.

Edit:
Here is a log excerpt from May 16th, right before I found out the feature was missing:
1526423924.533520542 ERROR [/media/data/catkin_ws/src/image_pipeline/depth_image_proc/src/nodelets/point_cloud_xyzi_radial.cpp:250(PointCloudXyziRadialNodelet::imageCb) [topics: /rosout, /ifm3d/camera/cloud_rect, /ifm3d/bond] Intensity image has unsupported encoding [32FC1]

@JWhitleyWork JWhitleyWork changed the base branch from indigo to melodic April 25, 2019 14:32
@SteveMacenski
Copy link
Member

@JWhitleyAStuff any issue merging this?

@JWhitleyWork
Copy link
Collaborator

LGTM! Onward!

@SteveMacenski SteveMacenski merged commit 56c3874 into ros-perception:melodic Nov 4, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants