cartagen.hull_delaunay#
- hull_delaunay(points, length)#
Create the hull of a set of points using the Delaunay triangulation.
This algorithm was described by Duckham et al. [1] and is also described in Galton & Duckham [2] It first computes the Delaunay triangulation of the points, and then removes iteratively the boundary edges that are longer than a given parameter.
- Parameters:
- Returns:
Warning
This algorithm cannot create multiple polygons, unlike
hull_swinging_arm(). Using a length too low can produce an invalid geometry.See also
hull_swinging_armCreate a polygon from a set of points using the swinging arm algorithm.
References
Examples
>>> points = [ Point(1, 1), Point(6, 6), Point(1, 6), Point(6, 5), Point(2, 4), Point(2, 1), Point(1, 4) ] >>> delaunay_hull(points, 2.0) <POLYGON ((1 1, 1 4, 1 6, 6 6, 6 5, 2 4, 2 1, 1 1))>