Closed Austin1511 closed 4 years ago
Radius search indeed returns sorted results. I think it should be straightforward to make this configurable.
If only interested in a limited number of points, I would recommend using kNNInRadiusSearch
which I think will be more efficient.
@wannesvanloock Thank you ! That solves my problem. I notice that there is another problem with the radiusSearch() funtion. When I want to search a area with 5 radius, I have to pass 5 * 5 to the radius parameter to get the correct result.
This was done to imitate the way nanoflann
works. Please note that distances returned in search results are also squared!
Ok, understood. A comment on the function may be appreciated. Thanks again!
Thank you for your great project! When I use KDTree.radiusSearch() in a huge for loop, it always returns the sorted result, and the sorting feature slows down the for loop. Even I changed the sorted class member to false in the nanoflann::SearchParams, I still get the sorted result. Do you know some way to disable the sort. Thank you for your help!