]> SALOME platform Git repositories - modules/smesh.git/commitdiff
Salome HOME
0020982: EDF 1547 SMESH: Creation of non-conformal quadratic pyramids
authoreap <eap@opencascade.com>
Thu, 26 May 2011 16:07:11 +0000 (16:07 +0000)
committereap <eap@opencascade.com>
Thu, 26 May 2011 16:07:11 +0000 (16:07 +0000)
   fix a just computed quadratic mesh by bending iternal links near concave boundary

src/SMESH/SMESH_Gen.cxx

index cbc49c40a0dee543d650c6551a80d516ed91512d..1c8022b0b4da6a77526991fe3395d432231dfccf 100644 (file)
 //  Author : Paul RASCLE, EDF
 //  Module : SMESH
 //
-#define CHRONODEF
+
+//#define CHRONODEF
+
 #include "SMESH_Gen.hxx"
-#include "SMESH_subMesh.hxx"
-#include "SMESH_HypoFilter.hxx"
-#include "SMESHDS_Document.hxx"
+
+#include "SMDS_Mesh.hxx"
 #include "SMDS_MeshElement.hxx"
 #include "SMDS_MeshNode.hxx"
-#include "SMDS_Mesh.hxx"
+#include "SMESHDS_Document.hxx"
+#include "SMESH_HypoFilter.hxx"
+#include "SMESH_MesherHelper.hxx"
+#include "SMESH_subMesh.hxx"
 
 #include "utilities.h"
 #include "OpUtil.hxx"
@@ -348,6 +352,15 @@ bool SMESH_Gen::Compute(SMESH_Mesh &          aMesh,
   MESSAGE("Number of cell objects " << SMDS_MeshCell::nbCells);
   //myMesh->dumpGrid();
   //aMesh.GetMeshDS()->Modified();
+
+  // fix quadratic mesh by bending iternal links near concave boundary
+  if ( aShape.IsSame( aMesh.GetShapeToMesh() ) &&
+       !aShapesId ) // not preview
+  {
+    SMESH_MesherHelper aHelper( aMesh );
+    if ( aHelper.IsQuadraticMesh() != SMESH_MesherHelper::LINEAR )
+      aHelper.FixQuadraticElements();
+  }
   return ret;
 }