Difference between Rhino API's Curve.IsPlanar and GH's Curve>Analysis>Planar

(C Heck) #1

Hi all,

I just ran into a strange behavior… it seems that Rhino API’s “Curve.IsPlanar()” (without arguments for tolerance) will sometimes return a different boolean result than the Grasshopper component “Curve>Analysis>Planar”.

This is surprising to me because none of them take any tolerance parameter, so I would assume both to work with the same tolerance (RhinoMath.ZeroTolerance).

Does anyone know what tolerance the GH component is using? It doesn’t appear to be configurable…
I would like to have the same behavior in code as in the component.

Thanks!

Cyril

0 Likes

#2

Grasshopper components (at least the default ones) take the tolerance from the Rhino document:


So you would have to change it in Rhino, then rerun the .gh definition.

0 Likes

(C Heck) #3

Thanks djordje!
I had searched the forum for info about the “planar” components… but didn’t think that it’s just a general behavior related to all tolerances.

0 Likes