OK, so I was thinking of manipulating (stacking / moving) curves by manipulating ControlPoints from a C# script, but I can’t find out how to gain access the CP’s of a given curve. Given a Line or Curve in GH I want to be able to :
@Michael_Pryor, Do you know how to add new ControlPoints to an existing NurbsCurve?
I tried the following, but the SetPoint method totally crashes Rhino (with or whithout doing Rebuild before SetPoint), perhaps because SetPoint doesn’t seem like it’s actually adding any point? (it doesn’t even try to overwrite an existing point at index…).
var insert_cnt = 100;
var degree = 3;
crv.Rebuild(insert_cnt, degree, false);
// ... but this did NOT change the CP count. :(
// ... so I tried this instead:
for (var i = 1; i < insert_cnt; i++)
{
var new_cp = // at a distance from each other ;
crv.Points.SetPoint(i, new_cp);
}
Print("DEBUG| CP Count : " + crv.Points.Count.ToString());
}