UNPKG

s2maps-gpu

Version:

S2 Maps GPU - An open source, high-performance, and GPU-accelerated map engine for rendering large-scale, interactive maps.

20 lines (19 loc) 729 B
import ProcessManager from './process/index.js'; import type { TileWorkerMessages } from './worker.spec.js'; /** * # Tile Worker * * A TileWorker has one job: prebuild tile data for the WebGL / WebGPU instance * During construction, the tileworker is given the map's id to send the data to the correct recepient * and also the style sheet to build the proper source data * * A TileWorker maintains map references to know how and who to send data back to */ export default class TileWorker extends ProcessManager { #private; /** * Given a tile message, process it according to its type * @param tileMessage - the tile message */ onMessage(tileMessage: MessageEvent<TileWorkerMessages>): void; }