Salome HOME
bos #29171 Refactor testing procedure
[modules/smesh.git] / doc / examples / filters_ex24.py
diff --git a/doc/examples/filters_ex24.py b/doc/examples/filters_ex24.py
new file mode 100644 (file)
index 0000000..2d8075c
--- /dev/null
@@ -0,0 +1,11 @@
+# Bare border volumes
+
+# create mesh
+from mechanic import *
+
+# remove some volumes to have volumes with bare borders
+mesh.RemoveElements(mesh.GetElementsByType(SMESH.VOLUME)[0:5])
+# get all volumes with bare borders
+filter = smesh_builder.GetFilter(SMESH.VOLUME, SMESH.FT_BareBorderVolume)
+ids = mesh.GetIdsFromFilter(filter)
+print("Volumes with bare borders:", ids)