Skip to main content

LASLoader

caution

The @loaders.gl/las module only supports LAS/lAZ files up to LAS v1.3. It does not support LAS v1.4 files. For more detail, see the discussion in Github Issues.

The LASLoader parses a point cloud in the LASER file format.

LoaderCharacteristic
File Extension.las, .laz
File TypeBinary
File FormatLASER file format
Data FormatPointCloud
Decoder TypeSynchronous
Worker Thread SupportYes
Streaming SupportNo

Usage​

import {LASLoader} from '@loaders.gl/las';
import {load} from '@loaders.gl/core';

const data = await load(url, LASLoader, options);

Options​

OptionTypeDefaultDescription
options.las.shapestringmeshFormat of parsed data, e.g: 'mesh', 'columnar-table', 'arrow-table'.
options.las.skipnumber1Read one from every n points.
options.las.fp64numberfalseIf true, positions are stored in 64-bit floats instead of 32-bit.
options.las.colorDepthnumber or string8Whether colors encoded using 8 or 16 bits? Can be set to 'auto'. Note: LAS specification recommends 16 bits.
options.onProgressfunction-Callback when a new chunk of data is read. Only works on the main thread.