[page:Object3D] →
[name]
Helper object to assist with visualizing a [page:DirectionalLight]'s effect on the scene.
This consists of plane and a line representing the light's position and direction.
Example
var light = new THREE.DirectionalLight( 0xFFFFFF );
var helper = new THREE.DirectionalLightHelper( light, 5 );
scene.add( helper );
Constructor
[name]( [param:DirectionalLight light], [param:Number size], [param:Hex color] )
[page:DirectionalLight light]-- The light to be visualized.
[page:Number size] -- (optional) dimensions of the plane. Default is *1*.
[page:Hex color] -- (optional) if this is not the set the helper will take the color of the light.
Properties
See the base [page:Object3D] class for common properties.
[property:Line lightPlane]
Contains the line mesh showing the location of the directional light.
[property:DirectionalLight light]
Reference to the [page:DirectionalLight directionalLight] being visualized.
[property:object matrix]
Reference to the light's [page:Object3D.matrixWorld matrixWorld].
[property:object matrixAutoUpdate]
See [page:Object3D.matrixAutoUpdate]. Set to *false* here as the helper is using the
light's [page:Object3D.matrixWorld matrixWorld].
[property:hex color]
The color parameter passed in the constructor. Default is *undefined*. If this is changed,
the helper's color will update the next time [page:.update update] is called.
Methods
See the base [page:Object3D] class for common properties.
[method:null dispose]()
Dispose of the directionalLightHelper.
[method:null update]()
Updates the helper to match the position and direction of the [page:.light directionalLight] being visualized.
Source
[link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]