From 98c5ada8d10c5ceb06dc5fcccd20bf3acfc476e4 Mon Sep 17 00:00:00 2001 From: Patrick Lerda Date: Mon, 5 Jan 2026 13:00:40 +0100 Subject: [PATCH] r600: disable l8_srgb on r700 and older gpus The gamma is not processed by the hardware when processing a one component format texture (FMT_8). This change triggers a fall back to the r8g8b8a8_srgb format which is properly supported by the hardware of these older gpus. Here are the tests fixed on rv770: spec/arb_framebuffer_srgb/fbo-fast-clear: fail pass spec/ext_texture_srgb/fbo-fast-clear: fail pass spec/!opengl 1.1/teximage-colors gl_sluminance8/gl_sluminance8 texture with gl_.*: fail pass Signed-off-by: Patrick Lerda Part-of: --- .../drivers/r600/ci/r600-rv770-fails.txt | 88 ------------------- src/gallium/drivers/r600/r600_state.c | 3 + 2 files changed, 3 insertions(+), 88 deletions(-) diff --git a/src/gallium/drivers/r600/ci/r600-rv770-fails.txt b/src/gallium/drivers/r600/ci/r600-rv770-fails.txt index 08d8a50f110..f6ff4fca424 100644 --- a/src/gallium/drivers/r600/ci/r600-rv770-fails.txt +++ b/src/gallium/drivers/r600/ci/r600-rv770-fails.txt @@ -390,90 +390,6 @@ spec@!opengl 1.1@linestipple@Factor 2x,Fail spec@!opengl 1.1@linestipple@Factor 3x,Fail spec@!opengl 1.1@linestipple@Line loop,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_ABGR_EXT and GL_BYTE,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_ABGR_EXT and GL_FLOAT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_ABGR_EXT and GL_INT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_ABGR_EXT and GL_SHORT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_ABGR_EXT and GL_UNSIGNED_BYTE,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_ABGR_EXT and GL_UNSIGNED_INT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_ABGR_EXT and GL_UNSIGNED_SHORT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_BGR and GL_BYTE,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_BGR and GL_FLOAT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_BGR and GL_INT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_BGR and GL_SHORT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_BGR and GL_UNSIGNED_BYTE,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_BGR and GL_UNSIGNED_INT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_BGR and GL_UNSIGNED_SHORT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_BGRA and GL_BYTE,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_BGRA and GL_FLOAT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_BGRA and GL_INT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_BGRA and GL_SHORT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_BGRA and GL_UNSIGNED_BYTE,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_BGRA and GL_UNSIGNED_INT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_BGRA and GL_UNSIGNED_INT_10_10_10_2,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_BGRA and GL_UNSIGNED_INT_2_10_10_10_REV,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_BGRA and GL_UNSIGNED_INT_8_8_8_8,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_BGRA and GL_UNSIGNED_INT_8_8_8_8_REV,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_BGRA and GL_UNSIGNED_SHORT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_BGRA and GL_UNSIGNED_SHORT_1_5_5_5_REV,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_BGRA and GL_UNSIGNED_SHORT_4_4_4_4,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_BGRA and GL_UNSIGNED_SHORT_4_4_4_4_REV,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_BGRA and GL_UNSIGNED_SHORT_5_5_5_1,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_LUMINANCE and GL_BYTE,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_LUMINANCE and GL_FLOAT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_LUMINANCE and GL_INT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_LUMINANCE and GL_SHORT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_LUMINANCE and GL_UNSIGNED_BYTE,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_LUMINANCE and GL_UNSIGNED_INT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_LUMINANCE and GL_UNSIGNED_SHORT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_LUMINANCE_ALPHA and GL_BYTE,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_LUMINANCE_ALPHA and GL_FLOAT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_LUMINANCE_ALPHA and GL_INT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_LUMINANCE_ALPHA and GL_SHORT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_LUMINANCE_ALPHA and GL_UNSIGNED_BYTE,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_LUMINANCE_ALPHA and GL_UNSIGNED_INT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_LUMINANCE_ALPHA and GL_UNSIGNED_SHORT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RED and GL_BYTE,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RED and GL_FLOAT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RED and GL_INT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RED and GL_SHORT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RED and GL_UNSIGNED_BYTE,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RED and GL_UNSIGNED_INT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RED and GL_UNSIGNED_SHORT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RG and GL_BYTE,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RG and GL_FLOAT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RG and GL_INT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RG and GL_SHORT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RG and GL_UNSIGNED_BYTE,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RG and GL_UNSIGNED_INT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RG and GL_UNSIGNED_SHORT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RGB and GL_BYTE,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RGB and GL_FLOAT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RGB and GL_INT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RGB and GL_SHORT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RGB and GL_UNSIGNED_BYTE,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RGB and GL_UNSIGNED_BYTE_2_3_3_REV,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RGB and GL_UNSIGNED_BYTE_3_3_2,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RGB and GL_UNSIGNED_INT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RGB and GL_UNSIGNED_SHORT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RGB and GL_UNSIGNED_SHORT_5_6_5,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RGB and GL_UNSIGNED_SHORT_5_6_5_REV,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RGBA and GL_BYTE,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RGBA and GL_FLOAT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RGBA and GL_INT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RGBA and GL_SHORT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RGBA and GL_UNSIGNED_BYTE,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RGBA and GL_UNSIGNED_INT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RGBA and GL_UNSIGNED_INT_10_10_10_2,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RGBA and GL_UNSIGNED_INT_2_10_10_10_REV,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RGBA and GL_UNSIGNED_INT_8_8_8_8,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RGBA and GL_UNSIGNED_INT_8_8_8_8_REV,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RGBA and GL_UNSIGNED_SHORT,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RGBA and GL_UNSIGNED_SHORT_1_5_5_5_REV,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RGBA and GL_UNSIGNED_SHORT_4_4_4_4,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RGBA and GL_UNSIGNED_SHORT_4_4_4_4_REV,Fail -spec@!opengl 1.1@teximage-colors gl_sluminance8@GL_SLUMINANCE8 texture with GL_RGBA and GL_UNSIGNED_SHORT_5_5_5_1,Fail spec@ext_texture_srgb_r8@teximage-colors gl_sr8_ext,Fail spec@ext_texture_srgb_r8@teximage-colors gl_sr8_ext@GL_SR8_EXT texture with GL_ABGR_EXT and GL_BYTE,Fail spec@ext_texture_srgb_r8@teximage-colors gl_sr8_ext@GL_SR8_EXT texture with GL_ABGR_EXT and GL_FLOAT,Fail @@ -639,8 +555,6 @@ spec@arb_fragment_layer_viewport@viewport-vs-write-gs-no-write-simple,Fail spec@arb_framebuffer_object@fbo-attachments-blit-scaled-linear,Fail spec@arb_framebuffer_object@fbo-blit-scaled-linear,Fail -spec@arb_framebuffer_srgb@fbo-fast-clear,Fail - spec@arb_pipeline_statistics_query@arb_pipeline_statistics_query-vert,Fail spec@arb_pixel_buffer_object@texsubimage-unpack pbo,Fail @@ -812,8 +726,6 @@ spec@ext_texture_snorm@fbo-blending-formats@GL_RGB16_SNORM,Fail spec@ext_texture_snorm@fbo-blending-formats@GL_RGB8_SNORM,Fail spec@ext_texture_snorm@fbo-blending-formats@GL_RGB_SNORM,Fail -spec@ext_texture_srgb@fbo-fast-clear,Fail - spec@ext_transform_feedback@immediate-reuse-index-buffer,Fail spec@glsl-1.20@execution@clipping@vs-clip-vertex-primitives,Fail diff --git a/src/gallium/drivers/r600/r600_state.c b/src/gallium/drivers/r600/r600_state.c index 380c9796f35..2e3959064e4 100644 --- a/src/gallium/drivers/r600/r600_state.c +++ b/src/gallium/drivers/r600/r600_state.c @@ -190,6 +190,9 @@ bool r600_is_format_supported(struct pipe_screen *screen, } } + if (unlikely(format == PIPE_FORMAT_L8_SRGB)) + return false; + if (usage & PIPE_BIND_SAMPLER_VIEW) { if (target == PIPE_BUFFER) { if (r600_is_buffer_format_supported(format, false, R600_PBO_NO_WORKAROUND_NEEDED))