Expand description
A module containing various mapping-algorithms for polygons.
Modules§
- double_
precision - This module contains polygon mapping-algorithms that are pregenerated for double precision floating points.
- single_
precision - This module contains polygon mapping-algorithms that are pregenerated for single precision floating points.
Functions§
- are_
multiple_ points_ in_ polygon - This function will run the
is_single_point_in_polygon
for each on of the points given, and the provided polygon, But pre-calculates the polygon extents to reduce workloads for larger datasets, please profile this for you specific use-case. - calculate_
polygon_ extents - This function calculates the extents of the polygon, i.e., the minimum and maximum values for each coordinate dimension.
- graham_
scan - Computes the convex hull of a set of points using the Graham Scan algorithm. Specifically the Monotone Chain variant This version sorts the points lexicographically before computing the convex hull. A downside of using this algorithm is that it does not handle collinear points well.
- is_
single_ point_ in_ polygon - Check if the provided point is within the provided polygon.
- jarvis_
march - Computes the convex hull of a set of points using the Jarvis March algorithm. This algorithm uses a pivot point to find the next point in the convex hull by selecting for each point, the point which makes the largest outwards turn that is less than 180 degrees.