mirror of
https://github.com/bilawalsidhu/gods-eye-view.git
synced 2026-11-18 17:22:19 +00:00
Merge origin/main into the renderer-contract branch: the procedural fleet models drawn through the renderer's model sets
Aircraft, military, local ADS-B, vessel, transit and rail models come from the fleet model set, loaded up front and drawn life size through the draw port's models sets; no layer touches the viewer or Cesium outside src/render/cesium/. The models capability gains glTF bytes (gltf), a per-axis stretch (axisScale), a colour for tinted parts (maskColor) and a cut below the origin (clip: 'belowOrigin'), with conformance checks. Main's rail layer and Data Library are ported to the ports; the CCTV footprint probe keeps the globe-terrain clamp through the query port.
This commit is contained in:
commit
e3865f462f
533 files changed
+55738
-2518
No files matched your search
@@ -788,6 +788,22 @@ export function createRendering({
|
||||
return query.rayCast({ origin, direction }, { against: 'surface' });
|
||||
}
|
||||
|
||||
/**
|
||||
* On a globe map, where the activation probe's axis meets the globe's
|
||||
* terrain: `{hit}`, `hit` null on a miss. Null when the globe is not shown
|
||||
* (the photoreal stack), where only the surface cast counts.
|
||||
* @returns {Promise<{hit: object|null}|null>}
|
||||
*/
|
||||
async function terrainHit(origin, direction) {
|
||||
const viewer = layerState._viewer;
|
||||
if (findGlobe(viewer)?.isGlobeVisible?.() !== true) return null;
|
||||
const query = findQuery(viewer);
|
||||
if (!query) return null;
|
||||
return {
|
||||
hit: await query.rayCast({ origin, direction }, { against: 'terrain' }),
|
||||
};
|
||||
}
|
||||
|
||||
/** Whether there is a query port to cast the activation probe through. */
|
||||
function canPickFromRay() {
|
||||
return typeof findQuery(layerState._viewer)?.rayCast === 'function';
|
||||
@@ -928,6 +944,7 @@ export function createRendering({
|
||||
buildCoverageEntities,
|
||||
placeCoverageLines,
|
||||
obstructionHit,
|
||||
terrainHit,
|
||||
canPickFromRay,
|
||||
removeCoverageEntities,
|
||||
extractPickedCameraId,
|
||||
|
||||
Reference in new issue
Block a user