diff options
author | ameerj <aj662@drexel.edu> | 2020-08-02 19:05:41 +0200 |
---|---|---|
committer | ameerj <aj662@drexel.edu> | 2020-08-16 18:02:22 +0200 |
commit | 31a76410e8fa09462d960c10148c075125dc385a (patch) | |
tree | a5e45c1f609cdf7d4537d1215699e741a469ba17 /src/video_core/shader/async_shaders.h | |
parent | Vk Async Worker directly emplace in cache (diff) | |
download | yuzu-31a76410e8fa09462d960c10148c075125dc385a.tar yuzu-31a76410e8fa09462d960c10148c075125dc385a.tar.gz yuzu-31a76410e8fa09462d960c10148c075125dc385a.tar.bz2 yuzu-31a76410e8fa09462d960c10148c075125dc385a.tar.lz yuzu-31a76410e8fa09462d960c10148c075125dc385a.tar.xz yuzu-31a76410e8fa09462d960c10148c075125dc385a.tar.zst yuzu-31a76410e8fa09462d960c10148c075125dc385a.zip |
Diffstat (limited to 'src/video_core/shader/async_shaders.h')
-rw-r--r-- | src/video_core/shader/async_shaders.h | 23 |
1 files changed, 13 insertions, 10 deletions
diff --git a/src/video_core/shader/async_shaders.h b/src/video_core/shader/async_shaders.h index d4eeb8fb6..7c10bd63f 100644 --- a/src/video_core/shader/async_shaders.h +++ b/src/video_core/shader/async_shaders.h @@ -86,12 +86,13 @@ public: VideoCommon::Shader::CompilerSettings compiler_settings, const VideoCommon::Shader::Registry& registry, VAddr cpu_addr); - void QueueVulkanShader(Vulkan::VKPipelineCache* pp_cache, + void QueueVulkanShader(Vulkan::VKPipelineCache* pp_cache, const Vulkan::VKDevice& device, + Vulkan::VKScheduler& scheduler, + Vulkan::VKDescriptorPool& descriptor_pool, + Vulkan::VKUpdateDescriptorQueue& update_descriptor_queue, + Vulkan::VKRenderPassCache& renderpass_cache, std::vector<VkDescriptorSetLayoutBinding> bindings, - Vulkan::SPIRVProgram program, Vulkan::RenderPassParams renderpass_params, - u32 padding, - std::array<GPUVAddr, Vulkan::Maxwell::MaxShaderProgram> shaders, - Vulkan::FixedPipelineState fixed_state); + Vulkan::SPIRVProgram program, Vulkan::GraphicsPipelineCacheKey key); private: void ShaderCompilerThread(Core::Frontend::GraphicsContext* context); @@ -114,12 +115,14 @@ private: // For Vulkan Vulkan::VKPipelineCache* pp_cache; + const Vulkan::VKDevice* vk_device; + Vulkan::VKScheduler* scheduler; + Vulkan::VKDescriptorPool* descriptor_pool; + Vulkan::VKUpdateDescriptorQueue* update_descriptor_queue; + Vulkan::VKRenderPassCache* renderpass_cache; std::vector<VkDescriptorSetLayoutBinding> bindings; Vulkan::SPIRVProgram program; - Vulkan::RenderPassParams renderpass_params; - u32 padding; - std::array<GPUVAddr, Vulkan::Maxwell::MaxShaderProgram> shaders; - Vulkan::FixedPipelineState fixed_state; + Vulkan::GraphicsPipelineCacheKey key; }; std::condition_variable cv; @@ -128,7 +131,7 @@ private: std::atomic<bool> is_thread_exiting{}; std::vector<std::unique_ptr<Core::Frontend::GraphicsContext>> context_list; std::vector<std::thread> worker_threads; - std::queue<std::unique_ptr<WorkerParams>> pending_queue; + std::queue<WorkerParams> pending_queue; std::vector<AsyncShaders::Result> finished_work; Core::Frontend::EmuWindow& emu_window; }; |