[Mesa-dev] [PATCH 18/45] mesa: replace FEATURE_texture_fxt1 with FEATURE_GL define.

Oliver McFadden oliver.mcfadden at linux.intel.com
Tue Sep 11 02:56:31 PDT 2012


Signed-off-by: Oliver McFadden <oliver.mcfadden at linux.intel.com>
---
 src/mesa/main/extensions.c       |    2 +-
 src/mesa/main/formats.c          |    2 +-
 src/mesa/main/mfeatures.h        |    1 -
 src/mesa/main/texcompress.c      |    2 +-
 src/mesa/main/texcompress_fxt1.c |    4 ++--
 src/mesa/main/texcompress_fxt1.h |    6 +++---
 src/mesa/main/texformat.c        |    2 +-
 7 files changed, 9 insertions(+), 10 deletions(-)

diff --git a/src/mesa/main/extensions.c b/src/mesa/main/extensions.c
index 4b69661..b16519d 100644
--- a/src/mesa/main/extensions.c
+++ b/src/mesa/main/extensions.c
@@ -524,7 +524,7 @@ _mesa_enable_sw_extensions(struct gl_context *ctx)
 #if FEATURE_ARB_vertex_program || FEATURE_ARB_fragment_program
    ctx->Extensions.EXT_gpu_program_parameters = GL_TRUE;
 #endif
-#if FEATURE_texture_fxt1
+#if FEATURE_GL
    _mesa_enable_extension(ctx, "GL_3DFX_texture_compression_FXT1");
 #endif
 #if FEATURE_texture_s3tc
diff --git a/src/mesa/main/formats.c b/src/mesa/main/formats.c
index 1fa641c..bd45090 100644
--- a/src/mesa/main/formats.c
+++ b/src/mesa/main/formats.c
@@ -2265,7 +2265,7 @@ _mesa_format_to_type_and_comps(gl_format format,
       return;
 #endif
 
-#if FEATURE_texture_fxt1
+#if FEATURE_GL
    case MESA_FORMAT_RGB_FXT1:
    case MESA_FORMAT_RGBA_FXT1:
 #endif
diff --git a/src/mesa/main/mfeatures.h b/src/mesa/main/mfeatures.h
index 8062628..97bb8b2 100644
--- a/src/mesa/main/mfeatures.h
+++ b/src/mesa/main/mfeatures.h
@@ -84,7 +84,6 @@
 #define FEATURE_remap_table               0
 #endif
 
-#define FEATURE_texture_fxt1              FEATURE_GL
 #define FEATURE_texture_s3tc              FEATURE_GL
 
 #define FEATURE_extra_context_init        FEATURE_ES
diff --git a/src/mesa/main/texcompress.c b/src/mesa/main/texcompress.c
index 846d4bb..91eabe0 100644
--- a/src/mesa/main/texcompress.c
+++ b/src/mesa/main/texcompress.c
@@ -375,7 +375,7 @@ GLenum
 _mesa_compressed_format_to_glenum(struct gl_context *ctx, gl_format mesaFormat)
 {
    switch (mesaFormat) {
-#if FEATURE_texture_fxt1
+#if FEATURE_GL
    case MESA_FORMAT_RGB_FXT1:
       return GL_COMPRESSED_RGB_FXT1_3DFX;
    case MESA_FORMAT_RGBA_FXT1:
diff --git a/src/mesa/main/texcompress_fxt1.c b/src/mesa/main/texcompress_fxt1.c
index 92af29a..90ef62c 100644
--- a/src/mesa/main/texcompress_fxt1.c
+++ b/src/mesa/main/texcompress_fxt1.c
@@ -42,7 +42,7 @@
 #include "swrast/s_context.h"
 
 
-#if FEATURE_texture_fxt1
+#if FEATURE_GL
 
 
 static void
@@ -1648,4 +1648,4 @@ fxt1_decode_1 (const void *texture, GLint stride, /* in pixels */
 }
 
 
-#endif /* FEATURE_texture_fxt1 */
+#endif /* FEATURE_GL */
diff --git a/src/mesa/main/texcompress_fxt1.h b/src/mesa/main/texcompress_fxt1.h
index bd84082..67dfe45 100644
--- a/src/mesa/main/texcompress_fxt1.h
+++ b/src/mesa/main/texcompress_fxt1.h
@@ -31,7 +31,7 @@
 
 struct swrast_texture_image;
 
-#if FEATURE_texture_fxt1
+#if FEATURE_GL
 
 extern GLboolean
 _mesa_texstore_rgb_fxt1(TEXSTORE_PARAMS);
@@ -47,7 +47,7 @@ extern void
 _mesa_fetch_texel_2d_f_rgb_fxt1(const struct swrast_texture_image *texImage,
                                 GLint i, GLint j, GLint k, GLfloat *texel);
 
-#else /* FEATURE_texture_fxt1 */
+#else /* FEATURE_GL */
 
 /* these are used only in texstore_funcs[] */
 #define _mesa_texstore_rgb_fxt1 NULL
@@ -57,6 +57,6 @@ _mesa_fetch_texel_2d_f_rgb_fxt1(const struct swrast_texture_image *texImage,
 #define _mesa_fetch_texel_2d_f_rgba_fxt1 NULL
 #define _mesa_fetch_texel_2d_f_rgb_fxt1 NULL
 
-#endif /* FEATURE_texture_fxt1 */
+#endif /* FEATURE_GL */
 
 #endif /* TEXCOMPRESS_FXT1_H */
diff --git a/src/mesa/main/texformat.c b/src/mesa/main/texformat.c
index 1a318ab..fa86686 100644
--- a/src/mesa/main/texformat.c
+++ b/src/mesa/main/texformat.c
@@ -289,7 +289,7 @@ _mesa_choose_tex_format(struct gl_context *ctx, GLenum target,
       }
    }
 
-#if FEATURE_texture_fxt1
+#if FEATURE_GL
    if (ctx->Extensions.TDFX_texture_compression_FXT1) {
       switch (internalFormat) {
          case GL_COMPRESSED_RGB_FXT1_3DFX:
-- 
1.7.8.6



More information about the mesa-dev mailing list