Adaptor class used internally by nanoflann. More...
#include <parsed_kdtree_distance.h>
Public Types | |
typedef double | coord_t |
A typedef used by nanoflann. More... | |
Public Member Functions | |
PointCloudAdaptor (const std::vector< Point< dim > > &_points) | |
The constrcutor needs the data set source. More... | |
size_t | kdtree_get_point_count () const |
Return number of points in the data set (required by nanoflann). More... | |
coord_t | kdtree_distance (const coord_t *p1, const size_t idx_p2, size_t size) const |
Return the L2 distance between points. More... | |
coord_t | kdtree_get_pt (const size_t idx, int d) const |
Return the dim'th component of the idx'th point in the class. More... | |
template<class BBOX > | |
bool | kdtree_get_bbox (BBOX &) const |
Optional bounding-box computation: return false to default to a standard bbox computation loop. More... | |
Public Attributes | |
const std::vector< Point< dim > > & | points |
Reference to the vector of points from which we want to compute the distance. More... | |
Adaptor class used internally by nanoflann.
Class actually stores a reference to the vector of points, and generates some helper functions for nanoflann.
Definition at line 83 of file parsed_kdtree_distance.h.
typedef double ParsedKDTreeDistance< dim >::PointCloudAdaptor::coord_t |
A typedef used by nanoflann.
Definition at line 88 of file parsed_kdtree_distance.h.
|
inline |
The constrcutor needs the data set source.
Definition at line 101 of file parsed_kdtree_distance.h.
|
inline |
Return the L2 distance between points.
Definition at line 116 of file parsed_kdtree_distance.h.
|
inline |
Optional bounding-box computation: return false to default to a standard bbox computation loop.
Return true if the BBOX was already computed by the class and returned in "bb" so it can be avoided to redo it again. Look at bb.size() to find out the expected dimensionality (e.g. 2 or 3 for point clouds).
Definition at line 144 of file parsed_kdtree_distance.h.
|
inline |
Return number of points in the data set (required by nanoflann).
Definition at line 107 of file parsed_kdtree_distance.h.
|
inline |
Return the dim'th component of the idx'th point in the class.
Definition at line 129 of file parsed_kdtree_distance.h.
const std::vector<Point<dim> >& ParsedKDTreeDistance< dim >::PointCloudAdaptor::points |
Reference to the vector of points from which we want to compute the distance.
A const ref to the data set origin
Definition at line 95 of file parsed_kdtree_distance.h.