aboutsummaryrefslogtreecommitdiff
path: root/Ryujinx.Graphics.OpenGL/Pipeline.cs
diff options
context:
space:
mode:
authorriperiperi <rhy3756547@hotmail.com>2020-05-27 08:51:03 +0100
committerGitHub <noreply@github.com>2020-05-27 17:51:03 +1000
commit5dab515c7a1d5cdfb39d5485696b938564761cfb (patch)
treec5bed0cbc5e36575357703da9f78ccad53817bed /Ryujinx.Graphics.OpenGL/Pipeline.cs
parentd941f4c07099bd365f6b0e8efb1cd727ae422009 (diff)
Flush GL commands before inevitably waiting for a query result. (#1278)
Diffstat (limited to 'Ryujinx.Graphics.OpenGL/Pipeline.cs')
-rw-r--r--Ryujinx.Graphics.OpenGL/Pipeline.cs6
1 files changed, 5 insertions, 1 deletions
diff --git a/Ryujinx.Graphics.OpenGL/Pipeline.cs b/Ryujinx.Graphics.OpenGL/Pipeline.cs
index affb4efc..ee4ce298 100644
--- a/Ryujinx.Graphics.OpenGL/Pipeline.cs
+++ b/Ryujinx.Graphics.OpenGL/Pipeline.cs
@@ -1067,11 +1067,15 @@ namespace Ryujinx.Graphics.OpenGL
}
}
- return false; // The GPU will flush the queries to CPU and evaluate the condition there instead.
+ // The GPU will flush the queries to CPU and evaluate the condition there instead.
+
+ GL.Flush(); // The thread will be stalled manually flushing the counter, so flush GL commands now.
+ return false;
}
public bool TryHostConditionalRendering(ICounterEvent value, ICounterEvent compare, bool isEqual)
{
+ GL.Flush(); // The GPU thread will be stalled manually flushing the counter, so flush GL commands now.
return false; // We don't currently have a way to compare two counters for conditional rendering.
}