From: eap Date: Thu, 8 May 2008 12:36:17 +0000 (+0000) Subject: PAL19680 Meshers: BLSURF, GHS3D and holed shapes X-Git-Tag: V4_1_2rc3~1 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=5b54cf448fe4d044f4e8548df0151c9278e133d7;p=plugins%2Fhybridplugin.git PAL19680 Meshers: BLSURF, GHS3D and holed shapes do not call findShapeID() if nb subdomains == 1 --- diff --git a/src/GHS3DPlugin_GHS3D.cxx b/src/GHS3DPlugin_GHS3D.cxx index 176d247..cea8df1 100644 --- a/src/GHS3DPlugin_GHS3D.cxx +++ b/src/GHS3DPlugin_GHS3D.cxx @@ -690,17 +690,19 @@ static bool readResultFile(const int fileOpen, int nodeId1 = strtol(ptr, &ptr, 10); int nodeId2 = strtol(ptr, &ptr, 10); int nodeId3 = strtol(ptr, &ptr, 10); - const SMDS_MeshNode* n1 = theGhs3dIdToNodeMap[ nodeId1 ]; - const SMDS_MeshNode* n2 = theGhs3dIdToNodeMap[ nodeId2 ]; - const SMDS_MeshNode* n3 = theGhs3dIdToNodeMap[ nodeId3 ]; - try { - OCC_CATCH_SIGNALS; - tabID[i] = findShapeID( theMesh, n1, n2, n3 ); + if ( nbTriangle > 1 ) { + const SMDS_MeshNode* n1 = theGhs3dIdToNodeMap[ nodeId1 ]; + const SMDS_MeshNode* n2 = theGhs3dIdToNodeMap[ nodeId2 ]; + const SMDS_MeshNode* n3 = theGhs3dIdToNodeMap[ nodeId3 ]; + try { + OCC_CATCH_SIGNALS; + tabID[i] = findShapeID( theMesh, n1, n2, n3 ); #ifdef _DEBUG_ - cout << i+1 << " subdomain: findShapeID() returns " << tabID[i] << endl; + cout << i+1 << " subdomain: findShapeID() returns " << tabID[i] << endl; #endif - } catch ( Standard_Failure ) { - } catch (...) {} + } catch ( Standard_Failure ) { + } catch (...) {} + } } shapePtr = ptr;