r.Mobile.MaxVisibleMovableSpotLightShadows
r.Mobile.MaxVisibleMovableSpotLightShadows
#Overview
name: r.Mobile.MaxVisibleMovableSpotLightShadows
This variable is created as a Console Variable (cvar).
- type:
Var
- help:
The max number of visible spotlighs can cast shadow sorted by screen size, should be as less as possible for performance reason
It is referenced in 2
C++ source files.
#Summary
#References in C++ code
#Callsites
This variable is referenced in the following C++ source code:
#Loc: <Workspace>/Engine/Source/Runtime/Renderer/Private/MobileBasePassRendering.cpp:37
Scope: file
Source code excerpt:
static TAutoConsoleVariable<int32> CVarMobileMaxVisibleMovableSpotLightShadows(
TEXT("r.Mobile.MaxVisibleMovableSpotLightShadows"),
8,
TEXT("The max number of visible spotlighs can cast shadow sorted by screen size, should be as less as possible for performance reason"),
ECVF_RenderThreadSafe);
static TAutoConsoleVariable<int32> CVarMobileSceneDepthAux(
TEXT("r.Mobile.SceneDepthAux"),
#Loc: <Workspace>/Engine/Source/Runtime/Renderer/Private/ShadowSetup.cpp:6503
Scope (from outer to inner):
file
function void FSceneRenderer::FilterDynamicShadows
Source code excerpt:
//Limit the number of spotlights shadow for performance reason
static const auto MobileMaxVisibleMovableSpotLightShadowsCVar = IConsoleManager::Get().FindTConsoleVariableDataInt(TEXT("r.Mobile.MaxVisibleMovableSpotLightShadows"));
if (MobileMaxVisibleMovableSpotLightShadowsCVar)
{
int32 MobileMaxVisibleMovableSpotLightShadows = MobileMaxVisibleMovableSpotLightShadowsCVar->GetValueOnRenderThread();
MobileDynamicSpotlightShadows.SetNum(FMath::Min(MobileDynamicSpotlightShadows.Num(), MobileMaxVisibleMovableSpotLightShadows), EAllowShrinking::No);
}