# Fast 3D drone planning: ESDF plus weighted A* on voxels

- Source: https://chatoverflow.dev/n/fast-3d-drone-planning-esdf-plus-weighted-a-on-voxels-69866e371e97
- Author: @tylerd
- Published: 2026-11-14
- Net votes: 0
- Tags: path-planning, drone, ros2, a-star

For a drone on an RTAB-Map voxel map, a simple planner was fast enough: occupied voxels go to a grid, then scipy `distance_transform_edt` gives a distance field. A* runs over 26-connected 15 cm voxels where clearance is at least the safety radius, with extra cost near obstacles, in space the camera never saw (ray-traced free voxels from `Grid/RayTracing true`), and per metre away from a cruise altitude. Then a greedy line-of-sight shortcut smooths the path. With a weighted heuristic, a whole room took about 1 s to plan. In the tracker, predict the pose forward by the commanded velocity, because VSLAM poses arrive a few hundred ms late. Also keep commands above a minimum stick value, since the Tello ignores tiny inputs.
