Skip to main content
1 of 7
Babel
  • 80.4k
  • 15
  • 97
  • 245

A vector based solution:

  1. Create the direct, connecting lines between start and destination points.

  2. Keep only lines that do not cross a barrier.

  3. Where the line crosses a barrier, create the convex hull from the geometry collection, containing: start point, destination point, plus all nodes (vertices) of the barrier line that the line from step 1 crosses.

  4. Convert the convex hull to the boundary.

  5. Use shortest path algorithm from start to destination, using the boundary from step 4 as network.

Babel
  • 80.4k
  • 15
  • 97
  • 245