ShadowCascade
Public / Attributes
Casters
The Batching object that holds the batches for rendering the terrain shadow casters into the shadowmap.
Mesh sectors outside of the light frustum have been culled away. The remaining mesh sectors have been marked explicitly.
- See also
ShadowFrustum
The fitted frustum in terrain-space that contains all shadow receivers and casters.
The plane at index 0
(see Frustum.PlaneAt) is perpendicular to the light direction and represent the far clipping plane. The other planes are parallel to the light direction vector and form a convex hull.
An object is a potential shadow caster if it intersects with the shadow frustum.
ShadowHull
Returns a vector shape that represents the convex hull of all shadow receivers and casters in shadowmap-space (see ShadowMatrix).
The convex hull is not needed for shadow-mapping, but it is useful for visual debugging.
- See also
ShadowMatrix
The shadow matrix that transforms terrain-space to shadowmap-space.
The shadowmap-space is defined as follows:
X := texture U-axis, [0..1] => left to right Y := texture V-axis, [0..1] => top to bottom Z := texture sample value, from 0 (near) to 1 (far)
ShadowMatrixLocal
The shadow matrix that transforms local terrain-space (i.e. centered at view point, see ShadowMapping.ViewPoint) to shadowmap-space.
The shadowmap-space is defined as follows:
X := texture U-axis, [0..1] => left to right Y := texture V-axis, [0..1] => top to bottom Z := texture sample value, from 0 (near) to 1 (far)
- See also
ShadowMatrixPerspective
Enable perspective transformation in shadow matrix?
Defaults to true
.
- See also
ShadowProjection
The shadow matrix that transforms local terrain-space (i.e. centered at view point, see ShadowMapping.ViewPoint) to normalized device coordinates.
Normalized device coordinates are defined as follows:
[+1, 0, 0] := right viewport edge [-1, 0, 0] := left viewport edge [0, +1, 0] := top viewport edge [0, -1, 0] := bottom viewport edge [0, 0, +1] := far plane [0, 0, N] := near plane
where N
is either 0
or -1
, depending on the value of INearAtZero.NearAtZero.
- See also
ShadowProjectionMaxZ
The maximum Z-value before division by W, produced by the shadow projection matrix (see ShadowProjection) when transforming the shadow receivers point soup (see Receivers).
This value is useful when using a non-linear depth buffer (e.g. a logarithmic one).
- See also