Hi @spb,
New Brep.Split overrides added to SR13
IronPython’s support for overloaded methods can be somewhat manual. In the case of Brep.Split
, you will need to use the .Overloads
property to access a method’s overloads:
For example:
import System
import System.Collections.Generic.IEnumerable as IEnumerable
import rhinoscriptsyntax as rs
import scriptcontext as sc
import Rhino
def test():
id = rs.GetObject( filter = 8+16, preselect = True)
if not id: return
brep = rs.coercebrep(id)
ids = rs.GetObjects(filter = 8+16,)
if not ids: return
cutters = [rs.coercebrep(item) for item in ids]
pass
out = brep.Split.Overloads[IEnumerable[Rhino.Geometry.Brep], System.Double]( cutters, .001)
rs.DeleteObject(id)
for item in out:
sc.doc.Objects.AddBrep(item)
sc.doc.Views.Redraw()
test()
– Dale