27#ifndef EASY3D_KD_TREE_SEARCH_ANN_H
28#define EASY3D_KD_TREE_SEARCH_ANN_H
30#include <easy3d/kdtree/kdtree_search.h>
92 std::vector<int> &neighbors, std::vector<float> &squared_distances
102 const vec3 &p,
int k,
103 std::vector<int> &neighbors
129 const vec3 &p,
float squared_radius,
130 std::vector<int> &neighbors, std::vector<float> &squared_distances
140 const vec3 &p,
float squared_radius,
141 std::vector<int> &neighbors
151 int k_for_radius_search_;
void find_points_in_range(const vec3 &p, float squared_radius, std::vector< int > &neighbors, std::vector< float > &squared_distances) const override
Queries the nearest neighbors within a fixed range.
Definition kdtree_search_ann.cpp:192
KdTreeSearch_ANN(const PointCloud *cloud)
Constructor.
Definition kdtree_search_ann.cpp:46
void set_k_for_radius_search(int k)
Specifies the K for fixed range search.
Definition kdtree_search_ann.h:117
void find_closest_k_points(const vec3 &p, int k, std::vector< int > &neighbors, std::vector< float > &squared_distances) const override
Queries the K nearest neighbors for a given point.
Definition kdtree_search_ann.cpp:155
int find_closest_point(const vec3 &p, float &squared_distance) const override
Queries the closest point for a given point.
Definition kdtree_search_ann.cpp:124
KdTreeSearch(const PointCloud *cloud)
Constructor.
Definition kdtree_search.cpp:32
A data structure for point clouds.
Definition point_cloud.h:45
Definition collider.cpp:182
Vec< 3, float > vec3
A 3D point/vector of float type.
Definition types.h:44