]> SALOME platform Git repositories - plugins/gmshplugin.git/commitdiff
Salome HOME
Gmsh upgrade 4.8 -> 4.10 mab/gmsh_4.10_squashed
authorAfeef <afeef.badri@gmail.com>
Fri, 24 Jun 2022 11:27:07 +0000 (13:27 +0200)
committerAfeef <afeef.badri@gmail.com>
Wed, 28 Sep 2022 08:45:41 +0000 (10:45 +0200)
- This commit adds interfaces MeshSizeFromCurvature which is used
to control mesh size on curved edges (input [int] # of elements per
2Pi).

- Adds new algorithm for quad meshing from Gmsh based on frame-fields.

- Corrects gmsh options for meshsizes.

- Updates documentation.

15 files changed:
doc/salome/gui/GMSHPLUGIN/images/Arguments.png
doc/salome/gui/GMSHPLUGIN/images/Compounds.png
doc/salome/gui/GMSHPLUGIN/input/gmsh_2d_3d_hypo.doc
doc/salome/gui/GMSHPLUGIN/input/index.doc
idl/GMSHPlugin_Algorithm.idl
src/GMSHPlugin/GMSHPlugin_Hypothesis.cxx
src/GMSHPlugin/GMSHPlugin_Hypothesis.hxx
src/GMSHPlugin/GMSHPlugin_Hypothesis_i.cxx
src/GMSHPlugin/GMSHPlugin_Hypothesis_i.hxx
src/GMSHPlugin/GMSHPlugin_Mesher.cxx
src/GMSHPlugin/GMSHPlugin_Mesher.hxx
src/GUI/GMSHPluginGUI_HypothesisCreator.cxx
src/GUI/GMSHPluginGUI_HypothesisCreator.h
src/GUI/GMSHPlugin_msg_en.ts
src/GUI/GMSHPlugin_msg_fr.ts

