![]() |
SWMMVis
6.0.0-alpha.4
Qt6/C++ GIS-based graphical user interface for the SWMMVis engine (6.0.0-alpha.4)
|
#include "map/mapextent.h"#include <QPointer>#include <QQuickItem>#include <QVector>#include <limits>Go to the source code of this file.
Classes | |
| class | SWMMLayerQSGRenderer |
Phase B.RHI of docs/RENDERING_5M_PLAN.md — Qt Quick Scene Graph renderer for SWMMModelLayer. Hosted in a QQuickWidget overlay on MapCanvas. Replaces the abandoned OpenGL renderer (SWMMLayerGLRenderer) which couldn't fill polygons via Qt's GL paint engine on macOS Apple Silicon.
Rendering architecture (see docs/QSG_PAN_ZOOM_OPTIMIZATIONS.md):
Stage 1–3: fixed anchor + m_contentDirty flag — pan costs one matrix write, geometry only rebuilt on model change or zoom. Stage 4: subcatchment tri cache keyed off geomRevision — O(n²) ear-clip runs once per geometry change, reused on zoom/selection/symbology. Stage 5: view-frustum culling — off-screen features skipped entirely. Stage 6: LOD — sub-pixel node/gage glyphs suppressed.
NOTE: Stage 7 (async build) was reverted. MapCanvas drives rendering via repaint() + grabFramebuffer() synchronously, so async building races with the grab and produces empty frames. All geometry is built synchronously inside updatePaintNode (on the render thread, which is the main thread for QQuickWidget). Stage 1-6 optimisations still eliminate the O(N) cost for pan and reduce rebuild cost significantly.