las2las -i fusa.laz -set_classification 1 -stdout |^
lasground_new64 -stdin -stdout |^
las2dem -stdin -pipe_on -keep_class 2 -step 1 -o dem.tif |^
lasgrid -stdin -pipe_on -density -keep_class 2 -step 1 -o density_ground.png |^
lasgrid -stdin -density -keep_first -step 1 -o density_first.png
I get what I want, but I also get these warning and error messages:
WARNING: written 161864 points but expected 277573 points
ERROR: stream not seekable. cannot update header from 277573 to 161864 points.
WARNING: end-of-file after 161864 of 277573 points
As far as I know, 277573 is total number of records and 161864 is number of ground points... but why these messages?
On a side note, piping is not very much documented in the README other than if -stdin / -stdout can be used with a given tool. It would be a good addition to have a seperate README (or inside each README) explaining how to use piping. It may not be that essential, but it would be faster than looking into the different threads in this forum. For example, what I finally understound is that -pipe_on is needed to pass the last -stdout to the next tool. Maybe I'm slow also...