JavaScript LAZ Implementation

Mon 07 July 2014 | tags: Open Source, LiDAR, JavaScript, -- (permalink)

One of the challenges we all struggle with as point cloud practitioners is data volume. LAZ has been an excellent solution to that challenge, but as-is it has a couple of limitations. For http://plas.io, Uday Verma and I wanted to be able to natively decompress LAZ data in a browser, with no plugins, no special sidecar software, and across all WebGL-capable browsers.

We recognize that LAZ is the defacto compressed format for aerial LiDAR at this time, probably for this entire generation of software/systems, and implementing support for it in a browser tackles two hard problems. The first is straightforward enough -- how do you get data to a browser efficiently. There's plenty of ways to skin that cat, and almost all of them would be just as valid as any other. The second is harder though. How do you decrease the data translation pain that users must suffer? The obvious answer to that is use what everyone else is using -- LAZ.

The attractiveness of this approach is easy to understand. There would be no extra format translation steps. Data can be streamed to the client in LAZ chunks, decompressed by the browser, and displayed or exploited as needed. Users could simply save data they've already fetched (and cached) right to their desktop for access by other LAZ-capable softwares. There's no need to reformat data, and it leverages the ecosystem of software that already provides support for LAZ.

This goal is simply not achievable with closed source, proprietary formats. By definition, a JavaScript implementation is open source, or at least source-viewable. A closed source format can't play in the space in this way. Plugins are a non-starter for most organizations. A pure JavaScript implementation opens up the guts of the format and tosses away the lockin feature of the format that is its raison d'ĂȘtre.

You can test it out at http://plas.io/jslaz/ It is still a little punchy, but it wins by a mile when compared to downloading the raw uncompressed LAS data.

comments powered by Disqus