Vulkan: Upgrade RGB8 textures to RGBA8.
It's unlikely any real hardware supports this format. Hack in a fixed
fallback format for RGB8. We could consider implementing conditional
support by checking the VkPhysicalDevice properties.
This extends the Vulkan format support info in the RendererVk class
to distinguish between a Buffer and Texture format. This is closely
related to how Vulkan has separate format support bits for Linear
Textures, Optimal Textures, and Buffers. We probably won't need to
keep separate caps for Linear/Optimal, but it makes sense for Buffers
to eventually use the same format tables.
BUG=angleproject:2207
Change-Id: I8d427a99db15b314b13dd99f31aa1ac5055f0881
Reviewed-on: https://chromium-review.googlesource.com/742376
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Frank Henigman <fjhenigman@chromium.org>
diff --git a/src/libANGLE/renderer/vulkan/RendererVk.cpp b/src/libANGLE/renderer/vulkan/RendererVk.cpp
index d81b215..d6de9c5 100644
--- a/src/libANGLE/renderer/vulkan/RendererVk.cpp
+++ b/src/libANGLE/renderer/vulkan/RendererVk.cpp
@@ -775,7 +775,7 @@
vk::StagingImage *imageOut)
{
ANGLE_TRY(imageOut->init(mDevice, mCurrentQueueFamilyIndex, mMemoryProperties, dimension,
- format.native, extent, usage));
+ format.vkTextureFormat, extent, usage));
return vk::NoError();
}