mirror of
https://github.com/bilawalsidhu/gods-eye-view.git
synced 2026-11-16 16:22:20 +00:00
setBase: the last call wins; an overtaken or disposed one changes nothing
A vector setBase awaited its style before changing anything, with no generation guard, so a slow earlier call landed over a later one, and one in flight at disposal rejected. Cesium and the stub now count calls like setPhotoreal and setTerrain, abort the overtaken style load, and resolve an overtaken call with imagery: [] and settled: false.
This commit is contained in:
1 parent
5fae3cf485
commit
72d8dd606d
6 files changed
+196
-7
No files matched your search
Vendored
+8
-1
@@ -237,7 +237,14 @@ export interface LoadProgress {
|
||||
export type SettleKind = 'base' | 'tiles' | 'terrain' | 'imagery' | 'surface';
|
||||
|
||||
export interface GlobePort {
|
||||
/** Switch the whole base at once; resolves when the new base has settled. */
|
||||
/**
|
||||
* Switch the whole base at once; resolves when the new base has settled.
|
||||
* The last call wins: one a later `setBase` (or the renderer's disposal)
|
||||
* overtakes before its base changes (its vector style still loading)
|
||||
* changes nothing and resolves with `imagery: []`, `settled: false` and the
|
||||
* photoreal status as it stands, never rejecting; one overtaken after it
|
||||
* changed the base resolves with `settled: false`.
|
||||
*/
|
||||
setBase(base: BaseSpec): Promise<BaseStatus>;
|
||||
/** `photoreal`: on, off or a new token route. */
|
||||
setPhotoreal(spec: PhotorealSpec | null): Promise<PhotorealStatus>;
|
||||
|
||||
Reference in new issue
Block a user