From 272916eeaf91f2430104b5454d765f762aa22cdc Mon Sep 17 00:00:00 2001 From: GPUCode Date: Sat, 1 Jul 2023 15:19:31 +0300 Subject: renderer_vulkan: Fix some missing view formats * Many times the format itself wouldn't have been added to the list causing device losses for nvidia GPUs * Also account for ASTC acceleration storage views --- src/video_core/renderer_vulkan/vk_texture_cache.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'src/video_core/renderer_vulkan') diff --git a/src/video_core/renderer_vulkan/vk_texture_cache.cpp b/src/video_core/renderer_vulkan/vk_texture_cache.cpp index f1b696e01..3aac3cfab 100644 --- a/src/video_core/renderer_vulkan/vk_texture_cache.cpp +++ b/src/video_core/renderer_vulkan/vk_texture_cache.cpp @@ -826,9 +826,8 @@ TextureCacheRuntime::TextureCacheRuntime(const Device& device_, Scheduler& sched } for (size_t index_a = 0; index_a < VideoCore::Surface::MaxPixelFormat; index_a++) { const auto image_format = static_cast(index_a); - const auto type_a = VideoCore::Surface::GetFormatType(image_format); - if (type_a != SurfaceType::ColorTexture) { - continue; + if (IsPixelFormatASTC(image_format) && !device.IsOptimalAstcSupported()) { + view_formats[index_a].push_back(VK_FORMAT_A8B8G8R8_UNORM_PACK32); } for (size_t index_b = 0; index_b < VideoCore::Surface::MaxPixelFormat; index_b++) { const auto view_format = static_cast(index_b); -- cgit v1.2.3