bitbybit.dev v1.0.0-rc.1
    Preparing search index...
    Index

    Constructors

    • Parameters

      • Optionalluminance: number
      • Optionalturbidity: number
      • Optionalrayleigh: number
      • OptionalmieCoefficient: number
      • OptionalmieDirectionalG: number
      • Optionaldistance: number
      • Optionalinclination: number
      • Optionalazimuth: number
      • OptionalsunPosition: Vector3
      • OptionaluseSunPosition: boolean
      • OptionalcameraOffset: Vector3
      • Optionalup: Vector3
      • Optionaldithering: boolean

      Returns SkyMaterialDto

    Properties

    luminance: number

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

    1
    

    0

    1

    0.01

    turbidity: number

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

    10
    

    0

    Infinity

    1

    rayleigh: number

    Defines the sky appearance (light intensity).

    2
    

    0

    Infinity

    1

    mieCoefficient: number

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

    0.005
    

    0

    Infinity

    0.001

    mieDirectionalG: number

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

    0.8
    

    0

    Infinity

    0.1

    distance: number

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

    500
    

    0

    Infinity

    10

    inclination: number

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

    0.49
    

    -0.5

    0.5

    0.01

    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.

    0.25
    

    0

    1

    0.01

    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.

    undefined
    

    true

    useSunPosition: boolean

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

    false
    
    cameraOffset: Vector3

    Defines an offset vector used to get a horizon offset.

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

    true

    up: number[]

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

    [0, 1, 0]
    
    dithering: boolean

    Defines if sky should be dithered.

    false