if (intel->ctx.Mesa_DXTn) {
ctx->Extensions.ANGLE_texture_compression_dxt = true;
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;
ctx->Extensions.NV_texture_rectangle = true;
if (ctx->Mesa_DXTn) {
ctx->Extensions.EXT_texture_compression_s3tc = true;
- ctx->Extensions.S3_s3tc = true;
+ ctx->Extensions.ANGLE_texture_compression_dxt = true;
}
/* GL constants. */
ctx->Extensions.NV_texture_rectangle = true;
if (ctx->Mesa_DXTn) {
ctx->Extensions.EXT_texture_compression_s3tc = true;
- ctx->Extensions.S3_s3tc = true;
+ ctx->Extensions.ANGLE_texture_compression_dxt = true;
}
/* GL constants. */
}
if (rmesa->radeon.glCtx.Mesa_DXTn) {
ctx->Extensions.EXT_texture_compression_s3tc = true;
- ctx->Extensions.S3_s3tc = true;
+ ctx->Extensions.ANGLE_texture_compression_dxt = true;
}
else if (driQueryOptionb (&rmesa->radeon.optionCache, "force_s3tc_enable")) {
ctx->Extensions.EXT_texture_compression_s3tc = true;
+ ctx->Extensions.ANGLE_texture_compression_dxt = true;
}
ctx->Extensions.ARB_texture_cube_map = true;
if (rmesa->radeon.glCtx.Mesa_DXTn) {
ctx->Extensions.EXT_texture_compression_s3tc = true;
- ctx->Extensions.S3_s3tc = true;
+ ctx->Extensions.ANGLE_texture_compression_dxt = true;
}
else if (driQueryOptionb (&rmesa->radeon.optionCache, "force_s3tc_enable")) {
ctx->Extensions.EXT_texture_compression_s3tc = true;
+ ctx->Extensions.ANGLE_texture_compression_dxt = true;
}
ctx->Extensions.NV_texture_rectangle = true;
_mesa_enable_2_1_extensions(mesaCtx);
if (mesaCtx->Mesa_DXTn) {
_mesa_enable_extension(mesaCtx, "GL_EXT_texture_compression_s3tc");
- _mesa_enable_extension(mesaCtx, "GL_S3_s3tc");
+ _mesa_enable_extension(mesaCtx, "GL_ANGLE_texture_compression_dxt");
}
_mesa_enable_extension(mesaCtx, "GL_3DFX_texture_compression_FXT1");
#if ENABLE_EXT_timer_query
{ "GL_EXT_subtexture", o(dummy_true), GLL, 1995 },
{ "GL_EXT_texture3D", o(EXT_texture3D), GLL, 1996 },
{ "GL_EXT_texture_array", o(EXT_texture_array), GL, 2006 },
- { "GL_EXT_texture_compression_dxt1", o(EXT_texture_compression_s3tc), GL | ES1 | ES2, 2004 },
+ { "GL_EXT_texture_compression_dxt1", o(ANGLE_texture_compression_dxt), GL | ES1 | ES2, 2004 },
{ "GL_ANGLE_texture_compression_dxt3", o(ANGLE_texture_compression_dxt), ES2, 2011 },
{ "GL_ANGLE_texture_compression_dxt5", o(ANGLE_texture_compression_dxt), ES2, 2011 },
{ "GL_EXT_texture_compression_latc", o(EXT_texture_compression_latc), GL, 2006 },
{ "GL_NV_texture_barrier", o(NV_texture_barrier), GL, 2009 },
{ "GL_NV_texture_env_combine4", o(NV_texture_env_combine4), GLL, 1999 },
{ "GL_NV_texture_rectangle", o(NV_texture_rectangle), GLL, 2000 },
- { "GL_S3_s3tc", o(S3_s3tc), GL, 1999 },
+ { "GL_S3_s3tc", o(ANGLE_texture_compression_dxt), GL, 1999 },
{ "GL_SGIS_generate_mipmap", o(dummy_true), GLL, 1997 },
{ "GL_SGIS_texture_border_clamp", o(ARB_texture_border_clamp), GLL, 1997 },
{ "GL_SGIS_texture_edge_clamp", o(dummy_true), GLL, 1997 },
case GL_RGB4_S3TC:
case GL_RGBA_S3TC:
case GL_RGBA4_S3TC:
- return _mesa_is_desktop_gl(ctx) && ctx->Extensions.S3_s3tc;
+ return _mesa_is_desktop_gl(ctx) &&
+ ctx->Extensions.ANGLE_texture_compression_dxt;
case GL_COMPRESSED_SRGB_S3TC_DXT1_EXT:
case GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT:
case GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT:
GLboolean NV_texture_env_combine4;
GLboolean NV_texture_rectangle;
GLboolean TDFX_texture_compression_FXT1;
- GLboolean S3_s3tc;
GLboolean OES_EGL_image;
GLboolean OES_draw_texture;
GLboolean OES_depth_texture_cube_map;
#include "formats.h"
#include "mfeatures.h"
#include "mtypes.h"
+#include "context.h"
#include "texcompress.h"
#include "texcompress_fxt1.h"
#include "texcompress_rgtc.h"
n += 3;
}
}
- if (ctx->Extensions.S3_s3tc) {
+ if (_mesa_is_desktop_gl(ctx)
+ && ctx->Extensions.ANGLE_texture_compression_dxt) {
if (formats) {
formats[n++] = GL_RGB_S3TC;
formats[n++] = GL_RGB4_S3TC;
*/
if (target != GL_TEXTURE_1D && target != GL_TEXTURE_1D_ARRAY) {
if (ctx->Extensions.EXT_texture_compression_s3tc ||
- ctx->Extensions.S3_s3tc)
+ ctx->Extensions.ANGLE_texture_compression_dxt)
RETURN_IF_SUPPORTED(MESA_FORMAT_RGB_DXT1);
if (ctx->Extensions.TDFX_texture_compression_FXT1)
RETURN_IF_SUPPORTED(MESA_FORMAT_RGB_FXT1);
/* We don't use texture compression for 1D and 1D array textures. */
if (target != GL_TEXTURE_1D && target != GL_TEXTURE_1D_ARRAY) {
if (ctx->Extensions.EXT_texture_compression_s3tc ||
- ctx->Extensions.S3_s3tc)
+ ctx->Extensions.ANGLE_texture_compression_dxt)
RETURN_IF_SUPPORTED(MESA_FORMAT_RGBA_DXT3); /* Not rgba_dxt1, see spec */
if (ctx->Extensions.TDFX_texture_compression_FXT1)
RETURN_IF_SUPPORTED(MESA_FORMAT_RGBA_FXT1);
}
}
- if (ctx->Extensions.S3_s3tc) {
+ if (_mesa_is_desktop_gl(ctx)
+ && ctx->Extensions.ANGLE_texture_compression_dxt) {
switch (internalFormat) {
case GL_RGB_S3TC:
case GL_RGB4_S3TC:
}
}
- if (ctx->Extensions.S3_s3tc) {
+ if (_mesa_is_desktop_gl(ctx)
+ && ctx->Extensions.ANGLE_texture_compression_dxt) {
switch (internalFormat) {
case GL_RGB_S3TC:
case GL_RGB4_S3TC:
PIPE_FORMAT_LATC2_SNORM } },
{ { o(EXT_texture_compression_s3tc),
- o(S3_s3tc) },
+ o(ANGLE_texture_compression_dxt) },
{ PIPE_FORMAT_DXT1_RGB,
PIPE_FORMAT_DXT1_RGBA,
PIPE_FORMAT_DXT3_RGBA,
if (!ctx->Mesa_DXTn && !st_get_s3tc_override()) {
ctx->Extensions.EXT_texture_compression_s3tc = GL_FALSE;
- ctx->Extensions.S3_s3tc = GL_FALSE;
+ ctx->Extensions.ANGLE_texture_compression_dxt = GL_FALSE;
}
if (screen->get_shader_param(screen, PIPE_SHADER_GEOMETRY,