mirror of
https://github.com/NGSolve/netgen.git
synced 2024-12-25 13:30:34 +05:00
python - visibility and transparency of csg objects
This commit is contained in:
parent
21bb5c61c3
commit
d167f1261a
@ -356,6 +356,7 @@ DLL_HEADER void ExportCSG()
|
||||
}
|
||||
delete bcname;
|
||||
}
|
||||
return tlonr;
|
||||
|
||||
}),
|
||||
(bp::arg("self"), bp::arg("solid"), bp::arg("bcmod")=bp::list())
|
||||
@ -381,6 +382,35 @@ DLL_HEADER void ExportCSG()
|
||||
}),
|
||||
(bp::arg("self"), bp::arg("solid1"), bp::arg("solid2"), bp::arg("reflevels")=2)
|
||||
)
|
||||
.def("GetTransparent", FunctionPointer
|
||||
([] (CSGeometry & self, int tlonr)
|
||||
{
|
||||
return self.GetTopLevelObject(tlonr)->GetTransparent();
|
||||
}),
|
||||
(bp::arg("self"), bp::arg("tlonr"))
|
||||
)
|
||||
.def("SetTransparent", FunctionPointer
|
||||
([] (CSGeometry & self, int tlonr, bool transparent)
|
||||
{
|
||||
self.GetTopLevelObject(tlonr)->SetTransparent(transparent);
|
||||
}),
|
||||
(bp::arg("self"), bp::arg("tlonr"), bp::arg("transparent"))
|
||||
)
|
||||
|
||||
.def("GetVisible", FunctionPointer
|
||||
([] (CSGeometry & self, int tlonr)
|
||||
{
|
||||
return self.GetTopLevelObject(tlonr)->GetVisible();
|
||||
}),
|
||||
(bp::arg("self"), bp::arg("tlonr"))
|
||||
)
|
||||
.def("SetVisible", FunctionPointer
|
||||
([] (CSGeometry & self, int tlonr, bool visible)
|
||||
{
|
||||
self.GetTopLevelObject(tlonr)->SetVisible(visible);
|
||||
}),
|
||||
(bp::arg("self"), bp::arg("tlonr"), bp::arg("visible"))
|
||||
)
|
||||
|
||||
.add_property ("ntlo", &CSGeometry::GetNTopLevelObjects)
|
||||
;
|
||||
|
Loading…
Reference in New Issue
Block a user