mparkan / Digital-Forestry-Toolbox

A collection of digital forestry tools for Matlab/Octave
http://mparkan.github.io/Digital-Forestry-Toolbox/
GNU General Public License v3.0
46 stars 16 forks source link

saving a new las file by just using xyz or xyzRGB point data #4

Closed songtaowhu closed 4 years ago

songtaowhu commented 4 years ago

Thank you very much. It is very useful. I have the difficulity in saving the new las file after merging multiple point cloud data (las files). Can we save a new las file by just using the data in the form of xyz or xyzRGB?

mparkan commented 4 years ago

Hello, could you please be more specific about the issue with saving the merged point cloud and provided a description of the files you are trying to merge?

The LAS format has different versions (from 1.0 to 1.4) and supports various point data record formats. You can check the specifications here:

There is no LAS point data record format that contains only XYZRGB.

If you just need to save the xyz and RGB attributes, you could extract them from your LAS files (with LASread function), merge them into a single xyzrgb Matlab/Octave variable and save the data as a Matlab/Octave binary file (with the save function) or as CSV file (with the fprintf function).