[dxvk] Don't create flat 2D views for cube maps

Fixes a rendering issue in Heroes of the Storm, where the game
binds a cube map array to a resource slot which expects a 2D
view.

Refs #777.
This commit is contained in:
Philip Rebohle 2019-02-09 01:00:40 +01:00
parent f6380fa152
commit 8543f96413
No known key found for this signature in database
GPG Key ID: C8CC613427A31C99
1 changed files with 3 additions and 1 deletions

View File

@ -145,9 +145,11 @@ namespace dxvk {
case VK_IMAGE_VIEW_TYPE_2D:
case VK_IMAGE_VIEW_TYPE_2D_ARRAY:
this->createView(VK_IMAGE_VIEW_TYPE_2D, 1);
/* fall through */
case VK_IMAGE_VIEW_TYPE_CUBE:
case VK_IMAGE_VIEW_TYPE_CUBE_ARRAY: {
this->createView(VK_IMAGE_VIEW_TYPE_2D, 1);
this->createView(VK_IMAGE_VIEW_TYPE_2D_ARRAY, info.numLayers);
if (m_image->info().flags & VK_IMAGE_CREATE_CUBE_COMPATIBLE_BIT) {