![]() |
Shamrock 2025.10.0
Astrophysical Code
|
Accessed version of CLBVHObjectIterator. More...
Public Member Functions | |
| template<class Functor1, class Functor2> | |
| void | rtree_for (Functor1 &&traverse_condition_with_aabb, Functor2 &&on_found_object) const |
| Traverses the tree and executes a function for each found object. | |
| template<class StackAccessor, class Functor1, class Functor2> | |
| void | rtree_for (StackAccessor &&stack, u32 stack_size, Functor1 &&traverse_condition_with_aabb, Functor2 &&on_found_object) const |
Public Attributes | |
| LeafCellIterator::acc | cell_iterator |
| Cell iterator. | |
| CLBVHTraverserAccessed< Tmorton, Tvec, dim > | tree_traverser |
| Tree traverser. | |
Static Public Attributes | |
| static constexpr u32 | tree_depth_max = shamrock::sfc::MortonCodes<Tmorton, 3>::significant_bits + 1 |
| maximum depth of the tree according to the morton codes | |
Accessed version of CLBVHObjectIterator.
Definition at line 166 of file CLBVHObjectIterator.hpp.
|
inline |
Traverses the tree and executes a function for each found object.
| [in] | traverse_condition_with_aabb | A function taking a node_id and its AABB, and returning a boolean indicating whether to traverse the node further. |
| [in] | on_found_object | A function to be called for each object found in a leaf node that meets the traversal condition. |
Definition at line 184 of file CLBVHObjectIterator.hpp.
|
inline |
version using a stack supplied by the caller instead of an internal std::array (e.g. a slice of a local_accessor for shared memory offload). stack is a functor (u32 id) -> u32 & giving access to the entry id of the stack and stack_size is its capacity, which must be at least the tree depth + 1.
Definition at line 200 of file CLBVHObjectIterator.hpp.
| LeafCellIterator::acc shamtree::CLBVHObjectIteratorAccessed< Tmorton, Tvec, dim >::cell_iterator |
Cell iterator.
Definition at line 172 of file CLBVHObjectIterator.hpp.
|
staticconstexpr |
maximum depth of the tree according to the morton codes
Definition at line 169 of file CLBVHObjectIterator.hpp.
| CLBVHTraverserAccessed<Tmorton, Tvec, dim> shamtree::CLBVHObjectIteratorAccessed< Tmorton, Tvec, dim >::tree_traverser |
Tree traverser.
Definition at line 173 of file CLBVHObjectIterator.hpp.