const TopoDS_Shape& aShape,
MapShapeNbElems& aResMap)
{
- int nbtri = 0, nbqua = 0;
+ smIdType nbtri = 0, nbqua = 0;
double fullArea = 0.0;
for (TopExp_Explorer exp(aShape, TopAbs_FACE); exp.More(); exp.Next()) {
TopoDS_Face F = TopoDS::Face( exp.Current() );
}
// collect info from edges
- int nb0d_e = 0, nb1d_e = 0;
+ smIdType nb0d_e = 0, nb1d_e = 0;
bool IsQuadratic = false;
bool IsFirst = true;
TopTools_MapOfShape tmpMap;
double aVolume = G.Mass();
double tetrVol = 0.1179*ELen*ELen*ELen;
double CoeffQuality = 0.9;
- int nbVols = int(aVolume/tetrVol/CoeffQuality);
- int nb1d_f = (nbtri*3 + nbqua*4 - nb1d_e) / 2;
- int nb1d_in = (int) ( nbVols*6 - nb1d_e - nb1d_f ) / 5;
+ smIdType nbVols = smIdType(aVolume/tetrVol/CoeffQuality);
+ smIdType nb1d_f = (nbtri*3 + nbqua*4 - nb1d_e) / 2;
+ smIdType nb1d_in = (smIdType) ( nbVols*6 - nb1d_e - nb1d_f ) / 5;
std::vector<smIdType> aVec(SMDSEntity_Last);
- for(int i=SMDSEntity_Node; i<SMDSEntity_Last; i++) aVec[i]=0;
+ for(smIdType i=SMDSEntity_Node; i<SMDSEntity_Last; i++) aVec[i]=0;
if( IsQuadratic ) {
aVec[SMDSEntity_Node] = nb1d_in/6 + 1 + nb1d_in;
aVec[SMDSEntity_Quad_Tetra] = nbVols - nbqua*2;
MESSAGE("GHS3DPlugin_Hypothesis::SetEnforcedGroup");
TIDSortedElemSet theElemSet;
if ( theIDs->length() == 0 ){MESSAGE("The source group is empty");}
- for ( CORBA::ULong i=0; i < theIDs->length(); i++) {
- CORBA::Long ind = theIDs[i];
+ for ( SMESH::smIdType i=0; i < theIDs->length(); i++) {
+ SMESH::smIdType ind = theIDs[i];
if (elementType == SMESH::NODE)
{
const SMDS_MeshNode * node = theMeshDS->FindNode(ind);
int nbNodes = theMGOutput->GmfStatKwd( inFile, GmfVertices );
int nbTet = theMGOutput->GmfStatKwd( inFile, GmfTetrahedra );
- int nbNodesOld = meshDS->NbNodes();
- int nbTetOld = meshDS->GetMeshInfo().NbTetras();
+ smIdType nbNodesOld = meshDS->NbNodes();
+ smIdType nbTetOld = meshDS->GetMeshInfo().NbTetras();
std::cout << "Optimization input: "
<< nbNodesOld << " nodes, \t" << nbTetOld << " tetra" << std::endl;
std::cout << "Optimization output: "
void getNodeByGhsId( SMESH_Mesh& mesh, std::vector <const SMDS_MeshNode*> & nodeByGhsId )
{
SMESHDS_Mesh* meshDS = mesh.GetMeshDS();
- const int nbNodes = meshDS->NbNodes();
+ const smIdType nbNodes = meshDS->NbNodes();
nodeByGhsId.resize( nbNodes + 1 );
SMDS_NodeIteratorPtr nodeIt = meshDS->nodesIterator();
while ( nodeIt->more() )