[pdal] How to generate a colored tif (RGB in 3 bands each) from colored las file

Howard Butler howard at hobu.co
Wed Sep 28 05:43:54 PDT 2022



> On Sep 28, 2022, at 7:11 AM, James Klassen <klassen.js at gmail.com> wrote:
> 
> One idea, probably not optimal:
> 
> Use 3 writers.gdal stages and output each band to a different file.  Then use GDAL to assemble the three files into a single TIFF.  (gdalbuildvrt -separate, followed by gdal_translate to make a tiff from the VRT). 

This is what I've done in the past, but one of the issues is PDAL's writers.gdal was interpolating using values outside the pixel, which is not ideal for picking pixel colors. For upcoming PDAL 2.5.0, we've added 'binmode' to writers.gdal [1], which will cause it to only consider points *inside* the pixel. This makes for better output in situations like this one (or making Intensity/Classification rasters).

Howard

[1] https://github.com/PDAL/PDAL/pull/3840


More information about the pdal mailing list