Timed imagery reads the drawn globe tiles through internals.js

The tiles the globe last drew are a private Cesium field: read through
globeTilesDrawn, whose field the internals test checks the installed
Cesium still declares.
This commit is contained in:
Sameh Khamis committed 2026-11-11 17:20:58 -08:00
1 parent ee9de4edda
commit a043854f27
3 files changed
+21 -1

No files matched your search

+2 -1
View File
@@ -13,6 +13,7 @@
* segment end is the nearest frame.
*/
import * as Cesium from 'cesium';
import { globeTilesDrawn } from './internals.js';
/** How far apart the times a video segment is seen at are, ms. */
export const VIDEO_STEP_MS = 250;
@@ -294,7 +295,7 @@ const SETTLED = new Set([
*/
export function layerDrawn(scene, layer) {
if (!layer || layer.isDestroyed?.() || !layer.ready) return false;
const tiles = scene.globe?._surface?._tilesToRender;
const tiles = globeTilesDrawn(scene.globe);
if (!tiles?.length) return false;
const bounds = layer.imageryProvider?.rectangle ?? layer.rectangle;
for (const tile of tiles) {