mirror of
https://github.com/DrBeef/QuestZDoom.git
synced 2025-04-24 18:22:02 +00:00
Fix "tearing" issue
This commit is contained in:
parent
7ec233af45
commit
d6d6085740
1 changed files with 8 additions and 2 deletions
|
@ -469,8 +469,14 @@ unsigned char *FGLRenderer::GetTextureBuffer(FTexture *tex, int &w, int &h)
|
|||
#ifdef USE_GL_HW_BUFFERS
|
||||
void FGLRenderer::GPUDropSync()
|
||||
{
|
||||
if(nbrHwBuffers > 1)
|
||||
syncBuff[VtxBuff] = glFenceSync(GL_SYNC_GPU_COMMANDS_COMPLETE,0);
|
||||
if(nbrHwBuffers > 1) {
|
||||
if (syncBuff[VtxBuff] != NULL)
|
||||
{
|
||||
glDeleteSync(syncBuff[VtxBuff]);
|
||||
}
|
||||
|
||||
syncBuff[VtxBuff] = glFenceSync(GL_SYNC_GPU_COMMANDS_COMPLETE, 0);
|
||||
}
|
||||
}
|
||||
|
||||
void FGLRenderer::GPUWaitSync()
|
||||
|
|
Loading…
Reference in a new issue