Fix texture flush from CPU WaitSync regression on OpenGL (#4289)
This commit is contained in:
parent
cd3a15aea5
commit
93df366b2c
2 changed files with 23 additions and 21 deletions
|
@ -1431,10 +1431,21 @@ namespace Ryujinx.Graphics.Gpu.Image
|
|||
return;
|
||||
}
|
||||
|
||||
handle.Sync(_context);
|
||||
bool isGpuThread = _context.IsGpuThread();
|
||||
|
||||
if (isGpuThread)
|
||||
{
|
||||
// No need to wait if we're on the GPU thread, we can just clear the modified flag immediately.
|
||||
handle.Modified = false;
|
||||
}
|
||||
|
||||
_context.Renderer.BackgroundContextAction(() =>
|
||||
{
|
||||
if (!isGpuThread)
|
||||
{
|
||||
handle.Sync(_context);
|
||||
}
|
||||
|
||||
Storage.SignalModifiedDirty();
|
||||
|
||||
lock (handle.Overlaps)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue