diff options
author | ReinUsesLisp <reinuseslisp@airmail.cc> | 2020-02-26 20:13:47 +0100 |
---|---|---|
committer | ReinUsesLisp <reinuseslisp@airmail.cc> | 2020-03-09 22:40:06 +0100 |
commit | bd8b9bbcee93549f323352f227ff44d0e79e0ad4 (patch) | |
tree | 5c68e7ab171db3f3d31bf27cd573c54a918f0708 /src/video_core/shader/track.cpp | |
parent | Merge pull request #3301 from ReinUsesLisp/state-tracker (diff) | |
download | yuzu-bd8b9bbcee93549f323352f227ff44d0e79e0ad4.tar yuzu-bd8b9bbcee93549f323352f227ff44d0e79e0ad4.tar.gz yuzu-bd8b9bbcee93549f323352f227ff44d0e79e0ad4.tar.bz2 yuzu-bd8b9bbcee93549f323352f227ff44d0e79e0ad4.tar.lz yuzu-bd8b9bbcee93549f323352f227ff44d0e79e0ad4.tar.xz yuzu-bd8b9bbcee93549f323352f227ff44d0e79e0ad4.tar.zst yuzu-bd8b9bbcee93549f323352f227ff44d0e79e0ad4.zip |
Diffstat (limited to 'src/video_core/shader/track.cpp')
-rw-r--r-- | src/video_core/shader/track.cpp | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/src/video_core/shader/track.cpp b/src/video_core/shader/track.cpp index 15e22b9fa..b1a0aa00c 100644 --- a/src/video_core/shader/track.cpp +++ b/src/video_core/shader/track.cpp @@ -94,13 +94,10 @@ std::tuple<Node, TrackSampler> ShaderIR::TrackBindlessSampler(Node tracked, cons } auto [gpr, base_offset] = *pair; const auto offset_inm = std::get_if<ImmediateNode>(&*base_offset); - auto gpu_driver = locker.AccessGuestDriverProfile(); - if (gpu_driver == nullptr) { - return {}; - } + const auto& gpu_driver = locker.AccessGuestDriverProfile(); const u32 bindless_cv = NewCustomVariable(); - const Node op = Operation(OperationCode::UDiv, NO_PRECISE, gpr, - Immediate(gpu_driver->GetTextureHandlerSize())); + const Node op = + Operation(OperationCode::UDiv, gpr, Immediate(gpu_driver.GetTextureHandlerSize())); const Node cv_node = GetCustomVariable(bindless_cv); Node amend_op = Operation(OperationCode::Assign, cv_node, std::move(op)); |