Mesa (staging/20.1): dri_util: Update internal_format to GL_RGB8 for MESA_FORMAT_B8G8R8X8_UNORM

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Wed Aug 12 13:08:35 UTC 2020


Module: Mesa
Branch: staging/20.1
Commit: 266af493eeb3037dbdce213cab52d6be9b0591a7
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=266af493eeb3037dbdce213cab52d6be9b0591a7

Author: Nanley Chery <nanley.g.chery at intel.com>
Date:   Mon Jun 22 15:19:38 2020 -0700

dri_util: Update internal_format to GL_RGB8 for MESA_FORMAT_B8G8R8X8_UNORM

Port the change done for RGBX8888 in
02a1f95386b43bf46cd1c8297d0955242f554fa2.

If XR24 images are considered to be VIEW_CLASS_24_BITS-compatible, it's
reasonable to assume that XB24 images would be as well.

Fixes: bf576772ab4d ("dri_util: add driImageFormatToSizedInternalGLFormat function")
Reviewed-by: Marek Olšák <marek.olsak at amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6095>
(cherry picked from commit 8abf59ff98863634321e3e0d60035277e58e92e8)

---

 .pick_status.json                      | 2 +-
 src/mesa/drivers/dri/common/dri_util.c | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/.pick_status.json b/.pick_status.json
index 1a8088e10a9..02fca372f23 100644
--- a/.pick_status.json
+++ b/.pick_status.json
@@ -166,7 +166,7 @@
         "description": "dri_util: Update internal_format to GL_RGB8 for MESA_FORMAT_B8G8R8X8_UNORM",
         "nominated": true,
         "nomination_type": 1,
-        "resolution": 0,
+        "resolution": 1,
         "master_sha": null,
         "because_sha": "bf576772ab4d9e76dae716640bed6de879f19567"
     },
diff --git a/src/mesa/drivers/dri/common/dri_util.c b/src/mesa/drivers/dri/common/dri_util.c
index e90179c7f2e..7ff7bfa5482 100644
--- a/src/mesa/drivers/dri/common/dri_util.c
+++ b/src/mesa/drivers/dri/common/dri_util.c
@@ -890,7 +890,7 @@ static const struct {
    {
       .image_format    = __DRI_IMAGE_FORMAT_XRGB8888,
       .mesa_format     =        MESA_FORMAT_B8G8R8X8_UNORM,
-      .internal_format =        GL_RGBA8,
+      .internal_format =        GL_RGB8,
    },
    {
       .image_format    = __DRI_IMAGE_FORMAT_ABGR16161616F,



More information about the mesa-commit mailing list