mesa: add missing case in _mesa_GetTexParameterfv()
authorTapani Pälli <tapani.palli@intel.com>
Wed, 20 Feb 2013 11:00:07 +0000 (13:00 +0200)
committerChad Versace <chad.versace@linux.intel.com>
Mon, 25 Feb 2013 17:17:20 +0000 (09:17 -0800)
missing case GL_REQUIRED_TEXTURE_IMAGE_UNITS_OES is required
by OES_EGL_image_external extension.

Note: This is a candidate for the stable branches.
Signed-off-by: Tapani Pälli <tapani.palli@intel.com>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Chad Versace <chad.versace@linux.intel.com>
src/mesa/main/texparam.c

index b6afd35ba235eeb480796d58080d57cb777ea732..bc66bb36dbf680a398948353de28d8dada312945 100644 (file)
@@ -1444,6 +1444,12 @@ _mesa_GetTexParameterfv( GLenum target, GLenum pname, GLfloat *params )
          *params = (GLfloat) obj->Immutable;
          break;
 
+      case GL_REQUIRED_TEXTURE_IMAGE_UNITS_OES:
+         if (!_mesa_is_gles(ctx) || !ctx->Extensions.OES_EGL_image_external)
+            goto invalid_pname;
+         *params = obj->RequiredTextureImageUnits;
+         break;
+
       case GL_TEXTURE_SRGB_DECODE_EXT:
          if (!ctx->Extensions.EXT_texture_sRGB_decode)
             goto invalid_pname;