UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
FTaskTagScope Class Reference

#include <CoreGlobals.h>

Public Member Functions

CORE_API FTaskTagScope (ETaskTag InTag)
 
CORE_API ~FTaskTagScope ()
 

Static Public Member Functions

static void CORE_API SetTagNone ()
 
static void CORE_API SetTagStaticInit ()
 
static ETaskTag CORE_API SwapTag (ETaskTag Tag)
 
static CORE_API ETaskTag GetCurrentTag ()
 
static CORE_API bool IsCurrentTag (ETaskTag InTag)
 
static CORE_API bool IsRunningDuringStaticInit ()
 

Friends

class FRunnableThread
 
class FRenderingThread
 

Detailed Description

This class can be used to Tag an execution context aka Thead or Job and allows us to later query the state when we are in the callstack It is usually used for the IsInRendering/GamethreadFunctions.

Parameters
CtorSignatureInTag the Tag to use

Constructor & Destructor Documentation

◆ FTaskTagScope()

FTaskTagScope::FTaskTagScope ( ETaskTag  InTag)

◆ ~FTaskTagScope()

FTaskTagScope::~FTaskTagScope ( )

Member Function Documentation

◆ GetCurrentTag()

ETaskTag FTaskTagScope::GetCurrentTag ( )
static

◆ IsCurrentTag()

bool FTaskTagScope::IsCurrentTag ( ETaskTag  InTag)
static

◆ IsRunningDuringStaticInit()

bool FTaskTagScope::IsRunningDuringStaticInit ( )
static

◆ SetTagNone()

void FTaskTagScope::SetTagNone ( )
static

Clear the ETaskTag::StaticInit tag so that the Main OS Thread has no active tag. This will allow functions such as IsInGameThread() to function properly when called from the Main Thread.

◆ SetTagStaticInit()

void FTaskTagScope::SetTagStaticInit ( )
static

Restore the ETaskTag::StaticInit tag so that the destructors of global (or local static) C++ objects function properly when checking thread state (from functions like IsInGameThread()).

◆ SwapTag()

ETaskTag FTaskTagScope::SwapTag ( ETaskTag  Tag)
static

Swap the Tag this is only used when Thread contexts move between different threads.

Friends And Related Symbol Documentation

◆ FRenderingThread

friend class FRenderingThread
friend

◆ FRunnableThread

friend class FRunnableThread
friend

The documentation for this class was generated from the following files: