itowns
Version:
A JS/WebGL framework for 3D geospatial data visualization
62 lines (61 loc) • 2.42 kB
TypeScript
declare namespace _default {
function enableLazPerf(path: any): void;
/**
* Terminate all worker instances.
* @returns {Promise<void>}
*/
function terminate(): Promise<void>;
/**
* Parses a chunk of a LAS or LAZ (LASZip) and returns the corresponding
* `THREE.BufferGeometry`.
*
* @param {ArrayBuffer} data - The file content to parse.
* @param {Object} options
* @param {Object} options.in - Options to give to the parser.
* @param {number} options.in.pointCount - Number of points encoded in this
* data chunk.
* @param {Object} options.in.header - Partial LAS file header.
* @param {number} options.in.header.pointDataRecordFormat - Type of Point
* Data Record contained in the LAS file.
* @param {number} options.in.header.pointDataRecordLength - Size (in bytes)
* of the Point Data Record.
* @param {Object} [options.eb] - Extra bytes LAS VLRs headers.
* @param { 8 | 16 } [options.in.colorDepth] - Color depth (in bits).
* Defaults to 8 bits for LAS 1.2 and 16 bits for later versions
* (as mandatory by the specification)
*
* @return {Promise<THREE.BufferGeometry>} A promise resolving with a
* `THREE.BufferGeometry`.
*/
function parseChunk(data: ArrayBuffer, options?: {
in: {
pointCount: number;
header: {
pointDataRecordFormat: number;
pointDataRecordLength: number;
};
};
eb?: Object | undefined;
}): Promise<THREE.BufferGeometry>;
/**
* Parses a LAS file or a LAZ (LASZip) file and return the corresponding
* `THREE.BufferGeometry`.
*
* @param {ArrayBuffer} data - The file content to parse.
* @param {Object} [options]
* @param {Object} [options.in] - Options to give to the parser.
* @param { 8 | 16 } [options.in.colorDepth] - Color depth (in bits).
* Defaults to 8 bits for LAS 1.2 and 16 bits for later versions
* (as mandatory by the specification)
*
* @return {Promise} A promise resolving with a `THREE.BufferGeometry`. The
* header of the file is contained in `userData`.
*/
function parse(data: ArrayBuffer, options?: {
in?: {
colorDepth?: 8 | 16 | undefined;
} | undefined;
}): Promise<any>;
}
export default _default;
import * as THREE from 'three';