index c5a836e9cdeeee7477971fca0234c8f893d956b2..9818e841bad570eda5dcaf78d7c1daeb7bb49ab0 100644 (file)
Binary files a/doc/salome/gui/GMSHPLUGIN/images/Arguments.png and b/doc/salome/gui/GMSHPLUGIN/images/Arguments.png differ
index 6a28d1357920f9eede174b7c91721a526c3eb02e..499f550d459ae1afcaa5686887db9092764c58c8 100644 (file)
Binary files a/doc/salome/gui/GMSHPLUGIN/images/Compounds.png and b/doc/salome/gui/GMSHPLUGIN/images/Compounds.png differ
index 233983f955f379d2b8425277ce7c28cc614d0444..ec9de91bc16fb6766b5afcc8d94bca82154a6f15 100644 (file)
@@ -10,12 +10,13 @@ hypotheses and algorithms (2D and 1D for meshing 3D objects and 1D for meshing 2
 <br>
 \image html Arguments.png Dialog boxes of <b>Gmsh 2D</b> and <b> Gmsh 3D</b> algorithms.
 
-The <b>Arguments tab</b> of the dialog boxes is very similar to the original <a href="http://www.geuz.org/gmsh/"> <b> Gmsh </b></a>
+The <b>Arguments tab</b> of the dialog boxes is very similar to the original <a href="https://gmsh.info"> <b> Gmsh </b></a>
 GUI general mesh option tab.
 One familiar with the original interface can refer to the <a href="http://www.geuz.org/gmsh/doc/texinfo/gmsh.html">
 <b> Gmsh documentation </b></a> for more information.
 We briefly describe each argument of the <b>Arguments tab</b> and give the original corresponding Gmsh keyword
 (referring to <a href="http://www.geuz.org/gmsh/doc/texinfo/gmsh.html#Mesh-options-list"> <b> Gmsh Mesh options list</b></a>):
+
 - <b>Name</b> - allows to define the name for the algorithm ("Gmsh Parameters" by default).
 - <b>2D algorithm</b> - allows to choose the Gmsh 2D algorithm for both 2D and 3D meshes.
 Original corresponding Gmsh keyword is <b>"Mesh.Algorithm"</b>.
@@ -29,14 +30,16 @@ Original corresponding Gmsh keyword is <b>"Mesh.SubdivisionAlgorithm"</b>.
 Original corresponding Gmsh keyword is <b>"Mesh.RemeshAlgorithm"</b>.
 - <b>Remeshing parametrization</b> - allows to choose the remeshing parametrization.
 Original corresponding Gmsh keyword is <b>"Mesh.RemeshParametrization"</b>.
-- <b>Smoothing steps</b> - Number of steps to smooth the final mesh.
+- <b>Smoothing steps</b> - number of steps to smooth the final mesh.
 Original corresponding Gmsh keyword is <b>"Mesh.Smoothing"</b>.
 - <b>Element size factor</b> - factor used to linearly increase or decrease the default mesh size.
-Original corresponding Gmsh keyword is <b>"Mesh.CharacteristicLengthFactor"</b>.
-- <b>Max Size</b> - maximum linear dimensions for mesh cells.
-Original corresponding Gmsh keyword is <b>"Mesh.CharacteristicLengthMax"</b>.
-- <b>Min Size</b> - minimum linear dimensions for mesh cells.
-Original corresponding Gmsh keyword is <b>"Mesh.CharacteristicLengthMin"</b>.
+Original corresponding Gmsh keyword is <b>"Mesh.MeshSizeFactor"</b>.
+- <b>Elements per 2Pi radians</b> -  number of  mesh elements per 2 Pi radians. This helps defining a mesh size with respect to the curvature of the underlying geometry.
+Original corresponding Gmsh keyword is <b>"Mesh.MeshSizeFromCurvature"</b>.
+- <b>Max. Size</b> - maximum linear dimensions for mesh cells.
+Original corresponding Gmsh keyword is <b>"Mesh.MeshSizeMax"</b>.
+- <b>Min. Size</b> - minimum linear dimensions for mesh cells.
+Original corresponding Gmsh keyword is <b>"Mesh.MeshSizeMin"</b>.
 - <b>Second Order</b> - if this box is checked in, the algorithm will create second order nodes on the mesh,
 which actually will become quadratic.
 Original corresponding Gmsh keyword is <b>"Mesh.ElementOrder"</b> (set to 2 if the box is checked in, else 1).
@@ -56,4 +59,4 @@ Each group will be treated as a single entity during meshing.
 When meshed, the single entity will be reparametrized as a single surface, whose mesh can thus cross internal boundaries.
 - <b>Remove</b> - deletes selected rows from the table.
 
-*/
+*/
\ No newline at end of file
index 1356d2203371d1cedb13a1109fade7058e9c7106..7095583db10fa2e4c1066c29b50221ab96a2dc53 100644 (file)
@@ -3,7 +3,7 @@
 \mainpage Introduction to GMSHPLUGIN
 
 \b GMSHPLUGIN plugin provides an integration of certain functionalities of the well known
-<a href="http://www.geuz.org/gmsh/"> <b>Gmsh three-dimensional finite element mesh generator</b></a>.
+<a href="https://www.gmsh.info"> <b>Gmsh three-dimensional finite element mesh generator</b></a>.
 It is possible to mesh 2D and 3D geometric entities. The plugin was especially developed to
 integrate the Gmsh compound functionality. The plugin provides support
 of sub-meshes.
index 93eaaea466f989b7781b18b6897508f3372e247a..cd210c5dd055fc15954b58f377b0d436c3aa745a 100644 (file)
@@ -77,6 +77,9 @@ module GMSHPlugin
     
     void SetSizeFactor(in double value);
     double GetSizeFactor();
+
+    void SetMeshCurvatureSize(in double value);
+    double GetMeshCurvatureSize();
     
     void SetMaxSize(in double value);
     double GetMaxSize();
index 5519748b46d5c407da64ac482c34337c013d2802..75996a673226092b9bb91959578762e520a7fb76 100644 (file)
@@ -44,6 +44,9 @@ GMSHPlugin_Hypothesis::GMSHPlugin_Hypothesis (int hypId,
     _remeshPara     (harmonic),
     _smouthSteps    (1),
     _sizeFactor     (1),
+#if GMSH_MAJOR_VERSION >=4 && GMSH_MINOR_VERSION >=10
+    _meshCurvatureSize(0),
+#endif
     _minSize        (0),
     _maxSize        (1e22),
     _secondOrder    (false),
@@ -143,6 +146,17 @@ void GMSHPlugin_Hypothesis::SetUseIncomplElem(bool theUseIncomplElem)
   }
 }
 
