Continuing the discussion from Python Split curve with curve?:
hi there,
I am trying exactly that on python (learning python at the moment) but i found several problems
here is my code at the moment:
#shift curves list
new_list =
for i in Curves:
new_list.insert(len(new_list)-1, i)
#get points at intersection
int_events =
for crv in Curves:
for n_crv in new_list:
int = rs.CurveCurveIntersection(crv, n_crv)
int_events.append(int[0])
#extract elements from list of lists
def Extract(a, lst):
return [item[a] for item in lst]
int_pts_a = Extract(1, int_events)
int_param_a = Extract(5, int_events)
#output
Intersection_Points = int_pts_a
Crv_param_at_int_Points = int_param_a
a = int_events
the problems I am facing so far are:
there is one intersection missing…???
if I use the shatter component with the output produced, I get a list of non-sense points…???
any help here pleasepython_split_curves.gh (6.5 KB)
2 posts - 2 participants