1
$\begingroup$

Rosanswers logo

Hi guys,

I have a list of (x,y,z) points all of which lie on the same plane. I need to visualize this plane on rviz with these points.

I googled on how to make a plane on rviz and someone mentioned making a cube but reduce a dimension so that it becomes a plane. Now, for a cube, we give a point which will become its center. But I have a bunch of (x,y,z) points that I need to visualize as a plane in rviz. How do I go about doing this? Any thoughts would be welcome.


Originally posted by robot_commander on ROS Answers with karma: 25 on 2017-11-03

Post score: 1

$\endgroup$

3 Answers 3

1
$\begingroup$

Rosanswers logo

The other answers contain some good pointers, but I would recommend you try out davetcoleman/rviz_visual_tools. It already provides you with the infrastructure to get RViz to render planes (in addition to all sorts of other geometric shapes).

rviz visual tools.


Originally posted by gvdhoorn with karma: 86574 on 2017-11-05

This answer was ACCEPTED on the original site

Post score: 2


Original comments

Comment by robot_commander on 2017-11-06:
oh wow. this is great! I'll check it out, thank you!

Comment by robot_commander on 2017-11-06:
I found this git repo which builds on davetcoleman/rviz_visual_tools and gives me a python implementation of publishing markers.

Comment by gvdhoorn on 2017-11-06:
The Python lib is a good find, but notice that the last commit was already almost 2 years ago. rviz_visual_tools has seen some development since that time, so you might want to check whether the Python lib is missing something.

Comment by robot_commander on 2017-11-06:
ahhhh. I see. ok I'll look at it. Thank you very much for all your help! :)

$\endgroup$
1
  • $\begingroup$ Does this remain the tool of choice for ROS Noetic in 2023? Primarily, I need to visualize many polygons somewhat efficiently and conveniently. $\endgroup$ Oct 4 at 15:37
0
$\begingroup$

Rosanswers logo

I would suggest to use the TriangleList as MarkerType. Do you have a triangulation of your points?


Originally posted by NEngelhard with karma: 3519 on 2017-11-04

This answer was NOT ACCEPTED on the original site

Post score: 1


Original comments

Comment by robot_commander on 2017-11-04:
oh you mean, like to make a triangle with three points and increase the scale to visualize?

Comment by robot_commander on 2017-11-04:
ok so I tried making it a triangle and increasing the scale. Now I'm curious as to how the scale affects the triangle_list marker type. so what does scale.x, scale.y and scale.z do specifically in triangle_list marker type?

$\endgroup$
0
$\begingroup$

Rosanswers logo

As far as I'm concerned, it will be better to compute the plane's normal vector and center first by the list of points you mentioned. Then you can make a two-dimensional cube with normal vector and center like the way you have googled.


Originally posted by jinseoi with karma: 21 on 2017-11-05

This answer was NOT ACCEPTED on the original site

Post score: 1

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.