summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorReinUsesLisp <reinuseslisp@airmail.cc>2021-05-08 21:36:51 +0200
committerameerj <52414509+ameerj@users.noreply.github.com>2021-07-23 03:51:30 +0200
commitdc02cb92e43d2ef05197e4edb2573116d7ae58c1 (patch)
treed75b0e2dd0db4bceb9503ae4da5ad0d1009b70b6 /src
parentglasm: Initial GLASM compute implementation for testing (diff)
downloadyuzu-dc02cb92e43d2ef05197e4edb2573116d7ae58c1.tar
yuzu-dc02cb92e43d2ef05197e4edb2573116d7ae58c1.tar.gz
yuzu-dc02cb92e43d2ef05197e4edb2573116d7ae58c1.tar.bz2
yuzu-dc02cb92e43d2ef05197e4edb2573116d7ae58c1.tar.lz
yuzu-dc02cb92e43d2ef05197e4edb2573116d7ae58c1.tar.xz
yuzu-dc02cb92e43d2ef05197e4edb2573116d7ae58c1.tar.zst
yuzu-dc02cb92e43d2ef05197e4edb2573116d7ae58c1.zip
Diffstat (limited to 'src')
-rw-r--r--src/video_core/renderer_opengl/gl_rasterizer.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/video_core/renderer_opengl/gl_rasterizer.cpp b/src/video_core/renderer_opengl/gl_rasterizer.cpp
index e527b76ba..4834d58f0 100644
--- a/src/video_core/renderer_opengl/gl_rasterizer.cpp
+++ b/src/video_core/renderer_opengl/gl_rasterizer.cpp
@@ -473,6 +473,14 @@ void RasterizerOpenGL::FlushCommands() {
return;
}
num_queued_commands = 0;
+
+ // Make sure memory stored from the previous GL command stream is visible
+ // This is only needed on assembly shaders where we write to GPU memory with raw pointers
+ // TODO: Call this only when NV_shader_buffer_load or NV_shader_buffer_store have been used
+ // and prefer using NV_shader_storage_buffer_object when possible
+ if (Settings::values.use_assembly_shaders.GetValue()) {
+ glMemoryBarrier(GL_BUFFER_UPDATE_BARRIER_BIT);
+ }
glFlush();
}