From adada8f56edb4533ff4cd6502c1f12c71186d268 Mon Sep 17 00:00:00 2001 From: Blixibon Date: Thu, 27 May 2021 11:41:52 -0500 Subject: [PATCH] Made env_global_light start using different cvars for shadow map resolution and filter size --- sp/src/game/client/c_env_global_light.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/sp/src/game/client/c_env_global_light.cpp b/sp/src/game/client/c_env_global_light.cpp index 4bbb96d2..b143a79d 100644 --- a/sp/src/game/client/c_env_global_light.cpp +++ b/sp/src/game/client/c_env_global_light.cpp @@ -27,7 +27,9 @@ ConVar cl_globallight_xoffset( "cl_globallight_xoffset", "0" ); ConVar cl_globallight_yoffset( "cl_globallight_yoffset", "0" ); static ConVar cl_globallight_slopescaledepthbias_shadowmap( "cl_globallight_slopescaledepthbias_shadowmap", "16", FCVAR_CHEAT ); +static ConVar cl_globallight_shadowfiltersize( "cl_globallight_shadowfiltersize", "0.1", FCVAR_CHEAT ); static ConVar cl_globallight_depthbias_shadowmap( "cl_globallight_depthbias_shadowmap", "0.00001", FCVAR_CHEAT ); +static ConVar cl_globallight_depthres( "cl_globallight_depthres", "8192", FCVAR_CHEAT ); #else ConVar cl_globallight_xoffset( "cl_globallight_xoffset", "-800" ); ConVar cl_globallight_yoffset( "cl_globallight_yoffset", "1600" ); @@ -291,6 +293,8 @@ void C_GlobalLight::ClientThink() #ifdef MAPBASE //state.m_bDrawShadowFrustum = true; // Don't draw that huge debug thing + state.m_flShadowMapResolution = cl_globallight_depthres.GetFloat(); + state.m_flShadowFilterSize = cl_globallight_shadowfiltersize.GetFloat(); state.m_flShadowSlopeScaleDepthBias = cl_globallight_slopescaledepthbias_shadowmap.GetFloat(); state.m_flShadowDepthBias = cl_globallight_depthbias_shadowmap.GetFloat(); state.m_bEnableShadows = m_bEnableShadows;