Shadow
Plain, user-tunable data owned by a shadow-casting light and exposed as a public member. Holds only the settings that cannot be derived from the light. The depth framebuffer, texture, and light-space projection are owned by the renderer, and the projection is derived from the light's own properties.
Properties
auto_update bool
Re-renders the shadow map every frame.
Disable for lights whose casters are static to skip their shadow passes. The light and its casters must not move while disabled.
bool auto_update {true};bias float
Constant depth bias applied to the shadow compare.
Positive values push the compare toward the light, reducing self-shadowing artifacts. Overly large values cause shadows to visibly detach from their casters.
float bias {0.0f};extent float
Half-width of the directional shadow camera's orthographic box.
float extent {15.0f};far float
Far plane of the shadow camera.
Directional lights always use this value. Point lights and spot lights with a positive range use the range instead.
float far {500.0f};map_size unsigned int
Resolution of the square shadow map.
unsigned int map_size {1024};near float
Near plane of the shadow camera.
float near {0.5f};needs_update bool
Requests a one-time shadow map refresh when auto_update is disabled.
Cleared by the renderer after the next render.
bool needs_update {false};