unreal.CompositeLayerSingleLightShadow¶
- class unreal.CompositeLayerSingleLightShadow(outer: Object | None = None, name: Name | str = 'None')¶
Bases:
CompositeLayerBaseLayer for catching shadows from a single light.
Classic shadow map percentage-closer filtering technique (without cascades), defaulting to 5x5. Implemented with custom render passes for minimal performance cost.
C++ Source:
Plugin: Composite
Module: Composite
File: CompositeLayerSingleLightShadow.h
Editor Properties: (see get_editor_property/set_editor_property)
is_enabled(bool): [Read-Write] Whether or not the pass is enabled.light(Light): [Read-Write] The reference light, whose exact transform will by used to render a shadow map. Please make sure it is aligned to your shadow casting scene by piloting the light.Only directional lights are currently supported.
name(str): [Read-Write] Pass layer name.operation(CompositeCoreMergeOp): [Read-Write] Merge operation applied on Input0 with Input1.orthographic_width(float): [Read-Write] The desired width (in world units) of the shadow map view (ignored if light is not directional). Reduce size to only contain the shadow casting geometry in view of the light.shadow_bias(float): [Read-Write] Shadow bias to avoid shadow acne. Increase until unwanted shadowing disappears (automatically scaled by r.Shadow.CSMDepthBias console variable).shadow_casting_actors(Array[Actor]): [Read-Write] Optional: List of shadow casting actors to be removed from the main camera view’s scene depth. This helps create a cleaner shadow matte preventing aliased dark edges around CG objects.shadow_map_resolution(int32): [Read-Write] Resolution of the shadow map texture. Lower resolutions will cause more blurry shadows, but require a higher shadow bias.shadow_strength(float): [Read-Write] Basic shadow strength multiplier, from 0 to 1.
- property light: Light¶
[Read-Write] The reference light, whose exact transform will by used to render a shadow map. Please make sure it is aligned to your shadow casting scene by piloting the light.
Only directional lights are currently supported.
- Type:
(Light)
- property orthographic_width: float¶
[Read-Write] The desired width (in world units) of the shadow map view (ignored if light is not directional). Reduce size to only contain the shadow casting geometry in view of the light.
- Type:
(float)
- property shadow_bias: float¶
[Read-Write] Shadow bias to avoid shadow acne. Increase until unwanted shadowing disappears (automatically scaled by r.Shadow.CSMDepthBias console variable).
- Type:
(float)
- property shadow_casting_actors: None¶
List of shadow casting actors to be removed from the main camera view’s scene depth. This helps create a cleaner shadow matte preventing aliased dark edges around CG objects.