From: Iván Briano Date: Thu, 7 May 2020 20:34:04 +0000 (-0700) Subject: anv: use the correct format on Android X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=6ae0762f5c05284cda768fff9334eee28f3d0355;p=mesa.git anv: use the correct format on Android Per https://android.googlesource.com/platform/frameworks/native/+/master/vulkan/libvulkan/swapchain.cpp#745 the format Android requires is R5G6B5, and we have it backwards here. Reviewed-by: Jason Ekstrand Reviewed-by: Tapani Pälli Part-of: --- diff --git a/src/intel/vulkan/anv_android.c b/src/intel/vulkan/anv_android.c index b46a990b32e..8e6d0b65ea1 100644 --- a/src/intel/vulkan/anv_android.c +++ b/src/intel/vulkan/anv_android.c @@ -616,7 +616,7 @@ setup_gralloc0_usage(VkFormat format, VkImageUsageFlags imageUsage, */ switch (format) { case VK_FORMAT_B8G8R8A8_UNORM: - case VK_FORMAT_B5G6R5_UNORM_PACK16: + case VK_FORMAT_R5G6B5_UNORM_PACK16: case VK_FORMAT_R8G8B8A8_UNORM: case VK_FORMAT_R8G8B8A8_SRGB: *grallocUsage |= GRALLOC_USAGE_HW_FB |