searchTree.h
Go to the documentation of this file.
1 
7 #ifndef __SEARCHTREE_H__
8 #define __SEARCHTREE_H__
9 
10 #include <vector>
11 using std::vector;
12 
13 #include "searchCache.h"
14 #include "ptpair.h"
15 #include "data_types.h"
16 
22 class Tree {
23 public:
28  virtual inline ~Tree() {};
29 };
30 
31 
32 class Scan;
39 class SearchTree : public Tree {
40  friend class Scan;
41 public:
45  inline SearchTree() {};
46 
53  SearchTree(double **pts, int n);
54 
59  virtual inline ~SearchTree() {};
60 
64  virtual inline void lock() {};
65 
69  virtual inline void unlock() {};
70 
81  virtual double *FindClosest(double *_p, double maxdist2, int threadNum = 0) const = 0 ;
82 
83  virtual void getPtPairs(vector <PtPair> *pairs,
84  double *source_alignxf,
85  double * const *q_points, unsigned int startindex, unsigned int endindex,
86  int thread_num,
87  int rnd, double max_dist_match2, double &sum,
88  double *centroid_m, double *centroid_d);
89 
90  virtual void getPtPairs(vector <PtPair> *pairs,
91  double *source_alignxf,
92  const DataXYZ& xyz_r, unsigned int startindex, unsigned int endindex,
93  int thread_num,
94  int rnd, double max_dist_match2, double &sum,
95  double *centroid_m, double *centroid_d);
96 };
97 
98 
105 class CachedSearchTree : public SearchTree {
106 public:
110  inline CachedSearchTree() {};
111 
118  CachedSearchTree(double **pts, int n, CachedSearchTree *_parent = 0);
119 
124  virtual inline ~CachedSearchTree() {};
125 
136  virtual SearchTreeCacheItem* FindClosestCacheInit(double *_p, double maxdist2, int threadNum = 0) = 0;
137 
148  virtual SearchTreeCacheItem* FindClosestCache(double *_p, double maxdist2, int threadNum = 0) = 0;
149  double *FindClosest(double *_p, double maxdist2, int threadNum = 0) const {
150  return 0;
151  }
152 };
153 
154 
155 #endif
virtual void lock()
Definition: searchTree.h:64
virtual ~SearchTree()
Definition: searchTree.h:59
double * FindClosest(double *_p, double maxdist2, int threadNum=0) const
Definition: searchTree.h:149
virtual void unlock()
Definition: searchTree.h:69
Representation of a general cache for search trees.
The search tree structure.
Definition: searchTree.h:105
The tree structure.
Definition: searchTree.h:22
The general Cache Item.
Definition: searchCache.h:15
Definition of point pairs.
virtual ~CachedSearchTree()
Definition: searchTree.h:124
virtual ~Tree()
Definition: searchTree.h:28
The search tree structure.
Definition: searchTree.h:39
Basic DataPointer class and its derivates SingleArray and TripleArray.


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 Mon Feb 28 2022 22:46:09