40 #ifndef PCL_KEYPOINTS_BRISK_KEYPOINT_2D_IMPL_H_ 41 #define PCL_KEYPOINTS_BRISK_KEYPOINT_2D_IMPL_H_ 43 #include <pcl/common/io.h> 46 template <
typename Po
intInT,
typename Po
intOutT,
typename IntensityT>
bool 51 PCL_ERROR (
"[pcl::%s::initCompute] init failed.!\n", name_.c_str ());
55 if (!input_->isOrganized ())
57 PCL_ERROR (
"[pcl::%s::initCompute] %s doesn't support non organized clouds!\n", name_.c_str ());
65 template <
typename Po
intInT,
typename Po
intOutT,
typename IntensityT>
void 69 const int width = int (input_->width);
70 const int height = int (input_->height);
73 std::vector<unsigned char> image_data (width*height);
75 for (
size_t i = 0; i < image_data.size (); ++i)
76 image_data[i] = static_cast<unsigned char> (intensity_ ((*input_)[i]));
82 pcl::copyPointCloud<pcl::PointWithScale, PointOutT> (output_temp, output);
90 if (remove_invalid_3D_keypoints_)
93 for (
size_t i = 0; i < output.
size (); ++i)
97 bilinearInterpolation (input_, output[i].x, output[i].y, pt);
103 output = output_clean;
bool isFinite(const PointT &pt)
Tests if the 3D components of a point are all finite param[in] pt point to be tested return true if f...
BRISK Scale Space helper.
std::vector< PointT, Eigen::aligned_allocator< PointT > > points
The point data.
void push_back(const PointT &pt)
Insert a new point in the cloud, at the end of the container.
uint32_t height
The point cloud height (if organized as an image-structure).
Keypoint represents the base class for key points.
uint32_t width
The point cloud width (if organized as an image-structure).
bool initCompute()
Initializes everything and checks whether input data is fine.
void detectKeypoints(PointCloudOut &output)
Detects the keypoints.
PointCloud represents the base class in PCL for storing collections of 3D points. ...
void constructPyramid(const std::vector< unsigned char > &image, int width, int height)
Construct the image pyramids.
bool is_dense
True if no points are invalid (e.g., have NaN or Inf values in any of their floating point fields)...
void getKeypoints(const int threshold, std::vector< pcl::PointWithScale, Eigen::aligned_allocator< pcl::PointWithScale > > &keypoints)
Get the keypoints for the associated image and threshold.