mcneel / ghpython

A Grasshopper component for Rhino.Python
http://www.food4rhino.com/project/ghpython
118 stars 34 forks source link

Datatypes in Grasshopper #18

Open scotttd opened 13 years ago

scotttd commented 13 years ago

How would I create these datatypes in GhPython to output as the native Grasshopper datatypes?

1) Box - should we marshall an rs.Addbox result into a Box type? 2) Rectangle - should we marshall a rs.AddPlanesurface?

sbaer commented 13 years ago

These are most likely just the Box and Rectangle3d classes in RhinoCommon.

piac commented 12 years ago

The AddRectangle call works also well because Grasshopper is able to convert a 4-pointed polyline in a rectangle if that is necessary, but the information is not retained for boxes. It seems a special case is necessary for Box.