Object3D

HemisphereLightHelper

Creates a visual aid consisting of a spherical Mesh for a HemisphereLight.

Code Example

const light = new v3d.HemisphereLight(0xffffbb, 0x080820, 1); const helper = new v3d.HemisphereLightHelper(light, 5); scene.add(helper);

Constructor

HemisphereLightHelper(light : HemisphereLight, sphereSize : Float, color : Color | Integer | String)

light — The light being visualized.
size — The size of the mesh used to visualize the light.
color — (optional) if this is not the set the helper will take the color of the light.

Properties

See the base Object3D class for common properties.

.light : HemisphereLight

Reference to the HemisphereLight being visualized.

.matrix : Object

Reference to the hemisphereLight's matrixWorld.

.matrixAutoUpdate : Object

See Object3D.matrixAutoUpdate. Set to false here as the helper is using the hemisphereLight's matrixWorld.

.color : Color

The color parameter passed in the constructor. Default is undefined. If this is changed, the helper's color will update the next time update is called.

Methods

See the base Object3D class for common methods.

.dispose()

Frees the GPU-related resources allocated by this instance. Call this method whenever this instance is no longer used in your app.

.update()

Updates the helper to match the position and direction of the .light.

Source

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