Rhinoscript IsCircle and IsArc methods


I see that a tolerance argument has been added to the Rhinoscript version of these methods. We now have some vital tools in our process that no longer work. I’ve attempted to add a tolerance to get this method working again but it’s not making any difference. Can someone post an example with a tolerance added so I can make sure I am doing it correctly?

I may have to roll back to SR7 if I can’t get this solved ASAP.



RhinoScript IsArc

Hey Dan,
In theory at least, previous scripts should still work - the tolerance argument is optional and if not supplied, the script should work by default as it did previously…

I tested here with and without the optional argument and both methods succeed - that is they return a true or false value and do not error out…

However, the tolerance value does not appear to be all that accurate… I tested on a deformable circle, CurveDeviation reports max .0055 deviation from a real circle object of same diameter, but I had to supply a tolerance value of 0.013 (more than twice the deviation) to have iIsCircle report as a circle within tolerance…


(Dale Fugier) #3

Dan, the SR7 and prior equivalent would be:

blnResult = Rhino.IsCircle(strCurve, Rhino.UnitAbsoluteTolerance)


Awesome, thanks. I will add that right away!

Thanks Dale,



I’ll try Dale’s suggestion. I’m going to have a mutiny on my hands if I don’t get these scripts recognizing circles again! :smiley:


Ah, that would be a change in behavior which would invalidate previous scripts then… New behavior if the tolerance argument is omitted is (according to the help): “If omitted, Rhino’s internal zero tolerance is used.”



Still having issues. I’ll have to take a good look at what else changed in SR8 to see why the scripts are misbehaving. Basically I use GetEdgeCurves from an imported SolidWorks model to find the radius and center of the holes. If Solidwork’s holes didn’t import thru STEP as 2 surfaces then this wouldn’t be an issue. But I need to check whether the edge is an arc or a circle before I can proceed.