9#include "Containers/Array.h"
12#include "Containers/Map.h"
13#include "Containers/Set.h"
90 return Ar <<
Info.Hash;
154 A.ClassNameAndObjectPath ==
B.ClassNameAndObjectPath &&
155 A.ShaderType ==
B.ShaderType &&
156 A.ShaderClass ==
B.ShaderClass &&
157 A.MaterialDomain ==
B.MaterialDomain &&
158 A.FeatureLevel ==
B.FeatureLevel &&
159 A.QualityLevel ==
B.QualityLevel &&
160 A.TargetFrequency ==
B.TargetFrequency &&
161 A.TargetPlatform ==
B.TargetPlatform &&
162 A.VFType ==
B.VFType &&
163 A.PermutationId ==
B.PermutationId &&
164 A.PipelineHash ==
B.PipelineHash;
188 return GetTypeHash(Key);
398 UE_DEPRECATED(5.6,
"DumpShaderCodeStats is deprecated due to being incorrect w.r.t shader duplication due to chunking.")
OODEFFUNC typedef void(OODLE_CALLBACK t_fp_OodleCore_Plugin_Free)(void *ptr)
bool LoadFromCompactBinary(FCbFieldView Field, FAssetDependency &Dependency)
Definition AssetRegistry.cpp:10420
#define UE_DEPRECATED(Version, Message)
Definition CoreMiscDefines.h:302
UE_FORCEINLINE_HINT TSharedRef< CastToType, Mode > StaticCastSharedRef(TSharedRef< CastFromType, Mode > const &InSharedRef)
Definition SharedPointer.h:127
#define DECLARE_DELEGATE_OneParam(DelegateName, Param1Type)
Definition DelegateCombinations.h:48
#define DECLARE_LOG_CATEGORY_EXTERN(CategoryName, DefaultVerbosity, CompileTimeVerbosity)
Definition LogMacros.h:361
EShaderFrequency
Definition RHIDefinitions.h:202
@ SF_NumGraphicsFrequencies
Definition RHIDefinitions.h:219
RENDERCORE_API FSharedShaderMapResourceExplicitRelease OnSharedShaderMapResourceExplicitRelease
Definition ShaderCodeLibrary.cpp:301
TSet< TUniquePtr< FStableShaderKeyAndValue >, FStableShaderKeyFuncs > FStableShaderSet
Definition ShaderCodeLibrary.h:192
TSet< FName > FShaderMapAssetPaths
Definition Shader.h:88
Definition Archive.h:1208
Definition CompactBinary.h:610
Definition CompactBinaryWriter.h:68
Definition IDelegateInstance.h:14
Definition IoChunkId.h:64
Definition NameTypes.h:617
Definition RHIResources.h:854
Definition SecureHash.h:226
Definition IPluginManager.h:111
Definition UnrealString.h.inl:34
Definition DelegateSignatureImpl.inl:1029
Definition RefCounting.h:454
Definition UniquePtr.h:107
Definition FieldSystemNoiseAlgo.cpp:6
Definition SetUtilities.h:23
Definition ShaderCodeLibrary.h:95
RENDERCORE_API FString ToStringPathOnly() const
Definition ShaderCodeLibrary.cpp:449
RENDERCORE_API void ParseFromString(const FStringView &Src)
Definition ShaderCodeLibrary.cpp:532
bool operator==(const FCompactFullName &Other) const
Definition ShaderCodeLibrary.h:98
RENDERCORE_API void AppendString(FStringBuilderBase &Out) const
Definition ShaderCodeLibrary.cpp:470
RENDERCORE_API FString ToString() const
Definition ShaderCodeLibrary.cpp:442
TArray< FName, TInlineAllocator< 16 > > ObjectClassAndPath
Definition ShaderCodeLibrary.h:96
friend RENDERCORE_API uint32 GetTypeHash(const FCompactFullName &A)
Definition ShaderCodeLibrary.cpp:584
static UE_FORCEINLINE_HINT uint32 MemCrc32(const void *Data, int32 Length, uint32 CRC=0)
Definition Crc.h:31
Definition ShaderCodeLibrary.h:48
uint32 Hash
Definition ShaderCodeLibrary.h:50
FSHAHash Shaders[SF_NumGraphicsFrequencies]
Definition ShaderCodeLibrary.h:49
friend bool operator==(const FShaderCodeLibraryPipeline &A, const FShaderCodeLibraryPipeline &B)
Definition ShaderCodeLibrary.h:57
friend FArchive & operator<<(FArchive &Ar, FShaderCodeLibraryPipeline &Info)
Definition ShaderCodeLibrary.h:84
FShaderCodeLibraryPipeline()
Definition ShaderCodeLibrary.h:55
friend uint32 GetTypeHash(const FShaderCodeLibraryPipeline &Key)
Definition ShaderCodeLibrary.h:69
RENDERCORE_API void GetPipelineHash(FSHAHash &Output)
Definition ShaderCodeLibrary.cpp:944
Definition ShaderCodeLibrary.h:211
static RENDERCORE_API FDelegateHandle RegisterSharedShaderCodeRequestDelegate_Handle(const FSharedShaderCodeRequest::FDelegate &Delegate)
Definition ShaderCodeLibrary.cpp:4703
static RENDERCORE_API FRayTracingShaderRHIRef CreateRayTracingShader(EShaderPlatform Platform, const FSHAHash &Hash, EShaderFrequency Frequency)
Definition ShaderCodeLibrary.cpp:4282
static RENDERCORE_API FPixelShaderRHIRef CreatePixelShader(EShaderPlatform Platform, const FSHAHash &Hash)
Definition ShaderCodeLibrary.cpp:4237
static RENDERCORE_API bool ContainsShaderCode(const FSHAHash &Hash)
Definition ShaderCodeLibrary.cpp:4180
static RENDERCORE_API bool ReleasePreloadedShader(const FSHAHash &Hash)
Definition ShaderCodeLibrary.cpp:4219
static RENDERCORE_API FVertexShaderRHIRef CreateVertexShader(EShaderPlatform Platform, const FSHAHash &Hash)
Definition ShaderCodeLibrary.cpp:4228
static RENDERCORE_API FComputeShaderRHIRef CreateComputeShader(EShaderPlatform Platform, const FSHAHash &Hash)
Definition ShaderCodeLibrary.cpp:4255
static RENDERCORE_API FAmplificationShaderRHIRef CreateAmplificationShader(EShaderPlatform Platform, const FSHAHash &Hash)
Definition ShaderCodeLibrary.cpp:4273
static RENDERCORE_API EShaderPlatform GetRuntimeShaderPlatform(void)
Definition ShaderCodeLibrary.cpp:4302
static RENDERCORE_API void UnregisterSharedShaderCodeRequestDelegate_Handle(FDelegateHandle Handle)
Definition ShaderCodeLibrary.cpp:4708
static RENDERCORE_API bool OpenLibrary(FString const &Name, FString const &Directory, bool bMonolithicOnly=false)
Definition ShaderCodeLibrary.cpp:4339
static RENDERCORE_API void Shutdown()
Definition ShaderCodeLibrary.cpp:4140
static RENDERCORE_API bool AreShaderMapsPreloadedAtLoadTime()
Definition ShaderCodeLibrary.cpp:4175
static RENDERCORE_API FMeshShaderRHIRef CreateMeshShader(EShaderPlatform Platform, const FSHAHash &Hash)
Definition ShaderCodeLibrary.cpp:4264
static RENDERCORE_API void DontOpenPluginShaderLibraryOnMount(const FString &PluginName)
Definition ShaderCodeLibrary.cpp:4713
static RENDERCORE_API void OpenPluginShaderLibrary(IPlugin &Plugin, bool bMonolithicOnly=true)
Definition ShaderCodeLibrary.cpp:4722
static RENDERCORE_API void SafeAssignHash(FRHIShader *InShader, const FSHAHash &Hash)
Definition ShaderCodeLibrary.cpp:4695
static RENDERCORE_API void CloseLibrary(FString const &Name)
Definition ShaderCodeLibrary.cpp:4349
static RENDERCORE_API FGeometryShaderRHIRef CreateGeometryShader(EShaderPlatform Platform, const FSHAHash &Hash)
Definition ShaderCodeLibrary.cpp:4246
static RENDERCORE_API void AddKnownChunkIDs(const int32 *IDs, const int32 NumChunkIDs)
Definition ShaderCodeLibrary.cpp:4312
static RENDERCORE_API bool IsEnabled()
Definition ShaderCodeLibrary.cpp:4170
static RENDERCORE_API uint32 GetShaderCount(void)
Definition ShaderCodeLibrary.cpp:4292
static RENDERCORE_API TRefCountPtr< FShaderMapResource > LoadResource(const FSHAHash &Hash, FArchive *Ar)
Definition ShaderCodeLibrary.cpp:4198
static RENDERCORE_API void InitForRuntime(EShaderPlatform ShaderPlatform)
Definition ShaderCodeLibrary.cpp:4076
static RENDERCORE_API void PreInit()
Definition ShaderCodeLibrary.cpp:4070
Definition ShaderCodeLibrary.h:118
FName MaterialDomain
Definition ShaderCodeLibrary.h:122
FName QualityLevel
Definition ShaderCodeLibrary.h:124
friend uint32 GetTypeHash(const FStableShaderKeyAndValue &Key)
Definition ShaderCodeLibrary.h:167
FName ShaderClass
Definition ShaderCodeLibrary.h:121
FSHAHash PipelineHash
Definition ShaderCodeLibrary.h:129
FName TargetFrequency
Definition ShaderCodeLibrary.h:125
RENDERCORE_API void ParseFromString(const FStringView &Src)
Definition ShaderCodeLibrary.cpp:635
FName PermutationId
Definition ShaderCodeLibrary.h:128
FName ShaderType
Definition ShaderCodeLibrary.h:120
uint32 KeyHash
Definition ShaderCodeLibrary.h:131
FName VFType
Definition ShaderCodeLibrary.h:127
static RENDERCORE_API FString HeaderLine()
Definition ShaderCodeLibrary.cpp:802
FStableShaderKeyAndValue()
Definition ShaderCodeLibrary.h:135
FSHAHash OutputHash
Definition ShaderCodeLibrary.h:133
RENDERCORE_API void SetPipelineHash(const FShaderPipeline *Pipeline)
Definition ShaderCodeLibrary.cpp:840
FName FeatureLevel
Definition ShaderCodeLibrary.h:123
RENDERCORE_API void AppendString(FAnsiStringBuilderBase &Out) const
Definition ShaderCodeLibrary.cpp:768
friend bool operator==(const FStableShaderKeyAndValue &A, const FStableShaderKeyAndValue &B)
Definition ShaderCodeLibrary.h:151
FName TargetPlatform
Definition ShaderCodeLibrary.h:126
RENDERCORE_API void ParseFromStringCached(const FStringView &Src, class TMap< uint32, FName > &NameCache)
Definition ShaderCodeLibrary.cpp:683
FCompactFullName ClassNameAndObjectPath
Definition ShaderCodeLibrary.h:119
RENDERCORE_API FString ToString() const
Definition ShaderCodeLibrary.cpp:732
RENDERCORE_API void ComputeKeyHash()
Definition ShaderCodeLibrary.cpp:617
Definition ShaderCodeLibrary.h:174
static FORCEINLINE const FStableShaderKeyAndValue & GetSetKey(const TUniquePtr< FStableShaderKeyAndValue > &Element)
Definition ShaderCodeLibrary.h:175
static FORCEINLINE uint32 GetKeyHash(const FStableShaderKeyAndValue &Key)
Definition ShaderCodeLibrary.h:186
static FORCEINLINE bool Matches(const FStableShaderKeyAndValue &A, const FStableShaderKeyAndValue &B)
Definition ShaderCodeLibrary.h:180