Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • SkyMaterialDto

Index

Constructors

constructor

  • new SkyMaterialDto(luminance?: number, turbidity?: number, rayleigh?: number, mieCoefficient?: number, mieDirectionalG?: number, distance?: number, inclination?: number, azimuth?: number, sunPosition?: Vector3, useSunPosition?: boolean, cameraOffset?: Vector3, up?: Vector3, dithering?: boolean): SkyMaterialDto
  • Parameters

    • Optional luminance: number
    • Optional turbidity: number
    • Optional rayleigh: number
    • Optional mieCoefficient: number
    • Optional mieDirectionalG: number
    • Optional distance: number
    • Optional inclination: number
    • Optional azimuth: number
    • Optional sunPosition: Vector3
    • Optional useSunPosition: boolean
    • Optional cameraOffset: Vector3
    • Optional up: Vector3
    • Optional dithering: boolean

    Returns SkyMaterialDto

Properties

azimuth

azimuth: number

Defines the solar azimuth in interval [0, 1]. The azimuth is the angle in the horizontal plan between an object direction and a reference direction.

default

0.25

minimum

0

maximum

1

step

0.01

cameraOffset

cameraOffset: Vector3

Defines an offset vector used to get a horizon offset.

example

skyMaterial.cameraOffset.y = camera.globalPosition.y // Set horizon relative to 0 on the Y axis

default

undefined

optional

true

distance

distance: number

Defines the distance of the sun according to the active scene camera.

default

500

minimum

0

maximum

Infinity

step

10

dithering

dithering: boolean

Defines if sky should be dithered.

default

false

inclination

inclination: number

Defines the sun inclination, in interval [-0.5, 0.5]. When the inclination is not 0, the sun is said "inclined".

default

0.49

minimum

-0.5

maximum

0.5

step

0.01

luminance

luminance: number

Defines the overall luminance of sky in interval ]0, 1[.

default

1

minimum

0

maximum

1

step

0.01

mieCoefficient

mieCoefficient: number

Defines the mieCoefficient in interval [0, 0.1] which affects the property .mieDirectionalG.

default

0.005

minimum

0

maximum

Infinity

step

0.001

mieDirectionalG

mieDirectionalG: number

Defines the amount of haze particles following the Mie scattering theory.

default

0.8

minimum

0

maximum

Infinity

step

0.1

rayleigh

rayleigh: number

Defines the sky appearance (light intensity).

default

2

minimum

0

maximum

Infinity

step

1

sunPosition

sunPosition: Vector3

Defines the sun position in the sky on (x,y,z). If the property .useSunPosition is set to false, then the property is overridden by the inclination and the azimuth and can be read at any moment.

default

undefined

optional

true

turbidity

turbidity: number

Defines the amount (scattering) of haze as opposed to molecules in atmosphere.

default

10

minimum

0

maximum

Infinity

step

1

up

up: number[]

Defines the vector the skyMaterial should consider as up. (default is Vector3(0, 1, 0) as returned by Vector3.Up())

default

[0, 1, 0]

useSunPosition

useSunPosition: boolean

Defines if the sun position should be computed (inclination and azimuth) according to the given .sunPosition property.

default

false

Generated using TypeDoc