mirror of
https://github.com/ZDoom/gzdoom-gles.git
synced 2024-11-11 15:22:15 +00:00
Fix viewport not being updated when resizing window when no scene is active
This commit is contained in:
parent
4e38f31a86
commit
847d2e8862
1 changed files with 3 additions and 0 deletions
|
@ -286,6 +286,9 @@ void FGLRenderer::Begin2D()
|
||||||
{
|
{
|
||||||
if (FGLRenderBuffers::IsEnabled())
|
if (FGLRenderBuffers::IsEnabled())
|
||||||
{
|
{
|
||||||
|
if (!mDrawingScene2D) // For when there's no scene rendered (main menu and intermission)
|
||||||
|
SetOutputViewport(nullptr);
|
||||||
|
|
||||||
mBuffers->Setup(mScreenViewport.width, mScreenViewport.height, mSceneViewport.width, mSceneViewport.height);
|
mBuffers->Setup(mScreenViewport.width, mScreenViewport.height, mSceneViewport.width, mSceneViewport.height);
|
||||||
if (mDrawingScene2D)
|
if (mDrawingScene2D)
|
||||||
mBuffers->BindSceneFB();
|
mBuffers->BindSceneFB();
|
||||||
|
|
Loading…
Reference in a new issue