Click or drag to resize
DigitalRuneCloudLayerNodeSunOcclusion Property
Gets the sun occlusion.

Namespace: DigitalRune.Graphics.SceneGraph
Assembly: DigitalRune.Graphics (in DigitalRune.Graphics.dll) Version: 1.2.0.0 (1.2.1.14562)
Syntax
public float SunOcclusion { get; }

Property Value

Type: Single
The sun occlusion.
Remarks

If SunQuerySize is greater than 0, then a hardware occlusion query is used to compute how much of the sun is occluded by clouds. The query size is the approximate size of the sun on screen. This value is used in the occlusion query to determine the visibility of the sun. The query size is the height of the sun relative to the viewport. Example: QuerySize = 0.1 means that the light source is approximately 1/10 of the viewport.

The resulting occlusion value is stored in SunOcclusion. An occlusion value of 0 means the sun is not occluded by clouds. An occlusion value of 1 means the sun is totally hidden by clouds. This information can be used to change the intensity of sun lens flares and similar effects that depend on the visibility of the sun.

Hardware occlusion queries usually require one or more frames to complete. This means that the value stored in SunOcclusion may be one or more frames old.

The SunOcclusion is not computed in Reach graphics profile. (The occlusion value is always 0.)

See Also