summaryrefslogtreecommitdiffstats
path: root/src/mesa/state_tracker/st_extensions.c
diff options
context:
space:
mode:
authorJosé Fonseca <[email protected]>2008-07-19 12:04:37 +0900
committerJosé Fonseca <[email protected]>2008-07-19 12:32:29 +0900
commit8aafc03b260ab8923f1b373f7effa75bcdb40a72 (patch)
tree0274cc6cad2d6993ba8ea3fdd34c49254c532d47 /src/mesa/state_tracker/st_extensions.c
parentff26c50153b3a348b35843262ceb27062ab37214 (diff)
gallium: Finer grained is_format_supported.
Diffstat (limited to 'src/mesa/state_tracker/st_extensions.c')
-rw-r--r--src/mesa/state_tracker/st_extensions.c14
1 files changed, 10 insertions, 4 deletions
diff --git a/src/mesa/state_tracker/st_extensions.c b/src/mesa/state_tracker/st_extensions.c
index d804d2b453d..cacf972a1ba 100644
--- a/src/mesa/state_tracker/st_extensions.c
+++ b/src/mesa/state_tracker/st_extensions.c
@@ -213,18 +213,24 @@ void st_init_extensions(struct st_context *st)
}
if (screen->is_format_supported(screen, PIPE_FORMAT_R8G8B8A8_SRGB,
- PIPE_TEXTURE)) {
+ PIPE_TEXTURE_2D,
+ PIPE_TEXTURE_USAGE_SAMPLER, 0)) {
ctx->Extensions.EXT_texture_sRGB = GL_TRUE;
}
#if 01
if (screen->is_format_supported(screen, PIPE_FORMAT_DXT5_RGBA,
- PIPE_TEXTURE)) {
+ PIPE_TEXTURE_2D,
+ PIPE_TEXTURE_USAGE_SAMPLER, 0)) {
ctx->Extensions.EXT_texture_compression_s3tc = GL_TRUE;
}
#endif
- if (screen->is_format_supported(screen, PIPE_FORMAT_YCBCR, PIPE_TEXTURE) ||
- screen->is_format_supported(screen, PIPE_FORMAT_YCBCR_REV, PIPE_TEXTURE)) {
+ if (screen->is_format_supported(screen, PIPE_FORMAT_YCBCR,
+ PIPE_TEXTURE_2D,
+ PIPE_TEXTURE_USAGE_SAMPLER, 0) ||
+ screen->is_format_supported(screen, PIPE_FORMAT_YCBCR_REV,
+ PIPE_TEXTURE_2D,
+ PIPE_TEXTURE_USAGE_SAMPLER, 0)) {
ctx->Extensions.MESA_ycbcr_texture = GL_TRUE;
}