import { Buffer } from '@luma.gl/core'; import type { BinaryAttribute } from "../lib/attribute/attribute.js"; import type { TypedArray } from "../types/types.js"; import type { AccessorFunction } from "../types/layer-props.js"; import type { TypedArrayManager } from "./typed-array-manager.js"; type ExternalBuffer = TypedArray | Buffer | BinaryAttribute; type TesselatorOptions = ExtraOptionsT & { attributes?: Record; getGeometry?: AccessorFunction; data?: any; buffers?: Record; geometryBuffer?: ExternalBuffer; positionFormat?: 'XY' | 'XYZ'; dataChanged?: { startRow: number; endRow?: number; }[] | string | false; normalize?: boolean; }; export type GeometryUpdateContext = { vertexStart: number; indexStart: number; geometrySize: number; geometryIndex: number; }; export default abstract class Tesselator { opts: TesselatorOptions; typedArrayManager: TypedArrayManager; indexStarts: number[]; vertexStarts: number[]; vertexCount: number; instanceCount: number; attributes: Record; protected _attributeDefs: any; protected data: any; protected getGeometry?: AccessorFunction | null; protected geometryBuffer?: ExternalBuffer; protected buffers: Record; protected positionSize: number; protected normalize: boolean; constructor(opts: TesselatorOptions); updateGeometry(opts: TesselatorOptions): void; updatePartialGeometry({ startRow, endRow }: { startRow: number; endRow: number; }): void; /** Convert geometry to a uniform shape */ protected abstract normalizeGeometry(geometry: GeometryT): NormalizedGeometryT; /** Update the positions buffer of a single geometry */ protected abstract updateGeometryAttributes(geometry: NormalizedGeometryT | null, context: GeometryUpdateContext): any; /** Get the number of vertices in a geometry */ protected abstract getGeometrySize(geometry: NormalizedGeometryT): number; protected getGeometryFromBuffer(geometryBuffer: ExternalBuffer): AccessorFunction | null; private _allocate; /** * Visit all objects * `data` is expected to be an iterable consistent with the base Layer expectation */ private _forEachGeometry; private _rebuildGeometry; } export {}; //# sourceMappingURL=tesselator.d.ts.map