Salome HOME
Merge from V6_3_BR 06/06/2011
[modules/smesh.git] / doc / salome / gui / SMESH / input / tui_filters.doc
index aa3e1eb1cc9cf199186d0e09ec41f6894cc924ef..48c108fe50dc0e9ae971b852dbf6ead5533900b0 100755 (executable)
@@ -689,4 +689,25 @@ print "Number of tetrahedrons:", len(ids_tet)
 print "Number of pyramids:", len(ids_pyr)
 \endcode
 
+\section combining_filters How to combine filters with Criterion structures?
+
+Filters can be combined by making use of "criteria".
+
+Example :
+
+\code
+# create mesh
+from SMESH_mechanic import *
+# get all the quadrangle faces ...
+criterion1 = smesh.GetCriterion(smesh.FACE, smesh.FT_ElemGeomType, smesh.Geom_QUADRANGLE, smesh.FT_LogicalAND)
+# ... AND do NOT get those from sub_face3
+criterion2 = smesh.GetCriterion(smesh.FACE, smesh.FT_BelongToGeom, sub_face3, smesh.FT_LogicalNOT)
+filter = smesh.CreateFilterManager().CreateFilter()
+filter.SetCriteria([criterion1,criterion2])
+ids = mesh.GetIdsFromFilter(filter)
+
+myGroup = mesh.MakeGroupByIds("Quads_on_cylindrical_faces",smesh.FACE,ids)
+\endcode
+
+
 */