Closed mawenwuda closed 22 hours ago
The indices in nn_indices
and spfh_indices
refer to surface_
, not to input_
. The indices in indices_
refer to input_
. I hope that helps.
Please use Stackoverflow or the Discord community chat for such questions in the future. The GitHub issues are intended for bug reports and compile errors.
This piece of code is from the computeSPFHSignatures function in the
fpfh.hpp
file, and the comment indicates that it computes SPFH for all points in the input point cloud.The comments are from the filefpfh.h
. For example, after downsampling the point cloud wheresurface_ != input_
holds true,this->searchForNeighbors(p_idx, search_parameter_, nn_indices, nn_dists)
performs nearest neighbor search on the downsampled point cloud. Despite this, after the loop,spfh_indices
still stores indices frominput_
. What is its significance then?We can simply assign the indices stored inindices_
tospfh_indices.
Link to the repo: https://github.com/PointCloudLibrary/pcl/blob/master/features/include/pcl/features/impl/fpfh.hpp https://github.com/PointCloudLibrary/pcl/blob/master/features/include/pcl/features/fpfh.h
I am puzzled about the purpose of this code snippet.