mirror of
https://github.com/bilawalsidhu/gods-eye-view.git
synced 2026-11-16 16:22:20 +00:00
Draw military flights from the shared GPU icon set
The flights icon planning and presentation move into `createAircraftIcons` (src/data/aircraftIconLayer.js), and the motion regime both layers dead-reckon from into src/data/aircraftMotionRegime.js. Flights keeps only its grounded-floor pass on top. Military now draws every contact as a row of that icon set, like flights: the billboards, the cull positions and the rotation-pass signature go. Tracking hides the row and untracking re-plans it from the tracked course. Queries read the drawn row position and judge the horizon as the shader does. Snapshots that arrive before init or after destroy are ignored, and per-contact lookups find no contact then instead of throwing. With about 120 live military contacts, preRender p95 drops from 0.7-0.8 ms to 0.2 ms on the same views. Render time and frame gaps are unchanged or slightly lower.
This commit is contained in:
1 parent
fa3a3a3bca
commit
b027bde6ad
33 files changed
+1256
-1376
No files matched your search
@@ -181,23 +181,17 @@ export const LANDED_SPEED_MAX_MPS = 23;
|
||||
/** @constant {number} Max viewer distance (km) for the fleet ground-floor clamp. */
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
// Icon orientation (2026-06-10 playtest fix): rotation is computed by
|
||||
// projecting each aircraft's course vector into WINDOW coordinates
|
||||
// (iconOrientation.js) with alignedAxis always ZERO — exact at every camera
|
||||
// pitch/heading, including tracked-entity orbit mode. Rotation passes run on
|
||||
// the fleet tick only when the camera pose changed (or 1s drift catch-up).
|
||||
// The same tick horizon-culls billboards: with the Cesium globe hidden there
|
||||
// is no far-side depth, so planes otherwise show through the planet.
|
||||
// Fleet icons are one GPU icon set (iconSet.js): the shader dead-reckons each
|
||||
// row's motion segment, projects its course into window coordinates and
|
||||
// horizon-culls it (with the Cesium globe hidden there is no far-side depth,
|
||||
// so planes otherwise show through the planet). The fleet tick only re-plans
|
||||
// expired rows and drives the model handoff.
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
/** @constant {number} Fleet dead-reckoning tick interval (ms) — ~12Hz, not per-frame. */
|
||||
|
||||
export const FLEET_DR_INTERVAL_MS = 80;
|
||||
|
||||
/** @constant {number} Max ms between rotation passes while the camera is idle. */
|
||||
|
||||
export const ROTATION_REFRESH_MS = 1000;
|
||||
|
||||
/** Max course slew (deg/s) — well above real turns (≤4°/s), hides fix-boundary
|
||||
* steps. Scaled down toward COURSE_MIN_DPS at low speed (courseSlewCapDps). */
|
||||
|
||||
|
||||
Reference in new issue
Block a user