This base class for ValueAccessors manages registration of an accessor with a tree so that the tree can automatically clear the accessor whenever one of its nodes is deleted.
More...
#include <openvdb/tree/ValueAccessor.h>
Inherited by ValueAccessorImpl< const PointIndexTree >, ValueAccessorImpl< TreeT >, ValueAccessorImpl< const TreeType, IsSafe >, ValueAccessorImpl< const TreeT, false >, ValueAccessorImpl< const TreeT >, ValueAccessorImpl< IntTreeT >, and ValueAccessorImpl< TreeType >.
|
static constexpr 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 constexpr bool | IsConstTree = std::is_const<TreeType>::value |
| Returns true if this accessor is operating on a const tree type. More...
|
|
|
template<typename > |
class | Tree |
|
template<typename TreeType, bool IsSafe>
class openvdb::v11_0::tree::ValueAccessorBase< TreeType, IsSafe >
This base class for ValueAccessors manages registration of an accessor with a tree so that the tree can automatically clear the accessor whenever one of its nodes is deleted.
◆ ValueAccessorBase() [1/2]
Construct from a tree. Should rarely be invoked directly, the drived implementation class calls this. Remains public for backwards compatibility.
◆ ~ValueAccessorBase()
◆ ValueAccessorBase() [2/2]
Copy constructor - if IsSafe, then the copy also registers itself against the tree it is accessing.
◆ clear()
Pure virtual method, clears the derived accessor.
Implemented in ValueAccessorImpl< _TreeType, IsSafe, MutexT, IntegerSequence >, ValueAccessorImpl< const PointIndexTree >, ValueAccessorImpl< TreeT >, ValueAccessorImpl< const TreeType, IsSafe >, ValueAccessorImpl< const TreeT, false >, ValueAccessorImpl< const TreeT >, ValueAccessorImpl< IntTreeT >, and ValueAccessorImpl< TreeType >.
◆ getTree()
TreeType* getTree |
( |
| ) |
const |
|
inline |
Return a pointer to the tree associated with this accessor.
The pointer will be null only if the tree from which this accessor was constructed was subsequently deleted (which generally leaves the accessor in an unsafe state).
◆ isSafe()
static constexpr bool isSafe |
( |
| ) |
|
|
inlinestaticconstexpr |
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).
◆ operator=()
◆ release()
Reimplemented in ValueAccessorImpl< _TreeType, IsSafe, MutexT, IntegerSequence >, ValueAccessorImpl< const PointIndexTree >, ValueAccessorImpl< TreeT >, ValueAccessorImpl< const TreeType, IsSafe >, ValueAccessorImpl< const TreeT, false >, ValueAccessorImpl< const TreeT >, ValueAccessorImpl< IntTreeT >, and ValueAccessorImpl< TreeType >.
◆ tree()
Return a reference to the tree associated with this accessor.
◆ Tree
◆ IsConstTree
constexpr bool IsConstTree = std::is_const<TreeType>::value |
|
staticconstexpr |
Returns true if this accessor is operating on a const tree type.
◆ mTree