RealDocs

UActorComponent::RequiresGameThreadEndOfFrameRecreate

function Engine Since 4.9
#include "Components/ActorComponent.h"
Access: public Specifiers: virtual

Description

Returns whether end-of-frame scene proxy recreations for this component must happen on the game thread. Similar to RequiresGameThreadEndOfFrameUpdates but governs the heavier recreate path.

Caveats & Gotchas

  • Proxy recreation involves calling CreateSceneProxy, which accesses render objects; most components can do this off the game thread, but components using Slate or other GT-only systems cannot.
  • Returning true from this but false from RequiresGameThreadEndOfFrameUpdates is valid — the two functions govern different code paths.
  • The base implementation returns false; only override when your CreateSceneProxy or DestroyRenderState_Concurrent implementations truly require the game thread.

Signature

ENGINE_API virtual bool RequiresGameThreadEndOfFrameRecreate() const;

Return Type

bool

Example

Require game thread for proxy recreation C++
bool UMySpecialComponent::RequiresGameThreadEndOfFrameRecreate() const
{
    // Our CreateSceneProxy accesses a UTexture2D asset, which is not MT-safe
    return true;
}

Version History

Introduced in: 4.9

Version Status Notes
5.6 stable

Feedback

Was this helpful?

Suggest an edit

Select a field above to begin editing.