Explorar el Código

Prevent attempting to compile the ColorCorrection function (uses unsupported sampler3D) on GLES.

Lasse Öörni hace 10 años
padre
commit
1d6a980136
Se han modificado 1 ficheros con 2 adiciones y 0 borrados
  1. 2 0
      bin/CoreData/Shaders/GLSL/PostProcess.glsl

+ 2 - 0
bin/CoreData/Shaders/GLSL/PostProcess.glsl

@@ -64,6 +64,7 @@ vec3 Uncharted2Tonemap(vec3 x)
    return ((x*(A*x+C*B)+D*E)/(x*(A*x+B)+D*F))-E/F;
 }
 
+#ifndef GL_ES
 vec3 ColorCorrection(vec3 color, sampler3D lut)
 {
     float lutSize = 16.0;
@@ -71,6 +72,7 @@ vec3 ColorCorrection(vec3 color, sampler3D lut)
     float offset = 1.0 / (2.0 * lutSize);
     return texture3D(lut, clamp(color, 0.0, 1.0) * scale + offset).rgb;
 }
+#endif
 
 const float Gamma = 2.2;
 const float InverseGamma = 1.0 / 2.2;