66 Node(
size_t index_,
double x_,
double y_)
80 WBAssert(std::fabs((y_axis ? y : x) - *(&x+y_axis)) < std::numeric_limits<double>::epsilon(),
81 "Internal error: y_axis=" << y_axis <<
", x=" << x <<
", y=" << y <<
", *(&x+y_axis)=" << *(&x+y_axis)
82 <<
", ((bool)y_axis ? x : y) - *(&x+y_axis)=" << fabs((y_axis ? x : y) - *(&x+y_axis)));
97 KDTree(
const std::vector<Node> point_list);
103 void create_tree(
const size_t left,
110 const std::vector<Node> &get_nodes()
const;
139 void find_closest_point_recursive(
const Point<2> &check_point,
151 void find_closest_points_recursive(
const Point<2> &check_point,
std::vector< Node > nodes
const double & operator[](const bool y_axis) const
std::vector< IndexDistance > vector
Node(size_t index_, double x_, double y_)
#define WBAssert(condition, message)