aMesh->myName = aMeshName;
aMesh->myMeshInfo = aMeshInfo;
aMesh->myNamedPointCoords(new VISU::TMEDNamedPointCoords());
-
+
INITMSG(MYDEBUG,"aMeshName = '"<<aMeshName<<
"; aDim = "<<aDim<<"\n");
- if(aType == MED::eNON_STRUCTURE){
+ if (aType == MED::eNON_STRUCTURE) {
- if(MED::PNodeInfo aNodeInfo = myMed->GetPNodeInfo(aMeshInfo)){
- MED::TEntityInfo anEntityInfo = myMed->GetEntityInfo(aMeshInfo);
+ if (MED::PNodeInfo aNodeInfo = myMed->GetPNodeInfo(aMeshInfo)) {
+ MED::TEntityInfo anEntityInfo = myMed->GetEntityInfo(aMeshInfo, MED::eNOD);
aMesh->myNbPoints = aNodeInfo->GetNbElem();
aMesh->myEntityInfo = anEntityInfo;
-
-
+
+ // Check connectivity (Mantis issue 0020483)
+ {
+ bool isDescConn = false;
+
+ MED::TEntityInfo aEntityInfoDesc = myMed->GetEntityInfo(aMeshInfo, MED::eDESC);
+ MED::TEntityInfo::iterator anEntityIterDesc = aEntityInfoDesc.begin();
+ for (; anEntityIterDesc != aEntityInfoDesc.end() && !isDescConn; anEntityIterDesc++) {
+ const MED::EEntiteMaillage& anEntity = anEntityIterDesc->first;
+ if (anEntity != MED::eNOEUD) isDescConn = true;
+ }
+
+ if (isDescConn)
+ MSG(1, "There are some elements in descending connectivity in med file. They were not read !!!");
+ }
+
#ifndef _DEXCEPT_
try{
#endif
INITMSG(MYDEBUG,"myNbPoints = "<<aMesh->myNbPoints<<
"; anEntityInfo.size() = "<<anEntityInfo.size()<<
"\n");
-
+
BuildMeshOnEntityMap(aMesh,
anEntityInfo,
aNodeInfo,
myMed);
-
+
#ifndef _DEXCEPT_
}catch(std::exception& exc){
MSG(MYDEBUG,"Follow exception was occured in:\n"<<exc.what());