+#if GMSH_MAJOR_VERSION >=4 && GMSH_MINOR_VERSION >=10
+void GMSHPlugin_Hypothesis::SetMeshCurvatureSize(double theMeshCurvatureSize)
+{
+  if (theMeshCurvatureSize != _meshCurvatureSize)
+  {
+    _meshCurvatureSize = theMeshCurvatureSize;
+    NotifySubMeshesHypothesisModification();
+  }
+}
+#endif
+
 void GMSHPlugin_Hypothesis::SetMaxSize(double theSize)
 {
   if (theSize != _maxSize)
@@ -206,6 +220,9 @@ std::ostream & GMSHPlugin_Hypothesis::SaveTo(std::ostream & save)
           " " << _remeshPara           <<
           " " << _smouthSteps          <<
           " " << _sizeFactor           <<
+#if GMSH_MAJOR_VERSION >=4 && GMSH_MINOR_VERSION >=10
+          " " << _meshCurvatureSize    <<
+#endif
           " " << _maxSize              <<
           " " << _minSize              <<
           " " << (int)_secondOrder     <<
@@ -288,6 +305,14 @@ std::istream & GMSHPlugin_Hypothesis::LoadFrom(std::istream & load)
   else
     load.clear(ios::badbit | load.rdstate());
 
+#if GMSH_MAJOR_VERSION >=4 && GMSH_MINOR_VERSION >=10
+  isOK = static_cast<bool>(load >> val);
+  if (isOK)
+    _meshCurvatureSize = val;
+  else
+    load.clear(ios::badbit | load.rdstate());
+#endif
+
   isOK = static_cast<bool>(load >> val);
   if (isOK)
     _maxSize = val;
index 7a0a3dc844caca30d638f33991a0d54e0af03596..d5c38fbb12de01dca5cc1f9787155e9e6d9028f9 100644 (file)
@@ -45,7 +45,12 @@ public:
    delaunay,
    frontal,
    delaunayforquad,
+#if GMSH_MAJOR_VERSION >=4 && GMSH_MINOR_VERSION >=10
+   packingparallelograms,
+   quadqs
+#else
    packingparallelograms
+#endif
   };
 
   void Set2DAlgo(Algo2D the2DAlgo);
@@ -124,6 +129,11 @@ public:
   
   void SetUseIncomplElem(bool theUseIncomplElem);
   bool GetUseIncomplElem() const { return _useIncomplElem; }
+
+#if GMSH_MAJOR_VERSION >=4 && GMSH_MINOR_VERSION >=10
+  void SetMeshCurvatureSize(double theMeshCurvatureSize);
+  double GetMeshCurvatureSize() const { return _meshCurvatureSize; }
+#endif
   
   void SetMaxSize(double theSize);
   double GetMaxSize() const { return _maxSize; }
@@ -170,6 +180,9 @@ private:
   RemeshPara    _remeshPara;
   double        _smouthSteps;
   double        _sizeFactor;
+#if GMSH_MAJOR_VERSION >=4 && GMSH_MINOR_VERSION >=10
+  double        _meshCurvatureSize;
+#endif
   double        _minSize, _maxSize;
   bool          _secondOrder, _useIncomplElem;
   bool          _is2d;
