Class FastConvexHull

java.lang.Object
com.github.micycle1.geoblitz.FastConvexHull

public final class FastConvexHull extends Object
Computes the convex hull of a set of points using a fast monotone chain algorithm.
  • Constructor Summary

    Constructors
    Constructor
    Description
    FastConvexHull(org.locationtech.jts.geom.Coordinate[] pts, org.locationtech.jts.geom.GeometryFactory geomFactory)
    Creates a new FastConvexHull for the given points.
    FastConvexHull(org.locationtech.jts.geom.Geometry geometry)
    Creates a new FastConvexHull for the given Geometry's coordinates.
  • Method Summary

    Modifier and Type
    Method
    Description
    org.locationtech.jts.geom.Geometry
    Computes the convex hull.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • FastConvexHull

      public FastConvexHull(org.locationtech.jts.geom.Geometry geometry)
      Creates a new FastConvexHull for the given Geometry's coordinates.
      Parameters:
      geometry - the geometry whose points will be used
    • FastConvexHull

      public FastConvexHull(org.locationtech.jts.geom.Coordinate[] pts, org.locationtech.jts.geom.GeometryFactory geomFactory)
      Creates a new FastConvexHull for the given points.
      Parameters:
      pts - the input points
      geomFactory - the geometry factory to use for the result
  • Method Details

    • getConvexHull

      public org.locationtech.jts.geom.Geometry getConvexHull()
      Computes the convex hull.
      Returns:
      the convex hull geometry