X
24052 Rate this article:
No rating

Programmatic Access to LiDAR Processing – A Powerful API, Not a Scary Endeavor!

Rebecca Lasica

Isn’t it great when things just work? Imagine your data are delivered in calibrated and atmospherically corrected units. What if multiple data modalities were co-registered and the spatial dimensions aligned perfectly so you could begin your day by clicking on tools to start complex analyses while you make a cup of coffee?

If I had the proverbial dollar for every time this scenario occurred in the world of image analysis for commercial applications – I would definitely need to keep my day job. Don’t get me wrong, robust workflows and access to hundreds of algorithms definitely get the job done – many times 100%of the way.

But those finding a 90% solution with their COTS tools need not despair. Custom development of additional tools to fill the gap is accessible and absolutely achievable. I want to take a moment to point you to some resources that will empower you to delve into creating your own library of discrete and unique solutions. This week my focus is on the ENVI LIDAR API.

First you need to instantiate an instance of ENVI LiDAR to have access to the library:

; Create a headless instance

e = E3De(/HEADLESS)

 

Next you will need to open a .las file:

; Example of how to point to and open a .las file. 
file = FILEPATH('DataSample.las', ROOT_DIR=e.ROOT_DIR, $
SUBDIRECTORY = ['DataSample'])
lidar = e.OpenLidar(file, /DIRECT_READ)

 

Once you have your .las file in an IDL variable, go to https://www.nv5geospatialsoftware.com/docs/home.html and click through the ENVI LiDAR > Programming with ENVI LiDAR >Routines. You will see a very approachable list of routines sorted into Application Control, Data Control, and Processing where example code is included for most every routine.

Some of the commercial applications I have seen come to fruition with great success include:

  • Sub-setting the point cloud using spatial constraints around a feature of interest and exporting a new .las file for processing to only include the area(s) relevant to the project. This is incredibly useful for customers who are trying to isolate a feature that is contained across multiple .las tiles.
  • Retrieving a basemap from an image service to display beneath the point cloud. This has utility in adding spatial context to the area and also for producing a polished deliverable via the stand-alone 3Dviewer.
  • Pointing to an image utilizing the RGB information to colorize the point cloud for true color display. The ability to merge data from different modalities is powerful for obvious data display advantages, but is also useful in pixel-based spectral processing downstream.

These are just a few examples of how some commercial LiDAR customers are using the ENVI LiDAR API to extend core capabilities to ensure they are reaching a 100% solution. With the power of IDL, ENVI, and the ENVI LiDAR API , the only limitation is imagination!