# HG changeset patch # User John Tsiombikas # Date 1351292079 -10800 # Node ID 110b2af4b9d8ef1b9775e1a98be5e5f5b4f728df # Parent 12a1dcfe91fa157870324493bbec68c283db534c fixed the shader non-conformity by explicitly converting 2.2 to vec3 before passing it to pow for the texel inverse-gamma thing diff -r 12a1dcfe91fa -r 110b2af4b9d8 prototype/sdr/mrt.p.glsl --- a/prototype/sdr/mrt.p.glsl Fri Oct 26 21:22:14 2012 +0300 +++ b/prototype/sdr/mrt.p.glsl Sat Oct 27 01:54:39 2012 +0300 @@ -30,7 +30,7 @@ float fog = clamp((fog_end + pos.z) / (fog_end - fog_start), 0.0, 1.0); vec3 texel_srgb = texture2D(tex_dif, gl_TexCoord[0].st).xyz; - vec3 texel = pow(texel_srgb.xyz, 2.2); + vec3 texel = pow(texel_srgb.xyz, vec3(2.2, 2.2, 2.2)); vec3 diffuse = fog * (gl_FrontMaterial.diffuse.xyz * texel); vec3 spec = fog * gl_FrontMaterial.specular.xyz;