- fixed: If GLRenderer is uninitialized (i.e. using software renderer, or during startup), gl_paltonemap_* CVARs would crash the game.

This commit is contained in:
Rachael Alexanderson 2017-01-28 00:13:27 -05:00
parent 00823217c7
commit f9eb06a22e

View file

@ -135,12 +135,14 @@ CUSTOM_CVAR(Float, gl_ssao_exponent, 1.8f, 0)
CUSTOM_CVAR(Float, gl_paltonemap_powtable, 2.0f, CVAR_ARCHIVE | CVAR_NOINITCALL)
{
GLRenderer->ClearTonemapPalette();
if (GLRenderer)
GLRenderer->ClearTonemapPalette();
}
CUSTOM_CVAR(Bool, gl_paltonemap_reverselookup, true, CVAR_ARCHIVE | CVAR_NOINITCALL)
{
GLRenderer->ClearTonemapPalette();
if (GLRenderer)
GLRenderer->ClearTonemapPalette();
}