Skip to content

Commit

Permalink
Merge pull request FreeCAD#15661 from FEA-eng/mesh_gmsh_quasi_quad
Browse files Browse the repository at this point in the history
MESH: Add missing Gmsh 2D algorithm (Quasi-structured Quad)
  • Loading branch information
chennes committed Jul 29, 2024
2 parents fe70234 + 0a50d27 commit 04acc05
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
6 changes: 4 additions & 2 deletions src/Mod/Mesh/Gui/RemeshGmsh.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,8 @@ GmshWidget::GmshWidget(QWidget* parent, Qt::WindowFlags fl)
FrontalDelaunay = 6,
BAMG = 7,
FrontalDelaunayForQuads = 8,
PackingOfParallelograms = 9
PackingOfParallelograms = 9,
QuasiStructuredQuad = 11
};

d->ui.method->addItem(tr("Automatic"), static_cast<int>(Automatic));
Expand All @@ -102,6 +103,7 @@ GmshWidget::GmshWidget(QWidget* parent, Qt::WindowFlags fl)
d->ui.method->addItem(QString::fromLatin1("BAMG"), static_cast<int>(BAMG));
d->ui.method->addItem(tr("Frontal Quad"), static_cast<int>(FrontalDelaunayForQuads));
d->ui.method->addItem(tr("Parallelograms"), static_cast<int>(PackingOfParallelograms));
d->ui.method->addItem(tr("Quasi-structured Quad"), static_cast<int>(QuasiStructuredQuad));
}

GmshWidget::~GmshWidget()
Expand Down Expand Up @@ -338,7 +340,7 @@ bool RemeshGmsh::writeProject(QString& inpFile, QString& outFile)
<< " Exit;\n"
<< "EndIf\n"
<< "Merge \"" << stl.filePath() << "\";\n\n"
<< "// 2D mesh algorithm (1=MeshAdapt, 2=Automatic, 5=Delaunay, 6=Frontal, 7=BAMG, 8=Frontal Quad, 9=Packing of Parallelograms)\n"
<< "// 2D mesh algorithm (1=MeshAdapt, 2=Automatic, 5=Delaunay, 6=Frontal, 7=BAMG, 8=Frontal Quad, 9=Packing of Parallelograms, 11=Quasi-structured Quad)\n"
<< "Mesh.Algorithm = " << algorithm << ";\n\n"
<< "// 3D mesh algorithm (1=Delaunay, 2=New Delaunay, 4=Frontal, 7=MMG3D, 9=R-tree, 10=HTX)\n"
<< "// Mesh.Algorithm3D = 1;\n\n"
Expand Down
2 changes: 1 addition & 1 deletion src/Mod/MeshPart/Gui/Tessellation.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -607,7 +607,7 @@ bool Mesh2ShapeGmsh::writeProject(QString& inpFile, QString& outFile)
<< "// mesh algorithm, only a few algorithms are usable with 3D boundary layer "
"generation\n"
<< "// 2D mesh algorithm (1=MeshAdapt, 2=Automatic, 5=Delaunay, 6=Frontal, "
"7=BAMG, 8=DelQuad, 9=Packing of Parallelograms)\n"
"7=BAMG, 8=DelQuad, 9=Packing of Parallelograms, 11=Quasi-structured Quad)\n"
<< "Mesh.Algorithm = " << algorithm << ";\n"
<< "// 3D mesh algorithm (1=Delaunay, 2=New Delaunay, 4=Frontal, 7=MMG3D, "
"9=R-tree, 10=HTX)\n"
Expand Down

0 comments on commit 04acc05

Please sign in to comment.