[Mesa-dev] [PATCH] st/dri: Add support for PIPE_FORMAT_RGBX8888_UNORM

Emil Velikov emil.l.velikov at gmail.com
Tue Jun 20 09:06:39 UTC 2017


Hi Lepton,

On 19 June 2017 at 18:51, Lepton Wu <lepton at google.com> wrote:
> The original dri2_format_to_pipe_format function just misses case branch
> for __DRI_IMAGE_FORMAT_XBGR8888. I discovered this when debugging one google
> map crash inside emulator.
>
> Signed-off-by: Lepton Wu <lepton at chromium.org>
> ---
>  src/gallium/state_trackers/dri/dri2.c | 3 +++
>  1 file changed, 3 insertions(+)
>
> diff --git a/src/gallium/state_trackers/dri/dri2.c b/src/gallium/state_trackers/dri/dri2.c
> index c5e69d639b..f02ef30dd7 100644
> --- a/src/gallium/state_trackers/dri/dri2.c
> +++ b/src/gallium/state_trackers/dri/dri2.c
> @@ -186,6 +186,9 @@ static enum pipe_format dri2_format_to_pipe_format (int format)
>     case __DRI_IMAGE_FORMAT_ARGB8888:
>        pf = PIPE_FORMAT_BGRA8888_UNORM;
>        break;
> +   case __DRI_IMAGE_FORMAT_XBGR8888:
> +      pf = PIPE_FORMAT_RGBX8888_UNORM;
> +      break;

Can you provide some additional information here:
 - How did you get here - a backtrace will be appreciated.
 - Do you have additional patches that you apply on top of Mesa - can
you share a link to them.

I'm asking all this information since the commit looks deceptively
close to an earlier one ccdcf91104a, which caused issues and had to be
reverted see c0c6ca40a25.

Thanks
Emil


More information about the mesa-dev mailing list