summaryrefslogtreecommitdiffstats
path: root/src/video_core
diff options
context:
space:
mode:
Diffstat (limited to 'src/video_core')
-rw-r--r--src/video_core/renderer_opengl/gl_shader_disk_cache.cpp5
-rw-r--r--src/video_core/renderer_opengl/gl_shader_disk_cache.h3
2 files changed, 8 insertions, 0 deletions
diff --git a/src/video_core/renderer_opengl/gl_shader_disk_cache.cpp b/src/video_core/renderer_opengl/gl_shader_disk_cache.cpp
index a87bb1f9e..4d02a800d 100644
--- a/src/video_core/renderer_opengl/gl_shader_disk_cache.cpp
+++ b/src/video_core/renderer_opengl/gl_shader_disk_cache.cpp
@@ -156,6 +156,11 @@ std::vector<ShaderDiskCachePrecompiledEntry> ShaderDiskCacheOpenGL::LoadPrecompi
return precompiled;
}
+void ShaderDiskCacheOpenGL::InvalidateTransferable() const {
+ FileUtil::Delete(GetTransferablePath());
+ InvalidatePrecompiled();
+}
+
void ShaderDiskCacheOpenGL::InvalidatePrecompiled() const {
FileUtil::Delete(GetPrecompiledPath());
}
diff --git a/src/video_core/renderer_opengl/gl_shader_disk_cache.h b/src/video_core/renderer_opengl/gl_shader_disk_cache.h
index e68aea694..6c4c7bd5c 100644
--- a/src/video_core/renderer_opengl/gl_shader_disk_cache.h
+++ b/src/video_core/renderer_opengl/gl_shader_disk_cache.h
@@ -147,6 +147,9 @@ public:
/// Loads current game's precompiled cache. Invalidates if emulator's version has changed.
std::vector<ShaderDiskCachePrecompiledEntry> LoadPrecompiled();
+ /// Removes the transferable (and precompiled) cache file.
+ void InvalidateTransferable() const;
+
/// Removes the precompiled cache file.
void InvalidatePrecompiled() const;