22 #include <geos/geom/Coordinate.h> 23 #include <geos/geom/Point.h> 24 #include <geos/geom/Envelope.h> 25 #include <geos/algorithm/construct/IndexedDistanceToPoint.h> 26 #include <geos/algorithm/locate/IndexedPointInAreaLocator.h> 27 #include <geos/operation/distance/IndexedFacetDistance.h> 37 class GeometryFactory;
116 static std::unique_ptr<geom::Point> getCenter(
const geom::Geometry* p_obstacles,
double p_tolerance);
127 static std::unique_ptr<geom::LineString> getRadiusLine(
const geom::Geometry* p_obstacles,
double p_tolerance);
129 std::unique_ptr<geom::Point> getCenter();
130 std::unique_ptr<geom::Point> getRadiusPoint();
131 std::unique_ptr<geom::LineString> getRadiusLine();
139 std::unique_ptr<geom::Geometry> boundary;
143 std::unique_ptr<algorithm::locate::IndexedPointInAreaLocator> boundaryPtLocater;
145 std::unique_ptr<IndexedFacetDistance> boundaryDistance;
146 geom::CoordinateXY centerPt;
147 geom::CoordinateXY radiusPt;
160 double distanceToConstraints(
double x,
double y);
167 static constexpr
double SQRT2 = 1.4142135623730951;
175 Cell(
double p_x,
double p_y,
double p_hSize,
double p_distanceToConstraints)
179 , distance(p_distanceToConstraints)
180 , maxDist(p_distanceToConstraints + (p_hSize*SQRT2))
189 bool isFullyOutside()
const 191 return maxDist < 0.0;
193 bool isOutside()
const 195 return distance < 0.0;
197 double getMaxDistance()
const 201 double getDistance()
const 205 double getHSize()
const 217 bool operator< (
const Cell& rhs)
const 219 return maxDist < rhs.maxDist;
221 bool operator> (
const Cell& rhs)
const 223 return maxDist > rhs.maxDist;
225 bool operator==(
const Cell& rhs)
const 227 return maxDist == rhs.maxDist;
231 bool mayContainCircleCenter(
const Cell& cell,
const Cell& farthestCell);
232 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:59
Coordinate is the lightweight class used to store coordinates.
Definition: Coordinate.h:217
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:197
Definition: LargestEmptyCircle.h:77
Supplies a set of utility methods for building Geometry objects from CoordinateSequence or other Geom...
Definition: GeometryFactory.h:70
Basic namespace for all GEOS functionalities.
Definition: Angle.h:25
Computes the distance between a point and a geometry (which may be a collection containing any type o...
Definition: IndexedDistanceToPoint.h:45