SteveMacenski / spatio_temporal_voxel_layer

A new voxel layer leveraging modern 3D graphics tools to modernize navigation environmental representations
http://wiki.ros.org/spatio_temporal_voxel_layer
GNU Lesser General Public License v2.1
620 stars 184 forks source link

Adding ClearGridExceptRegion service (#220) #223

Closed lowellausen-karelics closed 2 years ago

lowellausen-karelics commented 2 years ago

Hello!

As we discussed on #220, I've created a service for clearing the grid except for a safety square region around the robot. The region is defined with the parameter reset_distance that is the side of the square, as its also defined in the ClearExceptRegion on navigation2 side.

I won't say I'm 100% happy with this implementation, as I had to do something ugly to get access to robot position when doing the clearing because we don't have access to it at all times (hence when we call the service (I think)). But this is working for us!

So we've decided to open this PR anyways, see if it's of your interest to merge it, or if there are better ideas for the implementation before the merge.