17 #include <geos/geom/Point.h> 18 #include <geos/geom/Polygon.h> 19 #include <geos/geom/LineString.h> 20 #include <geos/geom/Geometry.h> 22 #include <geos/export.h> 31 class CoordinateSequence;
33 class GeometryFactory;
61 static constexpr
double SAFE_ENV_BUFFER_FACTOR = 0.1;
62 static constexpr
int SAFE_ENV_GRID_FACTOR = 3;
63 static constexpr
double AREA_HEURISTIC_TOLERANCE = 0.1;
76 static bool resultEnvelope(
int opCode,
const InputGeometry* inputGeom,
const PrecisionModel* pm,
Envelope& rsltEnvelope);
80 static bool isEmpty(
const Geometry* geom);
89 static bool isLess(
double v1,
double v2,
double tol) {
90 return v1 <= v2 * (1 + tol);
93 static bool isGreater(
double v1,
double v2,
double tol) {
94 return v1 >= v2 * (1 - tol);
117 static bool clippingEnvelope(
int opCode,
const InputGeometry* inputGeom,
const PrecisionModel* pm,
Envelope& rsltEnvelope);
141 static std::unique_ptr<Geometry> createEmptyResult(
int dim,
const GeometryFactory* geomFact);
156 static int resultDimension(
int opCode,
int dim0,
int dim1);
161 static std::unique_ptr<Geometry> createResultGeometry(
162 std::vector<std::unique_ptr<Polygon>>& resultPolyList,
163 std::vector<std::unique_ptr<LineString>>& resultLineList,
164 std::vector<std::unique_ptr<Point>>& resultPointList,
185 static bool isResultAreaConsistent(
187 int opCode,
const Geometry* result);
196 static void moveGeometry(std::vector<std::unique_ptr<T>>& inGeoms, std::vector<std::unique_ptr<Geometry>>& outGeoms)
198 static_assert(std::is_base_of<Geometry, T>::value,
"");
199 for (
auto& geom: inGeoms) {
201 outGeoms.emplace_back(outGeom);
An Envelope defines a rectangulare region of the 2D coordinate plane.
Definition: Envelope.h:58
Definition: OverlayUtil.h:57
Coordinate is the lightweight class used to store coordinates.
Definition: Coordinate.h:58
Definition: OverlayGraph.h:54
Specifies the precision model of the Coordinate in a Geometry.
Definition: PrecisionModel.h:90
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:66
Basic namespace for all GEOS functionalities.
Definition: Angle.h:25