[Mesa-dev] [PATCH 1/3] dri/common: add MESA_FORMAT_R8G8B8{A8, X8}_UNORM formats as supported configs
Marek Olšák
maraeo at gmail.com
Wed Apr 20 10:34:13 UTC 2016
For the series:
Reviewed-by: Marek Olšák <marek.olsak at amd.com>
You might want to wait for others to comment.
Mare
On Tue, Apr 19, 2016 at 9:38 PM, Rob Herring <robh at kernel.org> wrote:
> Add MESA_FORMAT_R8G8B8A8_UNORM and MESA_FORMAT_R8G8B8X8_UNORM formats as
> these are the preferred formats for Android.
>
> Signed-off-by: Rob Herring <robh at kernel.org>
> ---
> src/mesa/drivers/dri/common/utils.c | 10 ++++++++++
> 1 file changed, 10 insertions(+)
>
> diff --git a/src/mesa/drivers/dri/common/utils.c b/src/mesa/drivers/dri/common/utils.c
> index ae8fcab..4b2e89c 100644
> --- a/src/mesa/drivers/dri/common/utils.c
> +++ b/src/mesa/drivers/dri/common/utils.c
> @@ -171,6 +171,10 @@ driCreateConfigs(mesa_format format,
> { 0x3FF00000, 0x000FFC00, 0x000003FF, 0x00000000 },
> /* MESA_FORMAT_B10G10R10A2_UNORM */
> { 0x3FF00000, 0x000FFC00, 0x000003FF, 0xC0000000 },
> + /* MESA_FORMAT_R8G8B8A8_UNORM */
> + { 0x000000FF, 0x0000FF00, 0x00FF0000, 0xFF000000 },
> + /* MESA_FORMAT_R8G8B8X8_UNORM */
> + { 0x000000FF, 0x0000FF00, 0x00FF0000, 0x00000000 },
> };
>
> const uint32_t * masks;
> @@ -197,6 +201,12 @@ driCreateConfigs(mesa_format format,
> case MESA_FORMAT_B8G8R8A8_SRGB:
> masks = masks_table[2];
> break;
> + case MESA_FORMAT_R8G8B8A8_UNORM:
> + masks = masks_table[5];
> + break;
> + case MESA_FORMAT_R8G8B8X8_UNORM:
> + masks = masks_table[6];
> + break;
> case MESA_FORMAT_B10G10R10X2_UNORM:
> masks = masks_table[3];
> break;
> --
> 2.7.4
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/mesa-dev
More information about the mesa-dev
mailing list