AmbientLight Class |
Namespace: DigitalRune.Graphics
The AmbientLight type exposes the following members.
Name | Description | |
---|---|---|
AmbientLight |
Initializes a new instance of the AmbientLight class.
|
Name | Description | |
---|---|---|
Clone |
Creates a new Light that is a clone (deep copy) of the current instance.
(Inherited from Light.) | |
CloneCore |
Makes the instance a clone (deep copy) of the specified Light.
(Overrides LightCloneCore(Light).) | |
CreateInstanceCore |
When implemented in a derived class, creates a new instance of the
Light derived class.
(Overrides LightCreateInstanceCore.) | |
Equals | (Inherited from Object.) | |
Finalize | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.) | |
GetHashCode | Serves as a hash function for a particular type. (Inherited from Object.) | |
GetIntensity |
Gets the (approximated) light intensity at the given distance.
(Overrides LightGetIntensity(Single).) | |
GetType | Gets the Type of the current instance. (Inherited from Object.) | |
MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object.) | |
ToString | Returns a string that represents the current object. (Inherited from Object.) |
Name | Description | |
---|---|---|
Color |
Gets or sets the RGB color of the light.
| |
HdrScale |
Gets or sets the HDR scale of the light.
| |
HemisphericAttenuation |
Gets or sets the hemispheric attenuation factor.
| |
Intensity |
Gets or sets the intensity of the light.
| |
Name |
Gets or sets the name of the light.
(Inherited from Light.) | |
Shape |
Gets or sets the shape of the light volume.
|
The ambient light represents indirect light in a scene. Indirect light has no origin, direction or range, it has only color and intensity.
Color, Intensity, and HdrScale are multiplied to get the final light intensity which can be used in the lighting equations.
When using a low dynamic range lighting (LDR lighting) the ambient light intensity is Lambient = ColorRGB · Intensity
When using a high dynamic range lighting (HDR lighting) the ambient light intensity is Lambient = ColorRGB · Intensity · HdrScale
Hemispheric Lighting: If HemisphericAttenuation is greater than 0, then the AmbientLight acts as a hemispheric light with an up direction of (0, 1, 0) - see Up. (A LightNode needs to be created to orient a light within a 3D scene.) A hemispheric light uses the normal vector of the lit surface to attenuate the light intensity. See HemisphericAttenuation for more information.
The default Shape of an ambient light is an InfiniteShape which covers the whole game world. It is allowed to set a different shape to create a local light.