ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

If I were you, instead of trying to do this directly in RVIZ of Gazebo I would look at how to process the costmap in a custom node, and from there extract the information you want.

Maps in ROS are represented as Occupancy Grids. This stores a discretized (i.e. cells) representation of the environment. From this representation, with the correct logic in a roscpp or rospy node, you can extract the information you want. Here is an example in the ROS nav stack Global Planner Costmap which manipulates this discretized representation in c++. Costmap2D is not exactly a occupancy grid but the concept/representation is similar.

Once you have the grid available to you in c++, I imagine you can produce the logic required to generate the result you want.