Navigation
API > API/Runtime > API/Runtime/RenderCore
References
| Module | RenderCore |
| Header | /Engine/Source/Runtime/RenderCore/Public/ShaderParameterParser.h |
| Include | #include "ShaderParameterParser.h" |
Syntax
class FShaderParameterParser
Remarks
Validates and moves all the shader loose data parameter defined in the root scope of the shader into the root uniform buffer.
Variables
| Type | Name | Description | |
|---|---|---|---|
| bool | bBindlessResources | ||
| bool | bBindlessSamplers | ||
| bool | bModifiedShader | Indicates that the shader source was actually modified. | |
| bool | bMovedLoosedParametersToRootConstantBuffer | Indicates that parameters were actually moved to the root constant buffer. | |
| bool | bNeedToMoveToRootConstantBuffer | Indicates that parameters should be moved to the root cosntant buffer. | |
| FString | OriginalParsedShader | ||
| TMap< FString, FParsedShaderParameter > | ParsedParameters | ||
| const FPlatformConfiguration & | PlatformConfiguration |
Constructors
| Type | Name | Description | |
|---|---|---|---|
FShaderParameterParser
(
const FPlatformConfiguration& InPlatformConfiguration |
Destructors
| Type | Name | Description | |
|---|---|---|---|
Functions
| Type | Name | Description | |
|---|---|---|---|
| void | ApplyBindlessModifications
(
FString& PreprocessedShaderSource |
Converts parsed parameters into their bindless forms. | |
| bool | |||
| void | ExtractFileAndLine
(
int32 PragamLineoffset, |
||
| const FParsedShaderParameter & | FindParameterInfos
(
const FString& ParameterName |
Gets parsing information from a parameter binding name. | |
| const FParsedShaderParameter * | FindParameterInfosUnsafe
(
const FString& ParameterName |
||
| FString | GenerateBindlessParameterDeclaration
(
const FParsedShaderParameter& ParsedParameter |
Generates shader source code to declare a bindless resource or sampler (for automatic bindless conversion). | |
| FStringView | GetBindlessParameterPrefix
(
EShaderParameterType InShaderParameterType |
||
| void | GetParameterFileAndLine
(
const FParsedShaderParameter& ParsedParameter, |
Gets file and line of the parameter in the shader source code. | |
| bool | MoveShaderParametersToRootConstantBuffer
(
const FShaderParametersMetadata* RootParametersStructure, |
Moves parsed parameters into the root constant buffer. | |
| bool | ParseAndModify
(
const FShaderCompilerInput& CompilerInput, |
||
| EShaderParameterType | ParseAndRemoveBindlessParameterPrefix
(
FString& InName |
||
| EShaderParameterType | ParseAndRemoveBindlessParameterPrefix
(
FStringView& InName |
||
| bool | ParseParameters
(
const FShaderParametersMetadata* RootParametersStructure, |
Parses the preprocessed shader code | |
| EShaderParameterType | ParseParameterType
(
FStringView InType |
||
| bool | RemoveBindlessParameterPrefix
(
FString& InName |
||
| void | RemoveMovingParametersFromSource
(
FString& PreprocessedShaderSource |
||
| void | ValidateShaderParameterType
(
const FShaderCompilerInput& CompilerInput, |
||
| void | ValidateShaderParameterType
(
const FShaderCompilerInput& CompilerInput, |
Validates the shader parameter in code is compatible with the shader parameter structure. | |
| void | ValidateShaderParameterTypes
(
const FShaderCompilerInput& CompilerInput, |
||
| void | ValidateShaderParameterTypes
(
const FShaderCompilerInput& CompilerInput, |
Validates shader parameter map is compatible with the shader parameter structure. |
Classes
| Type | Name | Description | |
|---|---|---|---|
| FParsedShaderParameter | |||
| FPlatformConfiguration |
Constants
| Name | Description |
|---|---|
| kBindlessSamplerArrayPrefix | |
| kBindlessSamplerPrefix | |
| kBindlessSRVArrayPrefix | Prefix used to declare arrays of samplers/resources for bindless. |
| kBindlessSRVPrefix | |
| kBindlessUAVArrayPrefix | |
| kBindlessUAVPrefix |