fix(cctv): count a lone camera in the marker it sits against

A ground cell with one camera always drew its icon, so at some zooms a
camera poked out from under a count marker with its own callout.

An icon closer than the merge gap to a count marker now joins that marker:
the count grows by one and the icon, its callout and its card are not drawn.
Two lone cameras with no count beside them stay two icons, and the active
camera always keeps its own icon.
This commit is contained in:
German Khokhlov committed 2026-11-18 21:23:41 +04:00
1 parent c536d22ff0
commit 65942008bf
8 files changed
+125 -24

No files matched your search

+3 -1
View File
@@ -1956,7 +1956,9 @@ The CCTV layer draws only the cameras on or near the screen. Zoomed out, a
ground cell containing multiple cameras shows, at their centre, a marker with
a small green camera pictogram under its top edge and the count just below its
middle. The marker grows with the count and is drawn on the world overlay at
the same resolution as camera callouts.
the same resolution as camera callouts. A lone camera whose icon would sit
within 4 px of a marker is counted in that marker instead of being drawn; the
active camera always keeps its own icon.
The count includes cameras beyond the screen edge and excludes cameras beyond
the horizon. Counts that would overlap on screen merge into one that carries
their sum. Clicking a count zooms to its group. Single cameras keep their icons,