Public Types | Public Member Functions | Private Attributes | Friends | List of all members
ApproxMVBB::KdTree::Node< TTraits > Class Template Reference

#include <KdTree.hpp>

Inheritance diagram for ApproxMVBB::KdTree::Node< TTraits >:
Inheritance graph
[legend]

Public Types

using Base = NodeBase< Node< TTraits >, TTraits::Dimension >
 
using Traits = TTraits
 
- Public Types inherited from ApproxMVBB::KdTree::NodeBase< Node< TTraits >, TTraits::Dimension >
using BoundaryInfoType = BoundaryInformation
 
using DerivedNode = Node< TTraits >
 
using SplitAxisType = char
 

Public Member Functions

void cleanUp (bool data=true)
 
NodeDataType * data ()
 
const NodeDataType * data () const
 
const BoundaryInfoTypegetBoundaries () const
 
BoundaryInfoTypegetBoundaries ()
 
template<typename NeighbourIdxMap >
void getNeighbourLeafsIdx (NeighbourIdxMap &neigbourIdx, PREC minExtent)
 
 Node (std::size_t idx, const AABB< Dimension > &aabb, NodeDataType *data, unsigned int treeLevel=0)
 
template<typename Traits >
 Node (const Node< Traits > &n)
 
 Node (Node &&n)
 
void setBoundaryInfo (const BoundaryInfoType &b)
 
std::size_t size ()
 
template<typename TSplitHeuristic >
bool split (TSplitHeuristic &s, std::size_t startIdx=0)
 
 ~Node ()
 
- Public Member Functions inherited from ApproxMVBB::KdTree::NodeBase< Node< TTraits >, TTraits::Dimension >
AABB< Dimension > & aabb ()
 
const AABB< Dimension > & aabb () const
 
std::size_t getIdx () const
 
unsigned int getLevel () const
 
SplitAxisType getSplitAxis () const
 
PREC getSplitPosition () const
 
PREC getSplitRatio () const
 
bool hasChildren () const
 
bool hasLeftChildren () const
 
bool isLeaf () const
 
DerivedNodeleftNode ()
 
const DerivedNodeleftNode () const
 
 NodeBase ()
 
 NodeBase (std::size_t idx, const AABB< Dimension > &aabb, unsigned int treeLevel=0)
 
 NodeBase (const NodeBase< Derived, Dimension > &n)
 
 NodeBase (NodeBase< Derived, Dimension > &&n)
 
DerivedNodeparent ()
 
const DerivedNodeparent () const
 
DerivedNoderightNode ()
 
const DerivedNoderightNode () const
 
void setChilds (DerivedNode *r, DerivedNode *l)
 
void setIdx (std::size_t i)
 
void setLevel (unsigned int l) const
 
void setSplitAxis (SplitAxisType splitAxis)
 
void setSplitPosition (PREC splitPos)
 
 ~NodeBase ()
 

Private Attributes

BoundaryInfoType m_bound
 
NodeDataType * m_data = nullptr
 

Friends

template<typename T >
class Node
 
template<typename T , typename PD >
class NodeSimple
 
template<typename T >
class Tree
 
template<typename T >
class TreeBase
 

Additional Inherited Members

- Protected Member Functions inherited from ApproxMVBB::KdTree::NodeBase< Node< TTraits >, TTraits::Dimension >
 NodeBase (std::size_t idx, const AABB< Dimension > &aabb, SplitAxisType axis, PREC splitPos)
 
- Protected Attributes inherited from ApproxMVBB::KdTree::NodeBase< Node< TTraits >, TTraits::Dimension >
AABB< Dimension > m_aabb
 
std::array< DerivedNode *, 2 > m_child
 
std::size_t m_idx
 node index More...
 
DerivedNodem_parent
 
SplitAxisType m_splitAxis
 -1 indicates leaf node More...
 
PREC m_splitPosition
 
unsigned int m_treeLevel
 

Detailed Description

template<typename TTraits>
class ApproxMVBB::KdTree::Node< TTraits >

Forward declaration

Definition at line 906 of file KdTree.hpp.

Member Typedef Documentation

template<typename TTraits>
using ApproxMVBB::KdTree::Node< TTraits >::Base = NodeBase<Node<TTraits>,TTraits::Dimension>

Definition at line 1020 of file KdTree.hpp.

template<typename TTraits>
using ApproxMVBB::KdTree::Node< TTraits >::Traits = TTraits

Definition at line 1019 of file KdTree.hpp.

