mesa: GL_EXT_shadow_funcs is not optional with GL_ARB_shadow
authorIan Romanick <ian.d.romanick@intel.com>
Fri, 28 Jun 2013 01:20:34 +0000 (18:20 -0700)
committerKenneth Graunke <kenneth@whitecape.org>
Fri, 28 Jun 2013 20:35:22 +0000 (13:35 -0700)
Every driver left in Mesa that enables one also enables the other.
There's no reason to let it be optional.

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/drivers/dri/i915/intel_extensions.c
src/mesa/drivers/dri/i965/intel_extensions.c
src/mesa/main/extensions.c
src/mesa/main/mtypes.h
src/mesa/main/samplerobj.c
src/mesa/main/texparam.c
src/mesa/main/version.c
src/mesa/state_tracker/st_extensions.c

index 479217b889dc5c2f66968bd38e35ee25f33d71aa..1e48231ba6e1eed14b754f398e81496e39ed39bc 100644 (file)
@@ -91,7 +91,6 @@ intelInitExtensions(struct gl_context *ctx)
       ctx->Extensions.ARB_texture_non_power_of_two = true;
       ctx->Extensions.EXT_texture_sRGB = true;
       ctx->Extensions.EXT_texture_sRGB_decode = true;
-      ctx->Extensions.EXT_shadow_funcs = true;
       ctx->Extensions.EXT_stencil_two_side = true;
       ctx->Extensions.ATI_separate_stencil = true;
       ctx->Extensions.ATI_texture_env_combine3 = true;
index 980fd724f78e9c3a7083dd8a57249ce354929127..820c18508078605441c70741bf7bda89f41bd9dd 100644 (file)
@@ -105,7 +105,6 @@ intelInitExtensions(struct gl_context *ctx)
    ctx->Extensions.EXT_texture_sRGB = true;
    ctx->Extensions.EXT_texture_sRGB_decode = true;
    ctx->Extensions.EXT_texture_swizzle = true;
-   ctx->Extensions.EXT_shadow_funcs = true;
    ctx->Extensions.EXT_stencil_two_side = true;
    ctx->Extensions.EXT_vertex_array_bgra = true;
    ctx->Extensions.APPLE_object_purgeable = true;
