Commit Graph
4 Commits
Author SHA1 Message Date
German Khokhlov 81fe7f88cc fix(cctv): settle the review of the count markers
Bugs:
- Cameras on one mount stay side by side after their geometry is built,
  so a click or a settled view no longer folds them back into one icon.
- A count click yields to a card drawn over the marker and to another
  layer's object under it, waits while the cockpit or tracking holds the
  view, and flies at most halfway, so a long chain of cameras still splits.
- The active camera's icon is never covered by a count, transparent
  corners of the marker no longer catch clicks, and a count hidden under
  the HUD keeps its lone cameras.
- A lone camera joins only its nearest count and never bridges two; cameras
  close enough to draw as icons take part too, at their drawn icon size.
- Groups across the antimeridian keep their longitude; the flight frames
  the highest mount; markers on ground below the ellipsoid stay visible;
  counts fade outside the Scope circle.
- Mounts less than a metre apart count as one mount.
- A drawn-terrain height survives a late fallback answer, is read for an
  unresolved camera and for one projected off the window, is re-read when
  the terrain under it finishes loading or the terrain source changes, and
  the read budget no longer goes to the same misses each pass.

Cleanup: the glyph draws from one green SVG sprite instead of recolouring
pixels, marker-only constants move next to their use, layout tests check
behaviour rather than formulas, and docs and comments match the code.
docs/I18N.md names the one fixed notation of count badges as an exception.
2026-11-19 03:07:04 +04:00
German Khokhlov 2e18673df8 fix(cctv): stand cameras and count markers on the drawn terrain
When the terrain height batch loses a chunk to the rate limit, the cameras
in it keep a sea-level fallback height. In the mountains that put them far
under the surface, so the view pass judged them by a point that was not
where they are drawn: a tilted view dropped the count marker, a click on
the marker framed empty ground, and icons drifted on tilt and pan.

- A camera with no real ground height takes the height of the terrain the
  globe draws once it is near the screen (up to 300 reads a pass, through
  the height service), and a later answer from the batch replaces it.
- A count marker is anchored to the drawn terrain under its centre, and a
  click frames that ground.
- Cameras on one mount draw side by side, 30 px apart, each with its own
  callout, instead of as one icon with several callouts.

The photoreal map stack is not covered: terrain is not the surface there.
2026-11-19 00:03:34 +04:00
German Khokhlov 65942008bf 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.
2026-11-18 21:23:41 +04:00
German Khokhlov c536d22ff0 feat(cctv): green count markers that grow with the count and carry a camera icon
A count marker now says what it counts and how much:

- Its height grows with the count, from 40 px for two cameras to 58 px for
  several thousand, with clear fill around the digits.
- A small single-camera map icon sits under the top of the ring and the
  number just below the centre, so the two never touch. The icon is built
  from the same sprite as a single camera on the map.
- Thousands print as 1.7K or 12K in every UI language.
- The camera layer is green: count markers and idle single cameras share
  the colour, the active camera stays gold and live-video cameras violet.
2026-11-18 20:48:33 +04:00