OpenWalnut
1.5.0dev
|
implements the computation of a kd tree on a point array More...
#include <WKdTree.h>
Public Member Functions | |
WKdTree (int size, float *pointArray) | |
constructor More... | |
~WKdTree () | |
destructor More... | |
Public Attributes | |
std::vector< unsigned int > | m_tree |
stores the tree More... | |
Private Member Functions | |
void | buildTree (int left, int right, int axis) |
recursive function to compute a part of the kd tree More... | |
Private Attributes | |
int | m_size |
size of the tree More... | |
unsigned int | m_root |
index of the root point More... | |
float * | m_pointArray |
stores a pointer to the vertex array More... | |
WKdTree::WKdTree | ( | int | size, |
float * | pointArray | ||
) |
constructor
size | |
pointArray |
Definition at line 33 of file WKdTree.cpp.
References wlog::debug(), m_pointArray, m_root, m_size, m_tree, WThreadedRunner::run(), and WThreadedRunner::wait().
WKdTree::~WKdTree | ( | ) |
destructor
Definition at line 98 of file WKdTree.cpp.
|
private |
recursive function to compute a part of the kd tree
left | |
right | |
axis |
Definition at line 102 of file WKdTree.cpp.
References m_pointArray, and m_tree.
|
private |
stores a pointer to the vertex array
Definition at line 134 of file WKdTree.h.
Referenced by buildTree(), and WKdTree().
|
private |
|
private |
std::vector< unsigned int > WKdTree::m_tree |