Abstract base class for lights - all other light types inherit the properties and methods described here.


Light(color : Integer, intensity : Float)

color - (optional) hexadecimal color of the light. Default is 0xffffff (white).
intensity - (optional) numeric value of the light's strength/intensity. Default is 1.

Creates a new Light. Note that this is not intended to be called directly (use one of derived classes instead).


See the base Object3D class for common properties.

.color : Color

Color of the light. Defaults to a new Color set to white, if not passed in the constructor.

.intensity : Float

The light's intensity, or strength.
In physically correct mode, the product of color * intensity is interpreted as luminous intensity measured in candela.
Default - 1.0.


See the base Object3D class for common methods.

.copy (source : Light) : Light

Copies the value of color and intensity from the source light into this one.

.toJSON (meta : Object) : Object

meta -- object containing metadata such as materials, textures for objects.
Convert the light to Verge3D JSON Object/Scene format.


For more info on how to obtain the source code of this module see this page.