OpenVDB  7.1.0
Public Types | Public Member Functions | Static Public Attributes | Protected Types | Friends | List of all members
PointIndexLeafNode< T, Log2Dim > Struct Template Reference

#include <PointIndexGrid.h>

Public Types

using LeafNodeType = PointIndexLeafNode< T, Log2Dim >
 
using Ptr = SharedPtr< PointIndexLeafNode >
 
using ValueType = T
 
using IndexArray = std::vector< ValueType >
 
using BaseLeaf = tree::LeafNode< T, Log2Dim >
 
using NodeMaskType = util::NodeMask< Log2Dim >
 
using ValueOnIter = typename BaseLeaf::template ValueIter< MaskOnIterator, PointIndexLeafNode, const ValueType, ValueOn >
 
using ValueOnCIter = typename BaseLeaf::template ValueIter< MaskOnIterator, const PointIndexLeafNode, const ValueType, ValueOn >
 
using ValueOffIter = typename BaseLeaf::template ValueIter< MaskOffIterator, PointIndexLeafNode, const ValueType, ValueOff >
 
using ValueOffCIter = typename BaseLeaf::template ValueIter< MaskOffIterator, const PointIndexLeafNode, const ValueType, ValueOff >
 
using ValueAllIter = typename BaseLeaf::template ValueIter< MaskDenseIterator, PointIndexLeafNode, const ValueType, ValueAll >
 
using ValueAllCIter = typename BaseLeaf::template ValueIter< MaskDenseIterator, const PointIndexLeafNode, const ValueType, ValueAll >
 
using ChildOnIter = typename BaseLeaf::template ChildIter< MaskOnIterator, PointIndexLeafNode, ChildOn >
 
using ChildOnCIter = typename BaseLeaf::template ChildIter< MaskOnIterator, const PointIndexLeafNode, ChildOn >
 
using ChildOffIter = typename BaseLeaf::template ChildIter< MaskOffIterator, PointIndexLeafNode, ChildOff >
 
using ChildOffCIter = typename BaseLeaf::template ChildIter< MaskOffIterator, const PointIndexLeafNode, ChildOff >
 
using ChildAllIter = typename BaseLeaf::template DenseIter< PointIndexLeafNode, ValueType, ChildAll >
 
using ChildAllCIter = typename BaseLeaf::template DenseIter< const PointIndexLeafNode, const ValueType, ChildAll >
 

Public Member Functions

IndexArrayindices ()
 
const IndexArrayindices () const
 
bool getIndices (const Coord &ijk, const ValueType *&begin, const ValueType *&end) const
 
bool getIndices (Index offset, const ValueType *&begin, const ValueType *&end) const
 
void setOffsetOn (Index offset, const ValueType &val)
 
void setOffsetOnly (Index offset, const ValueType &val)
 
bool isEmpty (const CoordBBox &bbox) const
 
 PointIndexLeafNode ()
 Default constructor. More...
 
 PointIndexLeafNode (const Coord &coords, const T &value=zeroVal< T >(), bool active=false)
 
 PointIndexLeafNode (PartialCreate, const Coord &coords, const T &value=zeroVal< T >(), bool active=false)
 
 PointIndexLeafNode (const PointIndexLeafNode &rhs)
 Deep copy constructor. More...
 
template<typename OtherType , Index OtherLog2Dim>
bool hasSameTopology (const PointIndexLeafNode< OtherType, OtherLog2Dim > *other) const
 Return true if the given node (which may have a different ValueType than this node) has the same active value topology as this node. More...
 
bool operator== (const PointIndexLeafNode &other) const
 Check for buffer, state and origin equivalence. More...
 
bool operator!= (const PointIndexLeafNode &other) const
 
template<MergePolicy Policy>
void merge (const PointIndexLeafNode &rhs)
 
template<MergePolicy Policy>
void merge (const ValueType &tileValue, bool tileActive)
 
template<MergePolicy Policy>
void merge (const PointIndexLeafNode &other, const ValueType &, const ValueType &)
 
void addLeaf (PointIndexLeafNode *)
 
template<typename AccessorT >
void addLeafAndCache (PointIndexLeafNode *, AccessorT &)
 
PointIndexLeafNodetouchLeaf (const Coord &)
 Return a pointer to this node. More...
 
