HDK
|
#include <BV_Tree.h>
Public Types | |
enum | BV_Status { BV_PASS, BV_FAIL_ROTATIONS_UNSUPPORTED, BV_FAIL_BAD_TYPE, BV_FAIL } |
Public Member Functions | |
BV_Tree () | |
virtual | ~BV_Tree () |
BV_Tree * | clone () const |
virtual const char * | getType () const =0 |
virtual const BV_Tree * | castTo (const char *type) const |
virtual BV_Tree * | castTo (const char *type) |
int64 | getMemoryUsage () const |
int | getNumLeaves () const |
void | build (BV_LeafIterator &leafIt) |
Construct a volume hierarchy from the given primitives. More... | |
void | updateExtents (BV_LeafIterator &leafIt) |
void | save (std::ostream &os, bool onlyStructure) const |
bool | load (UT_IStream &is, bool onlyStructure) |
BV_Status | intersect (BV_Callback &callback, const BV_Tree &treeb, const UT_DMatrix4 &xforma, const UT_DMatrix4 &xformb, fpreal tol=0.001F) const |
BV_Status | intersect (BV_Callback &callback, const BV_Tree &treeb, fpreal tol=0.001F) const |
Static boxes only! More... | |
BV_Status | intersect (BV_Callback &callback, const BV_Tree &treeb, const UT_DMatrix4 &startxforma, const UT_DMatrix4 &startxformb, const UT_DMatrix4 &endxforma, const UT_DMatrix4 &endxformb, fpreal tol=0.001F) const |
Moving boxes only! More... | |
BV_Status | intersect (BV_Callback &callback, const BV_Tree &treeb, const UT_DMatrix4 &xforma, const UT_DMatrix4 &startxforma, const UT_DMatrix4 &startxformb, const UT_DMatrix4 &xformb, const UT_DMatrix4 &endxforma, const UT_DMatrix4 &endxformb, fpreal tol=0.001F) const |
Moving boxes only! More... | |
Protected Member Functions | |
BV_Tree (const BV_Tree &tree) | |
virtual BV_Tree * | cloneSubclass () const =0 |
virtual void | buildSubclass (BV_LeafIterator &leafIt)=0 |
virtual int64 | getMemoryUsageSubclass () const =0 |
virtual int | getNumLeavesSubclass () const =0 |
virtual void | saveSubclass (std::ostream &os, bool onlyStructure) const =0 |
virtual bool | loadSubclass (UT_IStream &is, bool onlyStructure)=0 |
virtual void | updateExtentsSubclass (BV_LeafIterator &leafIt)=0 |
virtual BV_Status | intersectSubclass (BV_Callback &callback, const BV_Tree &treeb, const UT_DMatrix4 &startxforma, const UT_DMatrix4 &startxformb, const UT_DMatrix4 &endxforma, const UT_DMatrix4 &endxformb, fpreal tol) const =0 |
Base class for bounding volume hierarchies. It's not really intended to be an all-encompassing base class; it's more intended as a rough template for other bounding volume classes to follow.
enum BV_Tree::BV_Status |
BV_Tree::BV_Tree | ( | ) |
|
virtual |
|
protected |
|
inline |
|
protectedpure virtual |
Implemented in BV_OBBTree, and BV_KDOPTree< K >.
|
virtual |
Reimplemented in BV_OBBTree, and BV_KDOPTree< K >.
|
virtual |
Reimplemented in BV_OBBTree, and BV_KDOPTree< K >.
|
protectedpure virtual |
Implemented in BV_OBBTree, and BV_KDOPTree< K >.
|
protectedpure virtual |
Implemented in BV_OBBTree, and BV_KDOPTree< K >.
|
protectedpure virtual |
Implemented in BV_OBBTree, and BV_KDOPTree< K >.
|
pure virtual |
Implemented in BV_OBBTree, and BV_KDOPTree< K >.
|
inline |
Find intersections of bounding volumes of this tree ("A") with tree B, rotated by ra and rb and translated by ta and tb respectively. For each intersection, call the callback with the leaves whose bounding volumes overlap.
The callback can return a "stop" status to stop testing for further intersections.
Note:
Static boxes only!
|
inline |
|
inline |
|
inline |
|
protectedpure virtual |
Implemented in BV_OBBTree, and BV_KDOPTree< K >.
|
inline |
|
protectedpure virtual |
Implemented in BV_OBBTree, and BV_KDOPTree< K >.
|
inline |
|
protectedpure virtual |
Implemented in BV_OBBTree, and BV_KDOPTree< K >.
|
inline |
|
protectedpure virtual |
Implemented in BV_OBBTree, and BV_KDOPTree< K >.