import { LatLngBounds, type LatLngLike } from "../geo.js"; import { InteractiveLayer } from "../interactive-layer.js"; import { type LayerOptions } from "../layer.js"; import type { Orihon } from "../map.js"; import type { PathOptions } from "./vector.js"; export interface WebGLPathBatchOptions extends LayerOptions, PathOptions { className?: string; maxDpr?: number; /** Fall back to Canvas 2D if WebGL init fails. Default true. */ fallbackCanvas?: boolean; /** Minimum time between exact GPU camera redraws while moving. Default 250 ms; 0 redraws every frame. */ cameraRedrawIntervalMs?: number; /** Idle time before the final exact GPU camera redraw. Default 120 ms. */ cameraSettleDelayMs?: number; } type ResolvedOptions = Required> & WebGLPathBatchOptions; /** * GPU stroked polylines: mercator segments uploaded once, camera via uniforms. * Uses ANGLE_instanced_arrays when available (one instance per segment). */ export declare class WebGLPathBatch extends InteractiveLayer { #private; canvas: HTMLCanvasElement | null; gl: WebGLRenderingContext | null; renderer: "webgl" | "canvas" | "none"; private program; private quadBuffer; private instanceBuffer; private locs; private ext; /** Per-segment: ax, ay, bx, by (normalized mercator). */ private _segBuf; private _segmentCount; private _bufferDirty; private _gpuBytes; private _cssW; private _cssH; private _attribsBound; private _drawnZoom; private _drawnOriginX; private _drawnOriginY; private _hasDrawn; private _forceGpu; private _lastGpuMs; private _redrawFrame; private _settleTimer; private color; private _minLat; private _maxLat; private _minLng; private _maxLng; constructor(options?: WebGLPathBatchOptions); get count(): number; getBounds(): LatLngBounds; clearPaths(): this; addPath(rings: LatLngLike[][], _closed?: boolean, style?: PathOptions): this; onAdd(map: Orihon): void; onRemove(): void; render(): void; } export declare function webglPathBatch(options?: WebGLPathBatchOptions): WebGLPathBatch; export {}; //# sourceMappingURL=webgl-path-batch.d.ts.map