![]() |
XII Release 0.1.0
|
Copyright (c) Theophilus Eriata. All Rights Reserved. More...
#include <FrameAllocator.h>
Public Types | |
| using | LinearAllocatorType = xiiLinearAllocator<xiiAllocatorTrackingMode::Basics, OverwriteMemoryOnReset> |
Public Member Functions | |
| xiiDoubleBufferedLinearAllocator (xiiStringView sName, xiiAllocator *pParent) | |
| Copyright (c) Theophilus Eriata. All Rights Reserved. | |
| XII_ALWAYS_INLINE xiiAllocator * | GetCurrentAllocator () const |
| void | Swap () |
| void | Reset () |
Static Public Attributes | |
| static constexpr bool | OverwriteMemoryOnReset = false |
Copyright (c) Theophilus Eriata. All Rights Reserved.
A double buffered linear allocator for temporary per-frame allocations.
This allocator maintains two linear allocators and swaps between them each frame. One allocator is used for the current frame while the previous frame's allocator is reset. This pattern ensures that allocations from the previous frame remain valid until the next frame begins, which is useful for data that needs to persist across frame boundaries.