template<typename AccessorT >
PointIndexLeafNodetouchLeafAndCache (const Coord &, AccessorT &)
 
template<typename NodeT , typename AccessorT >
NodeT * probeNodeAndCache (const Coord &, AccessorT &)
 
PointIndexLeafNodeprobeLeaf (const Coord &)
 
template<typename AccessorT >
PointIndexLeafNodeprobeLeafAndCache (const Coord &, AccessorT &)
 
const PointIndexLeafNodeprobeConstLeaf (const Coord &) const
 Return a const pointer to this node. More...
 
template<typename AccessorT >
const PointIndexLeafNodeprobeConstLeafAndCache (const Coord &, AccessorT &) const
 
template<typename AccessorT >
const PointIndexLeafNodeprobeLeafAndCache (const Coord &, AccessorT &) const
 
const PointIndexLeafNodeprobeLeaf (const Coord &) const
 
template<typename NodeT , typename AccessorT >
const NodeT * probeConstNodeAndCache (const Coord &, AccessorT &) const
 
void readBuffers (std::istream &is, bool fromHalf=false)
 
void readBuffers (std::istream &is, const CoordBBox &, bool fromHalf=false)
 
void writeBuffers (std::ostream &os, bool toHalf=false) const
 
Index64 memUsage () const
 
void assertNonmodifiable ()
 
void setActiveState (const Coord &, bool)
 
void setActiveState (Index, bool)
 
void setValueOnly (const Coord &, const ValueType &)
 
void setValueOnly (Index, const ValueType &)
 
void setValueOff (const Coord &)
 
void setValueOff (Index)
 
void setValueOff (const Coord &, const ValueType &)
 
void setValueOff (Index, const ValueType &)
 
void setValueOn (const Coord &)
 
void setValueOn (Index)
 
void setValueOn (const Coord &, const ValueType &)
 
void setValueOn (Index, const ValueType &)
 
void setValue (const Coord &, const ValueType &)
 
void setValuesOn ()
 
void setValuesOff ()
 
template<typename ModifyOp >
void modifyValue (Index, const ModifyOp &)
 
template<typename ModifyOp >
void modifyValue (const Coord &, const ModifyOp &)
 
template<typename ModifyOp >
void modifyValueAndActiveState (const Coord &, const ModifyOp &)
 
void clip (const CoordBBox &, const ValueType &)
 
void fill (const CoordBBox &, const ValueType &, bool)
 
void fill (const ValueType &)
 
void fill (const ValueType &, bool)
 
template<typename AccessorT >
void setValueOnlyAndCache (const Coord &, const ValueType &, AccessorT &)
 
template<typename ModifyOp , typename AccessorT >
void modifyValueAndActiveStateAndCache (const Coord &, const ModifyOp &, AccessorT &)
 
template<typename AccessorT >
void setValueOffAndCache (const Coord &, const ValueType &, AccessorT &)
 
template<typename AccessorT >
void setActiveStateAndCache (const Coord &, bool, AccessorT &)
 
void resetBackground (const ValueType &, const ValueType &)
 
void signedFloodFill (const ValueType &)
 
void signedFloodFill (const ValueType &, const ValueType &)
 
void negate ()
 
ValueOnCIter cbeginValueOn () const
 
ValueOnCIter beginValueOn () const
 
ValueOnIter beginValueOn ()
 
ValueOffCIter cbeginValueOff () const
 
ValueOffCIter beginValueOff () const
 
ValueOffIter beginValueOff ()
 
ValueAllCIter cbeginValueAll () const
 
ValueAllCIter beginValueAll () const
 
ValueAllIter beginValueAll ()
 
ValueOnCIter cendValueOn () const
 
ValueOnCIter endValueOn () const
 
ValueOnIter endValueOn ()
 
ValueOffCIter cendValueOff () const
 
ValueOffCIter endValueOff () const
 
ValueOffIter endValueOff ()
 
ValueAllCIter cendValueAll () const
 
ValueAllCIter endValueAll () const
 
ValueAllIter endValueAll ()
 
ChildOnCIter cbeginChildOn () const
 
ChildOnCIter beginChildOn () const
 
ChildOnIter beginChildOn ()
 
