version 3.3

VRS::StaticQuadtree< CONTENT > Class Template Reference

#include <vrs/container/quadtree.h>

Inheritance diagram for VRS::StaticQuadtree< CONTENT >:

VRS::StaticSpaceTree< CONTENT, 2 > VRS::SpaceTree< NODE, DIM > VRS::SharedObj VRS::Visitable

List of all members.

Public Types

typedef SpaceTreePath< 2 > Path
typedef StaticSpaceTree
< CONTENT, 2 >::NodePointer 
NodePointer

Public Member Functions

 StaticQuadtree (const Vector &p1, const Vector &p2, UINT depth, const Vector &xAxis=Vector(1, 0, 0), const Vector &yAxis=Vector(0, 1, 0))
SpaceTreePath< 2 > findContainingNode (const Vector &point, UINT level, bool mustExist=true)
Iterator< SpaceTreePath< 2 > > * findBoundsIntersectingNodes (const Bounds &bounds, UINT level, bool mustExist=true)
SpaceTreePath< 2 > findSmallestBoundsEnclosingNode (const Bounds &bounds, UINT maxLevel=16, bool mustExist=true)
virtual QuadtreeCell getQuadtreeCell (const Path &path)
virtual QuadtreeCell getQuadtreeCell (const NodePointer &np)
const MatrixgetTransform ()
const MatrixgetInverseTransform ()

template<typename CONTENT>
class VRS::StaticQuadtree< CONTENT >


Member Typedef Documentation

template<typename CONTENT>
typedef SpaceTreePath<2> VRS::StaticQuadtree< CONTENT >::Path

The original declaration of the following methods are part of a quite unreadable code section that need not to be read to understand how to use a SpaceTree. Therefore their declarations are repeated here: template<typename POINTSET,typename INCLUSIONTEST> SpaceTreePath<DIM> findSmallestEnclosingNode( const POINTSET& pointSet, UINT maxLevel = Path::MaxPathLength(), bool mustExist = true, INCLUSIONTEST test = DefaultInclusionTest<POINTSET>()); Returns the longest path that leads to a node whose cell completely encloses a given point set. If the path length attains "maxLevel", the search is aborted and the path of length maxLevel is returned. Not that the length of a path cannot exceed Path::MaxPathLength(). If "mustExist" is true, only existing nodes are considered. Otherwise the result can be a path leading to a still not existing node, whose cell would enclose the point set. The parameter "test" is a function object that provides an operator() with two parameters pointSet and cell, that returns true if the pointSet is contained in the cell. You can see how to realize the function object on the example of the DefaultIntersectionTest class (see below). If POINTSET provides a method isContainedIn(Cell), the test parameter can be left out. template<typename POINTSET, typename INTERSECTIONTEST> Iterator<SpaceTreePath<DIM> >* findIntersectingNodes( const POINTSET& pointSet, UINT level, bool mustExist = true, INTERSECTIONTEST test = DefaultIntersectionTest<POINTSET>()); Returns an iterator of paths to all nodes on a specified tree level that intersect a given point set. For the "mustExist" parameter see above. The intersection test of a point set and a cell is performed similar to the inclusion test above. The parameter "test" can be left out if POINTSET provides a method intersects(Cell). template<typename POINTSET, typename INCLUSIONTEST> Iterator<SpaceTreePath<DIM> >* findEnclosingNodes( const POINTSET& pointSet, UINT level, bool mustExist, INCLUSIONTEST test) { This method is only useful for derivates of SpaceTree that enable overlapping cells. Otherwise the result is empty or contains exactly one element,

Reimplemented from VRS::StaticSpaceTree< CONTENT, 2 >.

template<typename CONTENT>
typedef StaticSpaceTree<CONTENT, 2>::NodePointer VRS::StaticQuadtree< CONTENT >::NodePointer


Constructor & Destructor Documentation

template<typename CONTENT>
VRS::StaticQuadtree< CONTENT >::StaticQuadtree ( const Vector p1,
const Vector p2,
UINT  depth,
const Vector xAxis = Vector(1, 0, 0),
const Vector yAxis = Vector(0, 1, 0) 
)


Member Function Documentation

template<typename CONTENT>
SpaceTreePath<2> VRS::StaticQuadtree< CONTENT >::findContainingNode ( const Vector point,
UINT  level,
bool  mustExist = true 
)

template<typename CONTENT>
Iterator<SpaceTreePath<2> >* VRS::StaticQuadtree< CONTENT >::findBoundsIntersectingNodes ( const Bounds bounds,
UINT  level,
bool  mustExist = true 
)

template<typename CONTENT>
SpaceTreePath<2> VRS::StaticQuadtree< CONTENT >::findSmallestBoundsEnclosingNode ( const Bounds bounds,
UINT  maxLevel = 16,
bool  mustExist = true 
)

template<typename CONTENT>
virtual QuadtreeCell VRS::StaticQuadtree< CONTENT >::getQuadtreeCell ( const Path path  )  [virtual]

template<typename CONTENT>
virtual QuadtreeCell VRS::StaticQuadtree< CONTENT >::getQuadtreeCell ( const NodePointer np  )  [virtual]

template<typename CONTENT>
const Matrix& VRS::StaticQuadtree< CONTENT >::getTransform (  ) 

template<typename CONTENT>
const Matrix& VRS::StaticQuadtree< CONTENT >::getInverseTransform (  ) 


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

Generated on Tue May 22 06:00:19 2012 by Doxygen 1.5.6
© 2001-2010 Hasso-Plattner-Institut | Impressum | Contact