mirror of
https://github.com/NGSolve/netgen.git
synced 2025-01-24 20:00:33 +05:00
Merge branch 'occ_fuse' into 'master'
Add Fuse operation for occ shapes See merge request jschoeberl/netgen!437
This commit is contained in:
commit
66a6fd46b8
@ -1909,6 +1909,18 @@ DLL_HEADER void ExportNgOCCShapes(py::module &m)
|
|||||||
|
|
||||||
return builder.Shape();
|
return builder.Shape();
|
||||||
}, py::arg("shape"), "glue together shapes from shape, typically a compound");
|
}, py::arg("shape"), "glue together shapes from shape, typically a compound");
|
||||||
|
m.def("Fuse", [](const vector<TopoDS_Shape>& shapes) -> TopoDS_Shape
|
||||||
|
{
|
||||||
|
auto s = shapes[0];
|
||||||
|
for(auto i : Range(size_t(1), shapes.size()))
|
||||||
|
{
|
||||||
|
BRepAlgoAPI_Fuse builder(s, shapes[i]);
|
||||||
|
PropagateProperties(builder, s);
|
||||||
|
PropagateProperties(builder, shapes[i]);
|
||||||
|
s = builder.Shape();
|
||||||
|
}
|
||||||
|
return s;
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
// py::class_<Handle(Geom_TrimmedCurve)> (m, "Geom_TrimmedCurve")
|
// py::class_<Handle(Geom_TrimmedCurve)> (m, "Geom_TrimmedCurve")
|
||||||
|
Loading…
Reference in New Issue
Block a user