ChildOffCIter cbeginChildOff () const
 
ChildOffCIter beginChildOff () const
 
ChildOffIter beginChildOff ()
 
ChildAllCIter cbeginChildAll () const
 
ChildAllCIter beginChildAll () const
 
ChildAllIter beginChildAll ()
 
ChildOnCIter cendChildOn () const
 
ChildOnCIter endChildOn () const
 
ChildOnIter endChildOn ()
 
ChildOffCIter cendChildOff () const
 
ChildOffCIter endChildOff () const
 
ChildOffIter endChildOff ()
 
ChildAllCIter cendChildAll () const
 
ChildAllCIter endChildAll () const
 
ChildAllIter endChildAll ()
 

Static Public Attributes

static const Index LOG2DIM
 
static const Index TOTAL
 
static const Index DIM
 
static const Index NUM_VALUES
 
static const Index NUM_VOXELS
 
static const Index SIZE
 
static const Index LEVEL
 

Protected Types

using ValueOn = typename BaseLeaf::ValueOn
 
using ValueOff = typename BaseLeaf::ValueOff
 
using ValueAll = typename BaseLeaf::ValueAll
 
using ChildOn = typename BaseLeaf::ChildOn
 
using ChildOff = typename BaseLeaf::ChildOff
 
using ChildAll = typename BaseLeaf::ChildAll
 
using MaskOnIterator = typename NodeMaskType::OnIterator
 
using MaskOffIterator = typename NodeMaskType::OffIterator
 
using MaskDenseIterator = typename NodeMaskType::DenseIterator
 

Friends

template<typename , Index >
struct PointIndexLeafNode
 
class tree::IteratorBase< MaskOnIterator, PointIndexLeafNode >
 
class tree::IteratorBase< MaskOffIterator, PointIndexLeafNode >
 
class tree::IteratorBase< MaskDenseIterator, PointIndexLeafNode >
 

Member Typedef Documentation

◆ BaseLeaf

using BaseLeaf = tree::LeafNode<T, Log2Dim>

◆ ChildAll

using ChildAll = typename BaseLeaf::ChildAll
protected

◆ ChildAllCIter

using ChildAllCIter = typename BaseLeaf::template DenseIter< const PointIndexLeafNode, const ValueType, ChildAll>

◆ ChildAllIter

using ChildAllIter = typename BaseLeaf::template DenseIter< PointIndexLeafNode, ValueType, ChildAll>

◆ ChildOff

using ChildOff = typename BaseLeaf::ChildOff
protected

◆ ChildOffCIter

using ChildOffCIter = typename BaseLeaf::template ChildIter< MaskOffIterator, const PointIndexLeafNode, ChildOff>

◆ ChildOffIter

using ChildOffIter = typename BaseLeaf::template ChildIter< MaskOffIterator, PointIndexLeafNode, ChildOff>

◆ ChildOn

using ChildOn = typename BaseLeaf::ChildOn
protected

◆ ChildOnCIter

using ChildOnCIter = typename BaseLeaf::template ChildIter< MaskOnIterator, const PointIndexLeafNode, ChildOn>

◆ ChildOnIter

using ChildOnIter = typename BaseLeaf::template ChildIter< MaskOnIterator, PointIndexLeafNode, ChildOn>

◆ IndexArray

using IndexArray = std::vector<ValueType>

◆ LeafNodeType

using LeafNodeType = PointIndexLeafNode<T, Log2Dim>

◆ MaskDenseIterator

using MaskDenseIterator = typename NodeMaskType::DenseIterator
protected

◆ MaskOffIterator

using MaskOffIterator = typename NodeMaskType::OffIterator
protected

◆ MaskOnIterator

using MaskOnIterator = typename NodeMaskType::OnIterator
protected

◆ NodeMaskType

using NodeMaskType = util::NodeMask<Log2Dim>

◆ Ptr

◆ ValueAll

using ValueAll = typename BaseLeaf::ValueAll
protected

◆ ValueAllCIter

using ValueAllCIter = typename BaseLeaf::template ValueIter< MaskDenseIterator,const PointIndexLeafNode,const ValueType, ValueAll>

◆ ValueAllIter

using ValueAllIter = typename BaseLeaf::template ValueIter< MaskDenseIterator, PointIndexLeafNode, const ValueType, ValueAll>

