mirror of
https://git.salome-platform.org/gitpub/modules/smesh.git
synced 2024-12-27 09:50:34 +05:00
bos #20256 [CEA 18523] Porting SMESH to int 64 bits
fix regression in CGNS caused by rebase to master
This commit is contained in:
parent
b093728299
commit
7fb52246ac
@ -552,9 +552,9 @@ namespace
|
|||||||
nbNodes = ids[0];
|
nbNodes = ids[0];
|
||||||
++ids;
|
++ids;
|
||||||
#endif
|
#endif
|
||||||
vector<smIdType> idVec( ids[0] );
|
vector<smIdType> idVec( nbNodes );
|
||||||
for ( int i = 0; i < ids[0]; ++i )
|
for ( int i = 0; i < nbNodes; ++i )
|
||||||
idVec[ i ] = ToSmIdType( ids[ i + 1]);
|
idVec[ i ] = ToSmIdType( ids[ i ]);
|
||||||
return mesh->AddPolygonalFaceWithID( idVec, ToSmIdType(ID) );
|
return mesh->AddPolygonalFaceWithID( idVec, ToSmIdType(ID) );
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -892,6 +892,8 @@ Driver_Mesh::Status DriverCGNS_Read::Perform()
|
|||||||
curAddElemFun = addElemFuns[ elemType ];
|
curAddElemFun = addElemFuns[ elemType ];
|
||||||
SMDS_MeshElement* newElem = 0;
|
SMDS_MeshElement* newElem = 0;
|
||||||
const SMDS_MeshElement* face;
|
const SMDS_MeshElement* face;
|
||||||
|
vector<int> quantities;
|
||||||
|
vector<const SMDS_MeshNode*> nodes, faceNodes;
|
||||||
|
|
||||||
while ( pos < eDataSize )
|
while ( pos < eDataSize )
|
||||||
{
|
{
|
||||||
@ -923,9 +925,8 @@ Driver_Mesh::Status DriverCGNS_Read::Perform()
|
|||||||
// Face1M, Face2M, ... FaceNM
|
// Face1M, Face2M, ... FaceNM
|
||||||
nbFaces = polyOffset[ iElem + 1 ] - polyOffset[ iElem ];
|
nbFaces = polyOffset[ iElem + 1 ] - polyOffset[ iElem ];
|
||||||
|
|
||||||
vector<int> quantities( nbFaces );
|
quantities.resize( nbFaces ); quantities.back() = 0;
|
||||||
vector<const SMDS_MeshNode*> nodes, faceNodes;
|
nodes.clear(); nodes.reserve( nbFaces * 4 );
|
||||||
nodes.reserve( nbFaces * 4 );
|
|
||||||
for ( int iF = 0; iF < nbFaces; ++iF )
|
for ( int iF = 0; iF < nbFaces; ++iF )
|
||||||
{
|
{
|
||||||
const int faceID = std::abs( elemData[ pos++ ]) + zone._elemIdShift;
|
const int faceID = std::abs( elemData[ pos++ ]) + zone._elemIdShift;
|
||||||
@ -947,6 +948,7 @@ Driver_Mesh::Status DriverCGNS_Read::Perform()
|
|||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
polyhedError = true;
|
polyhedError = true;
|
||||||
|
pos += nbFaces - iF - 1;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -474,7 +474,7 @@ Driver_Mesh::Status DriverCGNS_Write::Perform()
|
|||||||
cgID-1, /*nbndry=*/0, elemData.data(), &iSec) != CG_OK )
|
cgID-1, /*nbndry=*/0, elemData.data(), &iSec) != CG_OK )
|
||||||
return addMessage( cg_get_error(), /*fatal = */true );
|
return addMessage( cg_get_error(), /*fatal = */true );
|
||||||
}
|
}
|
||||||
}
|
} // while ( elem )
|
||||||
|
|
||||||
// Write polyhedral volumes
|
// Write polyhedral volumes
|
||||||
// -------------------------
|
// -------------------------
|
||||||
|
Loading…
Reference in New Issue
Block a user