LasMerger

LasMerger merges all the LAS files of a folder into a single file, as the tiles in which surveys are delivered.

Details

All the files with the .las extension of the folder are merged, the compressed .laz files are ignored. The merged file covers the bounds of all of them and gets the crs of the first one that has a prj file.

The merged file is written with a precision of 1 cm for the coordinates and 1 mm for the elevation, the default of the writer, whatever the precision of the merged files. Write it outside of the merged folder: if it is in it, it is merged too the next time.

Parameters

Merges all the las files of a folder into a single file.

Toolbox folder: Lesto › filter
Status: Experimental
Keywords: las, merge
Authors: Andrea Antonello
Class: org.hortonmachine.lesto.modules.filter.LasMerger

Inputs

Parameter

Type

Unit

Default

Description

inFolder

folder

The folder of the las files to merge.

Outputs

Parameter

Type

Unit

Description

outLas

output file

The merged las file.

Example

The pieces of the example of LasSplitter merged back into a single file, outside of their folder:

import org.hortonmachine.lesto.modules.filter.LasMerger

// the folder with the lidar survey: change it to yours
var folder = "/data/flanginec/"

// merge the pieces of LasSplitter back into a single file
var merger = new LasMerger()
merger.inFolder = folder + "las_pieces"
merger.outLas = folder + "las_merged.las"
merger.process()

The merged file has the 33,410 points of the sample survey and its crs.