On this page
Octree iterator class More...
#include <pcl/octree/octree_iterator.h>
Public Types |
|
using | LeafNode = typename OctreeIteratorBase< OctreeT >::LeafNode |
using | BranchNode = typename OctreeIteratorBase< OctreeT >::BranchNode |
using | iterator_category = std::forward_iterator_tag |
using | value_type = const OctreeNode |
using | difference_type = void |
using | pointer = const OctreeNode * |
using | reference = const OctreeNode & |
using | LeafNode = typename OctreeT::LeafNode |
using | BranchNode = typename OctreeT::BranchNode |
using | LeafContainer = typename OctreeT::LeafContainer |
using | BranchContainer = typename OctreeT::BranchContainer |
Public Member Functions |
|
OctreeDepthFirstIterator (uindex_t max_depth_arg=0) | |
Empty constructor. More... |
|
OctreeDepthFirstIterator (OctreeT *octree_arg, uindex_t max_depth_arg=0) | |
Constructor. More... |
|
OctreeDepthFirstIterator (OctreeT *octree_arg, uindex_t max_depth_arg, IteratorState *current_state, const std::vector< IteratorState > &stack=std::vector< IteratorState >()) | |
Constructor. More... |
|
OctreeDepthFirstIterator (const OctreeDepthFirstIterator &other) | |
Copy Constructor. More... |
|
OctreeDepthFirstIterator & | operator= (const OctreeDepthFirstIterator &src) |
Copy assignment. More... |
|
virtual void | reset () |
Reset the iterator to the root node of the octree. More... |
|
OctreeDepthFirstIterator & | operator++ () |
Preincrement operator. More... |
|
OctreeDepthFirstIterator | operator++ (int) |
postincrement operator. More... |
|
void | skipChildVoxels () |
Skip all child voxels of current node and return to parent node. More... |
|
OctreeIteratorBase () | |
Empty constructor. More... |
|
OctreeIteratorBase (uindex_t max_depth_arg) | |
Constructor. More... |
|
OctreeIteratorBase (OctreeT *octree_arg) | |
Constructor. More... |
|
OctreeIteratorBase (OctreeT *octree_arg, uindex_t max_depth_arg) | |
Constructor. More... |
|
OctreeIteratorBase (OctreeT *octree_arg, uindex_t max_depth_arg, IteratorState *current_state) | |
Constructor. More... |
|
virtual | ~OctreeIteratorBase ()=default |
Empty deconstructor. More... |
|
bool | operator== (const OctreeIteratorBase &other) const |
Equal comparison operator. More... |
|
bool | operator!= (const OctreeIteratorBase &other) const |
Inequal comparison operator. More... |
|
void | reset () |
Reset iterator. More... |
|
const OctreeKey & | getCurrentOctreeKey () const |
Get octree key for the current iterator octree node. More... |
|
uindex_t | getCurrentOctreeDepth () const |
Get the current depth level of octree. More... |
|
OctreeNode * | getCurrentOctreeNode () const |
Get the current octree node. More... |
|
bool | isBranchNode () const |
check if current node is a branch node More... |
|
bool | isLeafNode () const |
check if current node is a branch node More... |
|
virtual OctreeNode * | operator* () const |
*operator. More... |
|
char | getNodeConfiguration () const |
Get bit pattern of children configuration of current node. More... |
|
const LeafContainer & | getLeafContainer () const |
Method for retrieving a single leaf container from the octree leaf node. More... |
|
LeafContainer & | getLeafContainer () |
Method for retrieving a single leaf container from the octree leaf node. More... |
|
const BranchContainer & | getBranchContainer () const |
Method for retrieving the container from an octree branch node. More... |
|
BranchContainer & | getBranchContainer () |
Method for retrieving the container from an octree branch node. More... |
|
virtual unsigned long | getNodeID () const |
get a integer identifier for current node (note: identifier depends on tree depth). More... |
|
Protected Attributes |
|
std::vector< IteratorState > | stack_ |
Stack structure. More... |
|
OctreeT * | octree_ |
Reference to octree class. More... |
|
IteratorState * | current_state_ |
Pointer to current iterator state. More... |
|
uindex_t | max_octree_depth_ |
Maximum octree depth. More... |
|
Detailed Description
template<typename OctreeT>
class pcl::octree::OctreeDepthFirstIterator< OctreeT >
Octree iterator class
- Note
- This class implements a forward iterator for traversing octrees in a depth-first manner.
Definition at line 377 of file octree_iterator.h.
Member Typedef Documentation
BranchNode
using pcl::octree::OctreeDepthFirstIterator< OctreeT >::BranchNode = typename OctreeIteratorBase<OctreeT>::BranchNode |
Definition at line 381 of file octree_iterator.h.
LeafNode
using pcl::octree::OctreeDepthFirstIterator< OctreeT >::LeafNode = typename OctreeIteratorBase<OctreeT>::LeafNode |
Definition at line 380 of file octree_iterator.h.
Constructor & Destructor Documentation
OctreeDepthFirstIterator() [1/4]
|
explicit |
Empty constructor.
- Parameters
-
[in] max_depth_arg Depth limitation during traversal
Definition at line 48 of file octree_iterator.hpp.
References pcl::octree::OctreeDepthFirstIterator< OctreeT >::reset().
OctreeDepthFirstIterator() [2/4]
|
explicit |
Constructor.
- Parameters
-
[in] octree_arg Octree to be iterated. Initially the iterator is set to its root node. [in] max_depth_arg Depth limitation during traversal
Definition at line 57 of file octree_iterator.hpp.
References pcl::octree::OctreeDepthFirstIterator< OctreeT >::reset().
OctreeDepthFirstIterator() [3/4]
|
inlineexplicit |
Constructor.
- Parameters
-
[in] octree_arg Octree to be iterated. Initially the iterator is set to its root node. [in] max_depth_arg Depth limitation during traversal [in] current_state A pointer to the current iterator state [in] stack A stack structure used for depth first search
- Warning
- For advanced users only.
Definition at line 404 of file octree_iterator.h.
OctreeDepthFirstIterator() [4/4]
|
inline |
Copy Constructor.
- Parameters
-
[in] other Another OctreeDepthFirstIterator to copy from
Definition at line 415 of file octree_iterator.h.
References pcl::octree::OctreeIteratorBase< OctreeT >::current_state_, and pcl::octree::OctreeDepthFirstIterator< OctreeT >::stack_.
Member Function Documentation
operator++() [1/2]
|
virtual |
Preincrement operator.
- Note
- recursively step to next octree node
Implements pcl::octree::OctreeIteratorBase< OctreeT >.
Reimplemented in pcl::octree::OctreeLeafNodeDepthFirstIterator< OctreeT >.
Definition at line 117 of file octree_iterator.hpp.
References pcl::octree::BRANCH_NODE, pcl::octree::IteratorState::depth_, pcl::octree::OctreeNode::getNodeType(), pcl::octree::IteratorState::key_, pcl::octree::IteratorState::node_, pcl::octree::OctreeKey::popBranch(), and pcl::octree::OctreeKey::pushBranch().
Referenced by pcl::octree::OctreeLeafNodeDepthFirstIterator< OctreeT >::operator++().
operator++() [2/2]
|
inline |
postincrement operator.
- Note
- recursively step to next octree node
Definition at line 457 of file octree_iterator.h.
operator=()
|
inline |
Copy assignment.
- Parameters
-
[in] src the iterator to copy into this
Definition at line 425 of file octree_iterator.h.
References pcl::octree::OctreeIteratorBase< OctreeT >::current_state_, and pcl::octree::OctreeDepthFirstIterator< OctreeT >::stack_.
reset()
|
virtual |
Reset the iterator to the root node of the octree.
Reimplemented in pcl::octree::OctreeLeafNodeDepthFirstIterator< OctreeT >.
Definition at line 68 of file octree_iterator.hpp.
References pcl::octree::IteratorState::depth_, pcl::octree::IteratorState::key_, pcl::octree::IteratorState::node_, pcl::octree::OctreeIteratorBase< OctreeT >::reset(), pcl::octree::OctreeKey::x, pcl::octree::OctreeKey::y, and pcl::octree::OctreeKey::z.
Referenced by pcl::octree::OctreeDepthFirstIterator< OctreeT >::OctreeDepthFirstIterator(), and pcl::octree::OctreeLeafNodeDepthFirstIterator< OctreeT >::reset().
skipChildVoxels()
void pcl::octree::OctreeDepthFirstIterator< OctreeT >::skipChildVoxels |
Skip all child voxels of current node and return to parent node.
Definition at line 94 of file octree_iterator.hpp.
Member Data Documentation
stack_
|
protected |
Stack structure.
Definition at line 471 of file octree_iterator.h.
Referenced by pcl::octree::OctreeDepthFirstIterator< OctreeT >::OctreeDepthFirstIterator(), and pcl::octree::OctreeDepthFirstIterator< OctreeT >::operator=().
The documentation for this class was generated from the following files:
- pcl/octree/octree_iterator.h
- pcl/octree/impl/octree_iterator.hpp
© 2009–2012, Willow Garage, Inc.
© 2012–, Open Perception, Inc.
Licensed under the BSD License.
https://pointclouds.org/documentation/classpcl_1_1octree_1_1_octree_depth_first_iterator.html