FRunnableThread::Create

Factory method to create a thread with the specified stack size and thread priority.

Windows
MacOS
Linux

References

Module

Core

Header

/Engine/Source/Runtime/Core/Public/HAL/RunnableThread.h

Include

#include "HAL/RunnableThread.h"

Source

/Engine/Source/Runtime/Core/Private/HAL/ThreadingBase.cpp

Syntax

static FRunnableThread * Create
(
    class FRunnable * InRunnable,
    const TCHAR * ThreadName,
    uint32 InStackSize,
    EThreadPriority InThreadPri,
    uint64 InThreadAffinityMask,
    EThreadCreateFlags InCreateFlags
)

Remarks

Factory method to create a thread with the specified stack size and thread priority.

Returns

The newly created thread or nullptr if it failed

Parameters

Parameter

Description

InRunnable

The runnable object to execute

ThreadName

Name of the thread

InStackSize

The size of the stack to create. 0 means use the current thread's stack size

InThreadPri

Tells the thread whether it needs to adjust its priority or not. Defaults to normal priority

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