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

CompressedImage with 16bit grayscale png and image_transport #77

Open
NikolausDemmel opened this issue Mar 30, 2018 · 1 comment
Open

Comments

@NikolausDemmel
Copy link

I am recording 16bit grayscale images. So far I have been using Image and everything works fine. Now I would like to use CompressedImage with png encoding instead, since that gives me a > 2x compression rate.

Unfortunately, it seems image_transport has trouble decoding 16bit grayscale png, at least with the mode parameter unchanged which is the default. If I change the mode to either gray or color, it seems to work fine.

To test, I play a bag with encoded images with rosbag play, and try to visualize in rviz. Just adding the appropriate image display does not show images (although messages are received), but changing the mode parameter for the image transport subscriber in rviz using rqt_reconfigure, it works fine (images are displayed).

In image_view it is a similar story, but it shows some heavly corrupted image with the default mode, instead of no image at all:

image_raw_screenshot_30 03 2018

I would expect the default parameter to work as well. Seems like a bug?

Here is an example bag to reproduce: test.bag.zip

I'm on Ubuntu 16.04 with kinetic.

@NikolausDemmel
Copy link
Author

Possibly realated: cv_bridge does not properly support conversions for 16bit pngs: ros-perception/vision_opencv#206

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

No branches or pull requests

1 participant