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>
108 std::unique_ptr<geom::Point> getCenter();
109 std::unique_ptr<geom::Point> getRadiusPoint();
110 std::unique_ptr<geom::LineString> getRadiusLine();
119 std::unique_ptr<geom::Geometry> boundary;
122 std::unique_ptr<algorithm::locate::IndexedPointInAreaLocator> ptLocator;
123 std::unique_ptr<operation::distance::IndexedFacetDistance> boundaryDistance;
141 double distanceToConstraints(
double x,
double y);
147 static constexpr double SQRT2 = 1.4142135623730951;
155 Cell(
double p_x,
double p_y,
double p_hSize,
double p_distanceToConstraints)
159 , distance(p_distanceToConstraints)
160 , maxDist(p_distanceToConstraints + (p_hSize*SQRT2))
169 bool isFullyOutside()
const
171 return maxDist < 0.0;
173 bool isOutside()
const
175 return distance < 0.0;
177 double getMaxDistance()
const
181 double getDistance()
const
185 double getHSize()
const
197 bool operator< (
const Cell& rhs)
const
199 return maxDist < rhs.maxDist;
201 bool operator> (
const Cell& rhs)
const
203 return maxDist > rhs.maxDist;
205 bool operator==(
const Cell& rhs)
const
207 return maxDist == rhs.maxDist;
211 bool mayContainCircleCenter(
const Cell& cell,
const Cell& farthestCell);
212 void createInitialGrid(
const geom::Envelope* env, std::priority_queue<Cell>& cellQueue);
213 Cell createCentroidCell(
const geom::Geometry* geom);
Definition: LargestEmptyCircle.h:74
static std::unique_ptr< geom::LineString > getRadiusLine(const geom::Geometry *p_obstacles, double p_tolerance)
static std::unique_ptr< geom::Point > getCenter(const geom::Geometry *p_obstacles, double p_tolerance)
LargestEmptyCircle(const geom::Geometry *p_obstacles, double p_tolerance)
Coordinate is the lightweight class used to store coordinates.
Definition: Coordinate.h:58
An Envelope defines a rectangulare region of the 2D coordinate plane.
Definition: Envelope.h:58
Supplies a set of utility methods for building Geometry objects from CoordinateSequence or other Geom...
Definition: GeometryFactory.h:66
Basic implementation of Geometry, constructed and destructed by GeometryFactory.
Definition: Geometry.h:186
Computes the distance between the facets (segments and vertices) of two Geometrys using a Branch-and-...
Definition: IndexedFacetDistance.h:46
Basic namespace for all GEOS functionalities.
Definition: geos.h:39