As an example, let’s say you have a single surface and two closed curves that lie on it.
Selecting the surface and the curves, coerce them to a brep and a list of curve objects, then run:
Is it because one of the 5 overloads on this method has an out parameter so they all have to have a reserved first index even if there’s nothing to return on the other 4 overloads?
import rhinoscriptsyntax as rs
import scriptcontext as sc
import Rhino, System
from System.Collections.Generic import IEnumerable
srf_id=rs.GetObject("Select the surface",8)
crv_ids=rs.GetObjects("Select the curves",4)
if srf_id and crv_ids:
brep=rs.coercebrep(srf_id)
crvs=[rs.coercecurve(crv_id) for crv_id in crv_ids]
tol=sc.doc.ModelAbsoluteTolerance
#splits=brep.Split([crv],tol) - 'multiple targets could match' - need to use overloads
splits=brep.Split.Overloads[IEnumerable[Rhino.Geometry.Curve],System.Double](crvs, tol)
for split in splits: print type(split)