Click or drag to resize
Ab4d.SharpEngine logo

GammaCorrectionPostProcess Class

GammaCorrectionPostProcess is a post process that can apply a custom gamma correction to the rendered image.
The following operation is executed in the shader: finalColor = float4(pow(color.rgb, 1.0 / Gamma), color.a)
Inheritance Hierarchy

Namespace: Ab4d.SharpEngine.PostProcessing
Assembly: Ab4d.SharpEngine (in Ab4d.SharpEngine.dll) Version: 4.0.9584+ba1aaa26d4181dd3fa8ed7b6398391d1affa36c8
Syntax
C#
public class GammaCorrectionPostProcess : SimpleFragmentShaderPostProcess

The GammaCorrectionPostProcess type exposes the following members.

Constructors
 NameDescription
Public methodGammaCorrectionPostProcess Initializes a new instance of the BlackAndWhitePostProcess class.
Top
Properties
 NameDescription
Public propertyGamma Gamma value (2.2 by default). The value is used in the following formula: finalColor = float4(pow(color.rgb, 1.0 / Gamma), color.a)
Top
Methods
 NameDescription
Protected methodCustomBindAction
(Overrides StandardPostProcessCustomBindAction(RenderingContext, CommandBuffer, PipelineLayout))
Protected methodGetFragmentPushConstantsSize GetFragmentPushConstantsSize can be overriden to provide the size in bytes of the push constants in fragment shader.
(Overrides StandardPostProcessGetFragmentPushConstantsSize)
Top
See Also