index b8ebfab5909f77f4ba19902614f4f52741b16ac7..1d2e131a8dfe785fa037e548f9d2580dd4708d58 100644 (file)
@@ -67,6 +67,22 @@ CORBA::Double GMSHPlugin_Hypothesis_i::GetMaxSize()
   return this->GetImpl()->GetMaxSize();
 }
 
+
+void GMSHPlugin_Hypothesis_i::SetMeshCurvatureSize (CORBA::Double theMeshCurvatureSize)
+{
+  if ( isToSetParameter( GetMeshCurvatureSize(), theMeshCurvatureSize, METH_SetMeshCurvatureSize ))
+  {
+    this->GetImpl()->SetMeshCurvatureSize(theMeshCurvatureSize);
+    SMESH::TPythonDump() << _this() << ".SetMeshCurvatureSize( " << SMESH::TVar(theMeshCurvatureSize) << " )";
+  }
+}
+
+CORBA::Double GMSHPlugin_Hypothesis_i::GetMeshCurvatureSize()
+{
+  return this->GetImpl()->GetMeshCurvatureSize();
+}
+
+
 void GMSHPlugin_Hypothesis_i::SetMinSize (CORBA::Double theValue)
 {
   if ( isToSetParameter( GetMinSize(), theValue, METH_SetMinSize ))
@@ -319,6 +335,7 @@ int GMSHPlugin_Hypothesis_i::getParamIndex(const TCollection_AsciiString& method
   if ( method == "SetNbSegPerEdge"   ) return 2;
   if ( method == "SetNbSegPerRadius" ) return 3;
   if ( method == "SetMinSize" )        return nbVars-1;
+  if ( method == "SetMeshCurvatureSize" )        return 5;
 
   return SMESH_Hypothesis_i::getParamIndex( method, nbVars ); // return default value
 }
@@ -340,6 +357,7 @@ std::string GMSHPlugin_Hypothesis_i::getMethodOfParameter(const int paramIndex,
   case 2: return "SetNbSegPerEdge";
   case 3: return "SetNbSegPerRadius";
   case 4: return "SetMinSize";
+  case 5: return "SetMeshCurvatureSize";
   }
   return "";
 }
index 53b49355ae861ee7d4e1c78b1c09d5db50c00f79..c7823fc99e516b9134302b211e50b9e9cf53dd9c 100644 (file)
@@ -46,6 +46,8 @@ class GMSHPLUGIN_EXPORT GMSHPlugin_Hypothesis_i:
   virtual ~GMSHPlugin_Hypothesis_i();
   
   // Ajout d'un truc
+  void SetMeshCurvatureSize(CORBA::Double theMeshCurvatureSize);
+  CORBA::Double GetMeshCurvatureSize();
   
   void SetMaxSize(CORBA::Double theSize);
   CORBA::Double GetMaxSize();
@@ -113,6 +115,7 @@ class GMSHPLUGIN_EXPORT GMSHPlugin_Hypothesis_i:
   // to remember whether a parameter is already set (issue 0021364)
   enum SettingMethod
   {
+    METH_SetMeshCurvatureSize = 5,
     METH_SetMaxSize          = 1,
     METH_SetMinSize          = 2,
     METH_SetSecondOrder      = 4,
index 0222b03e840ca6d182d016faeee2670c2cfd9191..23aa4d9b3395ee6461baeccb8be230e2af8aa07d 100644 (file)
@@ -176,6 +176,9 @@ void GMSHPlugin_Mesher::SetParameters(const GMSHPlugin_Hypothesis* hyp)
     _remeshPara      = hyp->GetRemeshPara();
     _smouthSteps     = hyp->GetSmouthSteps();
     _sizeFactor      = hyp->GetSizeFactor();
+#if GMSH_MAJOR_VERSION >=4 && GMSH_MINOR_VERSION >=10
+    _meshCurvatureSize = hyp->GetMeshCurvatureSize();
+#endif
     _minSize         = hyp->GetMinSize();
     _maxSize         = hyp->GetMaxSize();
     _secondOrder     = hyp->GetSecondOrder();
@@ -193,6 +196,9 @@ void GMSHPlugin_Mesher::SetParameters(const GMSHPlugin_Hypothesis* hyp)
     _remeshPara      = 0;
     _smouthSteps     = 1;
     _sizeFactor      = 1;
+#if GMSH_MAJOR_VERSION >=4 && GMSH_MINOR_VERSION >=10
+    _meshCurvatureSize = 0;
+#endif
     _minSize         = 0;
     _maxSize         = 1e22;
     _secondOrder     = false;
@@ -212,8 +218,11 @@ void GMSHPlugin_Mesher::SetParameters(const GMSHPlugin_Hypothesis* hyp)
 void GMSHPlugin_Mesher::SetMaxThreadsGmsh()
 {
   MESSAGE("GMSHPlugin_Mesher::SetMaxThreadsGmsh");
-  if (_compounds.size() > 0)
+  // compound meshing (_compounds.size() > 0) and quad meshing (_algo2d >= 5) will
+  // not be multi-threaded
+  if (_compounds.size() > 0 || _algo2d >= 5){
     _maxThreads = 1;
+  }
   else
     _maxThreads = omp_get_max_threads();
 }
@@ -252,6 +261,9 @@ void GMSHPlugin_Mesher::SetGmshOptions()
   mapAlgo2d[3]=6; // Frontal-Delaunay
   mapAlgo2d[4]=8; // DelQuad (Frontal-Delaunay for Quads)
   mapAlgo2d[5]=9; // Packing of parallelograms
+#if GMSH_MAJOR_VERSION >=4 && GMSH_MINOR_VERSION >=10
+  mapAlgo2d[6]=11;// Quasistructured quads with cross-fields
+#endif
 
   std::map <int,double> mapAlgo3d;
   mapAlgo3d[0]=1; // Delaunay
@@ -280,6 +292,10 @@ void GMSHPlugin_Mesher::SetGmshOptions()
   //ASSERT(ok);
   ok = GmshSetOption("Mesh", "Smoothing"                , (double)_smouthSteps)  ;
   //ASSERT(ok);
+#if GMSH_MAJOR_VERSION >=4 && GMSH_MINOR_VERSION >=10
+  ok = GmshSetOption("Mesh", "MeshSizeFromCurvature"       , _meshCurvatureSize) ;
+  ASSERT(ok);
+#endif
 #if GMSH_MAJOR_VERSION >=4 && GMSH_MINOR_VERSION >=8
   ok = GmshSetOption("Mesh", "MeshSizeFactor"              , _sizeFactor)     ;
   ASSERT(ok);
index a291d621f195df2d2fd1c59e2fd39ef6c623803d..b20520a11a0e7a4ef0635d2b33aa2014e1614afe 100644 (file)
@@ -97,6 +97,9 @@ class GMSHPLUGIN_EXPORT GMSHPlugin_Mesher
 #if GMSH_MAJOR_VERSION >=4 && GMSH_MINOR_VERSION >=3
   double               _maxThreads;
 #endif
+#if GMSH_MAJOR_VERSION >=4 && GMSH_MINOR_VERSION >=10
+  double               _meshCurvatureSize;
+#endif
 
   std::set<std::string> _compounds;
 
index caa321e9fe10e21fccaadc867f23558fa365e48e..a048c1656920e7ab4650863175af2e665306ef35 100644 (file)
@@ -53,7 +53,12 @@ enum Algo2D
    delaunay,
    frontal,
    delaunayforquad,
+#if GMSH_MAJOR_VERSION >=4 && GMSH_MINOR_VERSION >=10
+   packingparallelograms,
+   quadqs
+#else
    packingparallelograms
+#endif
   };
 
   enum Algo3D
