ClarityGFX

Fixed a issue where Gamma would not return any value.
This commit is contained in:
Jamie 2017-11-09 22:46:06 -08:00
parent 20ea9b085a
commit a1f07fb370

View File

@ -173,22 +173,22 @@ vec3 Technicolor2(vec3 inputColor) {
vec3 LiftGammaGainPass( vec3 colorInput )
{
// -- Get input --
vec3 color = colorInput.rgb;
vec3 color = colorInput;
// -- Lift --
color = color * (1.5-0.5 * RGB_Lift) + 0.5 * RGB_Lift - 0.5;
color = clamp(color, 0.0, 1. ); //isn't strictly necessary, but doesn't cost performance.
color = clamp(color, 0.0, 1.0); //isn't strictly necessary, but doesn't cost performance.
// -- Gain --
color *= RGB_Gain;
// -- Gamma --
colorInput.rgb = pow(color, 1.0 / RGB_Gamma); //Gamma
color = pow(color, 1.0 / RGB_Gamma); //Gamma
// -- Return output --
//return (colorInput);
return clamp(color, 0.0, 1. );
return clamp(color, 0.0, 1.0);
}
//LumaShapening