Copyright © 2021 by K4.org
  (v.0.48.124)

A virtual light which can be added to the scene. There are several types of lights available:

  • Ambient Delivers light to all surfaces.
  • Point Delivers light from a point source, only those surfaces whose normals are toward the source will be illuminated.
  • Directional Delivers light from one direction, like the Sun.
  • Spot Like a Point light, except only a conical area is illuminated, and more control is available for penumbra and attenuation.
  • Hemisphere A wide-area light for natural illumination.

Use the options parameter to supply additional values to certain light types. See three.js for details.

Note that by default, a Scene includes a standard set of lights, or nothing would be visible. If you want complete control over lighting, you will need to create a scene without the default lights, which is done by setting the Scene parameter useDefaultLights to false.

Index

Rules

__mod3

__mod3: String

Internal Use Only.

Flags : Cached, External (Note this is uncached)

Expression : R.THREE.makeLight(this.refChain, this.spec)

bbox

bbox: Any

An override of the Render3Mixin rule to ensure this does not contribute to the bbox of its parent.

Flags : Cached (Note this is uncached)

Expression : R.THREE.makeBB();

bboxLocal

bboxLocal: Any

An override of the Render3Mixin rule to ensure that this has no bbox.

Flags : Cached (Note this is uncached)

Expression : R.THREE.makeBB()

castShadow

castShadow: Boolean

If true, this light will cast shadows. Only Point, Spot, and Directional lights can cast shadows. Shadows must be enabled in the Scene in order for this to be respected.

Flags : Cached, Parameter (Note this is uncached)

Expression : true

color

color: String

The color which the light emits.

Flags : Cached, Parameter (Note this is uncached)

Expression : "White"

isSelectable

isSelectable: Boolean

An override of the standard rule.

Flags : Cached (Note this is uncached)

Expression : false

lightType

lightType: String

One of: 'Ambient', 'Point', 'Directional', 'Spot', or 'Hemisphere'.

Flags : Cached, Parameter (Note this is uncached)

Expression : "Ambient"

options

options: Any

Additional light-control options that can be supplied to three.js.

Flags : Cached, Parameter (Note this is uncached)

Expression : {}

renderNode

renderNode: Boolean

Override of Render3Mixin rule.

Flags : Cached (Note this is uncached)

Expression : true

showHelper

showHelper: Boolean

If true, a geometric representation of the light is added to the scene. Not all light types have a helper.

Flags : Cached, Parameter (Note this is uncached)

Expression : false

spec

spec: Any

Internal Use Only.

Flags : Cached (Note this is uncached)

Expression : Object.assign({}, this.options, {lightType: this.lightType, color: this.color, target: this.target, showHelper: this.showHelper})

target

target: Point

Defines the light aiming point. Only used by 'Directional' and 'Spot' lights.

Flags : Cached, Parameter (Note this is uncached)

Expression : this.nha.origin