From cce6f0894095ab047339b552826fa8ffe094bbd2 Mon Sep 17 00:00:00 2001 From: Erik Faye-Lund Date: Wed, 26 Nov 2025 12:49:08 +0100 Subject: [PATCH] Revert "mesa: check for ARB_ES3_compatibility in format checks" This reverts commit d5916cb3ca7af90f81639d91922efecf9e713fda. The GL_ARB_ES3_compatibility spec, says the following: > Issues > > 1) OpenGL-ES 3.0 contains several features that have been deprecated from > the latest OpenGL Core specification. These were retained in OpenGL-ES > 3.0 in order to provide backwards compatibility with OpenGL-ES 2.0. Those > features are: > > [snip] > > * Legacy pixel formats - all ALPHA, LUMINANCE, LUMINANCE_ALPHA > > [snip] > > Should we bring these features back into the OpenGL 4.x Core specification > so that it is a complete super-set of OpenGL-ES 3.0? > > RESOLVED: No, these will not be brought back into OpenGL 4.x Core. Apps > written for OpenGL-ES 3.0 that want to also be compatible with OpenGL > should make sure they don't use these features. So, it seems pretty clear that we shouldn't have included these formats here. So let's remove them. Turns out, this is a CTS bug, see this for more details: https://gitlab.khronos.org/Tracker/vk-gl-cts/-/issues/6191 Fixes: d5916cb3ca7 ("mesa: check for ARB_ES3_compatibility in format checks") (cherry picked from commit b92719f9267280c5cab633c4acbb2455ee73b934) Part-of: --- .pick_status.json | 2 +- src/mesa/main/glformats.c | 4 +--- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/.pick_status.json b/.pick_status.json index abcd7751cc4..31d593b0a3a 100644 --- a/.pick_status.json +++ b/.pick_status.json @@ -774,7 +774,7 @@ "description": "Revert \"mesa: check for ARB_ES3_compatibility in format checks\"", "nominated": true, "nomination_type": 2, - "resolution": 0, + "resolution": 1, "main_sha": null, "because_sha": "d5916cb3ca7af90f81639d91922efecf9e713fda", "notes": null diff --git a/src/mesa/main/glformats.c b/src/mesa/main/glformats.c index bb53d989fad..0bc2fe2bf01 100644 --- a/src/mesa/main/glformats.c +++ b/src/mesa/main/glformats.c @@ -1821,9 +1821,7 @@ valid_texture_format_enum(const struct gl_context *ctx, GLenum format) case GL_LUMINANCE_ALPHA: case GL_LUMINANCE: case GL_ALPHA: - return _mesa_is_desktop_gl_compat(ctx) || - _mesa_has_ARB_ES3_compatibility(ctx) || - _mesa_is_gles(ctx); + return _mesa_is_desktop_gl_compat(ctx) || _mesa_is_gles(ctx); case GL_SRGB_EXT: case GL_SRGB_ALPHA_EXT: