40 #ifndef PCL_KDTREE_IO_IMPL_HPP_
41 #define PCL_KDTREE_IO_IMPL_HPP_
43 #include <pcl/kdtree/io.h>
46 template <
typename Po
int1T,
typename Po
int2T>
void
56 std::vector<float> nn_dists (1);
57 indices.resize (cloud_in->
size ());
58 for (std::size_t i = 0; i < cloud_in->
size (); ++i)
61 indices[i] = nn_idx[0];
66 template <
typename Po
intT>
void
76 std::vector<float> nn_dists (1);
77 indices.resize (cloud_in->
size ());
78 for (std::size_t i = 0; i < cloud_in->
size (); ++i)
81 indices[i] = nn_idx[0];
KdTreeFLANN is a generic type of 3D spatial locator using kD-tree structures.
int nearestKSearch(const PointT &point, unsigned int k, Indices &k_indices, std::vector< float > &k_sqr_distances) const override
Search for k-nearest neighbors for the given query point.
void setInputCloud(const PointCloudConstPtr &cloud, const IndicesConstPtr &indices=IndicesConstPtr()) override
Provide a pointer to the input dataset.
int nearestKSearchT(const PointTDiff &point, unsigned int k, Indices &k_indices, std::vector< float > &k_sqr_distances) const
Search for k-nearest neighbors for the given query point.
shared_ptr< const PointCloud< PointT > > ConstPtr
void getApproximateIndices(const typename pcl::PointCloud< PointT >::ConstPtr &cloud_in, const typename pcl::PointCloud< PointT >::ConstPtr &cloud_ref, Indices &indices)
Get a set of approximate indices for a given point cloud into a reference point cloud.
IndicesAllocator<> Indices
Type used for indices in PCL.