Loading...
Searching...
No Matches
NodeManager< BuildT > Class Template Reference

NodeManager allows for sequential access to nodes. More...

`#include <nanovdb/util/NodeManager.h>`

Inheritance diagram for NodeManager< BuildT >:

## Public Member Functions

| NodeManager (const NodeManager &)=delete
| NodeManager (NodeManager &&)=delete
NodeManager & | operator= (const NodeManager &)=delete
NodeManager & | operator= (NodeManager &&)=delete
| ~NodeManager ()=delete
bool | isLinear () const
| return true if the nodes have both fixed size and are arranged breadth-first in memory. This allows for direct and memory-efficient linear access to nodes.
uint64_t | memUsage () const
| Return the memory footprint in bytes of this instance.
GridT & | grid ()
| Return a reference to the grid.
const GridT & | grid () const
TreeT & | tree ()
| Return a reference to the tree.
const TreeT & | tree () const
RootT & | root ()
| Return a reference to the root.
const RootT & | root () const
uint64_t | nodeCount (int level) const
| Return the number of tree nodes at the specified level.
template<int LEVEL>
const NodeT< LEVEL > & | node (uint32_t i) const
| Return the i'th leaf node with respect to breadth-first ordering.
template<int LEVEL>
NodeT< LEVEL > & | node (uint32_t i)
| Return the i'th node with respect to breadth-first ordering.
const Node0 & | leaf (uint32_t i) const
| Return the i'th leaf node with respect to breadth-first ordering.
Node0 & | leaf (uint32_t i)
const Node1 & | lower (uint32_t i) const
| Return the i'th lower internal node with respect to breadth-first ordering.
Node1 & | lower (uint32_t i)
const Node2 & | upper (uint32_t i) const
| Return the i'th upper internal node with respect to breadth-first ordering.
Node2 & | upper (uint32_t i)

## Static Public Member Functions

static bool | isLinear (const GridT &grid)
| return true if the nodes have both fixed size and are arranged breadth-first in memory. This allows for direct and memory-efficient linear access to nodes.
static uint64_t | memUsage (const GridT &grid)
| Return the memory footprint in bytes of the NodeManager derived from the specified grid.

## Detailed Description

template<typename BuildT>
class nanovdb::NodeManager< BuildT >

NodeManager allows for sequential access to nodes.

This class allows for sequential access to nodes in a NanoVDB tree.

Nodes are always arranged breadth first during sequential access of nodes at a particular level.

## Constructor & Destructor Documentation

## NodeManager() [1/2]

template<typename BuildT>

NodeManager | ( | const NodeManager< BuildT > & |  | ) |

delete

## NodeManager() [2/2]

template<typename BuildT>

NodeManager | ( | NodeManager< BuildT > && |  | ) |

delete

## ~NodeManager()

template<typename BuildT>

~NodeManager | ( |  | ) |

delete

## Member Function Documentation

## grid() [1/2]

template<typename BuildT>

GridT & grid | ( |  | ) |

inline

Return a reference to the grid.

## grid() [2/2]

template<typename BuildT>

const GridT & grid | ( |  | ) | const

inline

## isLinear() [1/2]

template<typename BuildT>

bool isLinear | ( |  | ) | const

inline

return true if the nodes have both fixed size and are arranged breadth-first in memory. This allows for direct and memory-efficient linear access to nodes.

## isLinear() [2/2]

template<typename BuildT>

bool isLinear | ( | const GridT & | grid | ) |

inline static

return true if the nodes have both fixed size and are arranged breadth-first in memory. This allows for direct and memory-efficient linear access to nodes.

## leaf() [1/2]

template<typename BuildT>

Node0 & leaf | ( | uint32_t | i | ) |

inline

## leaf() [2/2]

template<typename BuildT>

const Node0 & leaf | ( | uint32_t | i | ) | const

inline

Return the i'th leaf node with respect to breadth-first ordering.

## lower() [1/2]

template<typename BuildT>

Node1 & lower | ( | uint32_t | i | ) |

inline

## lower() [2/2]

template<typename BuildT>

const Node1 & lower | ( | uint32_t | i | ) | const

inline

Return the i'th lower internal node with respect to breadth-first ordering.

## memUsage() [1/2]

template<typename BuildT>

uint64_t memUsage | ( |  | ) | const

inline

Return the memory footprint in bytes of this instance.

## memUsage() [2/2]

template<typename BuildT>

uint64_t memUsage | ( | const GridT & | grid | ) |

inline static

Return the memory footprint in bytes of the NodeManager derived from the specified grid.

## node() [1/2]

template<typename BuildT>
template<int LEVEL>

NodeT< LEVEL > & node | ( | uint32_t | i | ) |

inline

Return the i'th node with respect to breadth-first ordering.

## node() [2/2]

template<typename BuildT>
template<int LEVEL>

const NodeT< LEVEL > & node | ( | uint32_t | i | ) | const

inline

Return the i'th leaf node with respect to breadth-first ordering.

## nodeCount()

template<typename BuildT>

uint64_t nodeCount | ( | int | level | ) | const

inline

Return the number of tree nodes at the specified level.

0 is leaf, 1 is lower internal, and 2 is upper internal level

## operator=() [1/2]

template<typename BuildT>

NodeManager & operator= | ( | const NodeManager< BuildT > & |  | ) |

delete

## operator=() [2/2]

template<typename BuildT>

NodeManager & operator= | ( | NodeManager< BuildT > && |  | ) |

delete

## root() [1/2]

template<typename BuildT>

RootT & root | ( |  | ) |

inline

Return a reference to the root.

## root() [2/2]

template<typename BuildT>

const RootT & root | ( |  | ) | const

inline

## tree() [1/2]

template<typename BuildT>

TreeT & tree | ( |  | ) |

inline

Return a reference to the tree.

## tree() [2/2]

template<typename BuildT>

const TreeT & tree | ( |  | ) | const

inline

## upper() [1/2]

template<typename BuildT>

Node2 & upper | ( | uint32_t | i | ) |

inline

## upper() [2/2]

template<typename BuildT>

const Node2 & upper | ( | uint32_t | i | ) | const

inline

Return the i'th upper internal node with respect to breadth-first ordering.