diff options
| author | 2021-06-22 00:04:55 -0300 | |
|---|---|---|
| committer | 2021-06-22 00:04:57 -0300 | |
| commit | 4009ae1da2360f20721c93cd204eb64c7342eb53 (patch) | |
| tree | 6bdd3084265212a096832f1e723c0c502f958f32 /src/video_core/rasterizer_interface.h | |
| parent | Merge pull request #6499 from FernandoS27/we-were-on-a-break (diff) | |
| download | yuzu-4009ae1da2360f20721c93cd204eb64c7342eb53.tar.gz yuzu-4009ae1da2360f20721c93cd204eb64c7342eb53.tar.xz yuzu-4009ae1da2360f20721c93cd204eb64c7342eb53.zip | |
bootmanager: Use std::stop_source for stopping emulation
Use its std::stop_token to abort shader cache loading.
Using std::stop_token instead of std::atomic_bool allows the usage of
other utilities like std::stop_callback.
Diffstat (limited to 'src/video_core/rasterizer_interface.h')
| -rw-r--r-- | src/video_core/rasterizer_interface.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/video_core/rasterizer_interface.h b/src/video_core/rasterizer_interface.h index f968b5b16..07939432f 100644 --- a/src/video_core/rasterizer_interface.h +++ b/src/video_core/rasterizer_interface.h | |||
| @@ -4,10 +4,10 @@ | |||
| 4 | 4 | ||
| 5 | #pragma once | 5 | #pragma once |
| 6 | 6 | ||
| 7 | #include <atomic> | ||
| 8 | #include <functional> | 7 | #include <functional> |
| 9 | #include <optional> | 8 | #include <optional> |
| 10 | #include <span> | 9 | #include <span> |
| 10 | #include <stop_token> | ||
| 11 | #include "common/common_types.h" | 11 | #include "common/common_types.h" |
| 12 | #include "video_core/engines/fermi_2d.h" | 12 | #include "video_core/engines/fermi_2d.h" |
| 13 | #include "video_core/gpu.h" | 13 | #include "video_core/gpu.h" |
| @@ -123,7 +123,7 @@ public: | |||
| 123 | virtual void UpdatePagesCachedCount(VAddr addr, u64 size, int delta) {} | 123 | virtual void UpdatePagesCachedCount(VAddr addr, u64 size, int delta) {} |
| 124 | 124 | ||
| 125 | /// Initialize disk cached resources for the game being emulated | 125 | /// Initialize disk cached resources for the game being emulated |
| 126 | virtual void LoadDiskResources(u64 title_id, const std::atomic_bool& stop_loading, | 126 | virtual void LoadDiskResources(u64 title_id, std::stop_token stop_loading, |
| 127 | const DiskResourceLoadCallback& callback) {} | 127 | const DiskResourceLoadCallback& callback) {} |
| 128 | 128 | ||
| 129 | /// Grant access to the Guest Driver Profile for recording/obtaining info on the guest driver. | 129 | /// Grant access to the Guest Driver Profile for recording/obtaining info on the guest driver. |