mirror of
https://github.com/NGSolve/netgen.git
synced 2024-12-26 13:50:33 +05:00
add identification for 1d meshes, used for periodic boundary conditions
This commit is contained in:
parent
b5571213f4
commit
8756aabd3c
@ -466,6 +466,20 @@ DLL_HEADER void ExportNetgenMeshing()
|
|||||||
.def ("GetMaterial", FunctionPointer([](Mesh & self, int domnr)
|
.def ("GetMaterial", FunctionPointer([](Mesh & self, int domnr)
|
||||||
{ return string(self.GetMaterial(domnr)); }))
|
{ return string(self.GetMaterial(domnr)); }))
|
||||||
|
|
||||||
|
.def ("AddPointIdentification", FunctionPointer ([](Mesh & self, bp::object pindex1, bp::object pindex2, int identnr, int type)
|
||||||
|
{
|
||||||
|
if(bp::extract<PointIndex>(pindex1).check() && bp::extract<PointIndex>(pindex2).check())
|
||||||
|
{
|
||||||
|
self.GetIdentifications().Add (bp::extract<PointIndex>(pindex1), bp::extract<PointIndex>(pindex2), identnr);
|
||||||
|
self.GetIdentifications().SetType(identnr, Identifications::ID_TYPE(type)); // type = 2 ... periodic
|
||||||
|
}
|
||||||
|
}),
|
||||||
|
bp::default_call_policies(),
|
||||||
|
(bp::arg("pid1"),
|
||||||
|
bp::arg("pid2"),
|
||||||
|
bp::arg("identnr"),
|
||||||
|
bp::arg("type")
|
||||||
|
))
|
||||||
.def ("GenerateVolumeMesh", FunctionPointer
|
.def ("GenerateVolumeMesh", FunctionPointer
|
||||||
([](Mesh & self, bp::object pymp)
|
([](Mesh & self, bp::object pymp)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user