![]() |
SWMMVis
6.0.0-alpha.4
Qt6/C++ GIS-based graphical user interface for the SWMMVis engine (6.0.0-alpha.4)
|
Classes | |
| struct | Stats |
| struct | Triangle |
Public Member Functions | |
| bool | prepare (const QPointF *xy, const double *z, Triangle &T) const |
| Validate a query plane and populate its local geometry/certification context. | |
| bool | nodeBound (const Node &n, const Triangle &T, double &bound, bool &overridden) const |
| Check node/query rectangle relevance and derive its affine residual upper bound. | |
| ~Impl () | |
| Release owned OGR forward/reverse transforms and the GDAL dataset handle. | |
| bool | readTile (GDALDataset *src, OGRCoordinateTransformation *ct, int tc, int tr, Tile &t, QString &err) const |
| Read one native raster tile and optionally compute transformed local mesh pixel centers. | |
| const Tile * | tile (int col, int row) const |
| Borrow a cached native tile for an absolute raster pixel, loading it on a miss. | |
| const Tile * | insertTile (std::unique_ptr< Tile > t) const |
| Transfer a completed heap tile into the shared cost-bounded LRU cache. | |
| double | z (const Tile *t, int i) const |
| Read one native tile elevation, reject missing/nonfinite input and apply vertical scale. | |
| void | meshXY (const Tile *t, int col, int row, int i, double &x, double &y) const |
| Resolve one tile sample center into mesh coordinates relative to the field origin. | |
| void | summarizeTile (const Tile *t, int tx, int ty, Node *nodes, int leafCols, Stats &st) const |
| Fit disjoint 16-pixel leaves of one tile and accumulate raw-terrain sample statistics. | |
| void | writeHeader (QDataStream &s) const |
| Serialize the identity envelope for the native-ABI persisted summary hierarchy. | |
| bool | loadIndex (const QString &file) |
| Attempt to replace summaries/statistics from a matching persisted index without modifying on a miss. | |
| bool | saveIndex (const QString &file) const |
| Best-effort atomically persist the retained hierarchy and raw-terrain statistics. | |
| void | prefetch () const |
| Best-effort warm the full summary-window raster cache after loading a saved hierarchy. | |
| void | prefetchBoxes (const QVector< QRectF > &boxes) const |
| Load a budget-selected subset of missing tiles under mesh-coordinate rectangles in parallel. | |
| bool | build (const std::function< bool(double)> &progress) |
| Construct leaf residual planes and aggregate the dyadic raw-terrain summary hierarchy. | |
Public Attributes | |
| QRectF | overrideBounds |
| std::function< double(double, double, double)> | queryOverride |
| std::function< bool(const QRectF &)> | overrideIntersects |
| GDALDataset * | ds = nullptr |
| QString | path |
| Source file; empty for in-memory grids. | |
| OGRCoordinateTransformation * | toMesh = nullptr |
| OGRCoordinateTransformation * | toDEM = nullptr |
| int | width = 0 |
| int | height = 0 |
| int | c0 = 0 |
| int | r0 = 0 |
| int | cols = 0 |
| int | rows = 0 |
| double | geo [6] = {} |
| double | inv [6] = {} |
| double | scale = 1 |
| double | noData = nan |
| QPointF | origin |
| QVector< Level > | levels |
| QCache< quint64, Tile > | cache |
| QMutex | cacheMutex |
| Guards cache only during the parallel build. | |
| bool | floatTiles = false |
| QString | error |
| bool | wholeUnits = true |
| double | minZ = std::numeric_limits<double>::infinity() |
| double | maxZ = -std::numeric_limits<double>::infinity() |
| std::function< bool()> | cancelled |
| bool | indexLoaded = false |
| bool | indexSaved = false |
Static Public Attributes | |
| static constexpr quint32 | kIndexMagic = 0x54454649 |
| static constexpr quint16 | kIndexVersion = 1 |
|
inline |
Release owned OGR forward/reverse transforms and the GDAL dataset handle.
|
inline |
Construct leaf residual planes and aggregate the dyadic raw-terrain summary hierarchy.
| [in] | progress | Optional borrowed synchronous fraction callback, invoked at 0, completed row chunks, repeated .95 for parent levels, and 1. False stores Cancelled and returns false; exceptions propagate, no callback retained and reentrant field/dataset mutation is unsupported. |
|
inline |
Transfer a completed heap tile into the shared cost-bounded LRU cache.
| [in] | t | Required nonnull unique_ptr moved by value; ownership is released to QCache, which can immediately delete/reject an over-budget tile. Header/arrays must match field storage/transform policy. |
|
inline |
Attempt to replace summaries/statistics from a matching persisted index without modifying on a miss.
| [in] | file | Borrowed input pathname, unchanged; caller has selected a source/settings-specific cache key. |
|
inline |
Resolve one tile sample center into mesh coordinates relative to the field origin.
| [in] | t | Required borrowed live tile; transformed arrays present when toMesh is active, unchanged. |
| [in] | col | Absolute raster column corresponding to i, unchecked. |
| [in] | row | Absolute raster row corresponding to i, unchecked. |
| [in] | i | Valid tile-local row-major index, used for cached transformed arrays. |
| [out] | x | Borrowed local mesh x output, always overwritten. |
| [out] | y | Borrowed local mesh y output, always overwritten; use distinct outputs. |
| bool mesh::TerrainErrorField::Impl::nodeBound | ( | const Node & | n, |
| const Triangle & | T, | ||
| double & | bound, | ||
| bool & | overridden | ||
| ) | const |
Check node/query rectangle relevance and derive its affine residual upper bound.
| [in] | n | Borrowed summary node with finite valid bounds/plane/residual metadata, unchanged. |
| [in] | T | Borrowed successfully prepared triangle context in the same local frame, unchanged. |
| [out] | bound | Borrowed vertical upper bound, assigned only when node is nonempty and bbox overlaps. |
| [out] | overridden | Borrowed flag, assigned only on that same relevant-node path; true when retained override bounds/predicate can affect the rectangle intersection. |
|
inline |
Best-effort warm the full summary-window raster cache after loading a saved hierarchy.
|
inline |
Load a budget-selected subset of missing tiles under mesh-coordinate rectangles in parallel.
| [in] | boxes | Borrowed finite mesh-CRS rectangles, unchanged; transformed pixel extrema/floor/ceil indices need int headroom. Invalid transform boxes are skipped, empty/no-path input returns. |
| bool mesh::TerrainErrorField::Impl::prepare | ( | const QPointF * | xy, |
| const double * | z, | ||
| Triangle & | T | ||
| ) | const |
Validate a query plane and populate its local geometry/certification context.
| [in] | xy | Required borrowed three-corner array in absolute mesh coordinates, finite and unchanged. |
| [in] | z | Required borrowed three-elevation array in scaled output units, finite and unchanged. |
| [out] | T | Borrowed query context, partly overwritten before possible determinant failure; usable only when true. Stores relative corners, plane, bounds, rounding slack and override relevance. |
|
inline |
Read one native raster tile and optionally compute transformed local mesh pixel centers.
| [in] | src | Required borrowed open dataset with band 1 and dimensions matching this field; caller owns/closes it and provides one independent reader per parallel worker. |
| [in] | ct | Optional borrowed source-to-mesh transform, independent per worker; null uses implicit native coordinates. Caller owns/destroys transform and must exclude concurrent use of that handle. |
| [in] | tc | Nonnegative tile column with tc*256 inside width, representable multiplication. |
| [in] | tr | Nonnegative tile row with tr*256 inside height. |
| [out] | t | Borrowed destination tile, header/arrays overwritten incrementally and possibly partial on failure. Native z uses exact float or double storage; transformed coordinates subtract field origin. |
| [out] | err | Borrowed diagnostic string, overwritten on RasterIO/transform failure, unchanged on success. |
|
inline |
Best-effort atomically persist the retained hierarchy and raw-terrain statistics.
| [in] | file | Borrowed destination path, parent volume/directory must exist and be writable, unchanged. |
|
inline |
Fit disjoint 16-pixel leaves of one tile and accumulate raw-terrain sample statistics.
| [in] | t | Required borrowed complete tile matching the supplied absolute tile origin, unchanged. |
| [in] | tx | Absolute tile first column aligned to 256, with valid 16-pixel-aligned summary window. |
| [in] | ty | Absolute tile first row under the same alignment/extent contract. |
| [in,out] | nodes | Required writable leaf-node array with leafCols*leafRows extent, initially defaulted; only this tile's disjoint leaves are populated, including bounds, valid/missing counts, fitted plane and maximum residual plus roundoff. No concurrent worker may touch the same leaf. |
| [in] | leafCols | Positive leaf-grid column stride, matching window layout. |
| [in,out] | st | Borrowed worker-local reduction, whole-unit flag ANDed and min/max extended over finite scaled samples. Requires positive field scale and representable fits/index arithmetic. |
|
inline |
Borrow a cached native tile for an absolute raster pixel, loading it on a miss.
| [in] | col | Absolute raster column, valid range [0,width); out-of-range returns null. |
| [in] | row | Absolute raster row, valid range [0,height); out-of-range returns null. |
|
inline |
Serialize the identity envelope for the native-ABI persisted summary hierarchy.
| [in,out] | s | Borrowed output stream, advanced by magic/version/Node size/tile/leaf constants, raster/window dimensions, geotransform, scale, NoData, origin and reprojection-presence flag. Caller pins Qt_6_0 version and owns the device; stream errors remain in its status. |
|
inline |
Read one native tile elevation, reject missing/nonfinite input and apply vertical scale.
| [in] | t | Required borrowed live cache/worker tile with arrays matching floatTiles, unchanged. |
| [in] | i | Valid row-major local element index [0,t.cols*t.rows), unchecked. |
| int mesh::TerrainErrorField::Impl::c0 = 0 |
|
mutable |
|
mutable |
Guards cache only during the parallel build.
| std::function<bool()> mesh::TerrainErrorField::Impl::cancelled |
| int mesh::TerrainErrorField::Impl::cols = 0 |
| GDALDataset* mesh::TerrainErrorField::Impl::ds = nullptr |
|
mutable |
| bool mesh::TerrainErrorField::Impl::floatTiles = false |
| double mesh::TerrainErrorField::Impl::geo[6] = {} |
| int mesh::TerrainErrorField::Impl::height = 0 |
| bool mesh::TerrainErrorField::Impl::indexLoaded = false |
| bool mesh::TerrainErrorField::Impl::indexSaved = false |
| double mesh::TerrainErrorField::Impl::inv[6] = {} |
|
staticconstexpr |
|
staticconstexpr |
| QVector<Level> mesh::TerrainErrorField::Impl::levels |
| double mesh::TerrainErrorField::Impl::noData = nan |
| QPointF mesh::TerrainErrorField::Impl::origin |
| QRectF mesh::TerrainErrorField::Impl::overrideBounds |
| std::function<bool(const QRectF &)> mesh::TerrainErrorField::Impl::overrideIntersects |
| QString mesh::TerrainErrorField::Impl::path |
Source file; empty for in-memory grids.
| int mesh::TerrainErrorField::Impl::r0 = 0 |
| int mesh::TerrainErrorField::Impl::rows = 0 |
| double mesh::TerrainErrorField::Impl::scale = 1 |
| OGRCoordinateTransformation * mesh::TerrainErrorField::Impl::toDEM = nullptr |
| OGRCoordinateTransformation* mesh::TerrainErrorField::Impl::toMesh = nullptr |
| bool mesh::TerrainErrorField::Impl::wholeUnits = true |
| int mesh::TerrainErrorField::Impl::width = 0 |