[ROS2] image_transport and RVIZ2 Camera, something wrong
Hi,
using Rviz2 and imagetransport with Crystal Clemmys I noticed that the Camera
plugin in Rviz2 is not aligned to how `imagetransport::CameraPublisher` creates the topic structure.
The Camera
plugin for an image topic image/data
expects the camera_info
as image/data/camera_info
, instead the image_transport::CameraPublisher
publishes it as image/camera_info
(as for ROS1).
Who is wrong? The Camera plugin or image_transport?
Asked by Myzhar on 2019-01-16 08:39:27 UTC
Answers
In the ROS1 image_transport, it is assumed that the camera_info
topic should be a peer to the topic that the data is being published on, so for example
- stereo/left/image (sensor_msgs/Image)
- stereo/left/image/compressed (
) - stereo/left/image/theora (
) - stereo/left/camera_info (sensor_msgs/CameraInfo)
The goal with the port of image_transport
to ROS2 was to reproduce the behavior from ROS1, so I believe that this is a bug in the way that RViz handles it. The quick fix would be to adjust this in RViz, but I believe a better fix would be to also bring the new image_transport
functionality into RViz.
Asked by mjcarroll on 2019-01-16 19:12:49 UTC
Comments
Yes, the bug is in the Rviz2 plugin. I found an old open issue about this problem on github. The wrong topic structure was reported, but no one fixed it yet.
Asked by Myzhar on 2019-01-17 01:55:46 UTC
For ref, the bug: https://github.com/ros2/rviz/issues/207. There's a PR to fix it: https://github.com/ros2/rviz/pull/419
Asked by clyde on 2019-12-06 20:43:41 UTC
Comments