◆ ValueOff

using ValueOff = typename BaseLeaf::ValueOff
protected

◆ ValueOffCIter

using ValueOffCIter = typename BaseLeaf::template ValueIter< MaskOffIterator,const PointIndexLeafNode,const ValueType, ValueOff>

◆ ValueOffIter

using ValueOffIter = typename BaseLeaf::template ValueIter< MaskOffIterator, PointIndexLeafNode, const ValueType, ValueOff>

◆ ValueOn

using ValueOn = typename BaseLeaf::ValueOn
protected

◆ ValueOnCIter

using ValueOnCIter = typename BaseLeaf::template ValueIter< MaskOnIterator, const PointIndexLeafNode, const ValueType, ValueOn>

◆ ValueOnIter

using ValueOnIter = typename BaseLeaf::template ValueIter< MaskOnIterator, PointIndexLeafNode, const ValueType, ValueOn>

◆ ValueType

using ValueType = T

Constructor & Destructor Documentation

◆ PointIndexLeafNode() [1/4]

PointIndexLeafNode ( )
inline

Default constructor.

◆ PointIndexLeafNode() [2/4]

PointIndexLeafNode ( const Coord coords,
const T &  value = zeroVal<T>(),
bool  active = false 
)
inlineexplicit

◆ PointIndexLeafNode() [3/4]

PointIndexLeafNode ( PartialCreate  ,
const Coord coords,
const T &  value = zeroVal<T>(),
bool  active = false 
)
inline

◆ PointIndexLeafNode() [4/4]

PointIndexLeafNode ( const PointIndexLeafNode< T, Log2Dim > &  rhs)
inline

Deep copy constructor.

Member Function Documentation

◆ addLeaf()

void addLeaf ( PointIndexLeafNode< T, Log2Dim > *  )
inline

◆ addLeafAndCache()

void addLeafAndCache ( PointIndexLeafNode< T, Log2Dim > *  ,
AccessorT &   
)
inline

◆ assertNonmodifiable()

void assertNonmodifiable ( )
inline

◆ beginChildAll() [1/2]

ChildAllIter beginChildAll ( )
inline

◆ beginChildAll() [2/2]

ChildAllCIter beginChildAll ( ) const
inline

◆ beginChildOff() [1/2]

ChildOffIter beginChildOff ( )
inline

◆ beginChildOff() [2/2]

ChildOffCIter beginChildOff ( ) const
inline

◆ beginChildOn() [1/2]

ChildOnIter beginChildOn ( )
inline

◆ beginChildOn() [2/2]

ChildOnCIter beginChildOn ( ) const
inline

◆ beginValueAll() [1/2]

ValueAllIter beginValueAll ( )
inline

◆ beginValueAll() [2/2]

ValueAllCIter beginValueAll ( ) const
inline

◆ beginValueOff() [1/2]

ValueOffIter beginValueOff ( )
inline

◆ beginValueOff() [2/2]

ValueOffCIter beginValueOff ( ) const
inline

◆ beginValueOn() [1/2]

ValueOnIter beginValueOn ( )
inline

◆ beginValueOn() [2/2]

ValueOnCIter beginValueOn ( ) const
inline

◆ cbeginChildAll()

ChildAllCIter cbeginChildAll ( ) const
inline

◆ cbeginChildOff()

ChildOffCIter cbeginChildOff ( ) const
inline

◆ cbeginChildOn()

ChildOnCIter cbeginChildOn ( ) const
inline

◆ cbeginValueAll()

ValueAllCIter cbeginValueAll ( ) const
inline

◆ cbeginValueOff()

ValueOffCIter cbeginValueOff ( ) const
inline

◆ cbeginValueOn()

ValueOnCIter cbeginValueOn ( ) const
inline

◆ cendChildAll()

ChildAllCIter cendChildAll ( ) const
inline

◆ cendChildOff()

ChildOffCIter cendChildOff ( ) const
inline

◆ cendChildOn()

ChildOnCIter cendChildOn ( ) const
inline

◆ cendValueAll()

ValueAllCIter cendValueAll ( ) const
inline

◆ cendValueOff()

ValueOffCIter cendValueOff ( ) const
inline

