voxolith

makeSceneCache()

The scene cache on any CacheStore: keys are prefixed with salt, maxBytes evicts by last use after each write. openSceneCache is this on IndexedDB.

function makeSceneCache(
   store: CacheStore, 
   salt: string, 
   opts?: SceneCacheOptions, 
   now?: () => number
): SceneCache;

Defined in: engine/src/worker/scene-cache.ts:214

Parameters

ParameterTypeDefault valueDescription
storeCacheStoreundefined-
saltstringundefined-
opts?SceneCacheOptions{}-
now?() => numberDate.nowThe clock for created / lastUsed (default Date.now); tests pass their own.

Returns

SceneCache

On this page