You've already forked UnrealEngineUWP
mirror of
https://github.com/izzy2lost/UnrealEngineUWP.git
synced 2026-03-26 18:15:20 -07:00
- Added simple blackboard container. - Added support for checking if a resource has been produced within the graph. - Moved all RHI validation into user validation cpp file. - Fixed bug in graph producer compilation logic when switching to subresources. #rb none [CL 14766062 by zach bethel in ue5-main branch]
28 lines
655 B
C++
28 lines
655 B
C++
// Copyright Epic Games, Inc. All Rights Reserved.
|
|
|
|
#include "RenderGraphBlackboard.h"
|
|
|
|
FString FRDGBlackboard::GetTypeName(const TCHAR* ClassName, const TCHAR* FileName, uint32 LineNumber)
|
|
{
|
|
return FString::Printf(TEXT("%s %s %d"), ClassName, FileName, LineNumber);
|
|
}
|
|
|
|
uint32 FRDGBlackboard::AllocateIndex(FString&& TypeName)
|
|
{
|
|
check(IsInRenderingThread());
|
|
static TMap<FString, uint32> StructMap;
|
|
static uint32 NextIndex = 0;
|
|
|
|
uint32 Result;
|
|
if (const uint32* FoundIndex = StructMap.Find(TypeName))
|
|
{
|
|
Result = *FoundIndex;
|
|
}
|
|
else
|
|
{
|
|
StructMap.Emplace(MoveTemp(TypeName), NextIndex);
|
|
Result = NextIndex;
|
|
NextIndex++;
|
|
}
|
|
return Result;
|
|
} |