mirror of
https://github.com/NGSolve/netgen.git
synced 2024-11-11 16:49:16 +05:00
Merge branch 'static_recv' into 'master'
Receive Mesh from python as static method See merge request jschoeberl/netgen!154
This commit is contained in:
commit
02b922fffe
@ -576,12 +576,12 @@ DLL_HEADER void ExportNetgenMeshing(py::module &m)
|
||||
else self->SendRecvMesh();
|
||||
return self;
|
||||
}, py::arg("comm"))
|
||||
.def("Receive", [](NgMPI_Comm comm) {
|
||||
.def_static("Receive", [](NgMPI_Comm comm) -> shared_ptr<Mesh> {
|
||||
auto mesh = make_shared<Mesh>();
|
||||
mesh->SetCommunicator(comm);
|
||||
mesh->SendRecvMesh();
|
||||
return mesh;
|
||||
})
|
||||
}, py::arg("comm"))
|
||||
.def("Load", FunctionPointer
|
||||
([](shared_ptr<Mesh> self, const string & filename)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user