[Mesa-dev] [PATCH] mesa: Allow TexImage3D on depth/stencil textures in ES 3.0.

Kenneth Graunke kenneth at whitecape.org
Wed Jan 16 13:49:01 PST 2013


ES 3.0 supports 2D array textures, which are populated via TexImage3D.

Fixes es3conform's shadow_execution_frag test.

Signed-off-by: Kenneth Graunke <kenneth at whitecape.org>
---
 src/mesa/main/glformats.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/mesa/main/glformats.c b/src/mesa/main/glformats.c
index 7969f77..9831ab4 100644
--- a/src/mesa/main/glformats.c
+++ b/src/mesa/main/glformats.c
@@ -2068,7 +2068,7 @@ _mesa_es3_error_check_format_and_type(GLenum format, GLenum type,
       break;
 
    case GL_DEPTH_COMPONENT:
-      if (dimensions != 2) {
+      if (dimensions == 1) {
          return GL_INVALID_OPERATION;
       }
       switch (type) {
@@ -2098,7 +2098,7 @@ _mesa_es3_error_check_format_and_type(GLenum format, GLenum type,
       break;
 
    case GL_DEPTH_STENCIL:
-      if (dimensions != 2) {
+      if (dimensions == 1) {
          return GL_INVALID_OPERATION;
       }
       switch (type) {
-- 
1.8.1



More information about the mesa-dev mailing list