GEOS
3.4.2
|
Computes the geometric overlay of two Geometry. More...
#include <OverlayOp.h>
Public Types | |
enum | OpCode { opINTERSECTION = 1, opUNION = 2, opDIFFERENCE = 3, opSYMDIFFERENCE = 4 } |
The spatial functions supported by this class. More... | |
Public Member Functions | |
OverlayOp (const geom::Geometry *g0, const geom::Geometry *g1) | |
Construct an OverlayOp with the given Geometry args. More... | |
geom::Geometry * | getResultGeometry (OpCode overlayOpCode) |
geomgraph::PlanarGraph & | getGraph () |
bool | isCoveredByLA (const geom::Coordinate &coord) |
This method is used to decide if a point node should be included in the result or not. More... | |
bool | isCoveredByA (const geom::Coordinate &coord) |
This method is used to decide if an L edge should be included in the result or not. More... | |
![]() | |
GeometryGraphOperation (const geom::Geometry *g0, const geom::Geometry *g1) | |
GeometryGraphOperation (const geom::Geometry *g0, const geom::Geometry *g1, const algorithm::BoundaryNodeRule &boundaryNodeRule) | |
GeometryGraphOperation (const geom::Geometry *g0) | |
const geom::Geometry * | getArgGeometry (unsigned int i) const |
Static Public Member Functions | |
static geom::Geometry * | overlayOp (const geom::Geometry *geom0, const geom::Geometry *geom1, OpCode opCode) |
static bool | isResultOfOp (const geomgraph::Label &label, OpCode opCode) |
static bool | isResultOfOp (int loc0, int loc1, OpCode opCode) |
This method will handle arguments of Location.NULL correctly. More... | |
Protected Member Functions | |
void | insertUniqueEdge (geomgraph::Edge *e) |
Insert an edge from one of the noded input graphs. More... | |
![]() | |
void | setComputationPrecision (const geom::PrecisionModel *pm) |
Additional Inherited Members | |
![]() | |
algorithm::LineIntersector | li |
const geom::PrecisionModel * | resultPrecisionModel |
std::vector < geomgraph::GeometryGraph * > | arg |
The operation args into an array so they can be accessed by index. | |
Computes the geometric overlay of two Geometry.
The overlay can be used to determine any boolean combination of the geometries.
The spatial functions supported by this class.
These operations implement various boolean combinations of the resultants of the overlay.
geos::operation::overlay::OverlayOp::OverlayOp | ( | const geom::Geometry * | g0, |
const geom::Geometry * | g1 | ||
) |
|
inline |
Gets the graph constructed to compute the overlay.
geom::Geometry* geos::operation::overlay::OverlayOp::getResultGeometry | ( | OpCode | overlayOpCode | ) |
Gets the result of the overlay for a given overlay operation.
Note: this method can be called once only.
overlayOpCode | the overlay operation to perform |
TopologyException | if a robustness problem is encountered |
|
protected |
Insert an edge from one of the noded input graphs.
Checks edges that are inserted to see if an identical edge already exists. If so, the edge is not inserted, but its label is merged with the existing edge.
bool geos::operation::overlay::OverlayOp::isCoveredByA | ( | const geom::Coordinate & | coord | ) |
This method is used to decide if an L edge should be included in the result or not.
bool geos::operation::overlay::OverlayOp::isCoveredByLA | ( | const geom::Coordinate & | coord | ) |
This method is used to decide if a point node should be included in the result or not.
|
static |
Tests whether a point with a given topological Label relative to two geometries is contained in the result of overlaying the geometries using a given overlay operation.
The method handles arguments of Location#NONE correctly
label | the topological label of the point |
opCode | the code for the overlay operation to test |
|
static |
This method will handle arguments of Location.NULL correctly.
|
static |
Computes an overlay operation for the given geometry arguments.
geom0 | the first geometry argument |
geom1 | the second geometry argument |
opCode | the code for the desired overlay operation |
TopologyException | if a robustness problem is encountered |