OptionalautoWhen true, the shadow frustum is auto-sized each frame to tightly bracket
the camera's view frustum (clamped to ShadowsParams.maxDistance).
This directs the shadow map's texel budget at what the user is actually
looking at, dramatically improving effective resolution.
When false, ShadowsParams.projectionSize and
ShadowsParams.lightDistance control the frustum manually.
Default value is true.
OptionalbiasDepth-compare bias used to avoid self-shadowing ("shadow acne").
Applied in light-space normalized depth units. Default value is 0.003.
OptionalcascadeNumber of shadow cascades (Cascaded Shadow Maps / PSSM). Higher counts give sharper near-distance shadows while still covering far distances, at the cost of one extra shadow-depth pass per cascade.
Range [1, 6]. 1 disables CSM (equivalent to the previous
single-cascade behaviour). Default is 4.
OptionalcascadeBlend between logarithmic and uniform split schemes for the cascade
boundaries. 0.0 uses uniform-distance splits (good for near-camera
detail density), 1.0 uses logarithmic (good for long-distance
coverage). 0.5 is the standard "practical split scheme" compromise.
Range [0, 1]. Default is 0.5.
OptionaldirectionWorld-space direction the shadow-casting light points in.
Default value is [-0.5, -1.0, -0.3].
OptionalintensityThe darkness of the shadow where a surface is fully occluded from the light.
Range is [0..1]. Default value is 0.45.
OptionallightDistance from the scene center to place the virtual light along ShadowsParams.direction.
Default value is 50.
OptionalmaxWhen ShadowsParams.autoFit is true, the far plane of the shadow
frustum is clamped to this distance from the camera, in world units.
Keeping this small focuses shadow-map resolution on nearby geometry.
Default value is 200.
OptionalnormalView-space distance by which receivers are pushed toward the light before sampling the shadow map. Eliminates shadow acne at glancing angles without needing a large depth ShadowsParams.bias.
Default value is 0.02.
OptionalpaddingMultiplier applied to the auto-fitted shadow frustum's width/height, to pad against cracks at the edges (caused by edge samples outside the fitted frustum).
Range [1.0, ~2.0]. Default value is 1.1.
OptionalpcfSide length of the PCF (Percentage Closer Filtering) kernel, in texels.
Must be an odd integer in the range [1, 7]. 1 disables PCF (hard
shadows). Larger kernels give softer edges at a quadratic sampling cost.
Default value is 3.
OptionalprojectionEdge-of-frustum dimension (world units) of the shadow map's orthographic projection.
Larger values cover more of the scene but reduce resolution. Default value is 30.
OptionalrenderWhich rendering modes in which to apply Shadows.
Default value is [RealisticRender].
OptionalresolutionPixel resolution of the (square) shadow map.
Default value is 2048.
OptionalslopeSlope-scaled depth bias: bias has this much added to it as the surface
tilts away from the light. Scales linearly with tan(angle(normal, light)),
clamped to avoid blow-up at near-parallel angles. Complements
ShadowsParams.normalOffsetBias.
Default value is 0.004.
Parameters for a Shadows.