54 Eigen::MatrixXf histogram;
59 if (indices.size () < 2)
71 minmax[0] = std::numeric_limits<double>::max();
72 minmax[1] = -std::numeric_limits<double>::max();
77 pcl::Indices::const_iterator i, begin (indices.begin()), end (indices.end());
78 for (i = begin+1; i != end; ++i)
81 double cosine = normals[*i].normal[0] * normals[*begin].normal[0] +
82 normals[*i].normal[1] * normals[*begin].normal[1] +
83 normals[*i].normal[2] * normals[*begin].normal[2];
86 double angle = std::acos (
cosine);
87 if (angle >
M_PI/2) angle =
M_PI - angle;
90 double dist =
sqrt ((surface[*i].x - surface[*begin].x) * (surface[*i].x - surface[*begin].x) +
91 (surface[*i].y - surface[*begin].y) * (surface[*i].y - surface[*begin].y) +
92 (surface[*i].z - surface[*begin].z) * (surface[*i].z - surface[*begin].z));
251 if (search_radius_ < 0)
253 PCL_ERROR (
"[pcl::%s::computeFeature] A search radius needs to be set!\n", getClassName ().
c_str ());
265 if (save_histograms_)
268 histograms_.
reset (
new std::vector<Eigen::MatrixXf, Eigen::aligned_allocator<Eigen::MatrixXf> >);
272 for (std::size_t idx = 0; idx < indices_->size (); ++idx)
283 for (std::size_t idx = 0; idx < indices_->size (); ++idx)
Eigen::MatrixXf computeRSD(const pcl::PointCloud< PointInT > &surface, const pcl::PointCloud< PointNT > &normals, const pcl::Indices &indices, double max_dist, int nr_subdiv, double plane_radius, PointOutT &radii, bool compute_histogram=false)
Estimate the Radius-based Surface Descriptor (RSD) for a given point based on its spatial neighborhoo...