Check vehicle costmap for collision-free poses or points
The checkFree
function checks whether vehicle poses or
points are free from obstacles on the vehicle costmap. Path planning algorithms use
checkFree
to check whether candidate vehicle poses along a path
are navigable.
To simplify the collision check for a vehicle pose, vehicleCostmap
inflates obstacles according to the vehicle's InflationRadius
, as specified by the
CollisionChecker
property of the costmap. The collision checker
calculates the inflation radius by enclosing the vehicle in a set of overlapping circles
of radius R, where the centers of these circles lie along the
longitudinal axis of the vehicle. The inflation radius is the minimum
R needed to fully enclose the vehicle in these circles.
A vehicle pose is collision-free when the following conditions apply:
None of the vehicle's circle centers lie on an inflated grid cell.
The cost value of each containing a circle center is less than the
FreeThreshold
of the costmap.
For more details, see the algorithm on
the vehicleCostmap
reference page.
checks whether the vehicle poses are free from collision with obstacles on the
costmap.free
= checkFree(costmap
,vehiclePoses
)
If you specify a small value of InflationRadius
that does not completely enclose
the vehicle, then checkFree
might report occupied poses as
collision-free. To avoid this situation, the default value of
InflationRadius
completely encloses the vehicle.