diff options
author | bunnei <bunneidev@gmail.com> | 2020-05-02 06:45:41 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-05-02 06:45:41 +0200 |
commit | e6b4311178b4f87b67eb2383f2a64520c2a8dd25 (patch) | |
tree | 066f25773f9db49747f26ddf94b23a5007502ff8 /src/video_core/shader/decode/image.cpp | |
parent | Merge pull request #3859 from jbeich/clang (diff) | |
parent | shader/texture: Support multiple unknown sampler properties (diff) | |
download | yuzu-e6b4311178b4f87b67eb2383f2a64520c2a8dd25.tar yuzu-e6b4311178b4f87b67eb2383f2a64520c2a8dd25.tar.gz yuzu-e6b4311178b4f87b67eb2383f2a64520c2a8dd25.tar.bz2 yuzu-e6b4311178b4f87b67eb2383f2a64520c2a8dd25.tar.lz yuzu-e6b4311178b4f87b67eb2383f2a64520c2a8dd25.tar.xz yuzu-e6b4311178b4f87b67eb2383f2a64520c2a8dd25.tar.zst yuzu-e6b4311178b4f87b67eb2383f2a64520c2a8dd25.zip |
Diffstat (limited to 'src/video_core/shader/decode/image.cpp')
-rw-r--r-- | src/video_core/shader/decode/image.cpp | 18 |
1 files changed, 8 insertions, 10 deletions
diff --git a/src/video_core/shader/decode/image.cpp b/src/video_core/shader/decode/image.cpp index 85ee9aa5e..60b6ad72a 100644 --- a/src/video_core/shader/decode/image.cpp +++ b/src/video_core/shader/decode/image.cpp @@ -485,11 +485,10 @@ u32 ShaderIR::DecodeImage(NodeBlock& bb, u32 pc) { Image& ShaderIR::GetImage(Tegra::Shader::Image image, Tegra::Shader::ImageType type) { const auto offset = static_cast<u32>(image.index.Value()); - const auto it = - std::find_if(std::begin(used_images), std::end(used_images), - [offset](const Image& entry) { return entry.GetOffset() == offset; }); + const auto it = std::find_if(std::begin(used_images), std::end(used_images), + [offset](const Image& entry) { return entry.offset == offset; }); if (it != std::end(used_images)) { - ASSERT(!it->IsBindless() && it->GetType() == it->GetType()); + ASSERT(!it->is_bindless && it->type == type); return *it; } @@ -505,13 +504,12 @@ Image& ShaderIR::GetBindlessImage(Tegra::Shader::Register reg, Tegra::Shader::Im const auto buffer = std::get<1>(result); const auto offset = std::get<2>(result); - const auto it = - std::find_if(std::begin(used_images), std::end(used_images), - [buffer = buffer, offset = offset](const Image& entry) { - return entry.GetBuffer() == buffer && entry.GetOffset() == offset; - }); + const auto it = std::find_if(std::begin(used_images), std::end(used_images), + [buffer, offset](const Image& entry) { + return entry.buffer == buffer && entry.offset == offset; + }); if (it != std::end(used_images)) { - ASSERT(it->IsBindless() && it->GetType() == it->GetType()); + ASSERT(it->is_bindless && it->type == type); return *it; } |