mesa: actually check for EXT_color_buffer_float support

EXT_color_buffer_float makes both 16 and 32 bit floating-point texture
formats color-renderable. We can't just unconditionally report that, we
need to check for support.

The RGB formats are a bit special under this extension, because it's not
specified as color-renderable. However, because the RGBA formats *are*
specified as color-renderable, and the state-tracker can emulate the RGB
formats with the RGBA ones, we don't need to test for that here.

While we're at it, move EXT_color_buffer_half_float to its correct
sorted position.

Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26870>
This commit is contained in:
Erik Faye-Lund
2024-01-03 11:20:25 +01:00
committed by Marge Bot
parent 5f995f5e34
commit 782fb8966b
3 changed files with 11 additions and 2 deletions
+2 -1
View File
@@ -64,7 +64,6 @@ struct gl_extensions
GLboolean ARB_conservative_depth;
GLboolean ARB_copy_image;
GLboolean ARB_cull_distance;
GLboolean EXT_color_buffer_half_float;
GLboolean ARB_depth_buffer_float;
GLboolean ARB_depth_clamp;
GLboolean ARB_derivative_control;
@@ -161,6 +160,8 @@ struct gl_extensions
GLboolean ARB_vertex_type_2_10_10_10_rev;
GLboolean ARB_viewport_array;
GLboolean EXT_blend_equation_separate;
GLboolean EXT_color_buffer_float;
GLboolean EXT_color_buffer_half_float;
GLboolean EXT_demote_to_helper_invocation;
GLboolean EXT_depth_bounds_test;
GLboolean EXT_disjoint_timer_query;
+1 -1
View File
@@ -227,7 +227,7 @@ EXT(EXT_buffer_storage , ARB_buffer_storage
EXT(EXT_clear_texture , dummy_true , x , x , x , 31, 2016)
EXT(EXT_clip_control , ARB_clip_control , x , x , x , ES2, 2017)
EXT(EXT_clip_cull_distance , ARB_cull_distance , x , x , x , 30, 2016)
EXT(EXT_color_buffer_float , dummy_true , x , x , x , 30, 2013)
EXT(EXT_color_buffer_float , EXT_color_buffer_float , x , x , x , 30, 2013)
EXT(EXT_color_buffer_half_float , EXT_color_buffer_half_float , x , x , x , 20, 2017)
EXT(EXT_compiled_vertex_array , dummy_true , GLL, x , x , x , 1996)
EXT(EXT_compressed_ETC1_RGB8_sub_texture , OES_compressed_ETC1_RGB8_texture , x , x , ES1, ES2, 2014)
+8
View File
@@ -916,6 +916,14 @@ void st_init_extensions(struct pipe_screen *screen,
{ PIPE_FORMAT_R16_FLOAT,
PIPE_FORMAT_R16G16_FLOAT,
PIPE_FORMAT_R16G16B16A16_FLOAT } },
{ { o(EXT_color_buffer_float) },
{ PIPE_FORMAT_R16_FLOAT,
PIPE_FORMAT_R16G16_FLOAT,
PIPE_FORMAT_R16G16B16A16_FLOAT,
PIPE_FORMAT_R32_FLOAT,
PIPE_FORMAT_R32G32_FLOAT,
PIPE_FORMAT_R32G32B32A32_FLOAT } },
};
/* Required: render target, sampler, and blending */