Method IsEqualTo
- Namespace
- GeometryHelper.Geometry
- Assembly
- GeometryHelper.dll
IsEqualTo(GeoPolygon2)
Determines whether another polygon encloses the same region, within the default tolerance.
public bool IsEqualTo(GeoPolygon2 other)
Parameters
otherGeoPolygon2The polygon to compare with.
Returns
- bool
true if the polygons are the same within tolerance; otherwise, false.
IsEqualTo(GeoPolygon2, Tolerance)
Determines whether another polygon encloses the same region, within a tolerance.
public bool IsEqualTo(GeoPolygon2 other, Tolerance tolerance)
Parameters
otherGeoPolygon2The polygon to compare with.
toleranceToleranceThe tolerance.
Returns
- bool
true if the polygons are the same within tolerance; otherwise, false.
Remarks
Where a loop starts is not part of the shape it encloses, so the comparison tries every rotation of the other polygon before giving up. The direction it runs in is part of the shape, and two polygons tracing one region in opposite directions are not equal.