algorithmic modeling for Rhino
Hi everybody.
I'm trying to begin working on python to develop some custom nodes for a definition.
Now I'm just doing some exercises, and trying to learn python syntax
first of all here is my definition:
--------------------------------------------------------------
import rhinoscriptsyntax as rs
import ghpythonlib.components as ghcomp
context = y
offsetContext = []
crv = 0
for crv in context:
f = rs.OffsetCurve(crv,[1,0,0],distance)
offsetContext.append(f)
RDiff = ghcomp.RegionDifference(x,offsetContext)
a=RDiff
------------------------------------------------------------
the problem is that i've seen with some tests and panels that python gives me back:
x = curve
offsetContext = 5 IronPython.Runtime.Lists
these lists and the curve do not interact and the result of the RDiff is <null>
instead if I insert the IronPython.Runtime.List in a new python component, it unpack the lists and it gives me back the curves to work with.
I would like to do all the work inside a single component, is there a way to do that.
At the end some photos and the GH file
thank you
Tags:
Welcome to
Grasshopper
Added by Parametric House 0 Comments 0 Likes
Added by Parametric House 0 Comments 0 Likes
Added by Parametric House 0 Comments 0 Likes
Added by Parametric House 0 Comments 0 Likes
© 2024 Created by Scott Davidson. Powered by