diff options
| author | ReinUsesLisp <reinuseslisp@airmail.cc> | 2021-01-20 20:09:57 -0300 |
|---|---|---|
| committer | ReinUsesLisp <reinuseslisp@airmail.cc> | 2021-01-21 00:41:03 -0300 |
| commit | 51512d01d8e956b2afada91e51dfd7c0a6444ad6 (patch) | |
| tree | 920ed6ec21b438894b7caeef0a946dbfc2ead10a /src/video_core/renderer_opengl/gl_device.h | |
| parent | 4cd8b2f1f7837ad3f138148474846b5bdd8c824e (diff) | |
renderer_opengl: Avoid precompiled cache and force NV GL cache directory
Setting __GL_SHADER_DISK_CACHE_PATH we can force the cache directory to
be in yuzu's user directory to stop commonly distributed malware from
deleting our driver shader cache. And by setting
__GL_SHADER_DISK_CACHE_SKIP_CLEANUP we can have an unbounded shader
cache size.
This has only been implemented on Windows, mostly because previous tests
didn't seem to work on Linux.
Disable the precompiled cache on Nvidia's driver. There's no need to
hide information the driver already has in its own cache.
Diffstat (limited to 'src/video_core/renderer_opengl/gl_device.h')
| -rw-r--r-- | src/video_core/renderer_opengl/gl_device.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/video_core/renderer_opengl/gl_device.h b/src/video_core/renderer_opengl/gl_device.h index 3e79d1e37..9141de635 100644 --- a/src/video_core/renderer_opengl/gl_device.h +++ b/src/video_core/renderer_opengl/gl_device.h @@ -120,6 +120,10 @@ public: return use_asynchronous_shaders; } + bool UseDriverCache() const { + return use_driver_cache; + } + private: static bool TestVariableAoffi(); static bool TestPreciseBug(); @@ -147,6 +151,7 @@ private: bool has_debugging_tool_attached{}; bool use_assembly_shaders{}; bool use_asynchronous_shaders{}; + bool use_driver_cache{}; }; } // namespace OpenGL |
