Loading...
Searching...
No Matches
LeafBuffer< bool, Log2Dim > Class Template Reference

`#include <openvdb/tree/LeafBuffer.h>`

## Public Types

using | NodeMaskType = util::NodeMask<Log2Dim>
using | WordType = typename NodeMaskType::Word
using | ValueType = bool
using | StorageType = WordType

## Public Member Functions

| LeafBuffer ()
| LeafBuffer (bool on)
| LeafBuffer (const NodeMaskType &other)
| LeafBuffer (const LeafBuffer &other)
| ~LeafBuffer ()
void | fill (bool val)
LeafBuffer & | operator= (const LeafBuffer &b)
const bool & | getValue (Index i) const
const bool & | operator[] (Index i) const
bool | operator== (const LeafBuffer &other) const
bool | operator!= (const LeafBuffer &other) const
void | setValue (Index i, bool val)
void | swap (LeafBuffer &other)
Index | memUsage () const
Index | memUsageIfLoaded () const
WordType * | data ()
| Return a pointer to the C-style array of words encoding the bits.
const WordType * | data () const
| Return a const pointer to the C-style array of words encoding the bits.
bool | isOutOfCore () const
| Return `true` if this buffer's values have not yet been read from disk.
bool | empty () const
| Return `true` if memory for this buffer has not yet been allocated.
bool | allocate ()
| Allocate memory for this buffer if it has not already been allocated.

## Static Public Member Functions

static Index | size ()

## Static Public Attributes

static const Index | WORD_COUNT = NodeMaskType::WORD_COUNT
static const Index | SIZE = 1 << 3 * Log2Dim
static const bool | sOn
static const bool | sOff

## Friends

template<typename, Index>
class | LeafNode
class | ::TestLeaf

## Member Typedef Documentation

## NodeMaskType

template<Index Log2Dim>

using NodeMaskType = util::NodeMask<Log2Dim>

## StorageType

template<Index Log2Dim>

using StorageType = WordType

## ValueType

template<Index Log2Dim>

using ValueType = bool

## WordType

template<Index Log2Dim>

using WordType = typename NodeMaskType::Word

## Constructor & Destructor Documentation

## LeafBuffer() [1/4]

template<Index Log2Dim>

LeafBuffer | ( |  | ) |

inline

## LeafBuffer() [2/4]

template<Index Log2Dim>

LeafBuffer | ( | bool | on | ) |

inline

## LeafBuffer() [3/4]

template<Index Log2Dim>

LeafBuffer | ( | const NodeMaskType & | other | ) |

inline

## LeafBuffer() [4/4]

template<Index Log2Dim>

LeafBuffer | ( | const LeafBuffer< bool, Log2Dim > & | other | ) |

inline

## ~LeafBuffer()

template<Index Log2Dim>

~LeafBuffer | ( |  | ) |

inline

## Member Function Documentation

## allocate()

bool allocate | ( |  | ) |

inline

Allocate memory for this buffer if it has not already been allocated.

## data() [1/2]

template<Index Log2Dim>

WordType * data | ( |  | ) |

inline

Return a pointer to the C-style array of words encoding the bits.

Warning
  This method should only be used by experts seeking low-level optimizations.

## data() [2/2]

template<Index Log2Dim>

const WordType * data | ( |  | ) | const

inline

Return a const pointer to the C-style array of words encoding the bits.

Warning
  This method should only be used by experts seeking low-level optimizations.

## empty()

bool empty | ( |  | ) | const

inline

Return `true` if memory for this buffer has not yet been allocated.

## fill()

template<Index Log2Dim>

void fill | ( | bool | val | ) |

inline

## getValue()

template<Index Log2Dim>

const bool & getValue | ( | Index | i | ) | const

inline

## isOutOfCore()

bool isOutOfCore | ( |  | ) | const

inline

Return `true` if this buffer's values have not yet been read from disk.

## memUsage()

template<Index Log2Dim>

Index memUsage | ( |  | ) | const

inline

## memUsageIfLoaded()

template<Index Log2Dim>

Index memUsageIfLoaded | ( |  | ) | const

inline

## operator!=()

template<Index Log2Dim>

bool operator!= | ( | const LeafBuffer< bool, Log2Dim > & | other | ) | const

inline

## operator=()

template<Index Log2Dim>

LeafBuffer & operator= | ( | const LeafBuffer< bool, Log2Dim > & | b | ) |

inline

## operator==()

template<Index Log2Dim>

bool operator== | ( | const LeafBuffer< bool, Log2Dim > & | other | ) | const

inline

## operator[]()

template<Index Log2Dim>

const bool & operator[] | ( | Index | i | ) | const

inline

## setValue()

template<Index Log2Dim>

void setValue | ( | Index | i,
|  | bool | val )

inline

## size()

template<Index Log2Dim>

Index size | ( |  | ) |

inline static

## swap()

template<Index Log2Dim>

void swap | ( | LeafBuffer< bool, Log2Dim > & | other | ) |

inline

## Friends And Related Symbol Documentation

## ::TestLeaf

friend class ::TestLeaf

friend

## LeafNode

template<Index Log2Dim>
template<typename, Index>

friend class LeafNode

friend

## Member Data Documentation

## SIZE

template<Index Log2Dim>

const Index SIZE = 1 << 3 * Log2Dim

static

## sOff

template<Index Log2Dim>

const bool sOff

static

## sOn

template<Index Log2Dim>

const bool sOn

static

## WORD_COUNT

template<Index Log2Dim>

const Index WORD_COUNT = NodeMaskType::WORD_COUNT

static