UNPKG

itowns

Version:

A JS/WebGL framework for 3D geospatial data visualization

57 lines (56 loc) 2.08 kB
export default Potree2Layer; /** * @property {boolean} isPotreeLayer - Used to checkout whether this layer * is a Potree2Layer. Default is `true`. You should not change this, as it is * used internally for optimisation. * * @extends PointCloudLayer */ declare class Potree2Layer extends PointCloudLayer { /** * Constructs a new instance of Potree2 layer. * * @example * // Create a new point cloud layer * const points = new Potree2Layer('points', * { * source: new Potree2Source({ * url: 'https://pointsClouds/', * file: 'metadata.json', * } * }); * * View.prototype.addLayer.call(view, points); * * @param {string} id - The id of the layer, that should be unique. It is * not mandatory, but an error will be emitted if this layer is added a * {@link View} that already has a layer going by that id. * @param {Object} config - Configuration, all elements in it * will be merged as is in the layer. For example, if the configuration * contains three elements `name, protocol, extent`, these elements will be * available using `layer.name` or something else depending on the property * name. See the list of properties to know which one can be specified. * @param {string} [config.crs=ESPG:4326] - The CRS of the {@link View} this * layer will be attached to. This is used to determine the extent of this * layer. Default to `EPSG:4326`. */ constructor(id: string, config: { crs?: string | undefined; }); /** * @type {boolean} * @readonly */ readonly isPotreeLayer: boolean; scale: THREE.Vector3; metadata: any; pointAttributes: Potree2PointAttributes; spacing: any; minElevationRange: any; maxElevationRange: any; extent: Extent; } import PointCloudLayer from '../Layer/PointCloudLayer'; import * as THREE from 'three'; import { Potree2PointAttributes } from '../Core/Potree2PointAttributes'; import { Extent } from '@itowns/geographic';