From: eap Date: Thu, 3 Apr 2014 17:01:55 +0000 (+0400) Subject: 22542: [CEA 1129]Convert to biquadradic creates a node ouside an element if mesh... X-Git-Tag: V7_4_0a1 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=e70b3d64327591b181ab9661504f820491e98302;p=modules%2Fsmesh.git 22542: [CEA 1129]Convert to biquadradic creates a node ouside an element if mesh has no CAD Fix quadratic->biquadratic w/o geometry --- diff --git a/src/SMESH/SMESH_MesherHelper.cxx b/src/SMESH/SMESH_MesherHelper.cxx index 6dda8f79b..a53e644d8 100644 --- a/src/SMESH/SMESH_MesherHelper.cxx +++ b/src/SMESH/SMESH_MesherHelper.cxx @@ -1200,10 +1200,11 @@ const SMDS_MeshNode* SMESH_MesherHelper::GetCentralNode(const SMDS_MeshNode* n1, } else // ( force3d || F.IsNull() ) { - P = ( SMESH_TNodeXYZ( n1 ) + - SMESH_TNodeXYZ( n2 ) + - SMESH_TNodeXYZ( n3 ) + - SMESH_TNodeXYZ( n4 ) ) / 4; + P = calcTFI (0.5, 0.5, + SMESH_TNodeXYZ(n1), SMESH_TNodeXYZ(n2), + SMESH_TNodeXYZ(n3), SMESH_TNodeXYZ(n4), + SMESH_TNodeXYZ(n12), SMESH_TNodeXYZ(n23), + SMESH_TNodeXYZ(n34), SMESH_TNodeXYZ(n41)); centralNode = meshDS->AddNode( P.X(), P.Y(), P.Z() ); if ( !F.IsNull() ) // force3d