C++ How to detect if a point is inside the area defined by a closed curve?

Hello,

I’m using a GetPoint() getter to get a point constrained onto a surface.
Now, there is a curve projected onto this surface, and we assume this curve is closed. Is there a way to check:
a) If the curve is actually closed?
b) If the curve is closed, whether the picked point lies inside the area enclosed by the curve?

I guess the solution goes around brep trims/loops, but I don’t know exactly how.

Many thanks,
Pablo

Hi @Pablo_Garcia-Amorena,

ON_Curve::IsClosed()

RhinoPointInPlanarClosedCurve()

– Dale

Crazy! Thank you :smiley:

Pablo