OpenVDB 11.0.0
|
VDB Tree, which is a thin wrapper around a RootNode. More...
#include <nanovdb/NanoVDB.h>
Public Types | |
using | DataType = TreeData |
using | RootType = RootT |
using | RootNodeType = RootT |
using | UpperNodeType = typename RootNodeType::ChildNodeType |
using | LowerNodeType = typename UpperNodeType::ChildNodeType |
using | LeafNodeType = typename RootType::LeafNodeType |
using | ValueType = typename RootT::ValueType |
using | BuildType = typename RootT::BuildType |
using | CoordType = typename RootT::CoordType |
using | AccessorType = DefaultReadAccessor<BuildType> |
using | Node3 = RootT |
using | Node2 = typename RootT::ChildNodeType |
using | Node1 = typename Node2::ChildNodeType |
using | Node0 = LeafNodeType |
Public Member Functions | |
Tree ()=delete | |
This class cannot be constructed or deleted. | |
Tree (const Tree &)=delete | |
Tree & | operator= (const Tree &)=delete |
~Tree ()=delete | |
DataType * | data () |
const DataType * | data () const |
RootT & | root () |
const RootT & | root () const |
AccessorType | getAccessor () const |
ValueType | getValue (const CoordType &ijk) const |
Return the value of the given voxel (regardless of state or location in the tree.) | |
ValueType | getValue (int i, int j, int k) const |
bool | isActive (const CoordType &ijk) const |
Return the active state of the given voxel (regardless of state or location in the tree.) | |
bool | probeValue (const CoordType &ijk, ValueType &v) const |
Return true if this tree is empty, i.e. contains no values or nodes. | |
const ValueType & | background () const |
Return a const reference to the background value. | |
void | extrema (ValueType &min, ValueType &max) const |
Sets the extrema values of all the active values in this tree, i.e. in all nodes of the tree. | |
uint64_t | activeVoxelCount () const |
Return a const reference to the index bounding box of all the active values in this tree, i.e. in all nodes of the tree. | |
const uint32_t & | activeTileCount (uint32_t level) const |
Return the total number of active tiles at the specified level of the tree. | |
template<typename NodeT > | |
uint32_t | nodeCount () const |
uint32_t | nodeCount (int level) const |
uint32_t | totalNodeCount () const |
template<typename NodeT > | |
NodeT * | getFirstNode () |
return a pointer to the first node of the specified type | |
template<typename NodeT > | |
const NodeT * | getFirstNode () const |
return a const pointer to the first node of the specified type | |
template<int LEVEL> | |
NodeTrait< RootT, LEVEL >::type * | getFirstNode () |
return a pointer to the first node at the specified level | |
template<int LEVEL> | |
const NodeTrait< RootT, LEVEL >::type * | getFirstNode () const |
return a const pointer to the first node of the specified level | |
LeafNodeType * | getFirstLeaf () |
Template specializations of getFirstNode. | |
const LeafNodeType * | getFirstLeaf () const |
NodeTrait< RootT, 1 >::type * | getFirstLower () |
const NodeTrait< RootT, 1 >::type * | getFirstLower () const |
NodeTrait< RootT, 2 >::type * | getFirstUpper () |
const NodeTrait< RootT, 2 >::type * | getFirstUpper () const |
template<typename OpT , typename... ArgsT> | |
auto | get (const CoordType &ijk, ArgsT &&... args) const |
template<typename OpT , typename... ArgsT> | |
auto | set (const CoordType &ijk, ArgsT &&... args) |
void | setRoot (const void *root) |
uint8_t * | getRoot () |
const uint8_t * | getRoot () const |
template<typename NodeT > | |
void | setFirstNode (const NodeT *node) |
bool | isEmpty () const |
CoordBBox | bbox () const |
Return the index bounding box of all the active values in this tree, i.e. in all nodes of the tree. | |
bool | isRootNext () const |
return true if RootData is layout out immediately after TreeData in memory | |
Static Public Member Functions | |
static uint64_t | memUsage () |
return memory usage in bytes for the class | |
Public Attributes | |
int64_t | mNodeOffset [4] |
uint32_t | mNodeCount [3] |
uint32_t | mTileCount [3] |
uint64_t | mVoxelCount |
using AccessorType = DefaultReadAccessor<BuildType> |
using BuildType = typename RootT::BuildType |
using CoordType = typename RootT::CoordType |
using LeafNodeType = typename RootType::LeafNodeType |
using LowerNodeType = typename UpperNodeType::ChildNodeType |
using Node0 = LeafNodeType |
using Node1 = typename Node2::ChildNodeType |
using Node2 = typename RootT::ChildNodeType |
using Node3 = RootT |
using RootNodeType = RootT |
using RootType = RootT |
using UpperNodeType = typename RootNodeType::ChildNodeType |
using ValueType = typename RootT::ValueType |
|
delete |
This class cannot be constructed or deleted.
|
delete |
|
inline |
Return the total number of active tiles at the specified level of the tree.
level = 1,2,3 corresponds to active tile count in lower internal nodes, upper internal nodes, and the root level. Note active values at the leaf level are referred to as active voxels (see activeVoxelCount defined above).
|
inline |
Return a const reference to the index bounding box of all the active values in this tree, i.e. in all nodes of the tree.
Return the total number of active voxels in this tree.
|
inline |
Return a const reference to the background value.
|
inlineinherited |
Return the index bounding box of all the active values in this tree, i.e. in all nodes of the tree.
|
inline |
|
inline |
Sets the extrema values of all the active values in this tree, i.e. in all nodes of the tree.
|
inline |
|
inline |
|
inline |
Template specializations of getFirstNode.
|
inline |
|
inline |
|
inline |
|
inline |
return a pointer to the first node of the specified type
|
inline |
return a pointer to the first node at the specified level
|
inline |
return a const pointer to the first node of the specified type
|
inline |
return a const pointer to the first node of the specified level
|
inline |
|
inline |
|
inlineinherited |
|
inlineinherited |
Return the value of the given voxel (regardless of state or location in the tree.)
|
inline |
|
inline |
Return the active state of the given voxel (regardless of state or location in the tree.)
|
inlineinherited |
|
inlineinherited |
|
inlinestatic |
return memory usage in bytes for the class
|
inline |
|
inline |
Return true if this tree is empty, i.e. contains no values or nodes.
Combines the previous two methods in a single call
|
inline |
|
inline |
|
inline |
|
inlineinherited |
|
inlineinherited |
|
inline |
|
inherited |
|
inherited |
|
inherited |
|
inherited |