Open cyberhuman opened 2 months ago
from ocp_vscode import show from build123d import * box = Box(10, 10, 10) comp_box = Compound(children=[box]) sphere = Sphere(6.5) comp_sphere = Compound(children=[Compound(children=[Compound(children=[sphere])])]) with BuildPart() as nested: add(comp_box) add(comp_sphere, mode=Mode.SUBTRACT) with BuildPart() as nested_workaround: add(comp_box) add(comp_sphere.solids(), mode=Mode.SUBTRACT) show( comp_box.cut(comp_sphere).moved(Pos(-11)), nested.part, nested_workaround.part.moved(Pos(+11)), )