41#include <pcl/search/search.h>
42#include <pcl/octree/octree_search.h>
109 tree_->deleteTree ();
110 tree_->setInputCloud (cloud);
111 tree_->addPointsFromInputCloud ();
122 tree_->deleteTree ();
123 tree_->setInputCloud (cloud, indices);
124 tree_->addPointsFromInputCloud ();
192 unsigned int max_nn = 0)
const override
213 unsigned int max_nn = 0)
const override
293#ifdef PCL_NO_PRECOMPILE
294#include <pcl/octree/impl/octree_search.hpp>
296#define PCL_INSTANTIATE_Octree(T) template class PCL_EXPORTS pcl::search::Octree<T>;
Iterator class for point clouds with or without given indices.
std::size_t size() const
Size of the range the iterator is going through.
PointCloud represents the base class in PCL for storing collections of 3D points.
shared_ptr< PointCloud< PointT > > Ptr
shared_ptr< const PointCloud< PointT > > ConstPtr
Octree container class that does not store any information.
Octree container class that does store a vector of point indices.
shared_ptr< OctreePointCloudSearch< PointT, LeafContainerT, BranchContainerT > > Ptr
search::Octree is a wrapper class which implements nearest neighbor search operations based on the pc...
void setInputCloud(const PointCloudConstPtr &cloud, const IndicesConstPtr &indices) override
Provide a pointer to the input dataset.
uindex_t boxSearch(const Eigen::Vector3f &min_pt, const Eigen::Vector3f &max_pt, Indices &k_indices) const
Search for points within rectangular search area.
typename PointCloud::Ptr PointCloudPtr
int nearestKSearch(index_t index, int k, Indices &k_indices, std::vector< float > &k_sqr_distances) const override
Search for the k-nearest neighbors for the given query point (zero-copy).
void setInputCloud(const PointCloudConstPtr &cloud)
Provide a pointer to the input dataset.
~Octree()
Empty Destructor.
int radiusSearch(const PointT &p_q, double radius, Indices &k_indices, std::vector< float > &k_sqr_distances, unsigned int max_nn=0) const override
search for all neighbors of query point that are within a given radius.
OctreePointCloudSearchPtr tree_
void approxNearestSearch(const PointCloudConstPtr &cloud, index_t query_index, index_t &result_index, float &sqr_distance)
Search for approximate nearest neighbor at the query point.
typename PointCloud::ConstPtr PointCloudConstPtr
int radiusSearch(index_t index, double radius, Indices &k_indices, std::vector< float > &k_sqr_distances, unsigned int max_nn=0) const override
search for all neighbors of query point that are within a given radius.
typename pcl::octree::OctreePointCloudSearch< PointT, LeafTWrap, BranchTWrap >::ConstPtr OctreePointCloudSearchConstPtr
void approxNearestSearch(index_t query_index, index_t &result_index, float &sqr_distance)
Search for approximate nearest neighbor at the query point.
Octree(const double resolution)
Octree constructor.
int radiusSearch(const PointCloud &cloud, index_t index, double radius, Indices &k_indices, std::vector< float > &k_sqr_distances, unsigned int max_nn=0) const override
search for all neighbors of query point that are within a given radius.
typename pcl::octree::OctreePointCloudSearch< PointT, LeafTWrap, BranchTWrap >::Ptr OctreePointCloudSearchPtr
void approxNearestSearch(const PointT &p_q, index_t &result_index, float &sqr_distance)
Search for approximate nearest neighbor at the query point.
int nearestKSearch(const PointT &point, int k, Indices &k_indices, std::vector< float > &k_sqr_distances) const override
Search for the k-nearest neighbors for the given query point.
int nearestKSearch(const PointCloud &cloud, index_t index, int k, Indices &k_indices, std::vector< float > &k_sqr_distances) const override
Search for the k-nearest neighbors for the given query point.
PointCloudConstPtr input_
void sortResults(Indices &indices, std::vector< float > &distances) const
pcl::IndicesConstPtr IndicesConstPtr
detail::int_type_t< detail::index_type_size, detail::index_type_signed > index_t
Type used for an index in PCL.
IndicesAllocator<> Indices
Type used for indices in PCL.
detail::int_type_t< detail::index_type_size, false > uindex_t
Type used for an unsigned index in PCL.
A point structure representing Euclidean xyz coordinates, and the RGB color.