OpenVDB
1.1.0
|
#include <ValueAccessor.h>
Inherits ValueAccessor0< TreeType >.
Public Types | |
typedef TreeType | TreeType |
typedef TreeType::ValueType | ValueType |
typedef TreeType::RootNodeType | RootNodeT |
typedef TreeType::LeafNodeType | LeafNodeT |
typedef ValueAccessorBase < TreeType > | BaseT |
Public Member Functions | |
ValueAccessor (TreeType &tree) | |
ValueAccessor (const ValueAccessor &other) | |
virtual | ~ValueAccessor () |
bool | isCached (const Coord &) const |
Return true if nodes along the path to the given voxel have been cached. | |
const ValueType & | getValue (const Coord &xyz) const |
Return the value of the voxel at the given coordinates. | |
bool | isValueOn (const Coord &xyz) const |
Return the active state of the voxel at the given coordinates. | |
bool | probeValue (const Coord &xyz, ValueType &value) const |
Return the active state of the voxel as well as its value. | |
int | getValueDepth (const Coord &xyz) const |
bool | isVoxel (const Coord &xyz) const |
void | setValueOn (const Coord &xyz) |
Mark the voxel at the given coordinates as active without changing its value. | |
void | setValueOnly (const Coord &xyz, const ValueType &value) |
Set the value of the voxel at the given coordinate but preserves its active state. | |
void | setValueOff (const Coord &xyz, const ValueType &value) |
Set the value of the voxel at the given coordinates and mark the voxel as inactive. | |
void | setValueOff (const Coord &xyz) |
Mark the voxel at the given coordinates as inactive without changing its value. | |
void | setValueOnSum (const Coord &xyz, const ValueType &value) |
void | setActiveState (const Coord &xyz, bool on=true) |
Set the active state of the voxel at the given coordinates without changing its value. | |
NodeT * | getNode () |
Return the cached node of type NodeType. [Mainly for internal use]. | |
void | insertNode (const Coord &, NodeT &) |
void | eraseNode () |
LeafNodeT * | touchLeaf (const Coord &xyz) |
LeafNodeT * | probeLeaf (const Coord &xyz) |
const LeafNodeT * | probeConstLeaf (const Coord &xyz) |
virtual void | clear () |
Remove all nodes from this cache, then reinsert the root node. | |
TreeType * | getTree () const |
void | setValue (const Coord &xyz, const ValueType &value) |
Set the value of the voxel at the given coordinates and mark the voxel as active. | |
void | setValueOn (const Coord &xyz, const ValueType &value) |
Set the value of the voxel at the given coordinates and mark the voxel as active. |
Static Public Member Functions | |
static Index | numCacheLevels () |
Return the number of cache levels employed by this ValueAccessor. |
Static Public Attributes | |
static const bool | IsConstTree = boost::is_const<TreeType>::value |
Protected Attributes | |
TreeType * | mTree |
Template specialization of the ValueAccessor with no mutex and no cache levels
|
inherited |
|
inherited |
|
inherited |
|
inherited |
|
inline |
|
inline |
|
inlinevirtual |
|
inlinevirtualinherited |
Remove all nodes from this cache, then reinsert the root node.
Implements ValueAccessorBase< TreeType >.
|
inlineinherited |
If a node of the given type exists in the cache, remove it, so that isCached(xyz) returns false
for any voxel (x, y, z) contained in that node. [Mainly for internal use]
|
inlineinherited |
Return the cached node of type NodeType. [Mainly for internal use].
|
inlineinherited |
Return the value of the voxel at the given coordinates.
|
inlineinherited |
Return the tree depth (0 = root) at which the value of voxel (x, y, z) resides, or -1 if (x, y, z) isn't explicitly represented in the tree (i.e., if it is implicitly a background voxel).
|
inlineinherited |
Cache the given node, which should lie along the path from the root node to the node containing voxel (x, y, z). [Mainly for internal use]
|
inlineinherited |
Return true
if nodes along the path to the given voxel have been cached.
|
inlineinherited |
Return the active state of the voxel at the given coordinates.
|
inlineinherited |
Return true
if the value of voxel (x, y, z) resides at the leaf level of the tree, i.e., if it is not a tile value.
|
inlinestaticinherited |
Return the number of cache levels employed by this ValueAccessor.
Return the active state of the voxel as well as its value.
|
inlineinherited |
Set the active state of the voxel at the given coordinates without changing its value.
Set the value of the voxel at the given coordinates and mark the voxel as active.
Set the value of the voxel at the given coordinates and mark the voxel as inactive.
|
inlineinherited |
Mark the voxel at the given coordinates as inactive without changing its value.
Set the value of the voxel at the given coordinates and mark the voxel as active.
|
inlineinherited |
Mark the voxel at the given coordinates as active without changing its value.
Set the value of the voxel at the given coordinate but preserves its active state.
Set the value of the voxel at the given coordinates to the sum of its current value and the given value, and mark the voxel as active.
|
staticinherited |
|
protectedinherited |