You've already forked UnrealEngineUWP
mirror of
https://github.com/izzy2lost/UnrealEngineUWP.git
synced 2026-03-26 18:15:20 -07:00
List of highlights * PlayerController - Removed ForceFeedback and and OnlineReplStructs * Class - Removed Package.h * World - Pawn, Blueprint and GameInstance * Actor - CoreNet, HitResult and ActorDatalayer * EngineBaseTypes - TaskGraphInterface * AssetManager - AssetData * Scene/Child/ActorComponent - CoreNet * AnimInstance - AttributesRuntime, Skeleton, AnimCurveTypes, AnimMontage, BonePose * BulkData - IoDispatcher * AssetData - IoDispatcher, LinkerLoad * SecureHash - AsyncWork * CanvasTypes - UnrealEngine, StaticMeshResources * IpAddress - AsyncWork, Stats #preflight 6363717ece676ae8688f5d8c #rb none [CL 22968258 by henrik karlsson in ue5-main branch]
49 lines
1.4 KiB
C++
49 lines
1.4 KiB
C++
// Copyright Epic Games, Inc. All Rights Reserved.
|
|
|
|
#pragma once
|
|
|
|
#include "Async/TaskGraphFwd.h"
|
|
#include "CoreMinimal.h"
|
|
#include "Templates/RefCounting.h"
|
|
|
|
namespace ENamedThreads { enum Type : int32; }
|
|
|
|
////////////////////////////////////
|
|
// Render fences
|
|
////////////////////////////////////
|
|
|
|
/**
|
|
* Used to track pending rendering commands from the game thread.
|
|
*/
|
|
class RENDERCORE_API FRenderCommandFence
|
|
{
|
|
public:
|
|
|
|
/**
|
|
* Adds a fence command to the rendering command queue.
|
|
* Conceptually, the pending fence count is incremented to reflect the pending fence command.
|
|
* Once the rendering thread has executed the fence command, it decrements the pending fence count.
|
|
* @param bSyncToRHIAndGPU, true if we should wait for the RHI thread or GPU, otherwise we only wait for the render thread.
|
|
*/
|
|
void BeginFence(bool bSyncToRHIAndGPU = false);
|
|
|
|
/**
|
|
* Waits for pending fence commands to retire.
|
|
* @param bProcessGameThreadTasks, if true we are on a short callstack where it is safe to process arbitrary game thread tasks while we wait
|
|
*/
|
|
void Wait(bool bProcessGameThreadTasks = false) const;
|
|
|
|
// return true if the fence is complete
|
|
bool IsFenceComplete() const;
|
|
|
|
// Ctor/dtor
|
|
FRenderCommandFence();
|
|
~FRenderCommandFence();
|
|
|
|
private:
|
|
/** Graph event that represents completion of this fence **/
|
|
mutable FGraphEventRef CompletionEvent;
|
|
/** Thread that will trigger the CompletionEvent **/
|
|
ENamedThreads::Type TriggerThreadIndex;
|
|
};
|