![]() |
MapLink Pro 11.1.1.0.
Envitia MapLink Pro: The Ultimate Mapping Application Toolkit
|
Utility class providing some useful geometrical functions.
Static Public Member Functions | |
static bool | isCoordOnSegment (const TSLCoord &startCoord, const TSLCoord &endCoord, const TSLCoord &thisCoord, double tolerance) |
static int | lineSegmentIntersection (const TSLCoord &seg1Start, const TSLCoord &seg1End, const TSLCoord &seg2Start, const TSLCoord &seg2End, TSLCoord &crossingPt1, TSLCoord &crossingPt2, double tolerance=0.5) |
static bool | ringIsClockwise (const TSLCoordSet &coordSet) |
static bool | ringIsSelfTouching (const TSLCoordSet &coordSet) |
static TSLCoordSetClassificationEnum | classifyCoordSet (const TSLCoordSet &coordSet, bool closed) |
|
static |
|
static |
Checks if the specified coordinate is on the specified line segment.
startCoord | Start point of the line segment. |
endCoord | End point of the line segment. |
thisCoord | The specified coordinate. |
tolerance | Specifies the maximum distance (in TMCs) the specified coordinate can be from the line segment to be considered on it. |
|
static |
This computes the intersection of the two specified line segments (including any intersection at their end points).
seg1Start | Start point of the 1st line segment. |
seg1End | End point of the 1st line segment. |
seg2Start | Start point of the 2nd line segment. |
seg2End | End point of the 2nd line segment. |
crossingPt1 | 1st crossing point will be returned here, if any. Only valid when return value is 1 or 2. |
crossingPt2 | 2nd crossing point will be returned here, if any. Only valid when return value is 2. |
tolerance | Specifies the maximum distance (in TMCs) the specified line segments can be from each other to still be considered intersecting. |
|
static |
Returns true if the ring defined by the coord set is clockwise orientated.
The function returns a valid value only if the coord set is simple (which is required anyway for a ring).
|
static |
Returns true if the ring defined by the coord set is not simple (i.e. is self-touching, is self-intersecting, or has spikes, punctures, duplicate sides, duplicated points or the same start and end points).