Repository navigation
Conversation
There was a problem hiding this comment.
🟡 Changes recommended
The tests can miss a permanent OpenGL fallback regression, and the rendering baseline uses invalid overlapping MultiPolygons, requiring fixture corrections and refreshed measurements.
2 open issues
What changed in this PR
This PR adds verification and performance documentation for the complex-polygon rendering pipeline introduced by Core triangulation in #66 and OpenGL mesh rendering in #68.
Changes:
- Adds tests for mesh retention across viewport changes and ring-based GDI fallback.
- Adds an opt-in complex-polygon benchmark covering scene preparation, mesh storage, memory growth, and backend frame costs.
- Updates rendering documentation to describe mesh-based OpenGL support and record performance measurements.
Builds and tests were not run during this review.
| File | Description |
|---|---|
tests/MapWinGIS.Core.Tests/MapViewTests.cpp |
Adds complex-scene mesh lifecycle coverage. |
tests/MapWinGIS.ActiveX.Tests/VectorLayerRendererTests.cpp |
Adds concave and holed polygon fallback coverage. |
tests/MapWinGIS.ActiveX.Tests/RenderingBaselineTests.cpp |
Adds complex geometry fixtures and performance measurements. |
docs/TESTING.md |
Documents benchmark workloads, usage, and recorded results. |
docs/PORTING.md |
Updates supported polygon rendering and fallback behavior. |
docs/ARCHITECTURE.md |
Describes retained meshes, backend responsibilities, and rendering costs. |
Review effort: Balanced
pmeems
force-pushed
the
polygon-triangulation-verification
branch
from
November 13, 2026 14:54
76da6b5 to
8eaea31
Compare
|
I reviewed the latest changes and did not find anything new to report. |
pmeems
force-pushed
the
polygon-triangulation-verification
branch
from
November 13, 2026 16:14
815c01d to
7f5e1fc
Compare
…e complex polygons - add a MapView lifecycle test proving concave and holed fill meshes survive resize, zoom, and pan without re-triangulation and that map changes rebuild meshes - add a coordinator fallback test proving GDI renders a mesh-less concave holed polygon from its original rings and recovers to OpenGL afterwards - add an opt-in complex-geometry rendering baseline (concave L-shapes, holed multipart features, 32-vertex stars) reporting triangulation and mesh-storage costs - update architecture, porting, and testing docs to drop the convex single-ring restriction and record the measured baseline numbers
- Move the holed-baseline satellite into the gap between bodies so the multipart components stay disjoint, and validate the complete multipart geometry while building the fixture - Probe OpenGL availability independently in GdiFallbackRendersConcaveHoledPolygonFromRings and require the second coordinator draw to select OpenGL when the probe succeeds - Refresh the recorded rendering baseline measurements in docs/TESTING.md
pmeems
force-pushed
the
polygon-triangulation-verification
branch
from
November 13, 2026 20:04
7f5e1fc to
ec5380b
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Phase 3 of the polygon triangulation plan: verify the complete rendering pipeline, measure triangulation cost and mesh storage, and bring the documentation in line with the implementation.
Depends on #66 (Core triangulation) and #68 (OpenGL mesh rendering); stacked on the #68 branch.
What changed
MapViewTest.ComplexSceneMeshesSurviveViewportChangesproves the triangulated fill meshes of a concave, holed multipart scene survive viewport resize, zoom in/out, anchored zoom, and pan without the scene being rebuilt or re-triangulated, and that layer add/remove rebuilds the scene with fresh meshes while keeping the original rings.VectorLayerRenderer.GdiFallbackRendersConcaveHoledPolygonFromRingsproves a polygon without a fill mesh is rendered by GDI from its original rings — concave indentation and interior ring stay unfilled — and that the coordinator recovers to OpenGL for a later mesh-complete frame.RenderingBaseline.MeasuresComplexPolygonCosts(opt-in, same env vars as the existing baseline) generates 50k concave L-shapes, 50k holed two-component multipolygons, and 12.5k 32-vertex star polygons across three layers, and reports scene-preparation time, mesh vertex/index storage, memory growth, and GDI/OpenGL frame costs.docs/ARCHITECTURE.md,docs/PORTING.md, anddocs/TESTING.mdno longer claim OpenGL supports only convex single-ring polygons; the measured baseline numbers (including the ~15 µs per polygon triangulation cost that now dominates scene preparation) are recorded indocs/TESTING.md.Measured (Release, x64, one workstation)
Validation
msbuild MapWinGIS6.slnx -restore -p:Configuration=Debug -p:Platform=x64 -m— clean (warnings are errors in this configuration).MapWinGIS.Core.Tests.exe: 312 passed, 1 skipped (network).MapWinGIS.ActiveX.Tests.exe: 67 passed, 3 skipped (interactive host + two opt-in baselines); both baselines pass in Release when opted in.No memory changes were needed: the measured numbers live in
docs/TESTING.md, and no new reusable pitfalls or tooling knowledge surfaced.