Navigation
API > API/Runtime > API/Runtime/RenderCore
| Name | FShaderCodeResource |
| Type | class |
| Header File | /Engine/Source/Runtime/RenderCore/Public/ShaderCore.h |
| Include Path | #include "ShaderCore.h" |
Syntax
class FShaderCodeResource
Structs
| Name | Remarks |
|---|---|
| FHeader |
Variables
Protected
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| Code | FSharedBuffer | ShaderCore.h | ||
| Header | FSharedBuffer | Header is cloned into shared buffer to avoid needing to determine what offsets FArchive serialization wrote everything at as such it needs explicitly initialized padding, so we ensure no additional padding was added by the compiler | ShaderCore.h | |
| Symbols | FCompressedBuffer | ShaderCore.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
FCompositeBuffer GetCacheBuffer() |
Returns a single composite buffer referencing both the header and code data to be cached. | ShaderCore.h | |
FSharedBuffer GetCodeBuffer() |
Return the buffer storing just the shader code for this resource | ShaderCore.h | |
TConstArrayView< uint8 > GetCodeView() |
Returns a uint8 array view representation of the Code FSharedBuffer, for compatibility's sake (much downstream usage of shader code expects an array of uint8) | ShaderCore.h | |
EShaderFrequency GetFrequency() |
Retrieves the shader frequency as stored in the FHeader buffer. | ShaderCore.h | |
int32 GetShaderCodeSize() |
Retrieves the actual shader code size (excluding optional data) as stored in the FHeader buffer. | ShaderCore.h | |
FCompressedBuffer GetSymbolsBuffer() |
Return the buffer storing the (compressed) symbols for this resource | ShaderCore.h | |
int32 GetUncompressedSize() |
Retrieves the uncompressed size of the shader code as stored in the FHeader buffer. | ShaderCore.h | |
void PopulateFromComposite
(
FCompositeBuffer CacheBuffer, |
Sets the Header and Code shared buffer references in this resource to the segments referenced by the given composite buffer. | ShaderCore.h | |
void PopulateHeader
(
int32 UncompressedSize, |
Populates the header for this code resource with the given sizes and frequency. | ShaderCore.h |
Static
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
static FCompositeBuffer Unpack
(
FSharedBuffer MonolithicBuffer |
Unpacks the given FSharedBuffer into separate header/code buffer views and returns them as a 2-segment composite buffer. | ShaderCore.h |