mesa/es: Remove redundant min/mag filter validation
authorIan Romanick <ian.d.romanick@intel.com>
Mon, 3 Oct 2011 20:05:47 +0000 (13:05 -0700)
committerIan Romanick <ian.d.romanick@intel.com>
Mon, 20 Aug 2012 16:52:27 +0000 (09:52 -0700)
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Brian Paul <brianp@vmware.com>
src/mesa/main/APIspec.xml
src/mesa/main/es1_conversion.c

index b6cf52d074a778f0bba8e64ef2a59226960c4ed8..1b8dae396bad6787f1f1b01fffcb2d6ceefc801d 100644 (file)
                </desc>
        </desc>
 
-       <desc name="pname">
-               <value name="GL_TEXTURE_MIN_FILTER"/>
-
-               <desc name="param">
-                       <value name="GL_NEAREST"/>
-                       <value name="GL_LINEAR"/>
-                       <value name="GL_NEAREST_MIPMAP_NEAREST"/>
-                       <value name="GL_NEAREST_MIPMAP_LINEAR"/>
-                       <value name="GL_LINEAR_MIPMAP_NEAREST"/>
-                       <value name="GL_LINEAR_MIPMAP_LINEAR"/>
-               </desc>
-       </desc>
-
-       <desc name="pname">
-               <value name="GL_TEXTURE_MAG_FILTER"/>
-
-               <desc name="param">
-                       <value name="GL_NEAREST"/>
-                       <value name="GL_LINEAR"/>
-               </desc>
-       </desc>
+        <desc name="pname">
+               <value name="GL_TEXTURE_MIN_FILTER"/>
+               <value name="GL_TEXTURE_MAG_FILTER"/>
+        </desc>
 
        <desc name="pname" category="GLES1.1">
                <value name="GL_GENERATE_MIPMAP"/>
index b8ae2673807a7d6c4d1c359bfb66d11bf1b677b1..9e8dbf2045a996b59980930581d1a6c2a8751984 100644 (file)
@@ -1376,19 +1376,7 @@ _es_TexParameterx(GLenum target, GLenum pname, GLfixed param)
       convert_param_value = false;
       break;
    case GL_TEXTURE_MIN_FILTER:
-      if (param != GL_NEAREST && param != GL_LINEAR && param != GL_NEAREST_MIPMAP_NEAREST && param != GL_NEAREST_MIPMAP_LINEAR && param != GL_LINEAR_MIPMAP_NEAREST && param != GL_LINEAR_MIPMAP_LINEAR) {
-         _mesa_error(_mesa_get_current_context(), GL_INVALID_ENUM,
-                     "glTexParameterx(pname=0x%x)", pname);
-         return;
-      }
-      convert_param_value = false;
-      break;
    case GL_TEXTURE_MAG_FILTER:
-      if (param != GL_NEAREST && param != GL_LINEAR) {
-         _mesa_error(_mesa_get_current_context(), GL_INVALID_ENUM,
-                     "glTexParameterx(pname=0x%x)", pname);
-         return;
-      }
       convert_param_value = false;
       break;
    case GL_GENERATE_MIPMAP:
@@ -1446,20 +1434,7 @@ _es_TexParameterxv(GLenum target, GLenum pname, const GLfixed *params)
       n_params = 1;
       break;
    case GL_TEXTURE_MIN_FILTER:
-      if (params[0] != GL_NEAREST && params[0] != GL_LINEAR && params[0] != GL_NEAREST_MIPMAP_NEAREST && params[0] != GL_NEAREST_MIPMAP_LINEAR && params[0] != GL_LINEAR_MIPMAP_NEAREST && params[0] != GL_LINEAR_MIPMAP_LINEAR) {
-         _mesa_error(_mesa_get_current_context(), GL_INVALID_ENUM,
-                     "glTexParameterxv(pname=0x%x)", pname);
-         return;
-      }
-      convert_params_value = false;
-      n_params = 1;
-      break;
    case GL_TEXTURE_MAG_FILTER:
-      if (params[0] != GL_NEAREST && params[0] != GL_LINEAR) {
-         _mesa_error(_mesa_get_current_context(), GL_INVALID_ENUM,
-                     "glTexParameterxv(pname=0x%x)", pname);
-         return;
-      }
       convert_params_value = false;
       n_params = 1;
       break;