◆ cendValueOn()

ValueOnCIter cendValueOn ( ) const
inline

◆ clip()

void clip ( const CoordBBox ,
const ValueType  
)
inline

◆ endChildAll() [1/2]

ChildAllIter endChildAll ( )
inline

◆ endChildAll() [2/2]

ChildAllCIter endChildAll ( ) const
inline

◆ endChildOff() [1/2]

ChildOffIter endChildOff ( )
inline

◆ endChildOff() [2/2]

ChildOffCIter endChildOff ( ) const
inline

◆ endChildOn() [1/2]

ChildOnIter endChildOn ( )
inline

◆ endChildOn() [2/2]

ChildOnCIter endChildOn ( ) const
inline

◆ endValueAll() [1/2]

ValueAllIter endValueAll ( )
inline

◆ endValueAll() [2/2]

ValueAllCIter endValueAll ( ) const
inline

◆ endValueOff() [1/2]

ValueOffIter endValueOff ( )
inline

◆ endValueOff() [2/2]

ValueOffCIter endValueOff ( ) const
inline

◆ endValueOn() [1/2]

ValueOnIter endValueOn ( )
inline

◆ endValueOn() [2/2]

ValueOnCIter endValueOn ( ) const
inline

◆ fill() [1/3]

void fill ( const CoordBBox ,
const ValueType ,
bool   
)
inline

◆ fill() [2/3]

void fill ( const ValueType )
inline

◆ fill() [3/3]

void fill ( const ValueType ,
bool   
)
inline

◆ getIndices() [1/2]

bool getIndices ( const Coord ijk,
const ValueType *&  begin,
const ValueType *&  end 
) const
inline

◆ getIndices() [2/2]

bool getIndices ( Index  offset,
const ValueType *&  begin,
const ValueType *&  end 
) const
inline

◆ hasSameTopology()

bool hasSameTopology ( const PointIndexLeafNode< OtherType, OtherLog2Dim > *  other) const
inline

Return true if the given node (which may have a different ValueType than this node) has the same active value topology as this node.

◆ indices() [1/2]

IndexArray& indices ( )
inline

◆ indices() [2/2]

const IndexArray& indices ( ) const
inline

◆ isEmpty()

bool isEmpty ( const CoordBBox bbox) const
inline

◆ memUsage()

Index64 memUsage
inline

◆ merge() [1/3]

void merge ( const PointIndexLeafNode< T, Log2Dim > &  other,
const ValueType ,
const ValueType  
)
inline

◆ merge() [2/3]

void merge ( const PointIndexLeafNode< T, Log2Dim > &  rhs)
inline

◆ merge() [3/3]

void merge ( const ValueType tileValue,
bool  tileActive 
)
inline

◆ modifyValue() [1/2]

void modifyValue ( const Coord ,
const ModifyOp &   
)
inline

◆ modifyValue() [2/2]

void modifyValue ( Index  ,
const ModifyOp &   
)
inline

◆ modifyValueAndActiveState()

void modifyValueAndActiveState ( const Coord ,
const ModifyOp &   
)
inline

◆ modifyValueAndActiveStateAndCache()

void modifyValueAndActiveStateAndCache ( const Coord ,
const ModifyOp &  ,
AccessorT &   
)
inline

◆ negate()

void negate ( )
inline

◆ operator!=()

bool operator!= ( const PointIndexLeafNode< T, Log2Dim > &  other) const
inline

◆ operator==()

bool operator== ( const PointIndexLeafNode< T, Log2Dim > &  other) const
inline

Check for buffer, state and origin equivalence.

◆ probeConstLeaf()

const PointIndexLeafNode* probeConstLeaf ( const Coord ) const
inline

Return a const pointer to this node.

◆ probeConstLeafAndCache()

const PointIndexLeafNode* probeConstLeafAndCache ( const Coord ,
AccessorT &   
) const
inline

◆ probeConstNodeAndCache()

const NodeT* probeConstNodeAndCache ( const Coord ,
AccessorT &   
) const
inline

◆ probeLeaf() [1/2]

PointIndexLeafNode* probeLeaf ( const Coord )
inline

◆ probeLeaf() [2/2]

const PointIndexLeafNode* probeLeaf ( const Coord ) const
inline

