mirror of
https://github.com/bilawalsidhu/gods-eye-view.git
synced 2026-11-17 08:42:21 +00:00
Load the Cesium SDK from index.html again, since engine-neutral modules read its global when they load
This reverts ae13a56f. In the production build every 'cesium' import is the global that Cesium.js defines; with the script loaded only when a Cesium globe started, modules evaluated at boot (cesiumConstants, annotationEngine) threw ReferenceError and neither engine started. A cold Navara start loading Cesium.js stays a known gap.
This commit is contained in:
1 parent
9cc108835e
commit
125fbc5a3b
27 files changed
+125
-275
No files matched your search
@@ -4,7 +4,7 @@
|
||||
import * as Cesium from 'cesium';
|
||||
import { bridgeEvent } from './events.js';
|
||||
|
||||
let scratchGregorian;
|
||||
const scratchGregorian = new Cesium.GregorianDate();
|
||||
|
||||
// JulianDate.toDate(time).getTime() without the Date: frame events must not
|
||||
// allocate. A raise without a time (not Cesium's own) reads the clock.
|
||||
@@ -27,7 +27,6 @@ function unixMilliseconds(scene, time) {
|
||||
* @returns {{ frames: object, destroy: () => void }}
|
||||
*/
|
||||
export function createCesiumFrames(viewer) {
|
||||
scratchGregorian ??= new Cesium.GregorianDate();
|
||||
const { scene } = viewer;
|
||||
const bridges = ['preUpdate', 'preRender', 'postRender'].map((name) => [
|
||||
name,
|
||||
|
||||
Reference in new issue
Block a user