FUObjectAllocator::AllocateUObject

Allocates a [UObjectBase](API\Runtime\CoreUObject\UObject\UObjectBase) from the free store or the permanent object pool

Windows
MacOS
Linux

References

Module

CoreUObject

Header

/Engine/Source/Runtime/CoreUObject/Public/UObject/UObjectAllocator.h

Include

#include "UObject/UObjectAllocator.h"

Source

/Engine/Source/Runtime/CoreUObject/Private/UObject/UObjectAllocator.cpp

Syntax

UObjectBase * AllocateUObject
(
    int32 Size,
    int32 Alignment,
    bool bAllowPermanent
)

Remarks

Allocates a UObjectBase from the free store or the permanent object pool

Returns

newly allocated UObjectBase (not really a UObjectBase yet, no constructor like thing has been called).

Parameters

Parameter

Description

Size

size of uobject to allocate

Alignment

alignment of uobject to allocate

bAllowPermanent

if true, allow allocation in the permanent object pool, if it fits

Help shape the future of Unreal Engine documentation! Tell us how we're doing so we can serve you better.
Take our survey
Dismiss