diff options
author | bunnei <bunneidev@gmail.com> | 2020-06-13 19:48:27 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-06-13 19:48:27 +0200 |
commit | c2ea1e1bcb88f8e307e54cf588829a516b40258e (patch) | |
tree | 3975cb756ef9d289cc13f3f6dc2a302dacc2c758 /src/video_core/engines/kepler_compute.cpp | |
parent | Merge pull request #3986 from ReinUsesLisp/shader-cache (diff) | |
parent | shader/texture: Join separate image and sampler pairs offline (diff) | |
download | yuzu-c2ea1e1bcb88f8e307e54cf588829a516b40258e.tar yuzu-c2ea1e1bcb88f8e307e54cf588829a516b40258e.tar.gz yuzu-c2ea1e1bcb88f8e307e54cf588829a516b40258e.tar.bz2 yuzu-c2ea1e1bcb88f8e307e54cf588829a516b40258e.tar.lz yuzu-c2ea1e1bcb88f8e307e54cf588829a516b40258e.tar.xz yuzu-c2ea1e1bcb88f8e307e54cf588829a516b40258e.tar.zst yuzu-c2ea1e1bcb88f8e307e54cf588829a516b40258e.zip |
Diffstat (limited to 'src/video_core/engines/kepler_compute.cpp')
-rw-r--r-- | src/video_core/engines/kepler_compute.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/video_core/engines/kepler_compute.cpp b/src/video_core/engines/kepler_compute.cpp index f6237fc6a..a82b06a38 100644 --- a/src/video_core/engines/kepler_compute.cpp +++ b/src/video_core/engines/kepler_compute.cpp @@ -92,8 +92,11 @@ SamplerDescriptor KeplerCompute::AccessBindlessSampler(ShaderType stage, u64 con ASSERT(stage == ShaderType::Compute); const auto& tex_info_buffer = launch_description.const_buffer_config[const_buffer]; const GPUVAddr tex_info_address = tex_info_buffer.Address() + offset; + return AccessSampler(memory_manager.Read<u32>(tex_info_address)); +} - const Texture::TextureHandle tex_handle{memory_manager.Read<u32>(tex_info_address)}; +SamplerDescriptor KeplerCompute::AccessSampler(u32 handle) const { + const Texture::TextureHandle tex_handle{handle}; const Texture::FullTextureInfo tex_info = GetTextureInfo(tex_handle); SamplerDescriptor result = SamplerDescriptor::FromTIC(tex_info.tic); result.is_shadow.Assign(tex_info.tsc.depth_compare_enabled.Value()); |