@@ -61,7 +66,8 @@ enum Algo2D
    delaunay3,
    frontal3,
    mmg3d,
-   rtree
+   rtree,
+   hxt
   };
 
 #if GMSH_MAJOR_VERSION >=4 && GMSH_MINOR_VERSION >=8
@@ -158,8 +164,17 @@ QFrame* GMSHPluginGUI_HypothesisCreator::buildFrame()
   aGroupLayout->addWidget( new QLabel( tr( "GMSH_2D_ALGO" ), GroupC1 ), row, 0 );
   my2DAlgo = new QComboBox( GroupC1 );
   QStringList types2DAlgo;
-  types2DAlgo << tr( "GMSH_AUTOMATIC" ) << tr( "GMSH_MESH_ADAPT" )   << tr( "GMSH_DELAUNAY" ) <<
-                 tr( "GMSH_FRONTAL" )       << tr( "GMSH_DELAUNAY_FOR_QUAD" ) << tr( "GMSH_PACKING_OF_PARALLELOGRAMS" );
+  types2DAlgo << tr( "GMSH_AUTOMATIC" )
+             << tr( "GMSH_MESH_ADAPT" )
+             << tr( "GMSH_DELAUNAY" )
+             << tr( "GMSH_FRONTAL" )
+             << tr( "GMSH_DELAUNAY_FOR_QUAD" )
+#if GMSH_MAJOR_VERSION >=4 && GMSH_MINOR_VERSION >=10
+             << tr( "GMSH_PACKING_OF_PARALLELOGRAMS" )
+              << tr( "GMSH_QUASI_STRUCTURED_QUAD" );
+#else
+              << tr( "GMSH_PACKING_OF_PARALLELOGRAMS" );
+#endif
   my2DAlgo->addItems( types2DAlgo );
   aGroupLayout->addWidget( my2DAlgo, row, 1 );
   row++;
@@ -229,6 +244,14 @@ QFrame* GMSHPluginGUI_HypothesisCreator::buildFrame()
   aGroupLayout->addWidget( mySizeFactor, row, 1 );
   row++;
 
+#if GMSH_MAJOR_VERSION >=4 && GMSH_MINOR_VERSION >=10
+  aGroupLayout->addWidget( new QLabel( tr( "GMSH_SIZE_FROM_CURVATURE" ), GroupC1 ), row, 0 );
+  myMeshCurvatureSize = new SMESHGUI_SpinBox( GroupC1 );
+  myMeshCurvatureSize->RangeStepAndValidator( 0.0, 1e+22, 1.0, "length_precision" );
+  aGroupLayout->addWidget( myMeshCurvatureSize, row, 1 );
+  row++;
+#endif
+
   aGroupLayout->addWidget( new QLabel( tr( "GMSH_MIN_SIZE" ), GroupC1 ), row, 0 );
   myMinSize = new SMESHGUI_SpinBox( GroupC1 );
   myMinSize->RangeStepAndValidator( 0.0, 1e+22, 1., "length_precision" );
@@ -380,6 +403,12 @@ void GMSHPluginGUI_HypothesisCreator::retrieveParams() const
     mySizeFactor->setValue( data.mySizeFactor );
   else
     mySizeFactor->setText( data.mySizeFactorVar );
+#if GMSH_MAJOR_VERSION >=4 && GMSH_MINOR_VERSION >=10
+  if(data.myMeshCurvatureSizeVar.isEmpty())
+    myMeshCurvatureSize->setValue( data.myMeshCurvatureSize );
+  else
+    myMeshCurvatureSize->setText( data.myMeshCurvatureSizeVar );
+#endif
   if(data.myMaxSizeVar.isEmpty())
     myMaxSize->setValue( data.myMaxSize );
   else