◆ probeLeafAndCache() [1/2]

PointIndexLeafNode* probeLeafAndCache ( const Coord ,
AccessorT &   
)
inline

◆ probeLeafAndCache() [2/2]

const PointIndexLeafNode* probeLeafAndCache ( const Coord ,
AccessorT &   
) const
inline

◆ probeNodeAndCache()

NodeT* probeNodeAndCache ( const Coord ,
AccessorT &   
)
inline

◆ readBuffers() [1/2]

void readBuffers ( std::istream &  is,
bool  fromHalf = false 
)
inline

◆ readBuffers() [2/2]

void readBuffers ( std::istream &  is,
const CoordBBox bbox,
bool  fromHalf = false 
)
inline

◆ resetBackground()

void resetBackground ( const ValueType ,
const ValueType  
)
inline

◆ setActiveState() [1/2]

void setActiveState ( const Coord ,
bool   
)
inline

◆ setActiveState() [2/2]

void setActiveState ( Index  ,
bool   
)
inline

◆ setActiveStateAndCache()

void setActiveStateAndCache ( const Coord ,
bool  ,
AccessorT &   
)
inline

◆ setOffsetOn()

void setOffsetOn ( Index  offset,
const ValueType val 
)
inline

◆ setOffsetOnly()

void setOffsetOnly ( Index  offset,
const ValueType val 
)
inline

◆ setValue()

void setValue ( const Coord ,
const ValueType  
)
inline

◆ setValueOff() [1/4]

void setValueOff ( const Coord )
inline

◆ setValueOff() [2/4]

void setValueOff ( const Coord ,
const ValueType  
)
inline

◆ setValueOff() [3/4]

void setValueOff ( Index  )
inline

◆ setValueOff() [4/4]

void setValueOff ( Index  ,
const ValueType  
)
inline

◆ setValueOffAndCache()

void setValueOffAndCache ( const Coord ,
const ValueType ,
AccessorT &   
)
inline

◆ setValueOn() [1/4]

void setValueOn ( const Coord )
inline

◆ setValueOn() [2/4]

void setValueOn ( const Coord ,
const ValueType  
)
inline

◆ setValueOn() [3/4]

void setValueOn ( Index  )
inline

◆ setValueOn() [4/4]

void setValueOn ( Index  ,
const ValueType  
)
inline

◆ setValueOnly() [1/2]

void setValueOnly ( const Coord ,
const ValueType  
)
inline

◆ setValueOnly() [2/2]

void setValueOnly ( Index  ,
const ValueType  
)
inline

◆ setValueOnlyAndCache()

void setValueOnlyAndCache ( const Coord ,
const ValueType ,
AccessorT &   
)
inline

◆ setValuesOff()

void setValuesOff ( )
inline

◆ setValuesOn()

void setValuesOn ( )
inline

◆ signedFloodFill() [1/2]

void signedFloodFill ( const ValueType )
inline

◆ signedFloodFill() [2/2]

void signedFloodFill ( const ValueType ,
const ValueType  
)
inline

◆ touchLeaf()

PointIndexLeafNode* touchLeaf ( const Coord )
inline

Return a pointer to this node.

◆ touchLeafAndCache()

PointIndexLeafNode* touchLeafAndCache ( const Coord ,
AccessorT &   
)
inline

◆ writeBuffers()

void writeBuffers ( std::ostream &  os,
bool  toHalf = false 
) const
inline

Friends And Related Function Documentation

◆ PointIndexLeafNode

friend struct PointIndexLeafNode
friend

◆ tree::IteratorBase< MaskDenseIterator, PointIndexLeafNode >

◆ tree::IteratorBase< MaskOffIterator, PointIndexLeafNode >

◆ tree::IteratorBase< MaskOnIterator, PointIndexLeafNode >

Member Data Documentation

◆ DIM

const Index DIM
static

◆ LEVEL

const Index LEVEL
static

◆ LOG2DIM

const Index LOG2DIM
static

◆ NUM_VALUES

const Index NUM_VALUES
static

◆ NUM_VOXELS

const Index NUM_VOXELS
static

◆ SIZE

const Index SIZE
static

◆ TOTAL

const Index TOTAL
static

The documentation for this struct was generated from the following file: