Abstract base class for light shadow classes. These classes represent the shadow configuration for different light types.
Attributes
- Companion
- object
- Graph
-
- Supertypes
-
class Objecttrait Anyclass Objecttrait Matchableclass Any
- Known subtypes
Members list
Value members
Concrete methods
Returns a new light shadow instance with copied values from this instance.
Returns a new light shadow instance with copied values from this instance.
Attributes
- Definition Classes
-
Object
Copies the values of the given light shadow instance to this instance.
Copies the values of the given light shadow instance to this instance.
Attributes
Frees the GPU-related resources allocated by this instance. Call this method whenever this instance is no longer used in your app.
Frees the GPU-related resources allocated by this instance. Call this method whenever this instance is no longer used in your app.
Attributes
Returns the frame extends.
Returns the frame extends.
Attributes
Gets the shadow cameras frustum. Used internally by the renderer to cull objects.
Gets the shadow cameras frustum. Used internally by the renderer to cull objects.
Attributes
Returns a viewport definition for the given viewport index.
Returns a viewport definition for the given viewport index.
Attributes
Used internally by the renderer to get the number of viewports that need to be rendered for this shadow.
Used internally by the renderer to get the number of viewports that need to be rendered for this shadow.
Attributes
Serializes the light shadow into JSON.
Serializes the light shadow into JSON.
Attributes
Update the matrices for the camera and shadow, used internally by the renderer.
Update the matrices for the camera and shadow, used internally by the renderer.
Attributes
Inherited methods
Attributes
- Inherited from:
- Object
Attributes
- Inherited from:
- Object
Attributes
- Inherited from:
- Object
Attributes
- Inherited from:
- Object
Attributes
- Inherited from:
- Object
Concrete fields
Enables automatic updates of the light's shadow. If you do not require dynamic lighting / shadows, you may set this to false.
Enables automatic updates of the light's shadow. If you do not require dynamic lighting / shadows, you may set this to false.
Attributes
Shadow map bias, how much to add or subtract from the normalized depth when deciding whether a surface is in shadow.
Shadow map bias, how much to add or subtract from the normalized depth when deciding whether a surface is in shadow.
The default is 0. Very tiny adjustments here (in the order of 0.0001) may help reduce artifacts in shadows.
Attributes
The amount of samples to use when blurring a VSM shadow map.
The amount of samples to use when blurring a VSM shadow map.
Attributes
The intensity of the shadow. The default is 1. Valid values are in the range [0, 1].
The intensity of the shadow. The default is 1. Valid values are in the range [0, 1].
Attributes
The depth map generated using the internal camera; a location beyond a pixel's depth is in shadow. Computed internally during rendering.
The depth map generated using the internal camera; a location beyond a pixel's depth is in shadow. Computed internally during rendering.
Attributes
The distribution map generated using the internal camera; an occlusion is calculated based on the distribution of depths. Computed internally during rendering.
The distribution map generated using the internal camera; an occlusion is calculated based on the distribution of depths. Computed internally during rendering.
Attributes
Defines the width and height of the shadow map. Higher values give better quality shadows at the cost of computation time. Values must be powers of two.
Defines the width and height of the shadow map. Higher values give better quality shadows at the cost of computation time. Values must be powers of two.
Attributes
The type of shadow texture. The default is UnsignedByteType.
The type of shadow texture. The default is UnsignedByteType.
Attributes
Model to shadow camera space, to compute location and depth in shadow map. This is computed internally during rendering.
Model to shadow camera space, to compute location and depth in shadow map. This is computed internally during rendering.
Attributes
When set to true, shadow maps will be updated in the next render call. If you have set [[LightShadow#autoUpdate]] to false, you will need to set this property to true and then make a render call to update the light's shadow.
When set to true, shadow maps will be updated in the next render call. If you have set [[LightShadow#autoUpdate]] to false, you will need to set this property to true and then make a render call to update the light's shadow.
Attributes
Defines how much the position used to query the shadow map is offset along the object normal. The default is 0. Increasing this value can be used to reduce shadow acne especially in large scenes where light shines onto geometry at a shallow angle. The cost is that shadows may appear distorted.
Defines how much the position used to query the shadow map is offset along the object normal. The default is 0. Increasing this value can be used to reduce shadow acne especially in large scenes where light shines onto geometry at a shallow angle. The cost is that shadows may appear distorted.
Attributes
Setting this to values greater than 1 will blur the edges of the shadow. High values will cause unwanted banding effects in the shadows - a greater map size will allow for a higher value to be used here before these effects become visible.
Setting this to values greater than 1 will blur the edges of the shadow. High values will cause unwanted banding effects in the shadows - a greater map size will allow for a higher value to be used here before these effects become visible.
The property has no effect when the shadow map type is PCFSoftShadowMap and and it is recommended to increase softness by decreasing the shadow map size instead.
The property has no effect when the shadow map type is BasicShadowMap.