Fix compilation on iOS. Fix shader compilation on OpenGL ES. Fix (harmless) GL errors on OpenGL ES 2. Resolves issue #1266.

--HG--
branch : minor
This commit is contained in:
Alex Szpakowski
2017-03-09 20:46:26 -04:00
parent 5ce084051a
commit 1a9262dda9
4 changed files with 34 additions and 12 deletions
+9
View File
@@ -71,6 +71,15 @@ uniform LOVE_HIGHP_OR_MEDIUMP mat3 NormalMatrix;
uniform LOVE_HIGHP_OR_MEDIUMP vec4 love_ScreenSize;]]
GLSL.FUNCTIONS = [[
#ifdef GL_ES
#if __VERSION__ >= 300 || defined(GL_EXT_texture_array)
precision lowp sampler2DArray;
#endif
#if __VERSION__ >= 300 || defined(GL_OES_texture_3D)
precision lowp sampler3D;
#endif
#endif
#if __VERSION__ >= 130 && !defined(LOVE_GLSL1_ON_GLSL3)
#define Texel texture
#else