mirror of
https://github.com/gnif/LookingGlass.git
synced 2025-07-07 03:59:52 +00:00
[client] corrected screen resize bug and incorrect scissor
This commit is contained in:
parent
893bb7e603
commit
5cfae05cae
@ -492,6 +492,8 @@ bool lgr_opengl_render(void * opaque)
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (this->frameUpdate)
|
||||||
|
{
|
||||||
if (this->resizeWindow)
|
if (this->resizeWindow)
|
||||||
{
|
{
|
||||||
// setup the projection matrix
|
// setup the projection matrix
|
||||||
@ -525,7 +527,12 @@ bool lgr_opengl_render(void * opaque)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// update the scissor rect to prevent drawing outside of the frame
|
// update the scissor rect to prevent drawing outside of the frame
|
||||||
glScissor(0, 0, this->format.width, this->format.height);
|
glScissor(
|
||||||
|
this->destRect.x,
|
||||||
|
this->destRect.y,
|
||||||
|
this->destRect.w,
|
||||||
|
this->destRect.h
|
||||||
|
);
|
||||||
|
|
||||||
this->resizeWindow = false;
|
this->resizeWindow = false;
|
||||||
glDisable(GL_SCISSOR_TEST);
|
glDisable(GL_SCISSOR_TEST);
|
||||||
@ -533,8 +540,6 @@ bool lgr_opengl_render(void * opaque)
|
|||||||
glEnable(GL_SCISSOR_TEST);
|
glEnable(GL_SCISSOR_TEST);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (this->frameUpdate)
|
|
||||||
{
|
|
||||||
glXWaitVideoSyncSGI(1, 0, &this->gpuFrameCount);
|
glXWaitVideoSyncSGI(1, 0, &this->gpuFrameCount);
|
||||||
glFinish();
|
glFinish();
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user