Hi Nick,
this is more a DOS subject than LAStools.
First I want to ask if it makes sense to save multiline-texts within a VLR.
I do not think so.
LAS is not a database but a storage for LiDAR data.
It should rather be the other way round: Build a database. Store your LAS/LAZ files there.
Put all you have around also into the database.
But may you have a really good reason to save a multi-line-text within a LAS file.
Then this hints may help you:
- You do not need a/this special version linked above. The feature is now in the reqular release.
- Right now the text is cropped after the first CR/LF.
- Right now we just save standard ASCII and no UTF-8,...
Because we crop you just have to replace your CR/LF into something else
and then restore the replacement when you get the data back.
If you have plain ASCII and just want to replace the CR/LF into something you
may be able to do this with some DOS commands.
If you have a real text or something else I would recommend to convert all
into a ASCII safe representation - e.g. a
Base64 encoded string.
There are many tools around to help you with this.
If you like DOS you may become happy with this:
setlocal enabledelayedexpansion
rem put your multiline input into a dos var and replace all linebreaks with a \n sequence
set "line="
for /f "delims=" %%a in (multiline.txt) do set "line=!line!%%a\n"
echo %line%
rem put this line into the VLR, add a "##" before to simplify decoding
las2las -i test1.laz -o test2.laz -add_empty_vlr "test" 123 "##"%line%
las2las -i test2.laz -save_vlrs
type vlrs.vlr
Hope this helps,
Jochen @rapidlasso