For now, set image view channel swizzle to match BGRA formats

* This should go away soon as there's an identity swizzle coming
This commit is contained in:
baldurk
2016-02-07 18:44:20 +01:00
parent b2b8822dfa
commit 3c2f72e0ef
+4
View File
@@ -688,6 +688,10 @@ bool VulkanReplay::RenderTextureInternal(TextureDisplay cfg, VkRenderPassBeginIn
0
};
// temporary hack, this should change soon, but identity channel swizzle has to match channels
if(iminfo.format == VK_FORMAT_B8G8R8A8_UNORM || iminfo.format == VK_FORMAT_B8G8R8A8_SRGB)
std::swap(viewInfo.channels.r, viewInfo.channels.b);
VkResult vkr = ObjDisp(dev)->CreateImageView(Unwrap(dev), &viewInfo, &iminfo.view);
RDCASSERT(vkr == VK_SUCCESS);