ShadowCastingMode enum Lighting and environment
How a node's meshes participate in shadow casting, set through
Node.shadowCastingMode.
Independent of whether the meshes are visible in the color image, except for shadowsOnly, which is defined as the combination of the two.
Values
- off → const ShadowCastingMode
-
The meshes never render into any shadow map. They still draw normally, so they are lit but throw no shadow. Use for geometry whose shadow is noise (foliage cards, decals, effects) or already baked into the scene.
- on → const ShadowCastingMode
-
The meshes cast shadows from the faces the light sees, respecting each material's own culling: a double-sided material casts from both faces. The default.
- doubleSided → const ShadowCastingMode
-
The meshes cast from every face, ignoring material culling. Fixes light leaking through single-sided geometry (a wall or ground plane modelled as one-sided), at the cost of rendering both faces into the map.
- shadowsOnly → const ShadowCastingMode
-
The meshes render into shadow maps but never into the color image, so they throw a shadow while staying invisible. Use for an off-screen or stand-in occluder: a cheap proxy casting in place of an expensive mesh, or geometry outside the frame that must still darken what is in it.
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- index → int
-
A numeric identifier for the enumerated value.
no setterinherited
- name → String
-
Available on Enum, provided by the EnumName extension
The name of the enum value.no setter - runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Constants
-
values
→ const List<
ShadowCastingMode> - A constant List of the values in this enum, in order of their declaration.