![]() |
SWMMVis
6.0.0-alpha.4
Qt6/C++ GIS-based graphical user interface for the SWMMVis engine (6.0.0-alpha.4)
|
#include "mesh/meshquadcleanup.h"#include "mesh/meshcellgeom.h"#include "mesh/meshquadmerge.h"#include <QHash>#include <algorithm>#include <cmath>Namespaces | |
| namespace | mesh |
Functions | |
| QVector< int > | mesh::reorderTrianglesFirst (MeshResult &mesh) |
| Reorder cells triangles-first, stable within each class. Returns the old→new cell index map. Shared with meshquadmatch. | |
| QuadCleanupStats | mesh::cleanupAndSmoothQuads (MeshResult &mesh, const QSet< int > &movable, const QuadCleanupOptions &opts, QVector< int > *vertexOldToNew) |
Run cleanup then smoothing. vertexOldToNew (optional) receives the vertex remap after doublet compaction (-1 = removed); identity when nothing was removed. Cells are rebuilt triangles-first afterwards. | |
Topological cleanup and guarded smoothing inside quad regions (QUAD_MESHING_REDESIGN_PLAN §4.4g–h): doublet removal, valence-driven diagonal swaps, then Jacobi "parallelogram" smoothing accepted only when the minimum scaled Jacobian around the vertex does not drop and every incident cell keeps its orientation (quads: convexity). Only vertices in the movable set are moved or removed.
| QVector<bool> cellAlive |
| QVector<MeshTriangle>& cells |
| QVector<QVector<int> > incident |
| QVector<MeshVertex>& V |
| QVector<bool> vertexAlive |