From 36f87b7135afa27dde8e74b457bf03585402c38f Mon Sep 17 00:00:00 2001 From: Christoph Oelckers Date: Thu, 22 Dec 2016 11:14:13 +0100 Subject: [PATCH] - removed gl_light_ambient. This really serves no use anymore and is mostly a remnant of old times with dark CRT monitors. The default ambient level was set at 20, meaning a sector light level of 40. This is a value actual levels rarely get to, except when using some lighting effects - but it's for those that the ambient clamping did the most damage. --- src/gl/renderer/gl_lightdata.cpp | 11 ----------- wadsrc/static/menudef.zz | 1 - 2 files changed, 12 deletions(-) diff --git a/src/gl/renderer/gl_lightdata.cpp b/src/gl/renderer/gl_lightdata.cpp index 0dd180dfb..25ad12344 100644 --- a/src/gl/renderer/gl_lightdata.cpp +++ b/src/gl/renderer/gl_lightdata.cpp @@ -46,12 +46,6 @@ int fogdensity; int outsidefogdensity; int skyfog; -CUSTOM_CVAR (Int, gl_light_ambient, 20, CVAR_ARCHIVE | CVAR_GLOBALCONFIG) -{ - // ambient of 0 does not work correctly because light level 0 is special. - if (self < 1) self = 1; -} - CVAR(Int, gl_weaponlight, 8, CVAR_ARCHIVE); CUSTOM_CVAR(Bool, gl_enhanced_nightvision, true, CVAR_ARCHIVE|CVAR_NOINITCALL) { @@ -209,11 +203,6 @@ int gl_CalcLightLevel(int lightlevel, int rellight, bool weapon) light=lightlevel; } - if (light>=1; - } return clamp(light+rellight, 0, 255); } diff --git a/wadsrc/static/menudef.zz b/wadsrc/static/menudef.zz index 253f984eb..1261286d6 100644 --- a/wadsrc/static/menudef.zz +++ b/wadsrc/static/menudef.zz @@ -231,7 +231,6 @@ OptionMenu "GLPrefOptions" Option "$GLPREFMNU_SPRBILLBOARD", gl_billboard_mode, "BillboardModes" Option "$GLPREFMNU_SPRBILLFACECAMERA", gl_billboard_faces_camera, "OnOff" Option "$GLPREFMNU_PARTICLESTYLE", gl_particles_style, "Particles" - Slider "$GLPREFMNU_AMBLIGHT", gl_light_ambient, 1.0, 255.0, 5.0 Option "$GLPREFMNU_RENDERQUALITY", gl_render_precise, "Precision" Option "$GLPREFMNU_VRMODE", vr_mode, "VRMode" Option "$GLPREFMNU_VRQUADSTEREO", vr_enable_quadbuffered, "OnOff"