import { LidarprofileConfigService as GmfLidarprofileConfigLidarprofileConfigService } from 'ngeo/lidar/Config'; import { LidarprofilePoints as GmfLidarprofileUtilsLidarprofilePoints } from 'ngeo/lidar/Utils'; import GmfLidarprofileUtils from 'ngeo/lidar/Utils'; import GmfLidarprofilePlot from 'ngeo/lidar/Plot'; import GmfLidarprofileMeasure from 'ngeo/lidar/Measure'; import { miscDebounce as ngeoMiscDebounceMiscDebounce } from 'ngeo/misc/debounce'; import OlMap from 'ol/Map'; import OlFeature from 'ol/Feature'; import OlOverlay from 'ol/Overlay'; import OlLayerVector from 'ol/layer/Vector'; import OlSourceVector from 'ol/source/Vector'; import OlGeomGeometry from 'ol/geom/Geometry'; import OlGeomLineString from 'ol/geom/LineString'; import { Coordinate as OlCoordinateCoordinate } from 'ol/coordinate'; type DebounceFunction = { (): void; }; export declare class LidarprofileManager { /** * @private */ ngeoDebounce_: ngeoMiscDebounceMiscDebounce; /** * @private */ promise_: undefined | Promise; plot: undefined | GmfLidarprofilePlot; measure: undefined | GmfLidarprofileMeasure; config: undefined | GmfLidarprofileConfigLidarprofileConfigService; /** * @private */ map_: undefined | OlMap; /** * The hovered point attributes in D3 profile highlighted on the 2D map. */ cartoHighlight: OlOverlay; /** * The hovered point geometry (point) in D3 profile highlighted on the 2D map. */ lidarPointHighlight: OlLayerVector>>; /** * The profile footpring represented as a LineString represented * with real mapunites stroke width. */ lidarBuffer: OlLayerVector>>; /** * The variable where all points of the profile are stored. */ profilePoints: GmfLidarprofileUtilsLidarprofilePoints; /** * @private */ isPlotSetup_: boolean; /** * @private */ line_: undefined | OlGeomLineString; utils: GmfLidarprofileUtils; pointSum: number; debouncer: () => void; /** * Provides a service to manage a D3js component to be used to draw an lidar point cloud profile chart. * Requires access to a Pytree webservice: https://github.com/sitn/pytree. */ constructor(); /** * @param config Config * @param map The map. */ init(config: GmfLidarprofileConfigLidarprofileConfigService, map: OlMap): void; /** * Clears the profile footprint. */ clearBuffer(): void; /** * Set the line for the profile. * @param line that defines the profile */ setLine(line: undefined | OlGeomLineString): void; /** * Set the map used by the profile. * @param map The map. */ setMap(map: OlMap): void; /** * @returns An empty lidarprofile points object. * @private */ getEmptyProfilePoints_(): GmfLidarprofileUtilsLidarprofilePoints; /** * Load profile data (lidar points) by successive Levels Of Details using asynchronous requests. * @param clippedLine an array of the clipped line coordinates * @param distanceOffset the left side of D3 profile domain at current zoom and pan configuration * @param resetPlot whether to reset D3 plot or not * @param minLOD minimum Level Of Detail */ getProfileByLOD(clippedLine: OlCoordinateCoordinate[], distanceOffset: number, resetPlot: boolean, minLOD: number): void; /** * Request to Pytree service for a range of Level Of Detail (LOD). * @param minLOD minimum Level Of Detail of the request * @param maxLOD maximum Level Of Detail of the request * @param iter the iteration in profile requests cycle * @param coordinates linestring in cPotree format * @param distanceOffset the left side of D3 profile domain at current zoom and pan configuration * @param lastLOD the deepest level to retrieve for this profile * @param width the width of the profile * @param resetPlot whether to reset D3 plot or not, used for first LOD * @private */ queryPytree_(minLOD: number, maxLOD: number, iter: number, coordinates: string, distanceOffset: number, lastLOD: boolean, width: number, resetPlot: boolean): void; /** * Process the binary array return by Pytree (cPotree). * @param profile binary array returned by cPotree executable called by Pytree * @param iter the iteration in profile requests cycle * @param distanceOffset the left side of D3 profile domain at current zoom and pan configuration * @param lastLOD the deepest level to retrieve for this profile * @param resetPlot whether to reset D3 plot or not * @private */ processBuffer_(profile: ArrayBuffer, iter: number, distanceOffset: number, lastLOD: boolean, resetPlot: boolean): void; /** * @returns The html for errors. * @private */ getHTMLError_(): string; /** * Update the profile data according to D3 chart zoom and pan level * The update will wait on a 200ms pause on the actions of users before to do the update. */ updateData(): void; /** * Callback method used by the debouncer to update the profile data. * @private */ updateData_(): void; } declare const gmfLidarprofileManager: LidarprofileManager; export default gmfLidarprofileManager;