mesa: glGetTexParameter support for GL_ARB_texture_storage
authorBrian Paul <brianp@vmware.com>
Mon, 31 Oct 2011 16:52:56 +0000 (10:52 -0600)
committerBrian Paul <brianp@vmware.com>
Mon, 31 Oct 2011 16:52:56 +0000 (10:52 -0600)
src/mesa/main/texparam.c

index dc5ee33a2b2ae64774666b8757b635100914f81c..a2424484422dc90d22bf46499f5d3745ebd6e9ad 100644 (file)
@@ -1204,6 +1204,12 @@ _mesa_GetTexParameterfv( GLenum target, GLenum pname, GLfloat *params )
          *params = (GLfloat) obj->Sampler.CubeMapSeamless;
          break;
 
+      case GL_TEXTURE_IMMUTABLE_FORMAT:
+         if (!ctx->Extensions.ARB_texture_storage)
+            goto invalid_pname;
+         *params = (GLfloat) obj->Immutable;
+         break;
+
       default:
          goto invalid_pname;
    }
@@ -1338,6 +1344,12 @@ _mesa_GetTexParameteriv( GLenum target, GLenum pname, GLint *params )
          *params = (GLint) obj->Sampler.CubeMapSeamless;
          break;
 
+      case GL_TEXTURE_IMMUTABLE_FORMAT:
+         if (!ctx->Extensions.ARB_texture_storage)
+            goto invalid_pname;
+         *params = (GLint) obj->Immutable;
+         break;
+
       default:
          goto invalid_pname;
    }