Part: expose GeomPlate algorithm to Python

This commit is contained in:
wmayer
2020-09-28 18:46:35 +02:00
parent 5c4b7fa776
commit 904574d368
11 changed files with 1558 additions and 0 deletions

View File

@@ -271,8 +271,20 @@ PartExport std::list<TopoDS_Edge> sort_Edges(double tol3d, std::list<TopoDS_Edge
}
namespace Part {
class GeomPlateModule : public Py::ExtensionModule<GeomPlateModule>
{
public:
GeomPlateModule() : Py::ExtensionModule<GeomPlateModule>("GeomPlate")
{
initialize("This is a module working with the GeomPlate framework."); // register with Python
}
virtual ~GeomPlateModule() {}
};
class Module : public Py::ExtensionModule<Module>
{
GeomPlateModule geomPlate;
public:
Module() : Py::ExtensionModule<Module>("Part")
{
@@ -488,6 +500,8 @@ public:
"joinSubname(sub,mapped,subElement) -> subname\n"
);
initialize("This is a module working with shapes."); // register with Python
PyModule_AddObject(m_module, "GeomPlate", geomPlate.module().ptr());
}
virtual ~Module() {}