Computes the intersections between two line segments in SegmentString and adds them to each string.
More...
#include <IntersectionAdder.h>
Computes the intersections between two line segments in SegmentString and adds them to each string.
The SegmentIntersector is passed to a Noder. The NodedSegmentString::addIntersections(algorithm::LineIntersector* li, size_t segmentIndex, size_t geomIndex) method is called whenever the Noder detects that two SegmentStrings might intersect. This class is an example of the Strategy pattern.
Definition at line 57 of file IntersectionAdder.h.
geos::noding::IntersectionAdder::IntersectionAdder |
( |
const IntersectionAdder & |
other | ) |
|
|
privatedelete |
const geom::Coordinate& geos::noding::IntersectionAdder::getProperIntersectionPoint |
( |
| ) |
|
|
inline |
- Returns
- the proper intersection point, or
Coordinate::getNull()
if none was found
Definition at line 124 of file IntersectionAdder.h.
bool geos::noding::IntersectionAdder::hasInteriorIntersection |
( |
| ) |
|
|
inline |
An interior intersection is an intersection which is in the interior of some segment.
Definition at line 165 of file IntersectionAdder.h.
bool geos::noding::IntersectionAdder::hasIntersection |
( |
| ) |
|
|
inline |
bool geos::noding::IntersectionAdder::hasProperInteriorIntersection |
( |
| ) |
|
|
inline |
bool geos::noding::IntersectionAdder::hasProperIntersection |
( |
| ) |
|
|
inline |
A proper intersection is an intersection which is interior to at least two line segments.
Note that a proper intersection is not necessarily in the interior of the entire Geometry, since another edge may have an endpoint equal to the intersection, which according to SFS semantics can result in the point being on the Boundary of the Geometry.
Definition at line 145 of file IntersectionAdder.h.
static bool geos::noding::IntersectionAdder::isAdjacentSegments |
( |
size_t |
i1, |
|
|
size_t |
i2 |
|
) |
| |
|
inlinestatic |
bool geos::noding::IntersectionAdder::isDone |
( |
| ) |
const |
|
inlineoverridevirtual |
bool geos::noding::IntersectionAdder::isTrivialIntersection |
( |
const SegmentString * |
e0, |
|
|
size_t |
segIndex0, |
|
|
const SegmentString * |
e1, |
|
|
size_t |
segIndex1 |
|
) |
| |
|
private |
A trivial intersection is an apparent self-intersection which in fact is simply the point shared by adjacent line segments. Note that closed edges require a special check for the point shared by the beginning and end segments.
void geos::noding::IntersectionAdder::processIntersections |
( |
SegmentString * |
e0, |
|
|
size_t |
segIndex0, |
|
|
SegmentString * |
e1, |
|
|
size_t |
segIndex1 |
|
) |
| |
|
overridevirtual |
This method is called by clients of the SegmentIntersector class to process intersections for two segments of the SegmentStrings being intersected.
Note that some clients (such as MonotoneChains) may optimize away this call for segment pairs which they have determined do not intersect (e.g. by an disjoint envelope test).
Implements geos::noding::SegmentIntersector.
bool geos::noding::IntersectionAdder::hasInterior |
|
private |
bool geos::noding::IntersectionAdder::hasIntersectionVar |
|
private |
These variables keep track of what types of intersections were found during ALL edges that have been intersected.
Definition at line 65 of file IntersectionAdder.h.
bool geos::noding::IntersectionAdder::hasProper |
|
private |
bool geos::noding::IntersectionAdder::hasProperInterior |
|
private |
int geos::noding::IntersectionAdder::numInteriorIntersections |
int geos::noding::IntersectionAdder::numIntersections |
int geos::noding::IntersectionAdder::numProperIntersections |
int geos::noding::IntersectionAdder::numTests |
The documentation for this class was generated from the following file: