Grasshopper

algorithmic modeling for Rhino

How does Rhino determine whether a curve is an arc or part of an ellipse?

Hi, just curious how Rhino tells that a curve, not necessarily closed, is circular or elliptic.

Views: 858

Replies to This Discussion

Can it tell whether it's elliptic?

I imagine three points are chosen on the original curve, a circle is fitted through these points, and then additional points on the curve are tested to see if they are near enough to the guide circle.

Well, if I shatter an ellipse, GH tells says the fragments are still elliptical curves. Maybe Rhino's just assuming a shattered ellipse or circle is still composed of similar curves and doesn't bother recalculating.

"Elliptical Curve" doesn't mean it's an Ellipse or a Circle. It can be, but it can be a part of it as well.

This just brings me back to my original question, how does Rhino "know"?

Could it be Rhino tries several "Tryget..." methods on the curve? There are for instance TryGetArc and TryGetEllipse methods (among others) for curves.

I don't know, and I never seem to be able to find answers to these kind of questions by digging through the Rhino source. I'm afraid you'll have to ask on the mcneel discourse forum where the Rhino programmers hang out.

The funny thing is, you can rebuild a circle or ellipse with enough points, regardless of degree, to resemble the original at practically an atomic level and it will still just reference as a "periodic planar curve", so they must be specified in some unique nurbistic manner.

RSS

About

Translate

Search

Videos

  • Add Videos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service