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;
96 static std::unique_ptr<geom::Point> getCenter(
const geom::Geometry* p_obstacles,
double p_tolerance);
106 static std::unique_ptr<geom::LineString> getRadiusLine(
const geom::Geometry* p_obstacles,
double p_tolerance);
108 std::unique_ptr<geom::Point> getCenter();
109 std::unique_ptr<geom::Point> getRadiusPoint();
110 std::unique_ptr<geom::LineString> getRadiusLine();
118 std::unique_ptr<geom::Geometry> boundary;
123 std::unique_ptr<algorithm::locate::IndexedPointInAreaLocator> ptLocator;
124 std::unique_ptr<operation::distance::IndexedFacetDistance> boundaryDistance;
125 geom::CoordinateXY centerPt;
126 geom::CoordinateXY radiusPt;
139 double distanceToConstraints(
double x,
double y);
146 static constexpr
double SQRT2 = 1.4142135623730951;
154 Cell(
double p_x,
double p_y,
double p_hSize,
double p_distanceToConstraints)
158 , distance(p_distanceToConstraints)
159 , maxDist(p_distanceToConstraints + (p_hSize*SQRT2))
168 bool isFullyOutside()
const 170 return maxDist < 0.0;
172 bool isOutside()
const 174 return distance < 0.0;
176 double getMaxDistance()
const 180 double getDistance()
const 184 double getHSize()
const 196 bool operator< (
const Cell& rhs)
const 198 return maxDist < rhs.maxDist;
200 bool operator> (
const Cell& rhs)
const 202 return maxDist > rhs.maxDist;
204 bool operator==(
const Cell& rhs)
const 206 return maxDist == rhs.maxDist;
210 bool mayContainCircleCenter(
const Cell& cell,
const Cell& farthestCell);
211 void createInitialGrid(
const geom::Envelope* env, std::priority_queue<Cell>& cellQueue);
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
Definition: LargestEmptyCircle.h:74
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