Added new shaders
Some checks failed
CI / Native Windows Build And Tests (push) Has been cancelled
CI / React UI Build (push) Has been cancelled
CI / Windows Release Package (push) Has been cancelled

This commit is contained in:
2026-05-05 22:36:52 +10:00
parent 119e49aec1
commit ce5905373a
32 changed files with 882 additions and 78 deletions

View File

@@ -0,0 +1,20 @@
float3 applyLiftGammaGainOffset(float3 color)
{
float3 liftAdjust = (lift.rgb - 0.5) * 0.5;
float3 offsetAdjust = (offset.rgb - 0.5) * 0.5;
float3 gammaAdjust = exp2((gamma.rgb - 0.5) * 2.0);
float3 gainAdjust = exp2((gain.rgb - 0.5) * 2.0);
float3 lifted = color + liftAdjust;
float3 gained = lifted * gainAdjust;
float3 corrected = pow(saturate(gained), 1.0 / max(gammaAdjust, float3(0.001)));
return corrected + offsetAdjust;
}
float4 shadeVideo(ShaderContext context)
{
float4 source = context.sourceColor;
float3 graded = applyLiftGammaGainOffset(source.rgb);
source.rgb = lerp(source.rgb, graded, strength);
return saturate(source);
}