Util::QuadTree< TYPE >::Node Class Reference
#include <quadtree.h>
Detailed Description
template<class TYPE>
class Util::QuadTree< TYPE >::Node
node in quad tree Public Member Functions | |
Node () | |
constructor | |
~Node () | |
destructor | |
void | Initialize (QuadTree< TYPE > *tree, uchar _level, ushort _col, ushort _row) |
recursively initialize the node | |
char | Level () const |
get the node's level | |
ushort | Column () const |
get the node's column | |
ushort | Row () const |
get the node's row | |
const Math::bbox & | GetBoundingBox () const |
compute the node's bounding box | |
Node * | FindContainmentNode (const Math::bbox &box) |
recursively find the smallest child node which contains the bounding box | |
void | ClearDataPtr () |
clear element ptr | |
void | SetDataPtr (TYPE *elem) |
set element ptr |
Member Function Documentation
template<class TYPE>
void Util::QuadTree< TYPE >::Node::Initialize | ( | QuadTree< TYPE > * | tree, | |
uchar | _level, | |||
ushort | _col, | |||
ushort | _row | |||
) | [inline] |
recursively initialize the node
Recursively initialize a quad tree node.
template<class TYPE>
QuadTree< TYPE >::Node * Util::QuadTree< TYPE >::Node::FindContainmentNode | ( | const Math::bbox & | checkBox | ) | [inline] |
recursively find the smallest child node which contains the bounding box
This finds the smallest child node which completely contains the given bounding box. Calls itself recursively.