🔧 Use color management only on plasma 6

This commit is contained in:
Simon Schneegans
2024-10-29 21:03:01 +01:00
parent e0be4d85f0
commit 5386887d29
+14
View File
@@ -42,7 +42,9 @@ uniform float uDuration;
#if defined(KWIN) // --------------------------------------------------------------------
#if defined(PLASMA6)
#include "colormanagement.glsl"
#endif
uniform sampler2D sampler;
uniform int textureWidth;
@@ -76,12 +78,19 @@ void setOutputColor(vec4 outColor) {
}
fragColor = vec4(outColor.rgb * outColor.a, outColor.a);
#if defined(PLASMA6)
fragColor = sourceEncodingToNitsInDestinationColorspace(fragColor);
fragColor = nitsToDestinationEncoding(fragColor);
#endif
}
#elif defined(KWIN_LEGACY) // -----------------------------------------------------------
#if defined(PLASMA6)
#include "colormanagement.glsl"
#endif
uniform sampler2D sampler;
uniform int textureWidth;
uniform int textureHeight;
@@ -112,6 +121,11 @@ void setOutputColor(vec4 outColor) {
}
gl_FragColor = vec4(outColor.rgb * outColor.a, outColor.a);
#if defined(PLASMA6)
fragColor = sourceEncodingToNitsInDestinationColorspace(fragColor);
fragColor = nitsToDestinationEncoding(fragColor);
#endif
}
#else // GNOME --------------------------------------------------------------------------