FShaderCodeArchive

Windows
MacOS
Linux

Inheritance Hierarchy

FRHIResource

FRHIShaderLibrary

FShaderCodeArchive

References

Module

RenderCore

Header

/Engine/Source/Runtime/RenderCore/Public/ShaderCodeArchive.h

Include

#include "ShaderCodeArchive.h"

Syntax

class FShaderCodeArchive : public FRHIShaderLibrary

Variables

Name Description

Protected variable

IFileCacheHandl...

 

FileCacheHandle

Library file handle for async reads.

Protected variable

int64

 

LibraryCodeOffset

Offset at where shader code starts in a code library.

Protected variable

FString

 

LibraryDir

Library directory.

Protected variable

FSerializedShad...

 

SerializedShaders

The shader code present in the library.

Protected variable

TArray< FGraphE...

 

ShaderMapPreloadEvents

Protected variable

FRWLock

 

ShaderPreloadLock

Protected variable

TArray< FShader...

 

ShaderPreloads

Constructors

Name Description

Protected function

FShaderCodeArchive

(
    EShaderPlatform InPlatform,
    const FString& InLibraryDir,
    const FString& InLibraryName
)

Destructors

Name Description

Public function Virtual

~FShaderCodeArchive()

Functions

Name Description

Protected function

void

 

CheckShaderCreation

(
    void* ShaderPtr,
    int32 Index
)

Public function Static

FShaderCodeA...

 

Create

(
    EShaderPlatform InPlatform,
    FArchive& Ar,
    const FString& InDestFilePath,
    const FString& InLibraryDir,
    const FString& InLibraryName
)

Public function Const

uint32

 

GetSizeBytes()

Public function

void

 

OnShaderPreloadFinished

(
    int32 ShaderIndex,
    const IMemoryReadStreamRef& Preloa...
)

Protected function

bool

 

WaitForPreload

(
    FShaderPreloadEntry& ShaderPreload...
)

Overridden from FRHIShaderLibrary

Name Description

Public function Virtual

TRefCountPtr...

 

CreateShader

(
    int32 Index
)

Public function Virtual

int32

 

FindShaderIndex

(
    const FSHAHash& Hash
)

Public function Virtual

int32

 

FindShaderMapIndex

(
    const FSHAHash& Hash
)

Public function Virtual Const

int32

 

GetNumShaderMaps()

Public function Virtual Const

int32

 

GetNumShaders()

Public function Virtual Const

int32

 

GetNumShadersForShaderMap

(
    int32 ShaderMapIndex
)

Public function Virtual Const

int32

 

GetShaderIndex

(
    int32 ShaderMapIndex,
    int32 i
)

Public function Virtual Const

bool

 

IsNativeLibrary()

Public function Virtual

bool

 

PreloadShader

(
    int32 ShaderIndex,
    FGraphEventArray& OutCompletionEve...
)

Public function Virtual

bool

 

PreloadShaderMap

(
    int32 ShaderMapIndex,
    FGraphEventArray& OutCompletionEve...
)

Public function Virtual

void

 

ReleasePreloadedShader

(
    int32 ShaderIndex
)

Public function Virtual

void

 

Teardown()

Classes

Name

Description

Protected struct

FShaderPreloadEntry

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