2
1
Fork 0
mirror of https://github.com/yuzu-emu/yuzu.git synced 2024-07-04 23:31:19 +01:00

shader_decompiler: only add StorageImageReadWithoutFormat when available

This commit is contained in:
Nguyen Dac Nam 2020-02-20 09:28:13 +07:00 committed by GitHub
parent 88cb05e6e7
commit fbbad95845
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -274,7 +274,6 @@ public:
AddCapability(spv::Capability::ImageBuffer); AddCapability(spv::Capability::ImageBuffer);
AddCapability(spv::Capability::ImageGatherExtended); AddCapability(spv::Capability::ImageGatherExtended);
AddCapability(spv::Capability::SampledBuffer); AddCapability(spv::Capability::SampledBuffer);
AddCapability(spv::Capability::StorageImageReadWithoutFormat);
AddCapability(spv::Capability::StorageImageWriteWithoutFormat); AddCapability(spv::Capability::StorageImageWriteWithoutFormat);
AddCapability(spv::Capability::SubgroupBallotKHR); AddCapability(spv::Capability::SubgroupBallotKHR);
AddCapability(spv::Capability::SubgroupVoteKHR); AddCapability(spv::Capability::SubgroupVoteKHR);
@ -291,6 +290,10 @@ public:
} }
} }
if (device.IsShaderStorageImageReadWithoutFormatSupported()) {
AddCapability(spv::Capability::StorageImageReadWithoutFormat);
}
if (device.IsFloat16Supported()) { if (device.IsFloat16Supported()) {
AddCapability(spv::Capability::Float16); AddCapability(spv::Capability::Float16);
} }