lasfilter.hpp
Go to the documentation of this file.
1 /*
2 ===============================================================================
3 
4  FILE: lasfilter.hpp
5 
6  CONTENTS:
7 
8  Filters LIDAR points based on certain criteria being true (or not).
9 
10  PROGRAMMERS:
11 
12  martin.isenburg@gmail.com
13 
14  COPYRIGHT:
15 
16  (c) 2007-2011, Martin Isenburg, LASSO - tools to catch reality
17 
18  This is free software; you can redistribute and/or modify it under the
19  terms of the GNU Lesser General Licence as published by the Free Software
20  Foundation. See the COPYING file for more information.
21 
22  This software is distributed WITHOUT ANY WARRANTY and without even the
23  implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
24 
25  CHANGE HISTORY:
26 
27  25 December 2010 -- created after swinging in Mara's hammock for hours
28 
29 ===============================================================================
30 */
31 #ifndef LAS_FILTER_HPP
32 #define LAS_FILTER_HPP
33 
34 #include "lasdefinitions.hpp"
35 
37 {
38 public:
39  virtual const char * name() const = 0;
40  virtual int get_command(char* string) const = 0;
41  virtual BOOL filter(const LASpoint* point) = 0;
42  virtual void reset(){};
43  virtual ~LAScriterion(){};
44 };
45 
46 class LASfilter
47 {
48 public:
49 
50  void usage() const;
51  void clean();
52  BOOL parse(int argc, char* argv[]);
53  int unparse(char* string) const;
54  inline BOOL active() const { return (num_criteria != 0); };
55  void addClipCircle(F64 x, F64 y, F64 radius);
57 
58  BOOL filter(const LASpoint* point);
59  void reset();
60 
61  LASfilter();
62  ~LASfilter();
63 
64 private:
65 
66  void add_criterion(LAScriterion* criterion);
70  int* counters;
71 };
72 
73 #endif
LASfilter::unparse
int unparse(char *string) const
Definition: lasfilter.cpp:1510
LASfilter::LASfilter
LASfilter()
Definition: lasfilter.cpp:1555
LASpoint
Definition: lasdefinitions.hpp:472
F64
double F64
Definition: mydefs.hpp:52
LAScriterion
Definition: lasfilter.hpp:36
LASfilter::clean
void clean()
Definition: lasfilter.cpp:790
LAScriterion::name
virtual const char * name() const =0
LASfilter::criteria
LAScriterion ** criteria
Definition: lasfilter.hpp:69
LASfilter::num_criteria
U32 num_criteria
Definition: lasfilter.hpp:67
LASfilter::add_criterion
void add_criterion(LAScriterion *criterion)
Definition: lasfilter.cpp:1568
LAScriterion::reset
virtual void reset()
Definition: lasfilter.hpp:42
LASfilter::parse
BOOL parse(int argc, char *argv[])
Definition: lasfilter.cpp:866
LASfilter::~LASfilter
~LASfilter()
Definition: lasfilter.cpp:1563
LAScriterion::~LAScriterion
virtual ~LAScriterion()
Definition: lasfilter.hpp:43
LASfilter::addScanDirectionChangeOnly
void addScanDirectionChangeOnly()
Definition: lasfilter.cpp:1526
LASfilter::counters
int * counters
Definition: lasfilter.hpp:70
BOOL
int BOOL
Definition: mydefs.hpp:57
LASfilter::usage
void usage() const
Definition: lasfilter.cpp:805
argc
int argc
Definition: tests_high_five_parallel.cpp:27
LASfilter::alloc_criteria
U32 alloc_criteria
Definition: lasfilter.hpp:68
LASfilter
Definition: lasfilter.hpp:46
LAScriterion::get_command
virtual int get_command(char *string) const =0
LASfilter::addClipCircle
void addClipCircle(F64 x, F64 y, F64 radius)
Definition: lasfilter.cpp:1521
U32
unsigned int U32
Definition: mydefs.hpp:39
LASfilter::active
BOOL active() const
Definition: lasfilter.hpp:54
LASfilter::filter
BOOL filter(const LASpoint *point)
Definition: lasfilter.cpp:1531
LASfilter::reset
void reset()
Definition: lasfilter.cpp:1546
LAScriterion::filter
virtual BOOL filter(const LASpoint *point)=0
argv
char ** argv
Definition: tests_high_five_parallel.cpp:28
lasdefinitions.hpp


lvr2
Author(s): Thomas Wiemann , Sebastian Pütz , Alexander Mock , Lars Kiesow , Lukas Kalbertodt , Tristan Igelbrink , Johan M. von Behren , Dominik Feldschnieders , Alexander Löhr
autogenerated on Wed Mar 2 2022 00:37:23