Cached Elevation Source Factory
Cross-platform ElevationSourceFactory backed by an ElevationStoreBackend + an optional upstream TileSource. Owns the source-format → storage-format transcoding pipeline (encode/decode via ElevationStorageCodec) so platforms (JS, iOS) don't have to reimplement it.
Platform-specific bits are deliberately small:
backend handles "where do the bytes live" (IDB / filesystem / etc.).
networkDecoder handles "how to decode the wire format" (each platform has its own BIL/TIFF/DTED decode path). The factory itself stays in commonMain.
Used by WebContentManager.createElevationSourceFactory (JS) and IosContentManager.createElevationSourceFactory (iOS). JVM keeps its own gpkg-bound factory (GpkgCachedElevationSourceFactory) because the GeoPackage ancillary-table layout doesn't fit the simple (scale, offset) shape the backend interface exposes.
Constructors
Properties
Unique elevation source factory content type name
Invoked (off the render thread, with (matrix ordinal, column, row)) after a stale tile is re-downloaded; the coverage wires this to drop the cached array + redraw.
Functions
Bulk-download path: by default skip already-cached tiles, otherwise force a network fetch and persist. Bypasses isCacheOnly — bulk is user-initiated and orthogonal to the renderer's offline toggle. Returns true on cache hit / successful fetch + write, false on cache miss + (no network / fetch failure / decode failure). When overrideCache is true, the cache hit short-circuit is skipped and every tile is re-downloaded.
Fetch one tile through the cache. Reads the encoded blob from backend; on cache miss falls through to networkSource, decodes via networkDecoder, transcodes via ElevationStorageCodec, persists to backend, returns the rendered ShortArray.