API Reference > FacetModeler Namespace > Classes > Contour2D Class > Contour2D Methods > Contour2D::isSelfIntersecting Method
Contour2D::isSelfIntersecting Method
Syntax
C++
bool isSelfIntersecting(const OdGeTol& gTol = FMGeGbl::gTol, bool bExcludeTouch = false) const;
Parameters 
Description 
const OdGeTol& gTol = FMGeGbl::gTol 
[in] Tolerance.  
bool bExcludeTouch = false 
[in] true for not considering a touch as self-intersection, or false otherwise. 

true if and only if there exists a pair of intersecting segments and the shortest distance along the contour between the intersections is greater than the tolerance, or false otherwise.

Checks whether the contour intersects itself. 

 

Runs in O( N * log(N) ) time at the average. 

E.g. The method returns true for an 8-shaped contour regardless of the central intersection type (touch or crossing). The method returns false for a O-shaped closed contour, but returns true for an open one.

Copyright © 2002-2020. Open Design Alliance. All rights reserved.