![]() |
SWMMVis
6.0.0-alpha.4
Qt6/C++ GIS-based graphical user interface for the SWMMVis engine (6.0.0-alpha.4)
|
#include <sizefield.h>
Public Attributes | |
| double | nearSize = 0.0 |
| double | gradation = 0.25 |
| double | areaFloor = 0.0 |
| qint64 | maxGridCells = 4'000'000 |
| bool | terrainDensity = false |
| double mesh::SizeFieldOptions::areaFloor = 0.0 |
Refinement floor A_min (map units², from MinSizePolicy). The returned area is never below this, matching MinSizePolicy::refinementAreaCap's rule that the floor may raise a too-small cap. 0 = no floor.
| double mesh::SizeFieldOptions::gradation = 0.25 |
Lipschitz slope g: how fast the target size may grow per unit of distance from a feature. Must be > 0 (0 = the caller should not build a field at all — the uniform cap already expresses that). Typical 0.1–0.5; 0.25 ≈ a 1.6× area step between neighbouring cells at the fine scale.
| qint64 mesh::SizeFieldOptions::maxGridCells = 4'000'000 |
Budget for the background grid. The pitch grows until the grid fits, so any domain builds — a huge one just gets a coarser distance field, which only softens the grading, never breaks it.
| double mesh::SizeFieldOptions::nearSize = 0.0 |
Element size (edge length, map units) AT a feature. Callers derive it from the uniform area cap: side of the equilateral triangle of GenerationOptions::maxArea. Must be > 0.
| bool mesh::SizeFieldOptions::terrainDensity = false |
Also bound the size by the local density of the UNTAGGED (marker 0) points passed to build() — the DTM thinner's output (QUAD_EVERYWHERE_PLAN_2026-09-07.md §3.4).
WHY. Terrain complexity normally reaches the mesh by the thinner's points simply BEING vertices: it puts them densely where the ground is complex. A quad region replaces them with its lattice (redesign D5), so under a whole-domain quad mesh that density would be lost unless it is re-expressed as a size. The thinner already chose the local resolution by where it put points, so the local point spacing IS the target element size: h_terrain = pitch / sqrt(points in the cell), propagated outward under the same Lipschitz slope, and combined as h = min(nearSize + gradation·d, h_terrain).
Off by default: it only matters when something drops those points.