mirror of
https://github.com/bilawalsidhu/gods-eye-view.git
synced 2026-11-16 08:12:24 +00:00
Cesium: revoke blob object URLs no longer drawn
The object URL store keeps its blob alive, so a blob image's URL, never revoked, kept every blob ever drawn. A blob's URL is now revoked once it has not been asked for in a minute with two frames drawn since (so a material, which loads in the next frame, has started its load); images already loading or loaded are unaffected, and a blob drawn again gets a new URL.
This commit is contained in:
1 parent
a3ffb33563
commit
748dc0a156
4 files changed
+124
-8
No files matched your search
@@ -36,7 +36,13 @@ import { temeToPseudoFixed } from '../../geo/celestial.js';
|
||||
import { alongLength } from '../../geo/polyline.js';
|
||||
import { clusterScreenPoints } from '../../geo/screenCluster.js';
|
||||
import { provideUnboundDraw } from '../rendererOf.js';
|
||||
import { blobUrl, listenerList, toCartesian, uncaught } from './common.js';
|
||||
import {
|
||||
blobUrl,
|
||||
blobUrlFrameDrawn,
|
||||
listenerList,
|
||||
toCartesian,
|
||||
uncaught,
|
||||
} from './common.js';
|
||||
import { createGpuIcons, GPU_ICON_CAPABILITIES } from './gpuIcons.js';
|
||||
import { blendHost } from './setBlend.js';
|
||||
import { createModelSets } from './drawModels.js';
|
||||
@@ -5196,6 +5202,7 @@ export function createCesiumDraw({
|
||||
},
|
||||
/** Each frame, after it drew: clamp state, and ground swaps. */
|
||||
afterRender() {
|
||||
blobUrlFrameDrawn();
|
||||
watchClamp();
|
||||
swapReady();
|
||||
// Clamped GPU icons take the ground under their segments.
|
||||
|
||||
Reference in new issue
Block a user