@loaders.gl/potree
Version:
potree loaders for large point clouds.
27 lines (26 loc) • 971 B
JavaScript
// loaders.gl
// SPDX-License-Identifier: MIT
// Copyright vis.gl contributors
import { parsePotreeHierarchyChunk } from "./parsers/parse-potree-hierarchy-chunk.js";
// __VERSION__ is injected by babel-plugin-version-inline
// @ts-ignore TS2304: Cannot find name '__VERSION__'.
const VERSION = typeof "4.3.2" !== 'undefined' ? "4.3.2" : 'latest';
/** Potree hierarchy chunk loader */
export const PotreeHierarchyChunkLoader = {
dataType: null,
batchType: null,
name: 'potree Hierarchy Chunk',
id: 'potree-hrc',
module: 'potree',
version: VERSION,
extensions: ['hrc'],
mimeTypes: ['application/octet-stream'],
// binary potree files have no header bytes, no content test function possible
// test: ['...'],
parse: async (arrayBuffer, options) => parsePotreeHierarchyChunk(arrayBuffer),
parseSync: (arrayBuffer, options) => parsePotreeHierarchyChunk(arrayBuffer),
options: {
potree: {}
},
binary: true
};