mirror of
https://github.com/bilawalsidhu/gods-eye-view.git
synced 2026-11-16 16:22:20 +00:00
Read the canvas from the renderer in the layers, voice and tools
Files off the Cesium list sized themselves by, listened on and set the cursor of `viewer.scene.canvas`. They now read `canvasOf(viewer)` from src/render/rendererOf.js: the bound renderer's canvas, else the viewer's own, the same element. Recent Imagery's divider moves the split through the globe port (`globeSplitTarget`, moved from the flood event into src/ui/imagerySplit.js), and traffic flow passes the viewer to the listed surface module (`viewerRoadSurface`) instead of reaching for its scene. The test fakes give their viewers a canvas, and the fake renderers report it, as the Cesium renderer reports the viewer's.
This commit is contained in:
1 parent
abe9f97768
commit
b19fa56565
49 files changed
+269
-119
No files matched your search
@@ -11,7 +11,12 @@ import {
|
||||
import { formatUtcDayMonth, t, msg } from '../../i18n/index.js';
|
||||
import { formatScaleLabel } from '../../ui/unitLabels.js';
|
||||
import { toLonLatH } from '../../geo/ellipsoid.js';
|
||||
import { cameraOf, findCamera, findQuery } from '../../render/rendererOf.js';
|
||||
import {
|
||||
cameraOf,
|
||||
canvasOf,
|
||||
findCamera,
|
||||
findQuery,
|
||||
} from '../../render/rendererOf.js';
|
||||
|
||||
/**
|
||||
* A stored (English) failure in the language. HTTP failures from source.js
|
||||
@@ -580,7 +585,7 @@ export function createWeatherLayer({
|
||||
const shownProblem = problem ? presentWeatherProblem(problem) : null;
|
||||
const shownHost = hostStatus ? t(hostStatus) : null;
|
||||
const b = manifest?.bounds;
|
||||
const canvas = viewer?.scene?.canvas;
|
||||
const canvas = canvasOf(viewer);
|
||||
const point =
|
||||
canvas &&
|
||||
findQuery(viewer)?.pickEllipsoid(
|
||||
|
||||
Reference in new issue
Block a user