ILightProvider

Description

interface Tinman.Engine.Components.ILightProvider

Base interface for classes that provide information about the primary light source in a terrain scene.

Public / Methods

Set​Light


public method SetLight → (4)

altitude in : float64

Latitude of the prominent light in this environment map (see LightAltitude).

azimuth in : float64

Longitude of the prominent light in this environment map (see LightAzimuth).

size in : float64

Apparent size of prominent light in this environment map, in degrees (see LightSize).

scale opt : float64 = 1

[>0]
The high-dynamic range scale factor of this environment (see LightScale).

Configures the prominent light.

Public / Attributes

Light​Altitude


public attribute LightAltitude → (get)

value : float64

[-90..90]
The altitude angle in degrees or Maths.NanD if there is no prominent light.

Altitude angle of the prominent light in the environment map, if applicable.

Light​Azimuth


public attribute LightAzimuth → (get)

value : float64

[-180..180]
The longitude angle in degrees or Maths.NanD if there is no prominent light.

Azimuth angle of the prominent light in the environment map, if applicable.

Light​Scale


public attribute LightScale → (get)

value : float64

[>=0]
The high-dynamic range scale factor.

The high-dynamic range scale factor of this environment.

Light​Size


public attribute LightSize → (get)

value : float64

[>=0]
The apparent diameter of the prominent light, given as an angle in degrees. Will be Maths.NanD if there is no prominent light.

Apparent size of prominent light in the environment map, if applicable.

Set​Light​Mask


public attribute SetLightMask → (get)

value : int32

Zero or more of the following bits:
1 : LightAltitude can be configured.
2 : LightAzimuth can be configured.
4 : LightSize can be configured.
8 : LightScale can be configured.

Can the SetLight method be used to configure the prominent light?

Extensions

Light​Vector


[Pure]
public static method LightVector → ()

returns → Vec3D

The unit-length light direction vector, in cartesian coordinates:

  • Y+ : up-vector (towards zenith)

  • X+ : side-vector (cross product of north-direction and up-vector.

  • Z+ : cross product of side-vector and up-vector.

Computes the direction vector of the prominent light in this environment map.

Set​Light


public static method SetLight → (1)

other in : ILightProvider

[not-null]
The light provider from which to copy the light settings.

Configures the prominent light.