22 #include <geos/geom/Coordinate.h> 23 #include <geos/geom/Point.h> 24 #include <geos/geom/Envelope.h> 25 #include <geos/algorithm/locate/IndexedPointInAreaLocator.h> 26 #include <geos/operation/distance/IndexedFacetDistance.h> 38 class GeometryFactory;
69 std::unique_ptr<geom::Point> getCenter();
81 std::unique_ptr<geom::Point> getRadiusPoint();
88 std::unique_ptr<geom::LineString> getRadiusLine();
98 static std::unique_ptr<geom::Point> getCenter(
const geom::Geometry* polygonal,
double tolerance);
108 static std::unique_ptr<geom::LineString> getRadiusLine(
const geom::Geometry* polygonal,
double tolerance);
124 static std::size_t computeMaximumIterations(
const geom::Geometry* geom,
double toleranceDist);
130 std::unique_ptr<geom::Geometry> inputGeomBoundary;
136 geom::CoordinateXY centerPt;
137 geom::CoordinateXY radiusPt;
141 double distanceToBoundary(
double x,
double y);
147 static constexpr
double SQRT2 = 1.4142135623730951;
155 Cell(
double p_x,
double p_y,
double p_hSize,
double p_distanceToBoundary)
159 , distance(p_distanceToBoundary)
160 , maxDist(p_distanceToBoundary+(p_hSize*SQRT2))
169 double getMaxDistance()
const 173 double getDistance()
const 177 double getHSize()
const 190 bool operator< (
const Cell& rhs)
const 192 return maxDist < rhs.maxDist;
195 bool operator> (
const Cell& rhs)
const 197 return maxDist > rhs.maxDist;
200 bool operator==(
const Cell& rhs)
const 202 return maxDist == rhs.maxDist;
210 using CellQueue = std::priority_queue<Cell>;
213 void createInitialGrid(
const geom::Envelope* env, Cell::CellQueue& cellQueue);
Determines the location of Coordinates relative to an areal geometry, using indexing for efficiency...
Definition: IndexedPointInAreaLocator.h:54
Definition: MaximumInscribedCircle.h:56
An Envelope defines a rectangulare region of the 2D coordinate plane.
Definition: Envelope.h:58
Coordinate is the lightweight class used to store coordinates.
Definition: Coordinate.h:216
Computes the distance between the facets (segments and vertices) of two Geometrys using a Branch-and-...
Definition: IndexedFacetDistance.h:46
Basic implementation of Geometry, constructed and destructed by GeometryFactory.
Definition: Geometry.h:186
Supplies a set of utility methods for building Geometry objects from CoordinateSequence or other Geom...
Definition: GeometryFactory.h:65
Basic namespace for all GEOS functionalities.
Definition: Angle.h:25