From 6d27b0192807073be0eae4757d0c8d0592b94692 Mon Sep 17 00:00:00 2001 From: eap Date: Thu, 11 Feb 2010 13:52:23 +0000 Subject: [PATCH] 0020693: EDF 1288 SMESH: Problem to recompute a mesh with a sub-mesh and a conversion linear-quadratic * Fix check if a face is triangle --- src/NETGENPlugin/NETGENPlugin_NETGEN_3D.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/NETGENPlugin/NETGENPlugin_NETGEN_3D.cxx b/src/NETGENPlugin/NETGENPlugin_NETGEN_3D.cxx index 3612155..08fc384 100644 --- a/src/NETGENPlugin/NETGENPlugin_NETGEN_3D.cxx +++ b/src/NETGENPlugin/NETGENPlugin_NETGEN_3D.cxx @@ -212,7 +212,7 @@ bool NETGENPlugin_NETGEN_3D::Compute(SMESH_Mesh& aMesh, const SMDS_MeshElement* elem = iteratorElem->next(); if ( !elem ) return error( COMPERR_BAD_INPUT_MESH, "Null element encounters"); - bool isTraingle = ( elem->NbNodes()==3 || (_quadraticMesh && elem->NbNodes()==6 )); + bool isTraingle = ( elem->NbNodes() == ( elem->IsQuadratic() ? 6 : 3 )); if ( !isTraingle ) { // using adaptor const list* faces = Adaptor.GetTriangles(elem); @@ -467,7 +467,7 @@ bool NETGENPlugin_NETGEN_3D::Compute(SMESH_Mesh& aMesh, const SMDS_MeshElement* elem = *itFace; if ( !elem ) return error( COMPERR_BAD_INPUT_MESH, "Null element encounters"); - bool isTraingle = ( elem->NbNodes()==3 || (_quadraticMesh && elem->NbNodes()==6 )); + bool isTraingle = ( elem->NbNodes() == ( elem->IsQuadratic() ? 6 : 3 )); if ( !isTraingle ) { // using adaptor const list* faces = Adaptor.GetTriangles(elem); -- 2.39.2