HDK
|
Template specialization of the ValueAccessor with no mutex and one cache level. More...
#include <ValueAccessor.h>
Public Member Functions | |
ValueAccessor (TreeType &tree) | |
ValueAccessor (const ValueAccessor &other) | |
virtual | ~ValueAccessor () |
![]() | |
HBOOST_STATIC_ASSERT (_TreeType::DEPTH >=2) | |
HBOOST_STATIC_ASSERT (0< _TreeType::RootNodeType::LEVEL) | |
ValueAccessor1 (TreeType &tree) | |
Constructor from a tree. More... | |
ValueAccessor1 (const ValueAccessor1 &other) | |
Copy constructor. More... | |
ValueAccessor1 & | operator= (const ValueAccessor1 &other) |
Asignment operator. More... | |
virtual | ~ValueAccessor1 () |
Virtual destructor. More... | |
bool | isCached (const Coord &xyz) const |
const ValueType & | getValue (const Coord &xyz) const |
Return the value of the voxel at the given coordinates. More... | |
bool | isValueOn (const Coord &xyz) const |
Return the active state of the voxel at the given coordinates. More... | |
bool | probeValue (const Coord &xyz, ValueType &value) const |
Return the active state of the voxel as well as its value. More... | |
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 but don't change its value. More... | |
void | setValueOnly (const Coord &xyz, const ValueType &value) |
Set the value of the voxel at the given coordinate but preserves its active state. More... | |
void | setValueOff (const Coord &xyz, const ValueType &value) |
Set the value of the voxel at the given coordinates and mark the voxel as inactive. More... | |
void | setValueOff (const Coord &xyz) |
Mark the voxel at the given coordinates as inactive but don't change its value. More... | |
void | modifyValue (const Coord &xyz, const ModifyOp &op) |
Apply a functor to the value of the voxel at the given coordinates and mark the voxel as active. More... | |
void | modifyValueAndActiveState (const Coord &xyz, const ModifyOp &op) |
Apply a functor to the voxel at the given coordinates. More... | |
void | setActiveState (const Coord &xyz, bool on=true) |
Set the active state of the voxel at the given coordinates but don't change its value. More... | |
NodeT * | getNode () |
Return the cached node of type NodeType. [Mainly for internal use]. More... | |
void | insertNode (const Coord &xyz, NodeT &node) |
void | eraseNode () |
void | addLeaf (LeafNodeT *leaf) |
Add the specified leaf to this tree, possibly creating a child branch in the process. If the leaf node already exists, replace it. More... | |
void | addTile (Index level, const Coord &xyz, const ValueType &value, bool state) |
Add a tile at the specified tree level that contains voxel (x, y, z), possibly deleting existing nodes or creating new nodes in the process. More... | |
LeafNodeT * | touchLeaf (const Coord &xyz) |
NodeT * | probeNode (const Coord &xyz) |
LeafNodeT * | probeLeaf (const Coord &xyz) |
const LeafNodeT * | probeLeaf (const Coord &xyz) const |
const NodeT * | probeConstNode (const Coord &xyz) const |
const LeafNodeT * | probeConstLeaf (const Coord &xyz) const |
virtual void | clear () |
Remove all the cached nodes and invalidate the corresponding hash-keys. More... | |
void | setValue (const Coord &xyz, const ValueType &value) |
Set the value of the voxel at the given coordinates and mark the voxel as active. More... | |
void | setValueOn (const Coord &xyz, const ValueType &value) |
Set the value of the voxel at the given coordinates and mark the voxel as active. More... | |
![]() | |
ValueAccessorBase (_TreeType &tree) | |
ValueAccessorBase (const ValueAccessorBase &other) | |
virtual | ~ValueAccessorBase () |
_TreeType * | getTree () const |
Return a pointer to the tree associated with this accessor. More... | |
_TreeType & | tree () const |
Return a reference to the tree associated with this accessor. More... | |
ValueAccessorBase & | operator= (const ValueAccessorBase &other) |
Additional Inherited Members | |
![]() | |
typedef _TreeType | TreeType |
typedef TreeType::ValueType | ValueType |
typedef TreeType::RootNodeType | RootNodeT |
typedef TreeType::LeafNodeType | LeafNodeT |
typedef ValueAccessorBase < TreeType, IsSafe > | BaseT |
typedef RootNodeT::NodeChainType | InvTreeT |
typedef hboost::mpl::at < InvTreeT, hboost::mpl::int_ < 0 > >::type | NodeT0 |
![]() | |
static Index | numCacheLevels () |
Return the number of cache levels employed by this ValueAccessor. More... | |
![]() | |
static bool | isSafe () |
Return true if this accessor is safe, i.e. registered by the tree from which it is constructed. Un-registered accessors can in rare cases be faster because it avoids the (small) overhead of registration, but they are unsafe if the tree is modified. So unless you're an expert it is highly recommended to set IsSafe = true (which is the default). More... | |
![]() | |
static const bool | IsConstTree |
![]() | |
_TreeType * | mTree |
Template specialization of the ValueAccessor with no mutex and one cache level.
Definition at line 501 of file ValueAccessor.h.
|
inline |
Definition at line 505 of file ValueAccessor.h.
|
inline |
Definition at line 506 of file ValueAccessor.h.
|
inlinevirtual |
Definition at line 507 of file ValueAccessor.h.