summaryrefslogtreecommitdiff
path: root/Source/Core/VideoBackends/OGL/OGLTexture.cpp
diff options
context:
space:
mode:
authorMarkus Wick <degasus@users.noreply.github.com>2018-02-19 16:26:35 +0100
committerGitHub <noreply@github.com>2018-02-19 16:26:35 +0100
commite01fe4606858d4fa0e8800bd7afb11804902bc02 (patch)
tree318ec016e251ab959ea7f6f91ef1d621d586c802 /Source/Core/VideoBackends/OGL/OGLTexture.cpp
parent93c502fef8980bf6f6db7316738857bb0818debf (diff)
parent6490c2b86b7c56be6a1cd49f6d5f5bea639f8f59 (diff)
Merge pull request #6367 from stenzek/gl-flush
OGL: Use explicit flush instead of GL_SYNC_FLUSH_COMMANDS_BIT
Diffstat (limited to 'Source/Core/VideoBackends/OGL/OGLTexture.cpp')
-rw-r--r--Source/Core/VideoBackends/OGL/OGLTexture.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/Source/Core/VideoBackends/OGL/OGLTexture.cpp b/Source/Core/VideoBackends/OGL/OGLTexture.cpp
index bc93c37dd4..680e1aceae 100644
--- a/Source/Core/VideoBackends/OGL/OGLTexture.cpp
+++ b/Source/Core/VideoBackends/OGL/OGLTexture.cpp
@@ -417,6 +417,7 @@ void OGLStagingTexture::CopyFromTexture(const AbstractTexture* src,
glMemoryBarrier(GL_CLIENT_MAPPED_BUFFER_BARRIER_BIT);
m_fence = glFenceSync(GL_SYNC_GPU_COMMANDS_COMPLETE, 0);
+ glFlush();
}
m_needs_flush = true;
@@ -475,6 +476,7 @@ void OGLStagingTexture::CopyToTexture(const MathUtil::Rectangle<int>& src_rect,
glDeleteSync(m_fence);
m_fence = glFenceSync(GL_SYNC_GPU_COMMANDS_COMPLETE, 0);
+ glFlush();
}
m_needs_flush = true;
@@ -490,7 +492,7 @@ void OGLStagingTexture::Flush()
return;
}
- glClientWaitSync(m_fence, GL_SYNC_FLUSH_COMMANDS_BIT, GL_TIMEOUT_IGNORED);
+ glClientWaitSync(m_fence, 0, GL_TIMEOUT_IGNORED);
glDeleteSync(m_fence);
m_fence = 0;
m_needs_flush = false;