Ask Your Question
0

Visualize 2d objects in 2d image in rviz

asked 2018-07-26 03:29:06 -0600

sietschie gravatar image

updated 2018-07-26 08:56:25 -0600

Hello,

I would like to visualize some 2d objects using lines or bounding boxes in a 2d image in RVIZ. So far I was not able to find a way. I am suspecting that this might not be supported by RVIZ. But since I only started using ROS it is also likely that I was just looking at the wrong place.

Here is what I found out so far:

  • I can visualize things in 3D using markers.
  • I can visualize an image using the display type Image.
  • I can also visualize an image using the display type camera, and I think if there is correct calibration information, the 3d markers get projected in that image.

But is there a way to directly draw something like the markers into a 2d image?

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2018-07-26 11:32:56 -0600

The easiest way to do this is to make your own node which subscribes to the image topic, draws the markers on top of the image and publishes it on a new topic. I do this for debugging vision algorithms on a regular basis.

The image transport package can be used to receive and publish openCV images, openCV's basic drawing functions are described here.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

Stats

Asked: 2018-07-26 03:28:13 -0600

Seen: 398 times

Last updated: Jul 26 '18