Navigation
API > API/Runtime > API/Runtime/Chaos
Here we are specializing the behaviour of our leaf container to minimize memory allocations/deallocations when the container is reset. This is accomplished by only resetting the leafArrays and not the whole container This is only specialized for one specific type, but can expanded to more types if necessary
| Name | TLeafContainer< TAABBTreeLeafArray< FAccelerationStructureHandle, true, FReal > > |
| Type | class |
| Header File | /Engine/Source/Runtime/Experimental/Chaos/Public/Chaos/AABBTree.h |
| Include Path | #include "Chaos/AABBTree.h" |
Syntax
template<>
class TLeafContainer< TAABBTreeLeafArray< FAccelerationStructureHandle, true, FReal > > : private TArray< TAABBTreeLeafArray< FAccelerationStructureHandle, true, FReal > >
Inheritance Hierarchy
- TArray → TLeafContainer< TAABBTreeLeafArray< FAccelerationStructureHandle, true, FReal > >
Typedefs
| Name | Type | Remarks | Include Path |
|---|---|---|---|
| ElementType | FParent::ElementType | Chaos/AABBTree.h | |
| FLeafType | TAABBTreeLeafArray< FAccelerationStructureHandle, true, FReal > | Chaos/AABBTree.h | |
| FParent | TArray< FLeafType > | Chaos/AABBTree.h |
Variables
Protected
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| NumOfValidElements | int32 | Chaos/AABBTree.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
SizeType Add
(
const FLeafType& Item |
Chaos/AABBTree.h | ||
SizeType Num() |
Chaos/AABBTree.h | ||
void Reserve
(
SizeType Number |
Chaos/AABBTree.h | ||
void Reset() |
Chaos/AABBTree.h | ||
void Serialize
(
FChaosArchive& Ar |
Chaos/AABBTree.h |
Operators
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
FLeafType & operator[]
(
SizeType Index |
Chaos/AABBTree.h | ||
const FLeafType & operator[]
(
SizeType Index |
Chaos/AABBTree.h |