summaryrefslogtreecommitdiff
path: root/drivers/gles2/shaders/canvas.glsl
diff options
context:
space:
mode:
authorclayjohn <claynjohn@gmail.com>2020-01-14 23:53:13 -0800
committerclayjohn <claynjohn@gmail.com>2020-01-31 10:01:05 -0800
commit68915ce20db291a149631ce43f704f2998d5ba62 (patch)
treed34a049d0cc9ee9368d30124bc4f9d8310145866 /drivers/gles2/shaders/canvas.glsl
parent8eef6d280b42f098e15d0e1e6acf8189ae4be489 (diff)
Add support for 3D textures to GLES2
Diffstat (limited to 'drivers/gles2/shaders/canvas.glsl')
-rw-r--r--drivers/gles2/shaders/canvas.glsl12
1 files changed, 12 insertions, 0 deletions
diff --git a/drivers/gles2/shaders/canvas.glsl b/drivers/gles2/shaders/canvas.glsl
index afce403a9f..3b685b3f0b 100644
--- a/drivers/gles2/shaders/canvas.glsl
+++ b/drivers/gles2/shaders/canvas.glsl
@@ -10,6 +10,12 @@ precision highp float;
precision highp int;
#endif
+#ifndef USE_GLES_OVER_GL
+#extension GL_OES_texture_3D : enable
+#else
+#extension GL_EXT_texture_array : enable
+#endif
+
uniform highp mat4 projection_matrix;
/* clang-format on */
@@ -229,6 +235,12 @@ VERTEX_SHADER_CODE
/* clang-format off */
[fragment]
+#ifndef USE_GLES_OVER_GL
+#extension GL_OES_texture_3D : enable
+#else
+#extension GL_EXT_texture_array : enable
+#endif
+
// texture2DLodEXT and textureCubeLodEXT are fragment shader specific.
// Do not copy these defines in the vertex section.
#ifndef USE_GLES_OVER_GL