From mboxrd@z Thu Jan 1 00:00:00 1970
From: bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ@public.gmane.org
Subject: [Bug 109330] GL_ALPHA_BITS set to non-zero with
EGL_PLATFORM_GBM_MESA
Date: Mon, 21 Jan 2019 00:30:26 +0000
Message-ID:
References:
Mime-Version: 1.0
Content-Type: multipart/mixed; boundary="===============0101814608=="
Return-path:
In-Reply-To:
List-Unsubscribe: ,
List-Archive:
List-Post:
List-Help:
List-Subscribe: ,
Errors-To: nouveau-bounces-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org
Sender: "Nouveau"
To: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org
List-Id: nouveau.vger.kernel.org
--===============0101814608==
Content-Type: multipart/alternative; boundary="15480306260.6DFeAb03A.3612"
Content-Transfer-Encoding: 7bit
--15480306260.6DFeAb03A.3612
Date: Mon, 21 Jan 2019 00:30:26 +0000
MIME-Version: 1.0
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://bugs.freedesktop.org/
Auto-Submitted: auto-generated
https://bugs.freedesktop.org/show_bug.cgi?id=3D109330
Ilia Mirkin changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution|--- |NOTOURBUG
--- Comment #5 from Ilia Mirkin ---
As per my comments on IRC, I think this is a wlroots bug:
drm_connector_set_mode calls init_drm_plane_surfaces (which in turn creates=
a
gbm surface) with GBM_FORMAT_XRGB8888. Flipping that to ARGB8888 resolves t=
he
issue.
As per my understanding, the config has to match the surface format, otherw=
ise
you get stuff like this. (At the extreme, imagine one said RGB10A2.)
The more detailed issue is that the winsys fb calls dri2_drm_image_get_buff=
ers
(via the getBuffers loader API call), which in turn uses the surface's form=
at
to create a backing bo. That format is XRGB8888, which becomes
PIPE_FORMAT_BGRX8888_UNORM. The pipe_surface also has this format. However =
the
GL believes that the format should be MESA_FORMAT_BGRA8888 (since that's wh=
at
the config said), and since that matches the glReadPixels format, decides it
can just do a memcpy.
Perhaps the pipe_surface should ignore the resource's format in this case, =
but
that's not how the current logic flows. In st_framebuffer_validate, it calls
u_surface_default_template which copies the format out of the given resourc=
e.
AFAIK having mismatches between surface format and config format is really =
bad
though, and not really supported. But I'm not a gbm API expert.
--=20
You are receiving this mail because:
You are the assignee for the bug.
You are the QA Contact for the bug.=
--15480306260.6DFeAb03A.3612
Date: Mon, 21 Jan 2019 00:30:26 +0000
MIME-Version: 1.0
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://bugs.freedesktop.org/
Auto-Submitted: auto-generated
Ilia Mirkin
changed
bug 10933=
0
| What |
Removed |
Added |
| Status |
NEW
|
RESOLVED
|
| Resolution |
---
|
NOTOURBUG
|
Commen=
t # 5
on bug 10933=
0
from Ilia Mirkin
As per my comments on IRC, I think this is a wlroots bug:
drm_connector_set_mode calls init_drm_plane_surfaces (which in turn creates=
a
gbm surface) with GBM_FORMAT_XRGB8888. Flipping that to ARGB8888 resolves t=
he
issue.
As per my understanding, the config has to match the surface format, otherw=
ise
you get stuff like this. (At the extreme, imagine one said RGB10A2.)
The more detailed issue is that the winsys fb calls dri2_drm_image_get_buff=
ers
(via the getBuffers loader API call), which in turn uses the surface's form=
at
to create a backing bo. That format is XRGB8888, which becomes
PIPE_FORMAT_BGRX8888_UNORM. The pipe_surface also has this format. However =
the
GL believes that the format should be MESA_FORMAT_BGRA8888 (since that's wh=
at
the config said), and since that matches the glReadPixels format, decides it
can just do a memcpy.
Perhaps the pipe_surface should ignore the resource's format in this case, =
but
that's not how the current logic flows. In st_framebuffer_validate, it calls
u_surface_default_template which copies the format out of the given resourc=
e.
AFAIK having mismatches between surface format and config format is really =
bad
though, and not really supported. But I'm not a gbm API expert.
You are receiving this mail because:
- You are the assignee for the bug.
- You are the QA Contact for the bug.
=
--15480306260.6DFeAb03A.3612--
--===============0101814608==
Content-Type: text/plain; charset="utf-8"
MIME-Version: 1.0
Content-Transfer-Encoding: base64
Content-Disposition: inline
X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX18KTm91dmVhdSBt
YWlsaW5nIGxpc3QKTm91dmVhdUBsaXN0cy5mcmVlZGVza3RvcC5vcmcKaHR0cHM6Ly9saXN0cy5m
cmVlZGVza3RvcC5vcmcvbWFpbG1hbi9saXN0aW5mby9ub3V2ZWF1Cg==
--===============0101814608==--