summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLuca Barbieri <luca@luca-barbieri.com>2010-08-20 10:36:17 +0200
committerLuca Barbieri <luca@luca-barbieri.com>2010-09-05 18:01:35 +0200
commit49a9948b6a81b7d813304d081139d98e95ba5d1a (patch)
tree4fa7a8b4c54b89d176bbe37e7055fb3d69bcbc65
parent7383632f7b6f9021b65f4973b7e7c99f0e8ce9b2 (diff)
mesa/st: enable ARB_texture_float if supported formats allow it
-rw-r--r--src/mesa/state_tracker/st_extensions.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/mesa/state_tracker/st_extensions.c b/src/mesa/state_tracker/st_extensions.c
index 4eb39b2c52..b8e2c8d4d5 100644
--- a/src/mesa/state_tracker/st_extensions.c
+++ b/src/mesa/state_tracker/st_extensions.c
@@ -344,6 +344,16 @@ void st_init_extensions(struct st_context *st)
ctx->Extensions.EXT_packed_depth_stencil = GL_TRUE;
}
+ /* float support - assume nothing exclusively supports 64-bit floats */
+ if (screen->is_format_supported(screen, PIPE_FORMAT_R32G32B32A32_FLOAT,
+ PIPE_TEXTURE_2D, 0,
+ PIPE_BIND_SAMPLER_VIEW, 0) ||
+ screen->is_format_supported(screen, PIPE_FORMAT_R16G16B16A16_FLOAT,
+ PIPE_TEXTURE_2D, 0,
+ PIPE_BIND_SAMPLER_VIEW, 0)) {
+ ctx->Extensions.ARB_texture_float = GL_TRUE;
+ }
+
/* sRGB support */
if (screen->is_format_supported(screen, PIPE_FORMAT_A8B8G8R8_SRGB,
PIPE_TEXTURE_2D, 0,