Navigation
API > API/Plugins > API/Plugins/GameplayCameras
A utility class that allocates and stores objects of, or derived from, a common base class. The storage is a paged buffer composed of one or more pages. If the needed storage size and alignment are known ahead of time, you can pre-allocate the first page appropriately and avoid any further paging.
| Name | TCameraObjectStorage |
| Type | class |
| Header File | /Engine/Plugins/Cameras/GameplayCameras/Source/GameplayCameras/Public/Core/CameraObjectStorage.h |
| Include Path | #include "Core/CameraObjectStorage.h" |
Syntax
template<typename BaseObjectType>
class TCameraObjectStorage
Derived Classes
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
| Core/CameraObjectStorage.h | |||
TCameraObjectStorage
(
TCameraObjectStorage&& Other |
Core/CameraObjectStorage.h | ||
TCameraObjectStorage
(
const TCameraObjectStorage& |
Core/CameraObjectStorage.h |
Destructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
~TCameraObjectStorage() |
Core/CameraObjectStorage.h |
Structs
| Name | Remarks |
|---|---|
| FAllocation | Allocation page |
| FObjectInfo | Pointer and info of objects inside the page buffers |
Variables
Protected
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| Allocations | TArray< FAllocation > | Allocated page buffers | Core/CameraObjectStorage.h | |
| ObjectInfos | TArray< FObjectInfo > | List of built objects | Core/CameraObjectStorage.h |
Functions
Protected
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void AllocatePage
(
uint32 InCapacity, |
Allocates a new page buffer. | Core/CameraObjectStorage.h | |
TEnableIf< TPointerIsConvertibleFromTo< ObjectType, BaseObjectType >::Value, ObjectType * >::Type BuildObject
(
ArgTypes&&... InArgs |
Creates an object of the given type. Will allocate a new page buffer if needed. | Core/CameraObjectStorage.h | |
void * BuildObjectUninitialized
(
uint32 Sizeof, |
Allocates memory for an object of the given size and alignment, but doesn't initialize anything in that memory block. | Core/CameraObjectStorage.h | |
void DestroyObject
(
BaseObjectType* BaseObjectPtr, |
Destroys a given object. | Core/CameraObjectStorage.h | |
void DestroyObjects
(
bool bFreeAllocations |
Destroys all objects in the storage. | Core/CameraObjectStorage.h | |
void GetAllocationInfo
(
uint32& OutTotalUsed, |
Computes information about the overall allocated memory. | Core/CameraObjectStorage.h | |
void RegisterInitializedObject
(
BaseObjectType* BaseObjectPtr |
Called to register an object after it has been constructed. | Core/CameraObjectStorage.h |
Operators
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
TCameraObjectStorage & operator=
(
TCameraObjectStorage&& Other |
Core/CameraObjectStorage.h | ||
TCameraObjectStorage & operator=
(
const TCameraObjectStorage& |
Core/CameraObjectStorage.h |