Skip to main content

smooth_path

Function smooth_path 

Source
pub fn smooth_path(path: &Path2D, grid_map: &GridMap) -> Path2D
Expand description

Smooth a path by removing intermediate waypoints that can be skipped via direct line-of-sight.

Uses a greedy forward scan: from the current anchor point, find the farthest reachable point with line-of-sight, advance the anchor there, and repeat.