How to use RhinoCommon Geometry Properties

Just wondering what would be the way to get a Circle’s center using Grasshopper Python. Or can I use RhinoCommonAPI 's Geometry Properties in python?

If yes then what would be a way to write the syntax. Would appreciate that. Thanks!

Hi,

It depends a little on what type your circle object is! You can always check its type with print type(circle).
Now, if your circle is for instance a Rhino.Geometry.Circle, you can very easily get is center with circle.Center.

https://developer.rhino3d.com/api/RhinoCommon/html/T_Rhino_Geometry_Circle.htm

What documentation does your screenshot refer to?

1 Like

Hi @diff-arch , Thanks for the reply.

The picture is referring to Rhino 7’s version. In case of a Circle’s center, it seems like Rhino 6 and 7 are the same (please correct me if I am wrong).

Now speaking of getting the Circle’s center, I followed what you suggested but couldn’t make it work. Here is the screenshot. Am I missing anything here?

Thanks!

Here you go

1 Like

@devin_jernigan Thanks a lot! Just realized that a minute ago!