diff --git a/libsrc/meshing/meshtype.hpp b/libsrc/meshing/meshtype.hpp index 77a0c1c0..522eb8c8 100644 --- a/libsrc/meshing/meshtype.hpp +++ b/libsrc/meshing/meshtype.hpp @@ -1020,13 +1020,6 @@ namespace netgen class DLL_HEADER MeshingParameters { public: - - - - - - - /** 3d optimization strategy: // m .. move nodes @@ -1131,6 +1124,8 @@ namespace netgen /// MeshingParameters (const MeshingParameters & mp2) = default; MeshingParameters (MeshingParameters && mp2) = default; + MeshingParameters & operator= (const MeshingParameters & mp2) = default; + MeshingParameters & operator= (MeshingParameters && mp2) = default; /// void Print (ostream & ost) const; /// diff --git a/libsrc/meshing/python_mesh.cpp b/libsrc/meshing/python_mesh.cpp index 59099743..fc5acc62 100644 --- a/libsrc/meshing/python_mesh.cpp +++ b/libsrc/meshing/python_mesh.cpp @@ -465,16 +465,24 @@ DLL_HEADER void ExportNetgenMeshing() .def ("SetMaterial", &Mesh::SetMaterial) .def ("GetMaterial", FunctionPointer([](Mesh & self, int domnr) { return string(self.GetMaterial(domnr)); })) - + .def ("GenerateVolumeMesh", FunctionPointer - ([](Mesh & self) + ([](Mesh & self, bp::object pymp) { cout << "generate vol mesh" << endl; + MeshingParameters mp; - mp.optsteps3d = 5; + if (bp::extract(pymp).check()) + mp = bp::extract(pymp)(); + else + { + mp.optsteps3d = 5; + } MeshVolume (mp, self); OptimizeVolume (mp, self); - })) + }), + (bp::arg("self"), bp::arg("mp")=bp::object()) + ) .def ("OptimizeVolumeMesh", FunctionPointer ([](Mesh & self)