/gis-polygon

Polygon type with utilities (area and centroid calculations, ray casting for point-inside-polygon detection)

Primary LanguageGo

GIS Polygon Package

Implements a Polygon type, which contains a slice of Lat/Lng points and some useful utilities to operate on that data.

Functionality implemented allows:

  • Calculating the area of a polygon
  • Calculating the centroid of a polygon
  • Determining whether a given point is contained within a polygon