Core::SequenceTreeIterator
Preorder iterator over a subtree of sequences and models connected using matrix multiplication connections. More...
#include "Core/Nodes/Iterators.h"
Inherits from ForwardIteratorBase< SequenceTreeIterator, Node, false >
Protected Types
Name | |
---|---|
using SequenceTreeIterator | Iterator |
using ForwardIteratorBase< SequenceTreeIterator, Node, false > | Super |
Public Functions
Name | |
---|---|
SequenceTreeIterator() | |
SequenceTreeIterator(Node * root) | |
reference | dereference() const |
bool | equals(const Iterator & b) const |
void | next() |
pointer | ptr() const |
glm::mat4 | transform() |
bool | valid() const |
Protected Attributes
Name | |
---|---|
Node * | m_curr <br>Current node of the iterated (sub)tree, nullptr indicates invalid/after-end iterator. |
bool | m_root |
std::stack< std::pair< Node *, glm::mat4 >, std::vector< std::pair< Node *, glm::mat4 > > > | m_stack |
glm::mat4 | m_transform |
Additional inherited members
Public Types inherited from ForwardIteratorBase< SequenceTreeIterator, Node, false >
Name | |
---|---|
using std::ptrdiff_t | difference_type |
using std::forward_iterator_tag | iterator_category |
using typename std::conditional< IsConst, const Value *, Value * >::type | pointer |
using typename std::conditional< IsConst, const Value &, Value & >::type | reference |
using typename std::conditional< IsConst, const Value, Value >::type | value_type |
Public Functions inherited from ForwardIteratorBase< SequenceTreeIterator, Node, false >
Name | |
---|---|
reference | operator*() |
Iterator & | operator++() |
Iterator | operator++(int ) |
pointer | operator->() |
Protected Functions inherited from ForwardIteratorBase< SequenceTreeIterator, Node, false >
Name | |
---|---|
ForwardIteratorBase() | |
Iterator * | self()<br>CRTP self pointer (pointer to the derived type) |
const Iterator * | self() const<br>CRTP const self pointer. |
Friends inherited from ForwardIteratorBase< SequenceTreeIterator, Node, false >
Name | |
---|---|
bool | operator!=(const Iterator & a, const Iterator & b) |
bool | operator==(const Iterator & a, const Iterator & b) |
Detailed Description
class Core::SequenceTreeIterator;
class Core::SequenceTreeIterator;
Preorder iterator over a subtree of sequences and models connected using matrix multiplication connections.
An accumulated transform from the root to each node is provided during iteration (not including the node and root).
Protected Types Documentation
using Iterator
using Core::SequenceTreeIterator::Iterator = SequenceTreeIterator;
using Core::SequenceTreeIterator::Iterator = SequenceTreeIterator;
using Super
using Core::SequenceTreeIterator::Super = ForwardIteratorBase<SequenceTreeIterator, Node, false>;
using Core::SequenceTreeIterator::Super = ForwardIteratorBase<SequenceTreeIterator, Node, false>;
Public Functions Documentation
function SequenceTreeIterator
inline SequenceTreeIterator()
inline SequenceTreeIterator()
function SequenceTreeIterator
inline SequenceTreeIterator(
Node * root
)
inline SequenceTreeIterator(
Node * root
)
function dereference
inline reference dereference() const
inline reference dereference() const
function equals
inline bool equals(
const Iterator & b
) const
inline bool equals(
const Iterator & b
) const
function next
inline void next()
inline void next()
function ptr
inline pointer ptr() const
inline pointer ptr() const
function transform
inline glm::mat4 transform()
inline glm::mat4 transform()
function valid
inline bool valid() const
inline bool valid() const
Protected Attributes Documentation
variable m_curr
Node * m_curr {nullptr};
Node * m_curr {nullptr};
Current node of the iterated (sub)tree, nullptr indicates invalid/after-end iterator.
variable m_root
bool m_root = true;
bool m_root = true;
variable m_stack
std::stack< std::pair< Node *, glm::mat4 >, std::vector< std::pair< Node *, glm::mat4 > > > m_stack;
std::stack< std::pair< Node *, glm::mat4 >, std::vector< std::pair< Node *, glm::mat4 > > > m_stack;
variable m_transform
glm::mat4 m_transform {1.0f};
glm::mat4 m_transform {1.0f};
Updated on 2025-05-31 at 12:55:31 +0000