[pdal] filter on return value
Luca Delucchi
lucadeluge at gmail.com
Thu Jun 4 06:36:00 PDT 2015
On 4 June 2015 at 15:11, Howard Butler <howard at hobu.co> wrote:
> Luca,
>
Hi Howard,
> Yes these two are somewhat overlapping in functionality, but the predicate filter is much more powerful in exchange for being a bit slower and definitely more complex. The intention is that filters.range is for when you can do simple attribute-based filters, and predicate/programmable are for when you want to do something with complex logic without having to write an entire filter in C++ to do it.
>
> The problem with --last-return-only is that it is a complex expression that means, “keep points where ReturnNumber==NumberOfReturns”. You can’t do that in a single filters.range invocation. You instead would have to make a filters.range for each last return combination, and then filters.merge them altogether afterward.
>
> See https://github.com/PDAL/PDAL/blob/master/test/data/plang/predicate-keep-last-return.xml.in for an example of how to use the predicate filter to keep last returns.
>
> Hope this helps,
>
yes sure, it was really useful.
Can I mix filters.predicate and filters.range right?
> Howard
>
--
ciao
Luca
http://gis.cri.fmach.it/delucchi/
www.lucadelu.org
More information about the pdal
mailing list