38 #ifndef PCL_KEYPOINT_H_
39 #define PCL_KEYPOINT_H_
42 #include <pcl/pcl_base.h>
43 #include <boost/function.hpp>
44 #include <boost/bind.hpp>
45 #include <pcl/search/pcl_search.h>
46 #include <pcl/pcl_config.h>
54 template <
typename Po
intInT,
typename Po
intOutT>
58 typedef boost::shared_ptr<Keypoint<PointInT, PointOutT> >
Ptr;
59 typedef boost::shared_ptr<const Keypoint<PointInT, PointOutT> >
ConstPtr;
71 typedef boost::function<int (int, double, std::vector<int> &, std::vector<float> &)>
SearchMethod;
72 typedef boost::function<int (const PointCloudIn &cloud, int index, double, std::vector<int> &, std::vector<float> &)>
SearchMethodSurface;
152 searchForNeighbors (
int index,
double parameter, std::vector<int> &indices, std::vector<float> &distances)
const
191 inline const std::string&
200 #include <pcl/keypoints/impl/keypoint.hpp>
202 #endif //#ifndef PCL_KEYPOINT_H_
boost::function< int(int, double, std::vector< int > &, std::vector< float > &)> SearchMethod
SearchMethod search_method_
The search method template for indices.
PointCloudInConstPtr surface_
An input point cloud describing the surface that is to be used for nearest neighbors estimation...
SearchMethodSurface search_method_surface_
The search method template for points.
boost::shared_ptr< pcl::search::Search< PointT > > Ptr
boost::shared_ptr< const PointCloud< PointT > > ConstPtr
int getKSearch()
get the number of k nearest neighbors used for the feature estimation.
void setRadiusSearch(double radius)
Set the sphere radius that is to be used for determining the nearest neighbors used for the key point...
pcl::PointCloud< PointOutT > PointCloudOut
pcl::search::Search< PointInT > KdTree
KdTreePtr tree_
A pointer to the spatial search object.
boost::shared_ptr< const Keypoint< PointInT, PointOutT > > ConstPtr
boost::shared_ptr< PointCloud< PointT > > Ptr
virtual void detectKeypoints(PointCloudOut &output)=0
Abstract key point detection method.
Keypoint()
Empty constructor.
boost::function< int(const PointCloudIn &cloud, int index, double, std::vector< int > &, std::vector< float > &)> SearchMethodSurface
double getRadiusSearch()
Get the sphere radius used for determining the neighbors.
PointCloudConstPtr input_
The input point cloud dataset.
virtual bool initCompute()
PCLBase< PointInT > BaseClass
KdTreePtr getSearchMethod()
Get a pointer to the search method used.
int searchForNeighbors(int index, double parameter, std::vector< int > &indices, std::vector< float > &distances) const
Search for k-nearest neighbors using the spatial locator from setSearchmethod, and the given surface ...
double getSearchParameter()
Get the internal search parameter.
pcl::search::Search< PointInT >::Ptr KdTreePtr
PointCloudInConstPtr getSearchSurface()
Get a pointer to the surface point cloud dataset.
double search_radius_
The nearest neighbors search radius for each point.
void setKSearch(int k)
Set the number of k nearest neighbors to use for the feature estimation.
void setSearchMethod(const KdTreePtr &tree)
Provide a pointer to the search object.
Keypoint represents the base class for key points.
PointCloudIn::Ptr PointCloudInPtr
int k_
The number of K nearest neighbors to use for each point.
pcl::PointCloud< PointInT > PointCloudIn
virtual ~Keypoint()
Empty destructor.
void compute(PointCloudOut &output)
Base method for key point detection for all points given in <setInputCloud (), setIndices ()> using t...
const std::string & getClassName() const
Get a string representation of the name of this class.
PointCloudIn::ConstPtr PointCloudInConstPtr
std::string name_
The key point detection method's name.
double search_parameter_
The actual search parameter (casted from either search_radius_ or k_).
virtual void setSearchSurface(const PointCloudInConstPtr &cloud)
Provide a pointer to the input dataset that we need to estimate features at every point for...
boost::shared_ptr< Keypoint< PointInT, PointOutT > > Ptr