@@ -70,6 +70,10 @@ uniform vec3 blacklevel;
uniform float gamma;
uniform float contrastExp;
+#if defined(APPLY_LSC)
+uniform sampler2D lsc_tex;
+#endif
+
float apply_contrast(float value)
{
// Apply simple S-curve
@@ -227,6 +231,10 @@ void main(void)
rgb = rgb - blacklevel;
+#if defined(APPLY_LSC)
+ rgb = rgb * texture2D(lsc_tex, textureOut).rgb;
+#endif
+
/*
* CCM is a 3x3 in the format
*
@@ -29,6 +29,10 @@ uniform vec3 blacklevel;
uniform float gamma;
uniform float contrastExp;
+#if defined(APPLY_LSC)
+uniform sampler2D lsc_tex;
+#endif
+
float apply_contrast(float value)
{
// Apply simple S-curve
@@ -130,6 +134,10 @@ void main(void) {
rgb = rgb - blacklevel;
+#if defined(APPLY_LSC)
+ rgb = rgb * texture2D(lsc_tex, center.xy).rgb;
+#endif
+
/*
* CCM is a 3x3 in the format
*