@@ -419,6 +448,9 @@ QString GMSHPluginGUI_HypothesisCreator::storeParams() const
 
   QString valStr = tr("GMSH_MAX_SIZE") + " = " + QString::number( data.myMaxSize ) + "; ";
   valStr += tr("GMSH_MIN_SIZE") + " = " + QString::number( data.myMinSize ) + "; ";
+#if GMSH_MAJOR_VERSION >=4 && GMSH_MINOR_VERSION >=10
+  valStr += tr("GMSH_SIZE_FROM_CURVATURE") + " = " + QString::number( data.myMeshCurvatureSize ) + "; ";
+#endif
   if ( data.mySecondOrder )
     valStr +=  tr("GMSH_SECOND_ORDER") + "; ";
 
@@ -443,6 +475,10 @@ bool GMSHPluginGUI_HypothesisCreator::readParamsFromHypo( GmshHypothesisData& h_
   h_data.myRemeshPara = (int) h->GetRemeshPara();
   h_data.mySmouthSteps = h->GetSmouthSteps();
   h_data.mySizeFactor = h->GetSizeFactor();
+#if GMSH_MAJOR_VERSION >=4 && GMSH_MINOR_VERSION >=10
+  h_data.myMeshCurvatureSize = h->GetMeshCurvatureSize();
+  h_data.myMeshCurvatureSizeVar = getVariableName("SetMeshCurvatureSize");
+#endif
   h_data.myMinSize = h->GetMinSize();
   h_data.myMaxSize = h->GetMaxSize();
   h_data.mySmouthStepsVar = getVariableName("SmouthSteps");
@@ -484,10 +520,16 @@ bool GMSHPluginGUI_HypothesisCreator::storeParamsToHypo( const GmshHypothesisDat
     h->SetRemeshPara( h_data.myRemeshPara );
     h->SetSmouthSteps( h_data.mySmouthSteps );
     h->SetSizeFactor( h_data.mySizeFactor );
+#if GMSH_MAJOR_VERSION >=4 && GMSH_MINOR_VERSION >=10
+    h->SetMeshCurvatureSize( h_data.myMeshCurvatureSize );
+#endif
     h->SetMinSize( h_data.myMinSize );
     h->SetMaxSize( h_data.myMaxSize );
     h->SetVarParameter( h_data.mySmouthStepsVar.toLatin1().constData(), "SmouthSteps");
     h->SetVarParameter( h_data.mySizeFactorVar.toLatin1().constData(), "SizeFactor");
+#if GMSH_MAJOR_VERSION >=4 && GMSH_MINOR_VERSION >=10
+    h->SetVarParameter( h_data.myMeshCurvatureSizeVar.toLatin1().constData(), "SetMeshCurvatureSize");
+#endif
     h->SetVarParameter( h_data.myMinSizeVar.toLatin1().constData(), "SetMinSize");
     h->SetVarParameter( h_data.myMaxSizeVar.toLatin1().constData(), "SetMaxSize");
     h->SetSecondOrder( h_data.mySecondOrder );
@@ -535,6 +577,10 @@ bool GMSHPluginGUI_HypothesisCreator::readParamsFromWidgets( GmshHypothesisData&
   h_data.myRemeshPara     = myRemeshPara->currentIndex();
   h_data.mySmouthSteps    = mySmouthSteps->value();
   h_data.mySizeFactor     = mySizeFactor->value();
+#if GMSH_MAJOR_VERSION >=4 && GMSH_MINOR_VERSION >=10
+  h_data.myMeshCurvatureSize    = myMeshCurvatureSize->value();
+  h_data.myMeshCurvatureSizeVar = myMeshCurvatureSize->text();
+#endif
   h_data.myMinSize        = myMinSize->value();
   h_data.myMaxSize        = myMaxSize->value();
   h_data.mySmouthStepsVar = mySmouthSteps->text();
index 6d8d7cb380afb40bd320aed10daccca6ffa8fbfe..2b022c9394ce731661545b7a3a90fad36a8f840a 100644 (file)
@@ -45,8 +45,13 @@ typedef struct
   int                 mySubdivAlgo,myRemeshAlgo,myRemeshPara,mySmouthSteps;
   bool                myUseIncomplElem;
   bool                mySecondOrder;
+#if GMSH_MAJOR_VERSION >=4 && GMSH_MINOR_VERSION >=10
+  double              mySizeFactor,myMaxSize, myMinSize, myMeshCurvatureSize;
+  QString             myMaxSizeVar, myMinSizeVar, mySmouthStepsVar, mySizeFactorVar, myMeshCurvatureSizeVar;
+#else
   double              mySizeFactor,myMaxSize, myMinSize;
   QString             myMaxSizeVar, myMinSizeVar, mySmouthStepsVar, mySizeFactorVar;
+#endif
   mutable QString     myErrorMsg;
 } GmshHypothesisData;
 
@@ -95,6 +100,9 @@ private:
  QComboBox*        myRemeshPara;
  SMESHGUI_SpinBox* mySmouthSteps;
  SMESHGUI_SpinBox* mySizeFactor;
+#if GMSH_MAJOR_VERSION >=4 && GMSH_MINOR_VERSION >=10
+ SMESHGUI_SpinBox* myMeshCurvatureSize;
+#endif
  SMESHGUI_SpinBox* myMaxSize;
  SMESHGUI_SpinBox* myMinSize;
  QCheckBox*        myUseIncomplElem;
index d649a34dca2011730656d37c56ee3b5111d1a29e..167f7ec83fa06f635be105ccf81c7b6732e184a6 100644 (file)
         <source>GMSH_3D_TITLE</source>
         <translation>Hypothesis Construction</translation>
     </message>
+    <message>
+        <source>GMSH_SIZE_FROM_CURVATURE</source>
+        <translation>Elements per 2Pi radians</translation>
+    </message>
     <message>
         <source>GMSH_MAX_SIZE</source>
         <translation>Max. Size</translation>
@@ -61,7 +65,7 @@
     </message>
     <message>
         <source>GMSH_MESH_ADAPT</source>
-        <translation>Mesh adapt</translation>
+        <translation>MeshAdapt</translation>
     </message>
     <message>
         <source>GMSH_DELAUNAY</source>
     </message>
     <message>
         <source>GMSH_FRONTAL</source>
-        <translation>Frontal</translation>
+        <translation>Frontal-Delaunay</translation>
     </message>
     <message>
         <source>GMSH_DELAUNAY_FOR_QUAD</source>
-        <translation>Delaunay for quads</translation>
+        <translation>Frontal-Delaunay for Quads</translation>
+    </message>
+    <message>
+        <source>GMSH_QUASI_STRUCTURED_QUAD</source>
+        <translation>Quasi-Structured Quad</translation>
     </message>
     <message>
         <source>GMSH_PACKING_OF_PARALLELOGRAMS</source>
index fc1376c833a1c8a16bc821006b531844dde2c339..aba708808b5fc9635d16f14c884a6e84f7cb2308 100644 (file)
         <source>GMSH_3D_TITLE</source>
         <translation>Construction d&apos;une hypothèse</translation>
     </message>
+    <message>
+        <source>GMSH_SIZE_FROM_CURVATURE</source>
+        <translation>Eléments par 2Pi radians</translation>
+    </message>
     <message>
         <source>GMSH_MAX_SIZE</source>
         <translation>Taille maximale</translation>
         <source>GMSH_DELAUNAY_FOR_QUAD</source>
         <translation>Delaunay pour quads</translation>
     </message>
+    <message>
+        <source>GMSH_QUASI_STRUCTURED_QUAD</source>
+        <translation>Quadrangles quasi-structuré</translation>
+    </message>
     <message>
         <source>GMSH_PACKING_OF_PARALLELOGRAMS</source>
         <translation>Remplissage de parallélogrammes</translation>