feat(globe): mover sets report ready(); Navara scales by distance as Cesium

Task 10b foundation.
- MoverSet.ready(): whether what the set draws has loaded (Navara: the
  model set's glTF, a URL atlas; Cesium: every instance's Model, the cropped
  atlas; parts without it draw at once). The aircraft renderer keeps the 2D
  glyph until a model set is ready, as the Cesium path waits on Model.ready.
  Contract suite: a drawn model set is ready() (both engines); unit test of
  the neutral store.
- Navara sprites and points interpolate scaleByDistance as Cesium's
  NearFarScalar (over the squared camera distance, eased by ^0.2) instead
  of linearly in distance, so aircraft glyphs have Cesium's size at every
  range; the CPU pick radius follows (distanceScale, tested equal to
  focusDeemphasis' port of czm_nearFarScalar). The contract text says so.
This commit is contained in:
German Khokhlov committed 2026-10-17 01:16:59 +04:00
1 parent d81ebf1268
commit 4dfcba8989
10 files changed
+103 -14

No files matched your search

+5 -1
View File
@@ -317,7 +317,8 @@
* sizePx: number, scaleByDistance?: number[] }} [sprite] An image atlas
* whose cells are [u0, v0, u1, v1] in 0..1 (v down from the image top);
* each sprite is a square of sizePx CSS px times its scale, times the
* NearFarScalar [nearM, nearScale, farM, farScale] when given.
* NearFarScalar [nearM, nearScale, farM, farScale] when given (Cesium's
* interpolation: over the squared camera distance, eased by ^0.2).
* @property {{ sizePx: number, outlinePx?: number, scaleByDistance?: number[] }} [point]
* A filled disc of sizePx CSS px diameter with a dark outline.
* @property {{ url: string, minimumPixelSize?: number, maximumScale?: number,
@@ -348,6 +349,9 @@
* requests a render; nothing else draws a frame.
* @property {() => Float64Array} positionsView x, y, z of the drawn
* instances (a view on the set's own array; read-only).
* @property {() => boolean} ready Whether what the set draws has loaded: a
* model set's glTF (Cesium: every instance's model), a sprite set's atlas.
* A layer keeps its fallback visual until then.
* @property {() => void} destroy
*
* @typedef {object} GlobeMovers