Module: Mesa
Branch: master
Commit: f0861c803edef82d27ccb3278ac7ab4c4c284272
URL:    
http://cgit.freedesktop.org/mesa/mesa/commit/?id=f0861c803edef82d27ccb3278ac7ab4c4c284272

Author: Adam Jackson <a...@redhat.com>
Date:   Tue Apr  6 15:57:26 2021 -0400

glx: Downgrade sRGB-ful fbconfigs

Again, NVIDIA supports this on every fbconfig, Mesa alternates it on and
off for some reason but only on some drivers, and in particular llvmpipe
doesn't try to create sRGB-ful fbconfigs. Nerf it out of the fbconfig.

Acked-By: Mike Blumenkrantz <michael.blumenkra...@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/1648>

---

 src/glx/dri_common.c | 12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/src/glx/dri_common.c b/src/glx/dri_common.c
index 4577ee4c7ea..f7a1a429a74 100644
--- a/src/glx/dri_common.c
+++ b/src/glx/dri_common.c
@@ -278,6 +278,18 @@ driConfigEqual(const __DRIcoreExtension *core,
          }
          break;
 
+      case __DRI_ATTRIB_FRAMEBUFFER_SRGB_CAPABLE:
+         if (!scalarEqual(config, attrib, value)) {
+            static int warned;
+            if (!warned) {
+               dri_message(_LOADER_DEBUG,
+                           "Disabling server's sRGB support\n");
+               warned = 1;
+            }
+            config->sRGBCapable = 0;
+         }
+         break;
+
       default:
          if (!scalarEqual(config, attrib, value))
             return GL_FALSE;

_______________________________________________
mesa-commit mailing list
mesa-commit@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-commit

Reply via email to