From c1d7d1bfe06a1f1d5f217404f9eb447c3e5db8bd Mon Sep 17 00:00:00 2001 From: pogokeen Date: Thu, 22 Mar 2018 07:13:30 +0000 Subject: [PATCH] Fix console background disappearing intermittently git-svn-id: https://svn.eduke32.com/eduke32@6785 1a8010ca-5511-0410-912e-c29ae57300e0 --- source/build/src/common.cpp | 2 ++ source/duke3d/src/osdfuncs.cpp | 3 +++ 2 files changed, 5 insertions(+) diff --git a/source/build/src/common.cpp b/source/build/src/common.cpp index e16e2debf..ba04de340 100644 --- a/source/build/src/common.cpp +++ b/source/build/src/common.cpp @@ -248,6 +248,7 @@ void COMMON_clearbackground(int32_t numcols, int32_t numrows) { // glPushAttrib(GL_FOG_BIT); polymost_setFogEnabled(false); + polymost_useColorOnly(true); setpolymost2dview(); glColor4f(0.f, 0.f, 0.f, 0.67f); @@ -257,6 +258,7 @@ void COMMON_clearbackground(int32_t numcols, int32_t numrows) glRecti(0, 8*numrows+4, xdim, 8*numrows+8); // glPopAttrib(); + polymost_useColorOnly(false); polymost_setFogEnabled(true); return; diff --git a/source/duke3d/src/osdfuncs.cpp b/source/duke3d/src/osdfuncs.cpp index 87840bea7..0241fb0f7 100644 --- a/source/duke3d/src/osdfuncs.cpp +++ b/source/duke3d/src/osdfuncs.cpp @@ -147,6 +147,7 @@ void GAME_clearbackground(int32_t numcols, int32_t numrows) const int32_t i8n8 = OSD_SCALE(OSDCHAR_HEIGHT*numrows); // glPushAttrib(GL_FOG_BIT); polymost_setFogEnabled(false); + polymost_useColorOnly(true); setpolymost2dview(); glColor4f(0.f, 0.f, 0.f, 0.67f); @@ -154,6 +155,8 @@ void GAME_clearbackground(int32_t numcols, int32_t numrows) glRecti(0, 0, xdim, i8n8+OSDCHAR_HEIGHT); glColor4f(0.f, 0.f, 0.f, 1.f); glRecti(0, i8n8+4, xdim, i8n8+OSDCHAR_HEIGHT); + + polymost_useColorOnly(false); if (!nofog) polymost_setFogEnabled(true); // glPopAttrib();