summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorReinUsesLisp <reinuseslisp@airmail.cc>2021-06-13 04:24:49 +0200
committerameerj <52414509+ameerj@users.noreply.github.com>2021-07-23 03:51:35 +0200
commit41cca8b8ad6f7ea33e74210aee4e3867ffa0622e (patch)
tree2b6935b99d9495d4ac50131057b47ea803ebf082
parentmain: Fix Open Transferable Shader Cache context item (diff)
downloadyuzu-41cca8b8ad6f7ea33e74210aee4e3867ffa0622e.tar
yuzu-41cca8b8ad6f7ea33e74210aee4e3867ffa0622e.tar.gz
yuzu-41cca8b8ad6f7ea33e74210aee4e3867ffa0622e.tar.bz2
yuzu-41cca8b8ad6f7ea33e74210aee4e3867ffa0622e.tar.lz
yuzu-41cca8b8ad6f7ea33e74210aee4e3867ffa0622e.tar.xz
yuzu-41cca8b8ad6f7ea33e74210aee4e3867ffa0622e.tar.zst
yuzu-41cca8b8ad6f7ea33e74210aee4e3867ffa0622e.zip
-rw-r--r--src/video_core/renderer_vulkan/vk_pipeline_cache.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/video_core/renderer_vulkan/vk_pipeline_cache.cpp b/src/video_core/renderer_vulkan/vk_pipeline_cache.cpp
index db7da5555..b17f34cdd 100644
--- a/src/video_core/renderer_vulkan/vk_pipeline_cache.cpp
+++ b/src/video_core/renderer_vulkan/vk_pipeline_cache.cpp
@@ -391,10 +391,16 @@ void PipelineCache::LoadDiskResources(u64 title_id, std::stop_token stop_loading
});
++state.total;
}};
+ const bool extended_dynamic_state = device.IsExtExtendedDynamicStateSupported();
+ const bool dynamic_vertex_input = device.IsExtVertexInputDynamicStateSupported();
const auto load_graphics{[&](std::ifstream& file, std::vector<FileEnvironment> envs) {
GraphicsPipelineCacheKey key;
file.read(reinterpret_cast<char*>(&key), sizeof(key));
+ if ((key.state.extended_dynamic_state != 0) != extended_dynamic_state ||
+ (key.state.dynamic_vertex_input != 0) != dynamic_vertex_input) {
+ return;
+ }
workers.QueueWork([this, key, envs = std::move(envs), &state, &callback]() mutable {
ShaderPools pools;
boost::container::static_vector<Shader::Environment*, 5> env_ptrs;