index 3fbdf3fd7db87750d7f8118353095242bcc069e7..e0428c683268c2181b29efdd27ba66074dda5073 100644 (file)
@@ -201,7 +201,7 @@ static const struct extension extension_table[] = {
    { "GL_EXT_secondary_color",                     o(dummy_true),                              GLL,            1999 },
    { "GL_EXT_separate_shader_objects",             o(EXT_separate_shader_objects),             GLL,            2008 },
    { "GL_EXT_separate_specular_color",             o(dummy_true),                              GLL,            1997 },
-   { "GL_EXT_shadow_funcs",                        o(EXT_shadow_funcs),                        GLL,            2002 },
+   { "GL_EXT_shadow_funcs",                        o(ARB_shadow),                              GLL,            2002 },
    { "GL_EXT_stencil_two_side",                    o(EXT_stencil_two_side),                    GLL,            2001 },
    { "GL_EXT_stencil_wrap",                        o(dummy_true),                              GLL,            2002 },
    { "GL_EXT_subtexture",                          o(dummy_true),                              GLL,            1995 },
@@ -424,7 +424,6 @@ _mesa_enable_sw_extensions(struct gl_context *ctx)
    ctx->Extensions.EXT_pixel_buffer_object = GL_TRUE;
    ctx->Extensions.EXT_point_parameters = GL_TRUE;
    ctx->Extensions.EXT_provoking_vertex = GL_TRUE;
-   ctx->Extensions.EXT_shadow_funcs = GL_TRUE;
    ctx->Extensions.EXT_stencil_two_side = GL_TRUE;
    ctx->Extensions.EXT_texture_array = GL_TRUE;
    ctx->Extensions.EXT_texture_compression_latc = GL_TRUE;
index d405ac8177ec62ded9540fc014bbee008fa7dc3c..1f62e2c9c9e087cb2d3caf48813c97744f10370d 100644 (file)
@@ -3061,7 +3061,6 @@ struct gl_extensions
    GLboolean EXT_pixel_buffer_object;
    GLboolean EXT_point_parameters;
    GLboolean EXT_provoking_vertex;
-   GLboolean EXT_shadow_funcs;
    GLboolean EXT_separate_shader_objects;
    GLboolean EXT_stencil_two_side;
    GLboolean EXT_texture3D;
index 91b17ab5ebf046bb2c305cfa2f9d78f564d7c88b..3857eda06515209691457fb90e26a63bfa14afa0 100644 (file)
@@ -529,21 +529,15 @@ set_sampler_compare_func(struct gl_context *ctx,
    switch (param) {
    case GL_LEQUAL:
    case GL_GEQUAL:
-      flush(ctx);
-      samp->CompareFunc = param;
-      return GL_TRUE;
    case GL_EQUAL:
    case GL_NOTEQUAL:
    case GL_LESS:
    case GL_GREATER:
    case GL_ALWAYS:
    case GL_NEVER:
-      if (ctx->Extensions.EXT_shadow_funcs) {
-         flush(ctx);
-         samp->CompareFunc = param;
-         return GL_TRUE;
-      }
-      /* fall-through */
+      flush(ctx);
+      samp->CompareFunc = param;
+      return GL_TRUE;
    default:
       return INVALID_PARAM;
    }
index 39cdad35e8ede242cfddd13315a858caba0eaf50..cf9a3014cde3fce5e69c9f7d2565afc1e4c4d1e3 100644 (file)
@@ -446,21 +446,15 @@ set_tex_parameteri(struct gl_context *ctx,
          switch (params[0]) {
          case GL_LEQUAL:
          case GL_GEQUAL:
-            flush(ctx);
-            texObj->Sampler.CompareFunc = params[0];
-            return GL_TRUE;
          case GL_EQUAL:
          case GL_NOTEQUAL:
          case GL_LESS:
          case GL_GREATER:
          case GL_ALWAYS:
          case GL_NEVER:
-            if (ctx->Extensions.EXT_shadow_funcs) {
-               flush(ctx);
-               texObj->Sampler.CompareFunc = params[0];
-               return GL_TRUE;
-            }
-            /* fall-through */
+            flush(ctx);
+            texObj->Sampler.CompareFunc = params[0];
+            return GL_TRUE;
          default:
             goto invalid_param;
          }
index 1bff19fbd0050d9961eb96c40f3b4226a49eb3fa..ab9b14c026ece457fdc27b14f1ec350bd3e452b0 100644 (file)
@@ -207,8 +207,7 @@ compute_version(struct gl_context *ctx)
                               ctx->Extensions.EXT_blend_minmax &&
                               ctx->Extensions.EXT_point_parameters);
    const GLboolean ver_1_5 = (ver_1_4 &&
-                              ctx->Extensions.ARB_occlusion_query &&
-                              ctx->Extensions.EXT_shadow_funcs);
+                              ctx->Extensions.ARB_occlusion_query);
    const GLboolean ver_2_0 = (ver_1_5 &&
                               ctx->Extensions.ARB_point_sprite &&
                               ctx->Extensions.ARB_vertex_shader &&
index 906eb07a22061b0cb36f3ed66dbc961daed085d9..83e8e2e969681a547af826a88c9b4fc5b49d0a74 100644 (file)
@@ -397,7 +397,6 @@ void st_init_extensions(struct st_context *st)
 
       { o(EXT_blend_equation_separate),      PIPE_CAP_BLEND_EQUATION_SEPARATE          },
       { o(EXT_draw_buffers2),                PIPE_CAP_INDEP_BLEND_ENABLE               },
-      { o(EXT_shadow_funcs),                 PIPE_CAP_TEXTURE_SHADOW_MAP               },
       { o(EXT_stencil_two_side),             PIPE_CAP_TWO_SIDED_STENCIL                },
       { o(EXT_texture_array),                PIPE_CAP_MAX_TEXTURE_ARRAY_LAYERS         },
       { o(EXT_texture_filter_anisotropic),   PIPE_CAP_ANISOTROPIC_FILTER               },