Salome HOME
projects
/
modules
/
smesh.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Remove unnecessary includes
[modules/smesh.git]
/
src
/
SMESH
/
SMESH_subMesh.cxx
diff --git
a/src/SMESH/SMESH_subMesh.cxx
b/src/SMESH/SMESH_subMesh.cxx
index 4f9955cf3000d6258458fe1ab6b7c139ed86ac6f..424377af7524a5e863942bd4152b6553b0947fab 100644
(file)
--- a/
src/SMESH/SMESH_subMesh.cxx
+++ b/
src/SMESH/SMESH_subMesh.cxx
@@
-1,4
+1,4
@@
-// Copyright (C) 2007-202
0
CEA/DEN, EDF R&D, OPEN CASCADE
+// Copyright (C) 2007-202
1
CEA/DEN, EDF R&D, OPEN CASCADE
//
// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
//
// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
@@
-39,7
+39,6
@@
#include "SMESH_subMeshEventListener.hxx"
#include "utilities.h"
#include "SMESH_subMeshEventListener.hxx"
#include "utilities.h"
-#include "OpUtil.hxx"
#include "Basics_Utils.hxx"
#include <BRep_Builder.hxx>
#include "Basics_Utils.hxx"
#include <BRep_Builder.hxx>
@@
-1331,12
+1330,12
@@
static void cleanSubMesh( SMESH_subMesh * subMesh )
if (SMESHDS_SubMesh * subMeshDS = subMesh->GetSubMeshDS())
{
SMESHDS_Mesh * meshDS = subMesh->GetFather()->GetMeshDS();
if (SMESHDS_SubMesh * subMeshDS = subMesh->GetSubMeshDS())
{
SMESHDS_Mesh * meshDS = subMesh->GetFather()->GetMeshDS();
-
int
nbElems = subMeshDS->NbElements();
+
smIdType
nbElems = subMeshDS->NbElements();
if ( nbElems > 0 )
for ( SMDS_ElemIteratorPtr ite = subMeshDS->GetElements(); ite->more(); )
meshDS->RemoveFreeElement( ite->next(), subMeshDS );
if ( nbElems > 0 )
for ( SMDS_ElemIteratorPtr ite = subMeshDS->GetElements(); ite->more(); )
meshDS->RemoveFreeElement( ite->next(), subMeshDS );
-
int
nbNodes = subMeshDS->NbNodes();
+
smIdType
nbNodes = subMeshDS->NbNodes();
if ( nbNodes > 0 )
for ( SMDS_NodeIteratorPtr itn = subMeshDS->GetNodes(); itn->more() ; )
{
if ( nbNodes > 0 )
for ( SMDS_NodeIteratorPtr itn = subMeshDS->GetNodes(); itn->more() ; )
{
@@
-1445,6
+1444,7
@@
bool SMESH_subMesh::ComputeStateEngine(compute_event event)
loadDependentMeshes();
ComputeSubMeshStateEngine( SUBMESH_LOADED );
//break;
loadDependentMeshes();
ComputeSubMeshStateEngine( SUBMESH_LOADED );
//break;
+ // fall through
case CHECK_COMPUTE_STATE:
if ( IsMeshComputed() )
_computeState = COMPUTE_OK;
case CHECK_COMPUTE_STATE:
if ( IsMeshComputed() )
_computeState = COMPUTE_OK;
@@
-1496,6
+1496,7
@@
bool SMESH_subMesh::ComputeStateEngine(compute_event event)
}
break;
}
}
break;
}
+ // fall through
case COMPUTE:
case COMPUTE_SUBMESH:
{
case COMPUTE:
case COMPUTE_SUBMESH:
{
@@
-1763,6
+1764,7
@@
bool SMESH_subMesh::ComputeStateEngine(compute_event event)
loadDependentMeshes();
ComputeSubMeshStateEngine( SUBMESH_LOADED );
//break;
loadDependentMeshes();
ComputeSubMeshStateEngine( SUBMESH_LOADED );
//break;
+ // fall through
case CHECK_COMPUTE_STATE:
if ( IsMeshComputed() )
_computeState = COMPUTE_OK;
case CHECK_COMPUTE_STATE:
if ( IsMeshComputed() )
_computeState = COMPUTE_OK;
@@
-1914,7
+1916,7
@@
bool SMESH_subMesh::Evaluate(MapShapeNbElems& aResMap)
bool ret = true;
if (_subShape.ShapeType() == TopAbs_VERTEX) {
bool ret = true;
if (_subShape.ShapeType() == TopAbs_VERTEX) {
- vector<
int
> aVec(SMDSEntity_Last,0);
+ vector<
smIdType
> aVec(SMDSEntity_Last,0);
aVec[SMDSEntity_Node] = 1;
aResMap.insert(make_pair(this,aVec));
return ret;
aVec[SMDSEntity_Node] = 1;
aResMap.insert(make_pair(this,aVec));
return ret;
@@
-1941,7
+1943,7
@@
bool SMESH_subMesh::Evaluate(MapShapeNbElems& aResMap)
SMESH_subMesh* sm = smIt->next();
int dim = SMESH_Gen::GetShapeDim( sm->GetSubShape() );
if (dim < dimToCheck) break; // the rest subMeshes are all of less dimension
SMESH_subMesh* sm = smIt->next();
int dim = SMESH_Gen::GetShapeDim( sm->GetSubShape() );
if (dim < dimToCheck) break; // the rest subMeshes are all of less dimension
- const vector<
int
> & nbs = aResMap[ sm ];
+ const vector<
smIdType
> & nbs = aResMap[ sm ];
subMeshEvaluated = (std::accumulate( nbs.begin(), nbs.end(), 0 ) > 0 );
}
if ( !subMeshEvaluated )
subMeshEvaluated = (std::accumulate( nbs.begin(), nbs.end(), 0 ) > 0 );
}
if ( !subMeshEvaluated )
@@
-1951,7
+1953,7
@@
bool SMESH_subMesh::Evaluate(MapShapeNbElems& aResMap)
if ( IsMeshComputed() )
{
if ( IsMeshComputed() )
{
- vector<
int
> & nbEntities = aResMap[ this ];
+ vector<
smIdType
> & nbEntities = aResMap[ this ];
nbEntities.resize( SMDSEntity_Last, 0 );
if ( SMESHDS_SubMesh* sm = GetSubMeshDS() )
{
nbEntities.resize( SMDSEntity_Last, 0 );
if ( SMESHDS_SubMesh* sm = GetSubMeshDS() )
{
@@
-1965,7
+1967,7
@@
bool SMESH_subMesh::Evaluate(MapShapeNbElems& aResMap)
{
ret = algo->Evaluate((*_father), _subShape, aResMap);
}
{
ret = algo->Evaluate((*_father), _subShape, aResMap);
}
- aResMap.insert( make_pair( this,vector<
int
>(0)));
+ aResMap.insert( make_pair( this,vector<
smIdType
>(0)));
}
return ret;
}
return ret;
@@
-2149,7
+2151,7
@@
void SMESH_subMesh::removeSubMeshElementsAndNodes()
// meshed at once along with _subShape
//=======================================================================
// meshed at once along with _subShape
//=======================================================================
-TopoDS_Shape SMESH_subMesh::getCollection(SMESH_Gen *
theGen
,
+TopoDS_Shape SMESH_subMesh::getCollection(SMESH_Gen *
/*theGen*/
,
SMESH_Algo* theAlgo,
bool & theSubComputed,
bool & theSubFailed,
SMESH_Algo* theAlgo,
bool & theSubComputed,
bool & theSubFailed,
@@
-2206,7
+2208,7
@@
TopoDS_Shape SMESH_subMesh::getCollection(SMESH_Gen * theGen,
}
}
}
}
- return aCompound;
+ return
theSubs.size() == 1 ? theSubs[0]->GetSubShape() :
aCompound;
}
//=======================================================================
}
//=======================================================================