Constructor & Destructor Documentation

template<typename TTraits>
ApproxMVBB::KdTree::Node< TTraits >::Node ( std::size_t  idx,
const AABB< Dimension > &  aabb,
NodeDataType *  data,
unsigned int  treeLevel = 0 
)
inline

Definition at line 1050 of file KdTree.hpp.

template<typename TTraits>
ApproxMVBB::KdTree::Node< TTraits >::~Node ( )
inline

Definition at line 1054 of file KdTree.hpp.

template<typename TTraits>
template<typename Traits >
ApproxMVBB::KdTree::Node< TTraits >::Node ( const Node< Traits > &  n)
inline

Copy from node childs are not deep copied (since the node does not own the childs) the child pointers have the same values as the node n. The tree class is responsible for copying the childs accordingly.

Definition at line 1064 of file KdTree.hpp.

template<typename TTraits>
ApproxMVBB::KdTree::Node< TTraits >::Node ( Node< TTraits > &&  n)
inline

Move from node

Definition at line 1071 of file KdTree.hpp.

Member Function Documentation

template<typename TTraits>
void ApproxMVBB::KdTree::Node< TTraits >::cleanUp ( bool  data = true)
inline

Definition at line 1232 of file KdTree.hpp.

template<typename TTraits>
NodeDataType* ApproxMVBB::KdTree::Node< TTraits >::data ( )
inline

Definition at line 1084 of file KdTree.hpp.

template<typename TTraits>
const NodeDataType* ApproxMVBB::KdTree::Node< TTraits >::data ( ) const
inline

Definition at line 1087 of file KdTree.hpp.

template<typename TTraits>
const BoundaryInfoType& ApproxMVBB::KdTree::Node< TTraits >::getBoundaries ( ) const
inline

Definition at line 1077 of file KdTree.hpp.

template<typename TTraits>
BoundaryInfoType& ApproxMVBB::KdTree::Node< TTraits >::getBoundaries ( )
inline

Definition at line 1078 of file KdTree.hpp.

template<typename TTraits>
template<typename NeighbourIdxMap >
void ApproxMVBB::KdTree::Node< TTraits >::getNeighbourLeafsIdx ( NeighbourIdxMap &  neigbourIdx,
PREC  minExtent 
)
inline

Definition at line 1141 of file KdTree.hpp.

template<typename TTraits>
void ApproxMVBB::KdTree::Node< TTraits >::setBoundaryInfo ( const BoundaryInfoType b)
inline

Definition at line 1080 of file KdTree.hpp.

template<typename TTraits>
std::size_t ApproxMVBB::KdTree::Node< TTraits >::size ( )
inline

Definition at line 1239 of file KdTree.hpp.

template<typename TTraits>
template<typename TSplitHeuristic >
bool ApproxMVBB::KdTree::Node< TTraits >::split ( TSplitHeuristic &  s,
std::size_t  startIdx = 0 
)
inline

Splits the node into two new nodes by the splitting position The ownership of the left and right nodes is the caller of this function! If startIdx, which specifies the start numbering for the left child , right child is startIdx+1, is zero then we number according to a complete binary tree, left = 2*m_idx +1 and right 2*m_idx + 2

Definition at line 1097 of file KdTree.hpp.

Friends And Related Function Documentation

template<typename TTraits>
template<typename T >
friend class Node
friend

Node Friends

Definition at line 1039 of file KdTree.hpp.

template<typename TTraits>
template<typename T , typename PD >
friend class NodeSimple
friend

Definition at line 1041 of file KdTree.hpp.

template<typename TTraits>
template<typename T >
friend class Tree
friend

Tree Access

Definition at line 1033 of file KdTree.hpp.

template<typename TTraits>
template<typename T >
friend class TreeBase
friend

Definition at line 1035 of file KdTree.hpp.

Member Data Documentation

template<typename TTraits>
BoundaryInfoType ApproxMVBB::KdTree::Node< TTraits >::m_bound
private

Boundary information which is empty for non-leaf nodes Pointer which point to the subtrees min/max for each dimension

Definition at line 1250 of file KdTree.hpp.

template<typename TTraits>
NodeDataType* ApproxMVBB::KdTree::Node< TTraits >::m_data = nullptr
private

Definition at line 1245 of file KdTree.hpp.


The documentation for this class was generated from the following file:


asr_approx_mvbb
Author(s): Gassner Nikolai
autogenerated on Mon Jun 10 2019 12:38:09