Blender V2.61 - r43446
Public Member Functions | Public Attributes

BVHNode Class Reference

#include <bvh_node.h>

Inheritance diagram for BVHNode:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 BVHNode ()
virtual ~BVHNode ()
virtual bool is_leaf () const =0
virtual int num_children () const =0
virtual BVHNodeget_child (int i) const =0
virtual int num_triangles () const
virtual void print (int depth=0) const =0
float getArea () const
int getSubtreeSize (BVH_STAT stat=BVH_STAT_NODE_COUNT) const
float computeSubtreeSAHCost (const BVHParams &p, float probability=1.0f) const
void deleteSubtree ()

Public Attributes

struct BVHNode ** children
struct BVHNodeparent
struct BVHNodeskip [2]
float * bv
int index
char totnode
char main_axis
BoundBox m_bounds
uint m_visibility

Detailed Description

Definition at line 53 of file BLI_kdopbvh.c.


Constructor & Destructor Documentation

BVHNode::BVHNode ( ) [inline]

Definition at line 41 of file bvh_node.h.

virtual BVHNode::~BVHNode ( ) [inline, virtual]

Definition at line 45 of file bvh_node.h.


Member Function Documentation

float BVHNode::computeSubtreeSAHCost ( const BVHParams p,
float  probability = 1.0f 
) const
void BVHNode::deleteSubtree ( )

Definition at line 59 of file bvh_node.cpp.

References deleteSubtree(), get_child(), i, and num_children().

Referenced by BVH::build(), BVHBuild::build_node(), and deleteSubtree().

virtual BVHNode* BVHNode::get_child ( int  i) const [pure virtual]
float BVHNode::getArea ( ) const [inline]

Definition at line 52 of file bvh_node.h.

References BoundBox::area(), and m_bounds.

CCL_NAMESPACE_BEGIN int BVHNode::getSubtreeSize ( BVH_STAT  stat = BVH_STAT_NODE_COUNT) const
virtual bool BVHNode::is_leaf ( ) const [pure virtual]

Implemented in InnerNode, and LeafNode.

Referenced by getSubtreeSize(), and QBVH::pack_nodes().

virtual int BVHNode::num_children ( ) const [pure virtual]

Implemented in InnerNode, and LeafNode.

Referenced by computeSubtreeSAHCost(), deleteSubtree(), and getSubtreeSize().

virtual int BVHNode::num_triangles ( ) const [inline, virtual]

Reimplemented in LeafNode.

Definition at line 49 of file bvh_node.h.

Referenced by computeSubtreeSAHCost(), and getSubtreeSize().

virtual void BVHNode::print ( int  depth = 0) const [pure virtual]

Implemented in InnerNode, and LeafNode.

Referenced by InnerNode::print().


Member Data Documentation

float* BVHNode::bv

Definition at line 55 of file bvh_node.h.

Referenced by InnerNode::InnerNode(), LeafNode::LeafNode(), and RegularBVH::pack_leaf().

Definition at line 61 of file BLI_kdopbvh.c.

Referenced by dfs_find_nearest_dfs(), dfs_raycast(), and non_recursive_bvh_div_nodes().

Definition at line 56 of file BLI_kdopbvh.c.

Referenced by non_recursive_bvh_div_nodes().

struct BVHNode* BVHNode::skip[2]

Definition at line 57 of file BLI_kdopbvh.c.

Referenced by build_skip_links().


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