mirror of
https://github.com/NGSolve/netgen.git
synced 2024-12-26 22:00:33 +05:00
Merge branch 'occ_make_polygon' into 'master'
export occ MakePolygon See merge request ngsolve/netgen!678
This commit is contained in:
commit
3e279da9bf
@ -22,6 +22,7 @@
|
||||
#include <BRepAlgo_NormalProjection.hxx>
|
||||
#include <BRepBuilderAPI_MakeEdge.hxx>
|
||||
#include <BRepBuilderAPI_MakeFace.hxx>
|
||||
#include <BRepBuilderAPI_MakePolygon.hxx>
|
||||
#include <BRepBuilderAPI_MakeVertex.hxx>
|
||||
#include <BRepBuilderAPI_MakeWire.hxx>
|
||||
#include <BRepBuilderAPI_Transform.hxx>
|
||||
@ -1671,8 +1672,14 @@ DLL_HEADER void ExportNgOCCShapes(py::module &m)
|
||||
|
||||
py::implicitly_convertible<TopoDS_Shape, TopoDS_Face>();
|
||||
py::implicitly_convertible<TopoDS_Edge, TopoDS_Wire>();
|
||||
|
||||
|
||||
m.def("MakePolygon", [](std::vector<TopoDS_Vertex> verts)
|
||||
{
|
||||
BRepBuilderAPI_MakePolygon builder;
|
||||
for(auto& v : verts)
|
||||
builder.Add(v);
|
||||
return builder.Wire();
|
||||
});
|
||||
|
||||
class ListOfShapesIterator
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user