A pixel shader for rendering a masked texture using signed distance filed for alpha on a simple element.
更多...
#include <SimpleElementShaders.h>
|
|
| FSimpleElementDistanceFieldGammaPS () |
| | Default constructor
|
| |
| | FSimpleElementDistanceFieldGammaPS (const ShaderMetaType::CompiledShaderInitializerType &Initializer) |
| | Constructor 更多...
|
| |
| void | SetParameters (FRHICommandList &RHICmdList, const FTexture *Texture, float Gamma, float ClipRef, float SmoothWidthValue, bool EnableShadowValue, const FVector2D &ShadowDirectionValue, const FLinearColor &ShadowColorValue, float ShadowSmoothWidthValue, const FDepthFieldGlowInfo &GlowInfo, ESimpleElementBlendMode BlendMode) |
| | Sets all the constant parameters for this shader 更多...
|
| |
| void | SetEditorCompositingParameters (FRHICommandList &RHICmdList, const FSceneView *View) |
| | Sets parameters for compositing editor primitives 更多...
|
| |
| | FShader () |
| | Used to construct a shader for deserialization. 更多...
|
| |
|
| FShader (const CompiledShaderInitializerType &Initializer) |
| | Construct a shader from shader compiler output.
|
| |
|
const FSHAHash & | GetHash () const |
| | Returns the hash of the shader file that this shader was compiled with.
|
| |
|
template<typename UniformBufferStructType > |
| FORCEINLINE_DEBUGGABLE const TShaderUniformBufferParameter< UniformBufferStructType > & | GetUniformBufferParameter () const |
| | Finds an automatically bound uniform buffer matching the given uniform buffer type if one exists, or returns an unbound parameter.
|
| |
|
FORCEINLINE_DEBUGGABLE const FShaderUniformBufferParameter & | GetUniformBufferParameter (const FHashedName SearchName) const |
| | Finds an automatically bound uniform buffer matching the HashedName if one exists, or returns an unbound parameter.
|
| |
|
FORCEINLINE_DEBUGGABLE const FShaderUniformBufferParameter & | GetUniformBufferParameter (const FShaderParametersMetadata *SearchStruct) const |
| | Finds an automatically bound uniform buffer matching the given uniform buffer struct if one exists, or returns an unbound parameter.
|
| |
|
| static bool | ShouldCompilePermutation (const FGlobalShaderPermutationParameters &Parameters) |
| | Determine if this shader should be compiled 更多...
|
| |
|
static const FShaderParametersMetadata * | GetRootParametersMetadata () |
| | Returns the meta data for the root shader parameter struct.
|
| |
|
static void | ModifyCompilationEnvironment (const FShaderPermutationParameters &, FShaderCompilerEnvironment &) |
| | Can be overridden by FShader subclasses to modify their compile environment just before compilation occurs.
|
| |
|
static bool | ShouldCompilePermutation (const FShaderPermutationParameters &) |
| | Can be overridden by FShader subclasses to determine whether a specific permutation should be compiled.
|
| |
|
static bool | ValidateCompiledResult (EShaderPlatform InPlatform, const FShaderParameterMap &InParameterMap, TArray< FString > &OutError) |
| | Can be overridden by FShader subclasses to determine whether compilation is valid.
|
| |
|
| | LAYOUT_FIELD_EDITORONLY (FSHAHash, OutputHash) |
| | Hash of the compiled output from this shader and the resulting parameter map. 更多...
|
| |
|
| LAYOUT_FIELD_EDITORONLY (FSHAHash, SourceHash) |
| | Hash of this shader's source files generated at compile time, and stored to allow creating an FShaderId.
|
| |
|
| LAYOUT_FIELD_EDITORONLY (FSHAHash, VFSourceHash) |
| | Vertex factory source hash, stored so that an FShaderId can be constructed from this shader.
|
| |
A pixel shader for rendering a masked texture using signed distance filed for alpha on a simple element.
◆ FSimpleElementDistanceFieldGammaPS()
| FSimpleElementDistanceFieldGammaPS::FSimpleElementDistanceFieldGammaPS |
( |
const ShaderMetaType::CompiledShaderInitializerType & |
Initializer | ) |
|
Constructor
- 参数
-
| Initializer | - shader initialization container |
◆ SetParameters()
| void FSimpleElementDistanceFieldGammaPS::SetParameters |
( |
FRHICommandList & |
RHICmdList, |
|
|
const FTexture * |
Texture, |
|
|
float |
Gamma, |
|
|
float |
ClipRef, |
|
|
float |
SmoothWidthValue, |
|
|
bool |
EnableShadowValue, |
|
|
const FVector2D & |
ShadowDirectionValue, |
|
|
const FLinearColor & |
ShadowColorValue, |
|
|
float |
ShadowSmoothWidthValue, |
|
|
const FDepthFieldGlowInfo & |
GlowInfo, |
|
|
ESimpleElementBlendMode |
BlendMode |
|
) |
| |
Sets all the constant parameters for this shader
- 参数
-
| Texture | - 2d tile texture |
| Gamma | - if gamma != 1.0 then a pow(color,Gamma) is applied |
| ClipRef | - reference value to compare with alpha for killing pixels |
| SmoothWidth | - The width to smooth the edge the texture |
| EnableShadow | - Toggles drop shadow rendering |
| ShadowDirection | - 2D vector specifying the direction of shadow |
| ShadowColor | - Color of the shadowed pixels |
| ShadowSmoothWidth | - The width to smooth the edge the shadow of the texture |
| BlendMode | - current batched element blend mode being rendered |
◆ ShouldCompilePermutation()
| static bool FSimpleElementDistanceFieldGammaPS::ShouldCompilePermutation |
( |
const FGlobalShaderPermutationParameters & |
Parameters | ) |
|
|
inlinestatic |
Determine if this shader should be compiled
- 参数
-
| Platform | - current shader platform being compiled |
- 返回
- true if this shader should be cached for the given platform
该类的文档由以下文件生成: