aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/dri
diff options
context:
space:
mode:
authorIan Romanick <[email protected]>2011-08-22 13:18:06 -0700
committerIan Romanick <[email protected]>2011-09-09 14:02:20 -0700
commit0a5478c1d9f9a892371d9ff004976e783a086694 (patch)
treee2da3e921dc5405da923dbfca64e555922f459fe /src/mesa/drivers/dri
parent71ceccad7e36f23e33d340fa0da157e2e0d2b6ac (diff)
intel: Move S3TC extension enable bits to intel_extensions.c
Reviewed-by: Eric Anholt <[email protected]> Reviewed-by: Kenneth Graunke <[email protected]>
Diffstat (limited to 'src/mesa/drivers/dri')
-rw-r--r--src/mesa/drivers/dri/intel/intel_context.c7
-rw-r--r--src/mesa/drivers/dri/intel/intel_extensions.c8
2 files changed, 8 insertions, 7 deletions
diff --git a/src/mesa/drivers/dri/intel/intel_context.c b/src/mesa/drivers/dri/intel/intel_context.c
index 165720fa107..2589ee54a2e 100644
--- a/src/mesa/drivers/dri/intel/intel_context.c
+++ b/src/mesa/drivers/dri/intel/intel_context.c
@@ -856,13 +856,6 @@ intelInitContext(struct intel_context *intel,
intel_fbo_init(intel);
- if (intel->ctx.Mesa_DXTn) {
- _mesa_enable_extension(ctx, "GL_EXT_texture_compression_s3tc");
- _mesa_enable_extension(ctx, "GL_S3_s3tc");
- }
- else if (driQueryOptionb(&intel->optionCache, "force_s3tc_enable")) {
- _mesa_enable_extension(ctx, "GL_EXT_texture_compression_s3tc");
- }
intel->use_texture_tiling = driQueryOptionb(&intel->optionCache,
"texture_tiling");
intel->use_early_z = driQueryOptionb(&intel->optionCache, "early_z");
diff --git a/src/mesa/drivers/dri/intel/intel_extensions.c b/src/mesa/drivers/dri/intel/intel_extensions.c
index 43b767f3445..3727b05dcdc 100644
--- a/src/mesa/drivers/dri/intel/intel_extensions.c
+++ b/src/mesa/drivers/dri/intel/intel_extensions.c
@@ -165,4 +165,12 @@ intelInitExtensions(struct gl_context *ctx)
if (driQueryOptionb(&intel->optionCache, "stub_occlusion_query"))
ctx->Extensions.ARB_occlusion_query = true;
}
+
+ if (intel->ctx.Mesa_DXTn) {
+ ctx->Extensions.EXT_texture_compression_s3tc = true;
+ ctx->Extensions.S3_s3tc = true;
+ }
+ else if (driQueryOptionb(&intel->optionCache, "force_s3tc_enable")) {
+ ctx->Extensions.EXT_texture_compression_s3tc = true;
+ }
}