mirror of
https://github.com/NGSolve/netgen.git
synced 2024-12-25 05:20:34 +05:00
code for drawing occ identifications in webgui
This commit is contained in:
parent
fffe1831a3
commit
8da01ff353
@ -1209,7 +1209,16 @@ DLL_HEADER void ExportNetgenMeshing(py::module &m)
|
||||
|
||||
.def ("GetCD3Name", &Mesh::GetCD3Name)
|
||||
.def ("SetCD3Name", &Mesh::SetCD3Name)
|
||||
|
||||
.def("GetIdentifications", [](Mesh & self) -> py::list
|
||||
{
|
||||
py::list points;
|
||||
for(const auto& pair : self.GetIdentifications().GetIdentifiedPoints())
|
||||
{
|
||||
py::tuple pnts = py::make_tuple(pair.first.I1(), pair.first.I2());
|
||||
points.append(pnts);
|
||||
}
|
||||
return points;
|
||||
})
|
||||
.def ("AddPointIdentification", [](Mesh & self, py::object pindex1, py::object pindex2, int identnr, Identifications::ID_TYPE type)
|
||||
{
|
||||
if(py::extract<PointIndex>(pindex1).check() && py::extract<PointIndex>(pindex2).check())
|
||||
|
@ -14,7 +14,7 @@ if not USE_OCC:
|
||||
raise ImportError("Netgen was not built with Opencascade support")
|
||||
|
||||
from .libngpy._NgOCC import *
|
||||
from .meshing import meshsize
|
||||
from .meshing import meshsize, IdentificationType
|
||||
|
||||
|
||||
gp_Ax3 = Axes
|
||||
|
Loading…
Reference in New Issue
Block a user