Robotics StackExchange | Archived questions

Accessing video frames of a rosviz display

Hi,

do someone have experience accessing the video frame of a rviz display? I explain better: let's say I implement an application like the sample one: http://docs.ros.org/melodic/api/librviz_tutorial/html/index.html

but then I want to send over a network stream the frames and timestamps of my rviz display. So I want to access the video frames through the C++ API and the related timestamps.

Any ideas on how to achieve that?

Thanks

Asked by Sergio Cap on 2019-04-13 09:21:12 UTC

Comments

Look at #q142351

Asked by lucasw on 2019-04-15 10:03:37 UTC

Hi Luca, thanks for the answer, it looks what I was searching for. Although I'm trying to install it using catkin...I can see the plugin available in rosviz, but when I try to add it, I have the following error:

CameraPub The class required for this display, 'rviz_camera_stream/CameraPub', could not be loaded. Error: Could not find library corresponding to plugin rviz_camera_stream/CameraPub. Make sure the plugin description XML file has the correct name of the library and that the library actually exists.

Any advice?

Asked by Sergio Cap on 2019-04-15 14:53:38 UTC

Run source on your devel/setup.bash before running rviz. If you are using install/setup.bash it's possible I haven't made it install properly, I can take a look in a day or two.

Asked by lucasw on 2019-04-15 15:04:59 UTC

Thanks :) It work now

Asked by Sergio Cap on 2019-04-16 06:51:27 UTC

Hi Lucas, is there a way to move the camera created by your plugin? Could they be moved in rosviz? Or through a topic?

Asked by Sergio Cap on 2019-05-02 17:40:59 UTC

It's controlled by the transform of the frame_id in the input camera_info header. You could broadcast that tf manually, through a static_transform_publisher, or through an rviz interactive tf broadcaster like https://github.com/lucasw/rviz_interactive_tf (there are some others out there also).

Asked by lucasw on 2019-05-02 18:31:08 UTC

Answers