def MakeGroupByCriterion(self, groupName, Criterion):
aFilterMgr = self.smeshpyD.CreateFilterManager()
aFilter = aFilterMgr.CreateFilter()
- aFilter.SetMesh( self.mesh )
aCriteria = []
aCriteria.append(Criterion)
aFilter.SetCriteria(aCriteria)
def MakeGroupByCriteria(self, groupName, theCriteria):
aFilterMgr = self.smeshpyD.CreateFilterManager()
aFilter = aFilterMgr.CreateFilter()
- aFilter.SetMesh( self.mesh )
aFilter.SetCriteria(theCriteria)
group = self.MakeGroupByFilter(groupName, aFilter)
return group
# @ingroup l2_grps_create
def MakeGroupByFilter(self, groupName, theFilter):
group = self.CreateEmptyGroup(theFilter.GetElementType(), groupName)
+ theFilter.SetMesh( self.mesh )
group.AddFrom( theFilter )
return group
# @return a list of ids
# @ingroup l1_controls
def GetIdsFromFilter(self, theFilter):
+ theFilter.SetMesh( self.mesh )
return theFilter.GetIDs()
## Verifies whether a 2D mesh element has free edges (edges connected to one face only)\n
pass
except:
name = mesh.geompyD.SubShapeName(geom, piece)
- mesh.geompyD.addToStudyInFather(piece, geom, name)
+ if not name:
+ name = "%s_%s"%(geom.GetShapeType(), id(geom%1000))
pass
self.subm = mesh.mesh.GetSubMesh(geom, algo.GetName())