summaryrefslogtreecommitdiffstats
path: root/src/video_core
diff options
context:
space:
mode:
authorLioncash <mathew1800@gmail.com>2019-03-11 17:07:20 +0100
committerLioncash <mathew1800@gmail.com>2019-03-11 17:20:35 +0100
commit3350c0a77944068010794fe5a53cd63929a3fe28 (patch)
tree61eda6611cfff3a4b5230c9a415c8e0b3f2cfcff /src/video_core
parentrenderer_opengl/gl_global_cache: Append missing override specifiers (diff)
downloadyuzu-3350c0a77944068010794fe5a53cd63929a3fe28.tar
yuzu-3350c0a77944068010794fe5a53cd63929a3fe28.tar.gz
yuzu-3350c0a77944068010794fe5a53cd63929a3fe28.tar.bz2
yuzu-3350c0a77944068010794fe5a53cd63929a3fe28.tar.lz
yuzu-3350c0a77944068010794fe5a53cd63929a3fe28.tar.xz
yuzu-3350c0a77944068010794fe5a53cd63929a3fe28.tar.zst
yuzu-3350c0a77944068010794fe5a53cd63929a3fe28.zip
Diffstat (limited to 'src/video_core')
-rw-r--r--src/video_core/renderer_opengl/gl_global_cache.cpp4
-rw-r--r--src/video_core/renderer_opengl/gl_global_cache.h2
2 files changed, 3 insertions, 3 deletions
diff --git a/src/video_core/renderer_opengl/gl_global_cache.cpp b/src/video_core/renderer_opengl/gl_global_cache.cpp
index c7f32feaa..7161d1dea 100644
--- a/src/video_core/renderer_opengl/gl_global_cache.cpp
+++ b/src/video_core/renderer_opengl/gl_global_cache.cpp
@@ -57,8 +57,8 @@ GlobalRegion GlobalRegionCacheOpenGL::GetUncachedGlobalRegion(VAddr addr, u32 si
return region;
}
-void GlobalRegionCacheOpenGL::ReserveGlobalRegion(const GlobalRegion& region) {
- reserve[region->GetAddr()] = region;
+void GlobalRegionCacheOpenGL::ReserveGlobalRegion(GlobalRegion region) {
+ reserve.insert_or_assign(region->GetAddr(), std::move(region));
}
GlobalRegionCacheOpenGL::GlobalRegionCacheOpenGL(RasterizerOpenGL& rasterizer)
diff --git a/src/video_core/renderer_opengl/gl_global_cache.h b/src/video_core/renderer_opengl/gl_global_cache.h
index b8f1f7c2e..ba2bdc60c 100644
--- a/src/video_core/renderer_opengl/gl_global_cache.h
+++ b/src/video_core/renderer_opengl/gl_global_cache.h
@@ -70,7 +70,7 @@ public:
private:
GlobalRegion TryGetReservedGlobalRegion(VAddr addr, u32 size) const;
GlobalRegion GetUncachedGlobalRegion(VAddr addr, u32 size);
- void ReserveGlobalRegion(const GlobalRegion& region);
+ void ReserveGlobalRegion(GlobalRegion region);
std::unordered_map<VAddr, GlobalRegion> reserve;
};