Need help visualizing topics using Rviz and opennicamera plugin

asked 2019-02-11 06:21:58 -0500

Hello, I'm trying to visualize the topics that are being published by my gazebo model using the opennicamera plugin, if I execute rostopic list this is the output:

peroanjo@peroanjoPC:~$ rostopic list


which makes me think that the topics are being published correctly, however when I open rviz and select the /camera/depth/image_raw topic, a warning shows up telling that there is no image being recevied. Does this mean that my .gazebo file isn't configured correctly? This is the part of my .gazebo file regarding the kinect camera:

    <!-- kinect -->
    <gazebo reference="kinect">
    <sensor name="camera" type="depth">
<plugin name="camera_plugin" filename="">
          <!-- Keep this zero, update_rate in the parent <sensor> tag
            will control the frame rate. -->
edit retag flag offensive close merge delete


Can you use either rostopic echo <topic_name> or rostopic hz <topic_name> to confirm if any messages are being sent over these topics?

PeteBlackerThe3rd gravatar imagePeteBlackerThe3rd ( 2019-02-11 08:37:18 -0500 )edit

I managed to visualize the first one but for the second one I have the following error: Transform [sender=unknown_publisher] For frame [kinect]: Frame [kinect] does not exist. Both topics seem to be working correctly when using rostopic echo.

peroanjo gravatar imageperoanjo ( 2019-02-11 17:33:20 -0500 )edit

Whenever RVIZ says a frame doesn't exist it means there's no TF link between the currently selected fixed frame and that sensors frame. In your case you probably just need to change the fixed frame in RVIZ to kinect.

PeteBlackerThe3rd gravatar imagePeteBlackerThe3rd ( 2019-02-11 17:50:38 -0500 )edit

Also make sure you a viewing the topic as an image not a camera. They are different things, the image view is what will show you the images received more easily.

PeteBlackerThe3rd gravatar imagePeteBlackerThe3rd ( 2019-02-11 17:51:57 -0500 )edit

But the link between my fixed frame (base_link) and my sensor is called kinect, or at least this is the part of my .gazebo file regarding that:

<link name="kinect"> <inertial>....... ....

peroanjo gravatar imageperoanjo ( 2019-02-11 18:04:15 -0500 )edit

Sorry, my .xacro file, not my .gazebo file.

peroanjo gravatar imageperoanjo ( 2019-02-11 18:05:59 -0500 )edit