[pdal] entwine error with PDAL with lasperf and no laszip

Howard Butler howard at hobu.co
Tue Jan 11 08:11:38 PST 2022



> On Jan 11, 2022, at 9:50 AM, Jim Klassen <klassen.js at gmail.com> wrote:
> 
> If PDAL is built with lasperf but without laszip then entwine gives the error:
> 
>    Exception in pool task: writers.las: Can't write LAZ output. PDAL not built with LASzip.
> 
> Tested with entwine commit cd22b9f843badcbd236999c7dd75400a7237c0df   Thu Sep 23 14:58:28 2021 -0500
> 
> The following patch "fixes" it but is less than ideal because then it requires lasperf.  Maybe using "compression": "true" would be better to let PDAL pick the implementation?  Or maybe choosing based on cmake settings?
> 
> diff --git a/entwine/io/laszip.cpp b/entwine/io/laszip.cpp
> index a94d0e2..ea90be4 100644
> --- a/entwine/io/laszip.cpp
> +++ b/entwine/io/laszip.cpp
> @@ -56,7 +56,7 @@ void write(
>     options.add("minor_version", 2);
>     options.add("extra_dims", "all");
>     options.add("software_id", "Entwine " + currentEntwineVersion().toString());
> -    options.add("compression", "laszip");
> +    options.add("compression", "lasperf");
>     options.add("dataformat_id", timeMask | colorMask);
>      const auto so = getScaleOffset(metadata.schema);

A better fix would be for Entwine to use pdal::Config::hasFeature(Feature::LAZPERF) to condition this.





More information about the pdal mailing list