m
maplibre-gl-lidar
LiDAR point clouds on the map
Maintained by Open Geospatial Solutions
A MapLibre GL JS control for viewing LiDAR point clouds (LAS, LAZ and streamed COPC) with deck.gl: color by elevation, intensity or classification, filter points, and hover to inspect them.
Live demo
maplibre-gl-lidar running on MapLibre GL JS in your browser
Loading the map…
Demo code
import { LidarControl } from "maplibre-gl-lidar";
import "maplibre-gl-lidar/style.css";
import type { PluginDemo } from "../types";
export default {
center: [-123.075, 44.05], // Autzen Stadium, Eugene, Oregon
zoom: 15,
pitch: 60,
async run({ map }) {
// A LiDAR viewer panel: load, color, filter and pick points of a point cloud.
const lidar = new LidarControl({
title: "LiDAR Viewer",
collapsed: true,
pointSize: 2,
colorScheme: "elevation",
});
map.addControl(lidar, "top-right");
// A public Cloud Optimized Point Cloud (COPC), streamed by range requests.
await lidar.loadPointCloud("https://s3.amazonaws.com/hobu-lidar/autzen-classified.copc.laz");
lidar.flyToPointCloud();
},
} satisfies PluginDemo;