From fbbad9584530c186d2a592db8997eb850ba37547 Mon Sep 17 00:00:00 2001 From: Nguyen Dac Nam Date: Thu, 20 Feb 2020 09:28:13 +0700 Subject: shader_decompiler: only add StorageImageReadWithoutFormat when available --- src/video_core/renderer_vulkan/vk_shader_decompiler.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/video_core') diff --git a/src/video_core/renderer_vulkan/vk_shader_decompiler.cpp b/src/video_core/renderer_vulkan/vk_shader_decompiler.cpp index c02306d69..6cd5fae30 100644 --- a/src/video_core/renderer_vulkan/vk_shader_decompiler.cpp +++ b/src/video_core/renderer_vulkan/vk_shader_decompiler.cpp @@ -274,7 +274,6 @@ public: AddCapability(spv::Capability::ImageBuffer); AddCapability(spv::Capability::ImageGatherExtended); AddCapability(spv::Capability::SampledBuffer); - AddCapability(spv::Capability::StorageImageReadWithoutFormat); AddCapability(spv::Capability::StorageImageWriteWithoutFormat); AddCapability(spv::Capability::SubgroupBallotKHR); AddCapability(spv::Capability::SubgroupVoteKHR); @@ -290,6 +289,10 @@ public: AddCapability(spv::Capability::ShaderViewportIndexLayerEXT); } } + + if (device.IsShaderStorageImageReadWithoutFormatSupported()) { + AddCapability(spv::Capability::StorageImageReadWithoutFormat); + } if (device.IsFloat16Supported()) { AddCapability(spv::Capability::Float16); -- cgit v1.2.3