mirror of
https://github.com/ZDoom/Raze.git
synced 2024-11-16 01:11:44 +00:00
astub.cpp: only call GL functions if we are in a GL mode
git-svn-id: https://svn.eduke32.com/eduke32@6709 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
322f1b46dd
commit
94b2fc68af
1 changed files with 13 additions and 4 deletions
|
@ -2509,15 +2509,21 @@ static int32_t DrawTiles(int32_t iTopLeft, int32_t iSelected, int32_t nXTiles, i
|
|||
static inline void pushDisableFog(void)
|
||||
{
|
||||
#ifdef USE_OPENGL
|
||||
glPushAttrib(GL_ENABLE_BIT);
|
||||
glDisable(GL_FOG);
|
||||
if (getrendermode() >= REND_POLYMOST)
|
||||
{
|
||||
glPushAttrib(GL_ENABLE_BIT);
|
||||
glDisable(GL_FOG);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
static inline void popDisableFog(void)
|
||||
{
|
||||
#ifdef USE_OPENGL
|
||||
glPopAttrib();
|
||||
if (getrendermode() >= REND_POLYMOST)
|
||||
{
|
||||
glPopAttrib();
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
|
@ -3264,7 +3270,10 @@ static int32_t OnSelectTile(int32_t tileNum)
|
|||
|
||||
setpolymost2dview();
|
||||
#ifdef USE_OPENGL
|
||||
glEnable(GL_TEXTURE_2D);
|
||||
if (getrendermode() >= REND_POLYMOST)
|
||||
{
|
||||
glEnable(GL_TEXTURE_2D);
|
||||
}
|
||||
#endif
|
||||
clearview(-1);
|
||||
|
||||
|
|
Loading…
Reference in a new issue