class SpotLight extends ShadowLight
Creates a SpotLight object in the scene with the passed parameters :
angle
(float, in radians) is the spot light cone angle,
exponent
(float) is the light decay speed with the distance from the emission spot.
A spot light is a simply light oriented cone.
It can cast shadows.
Documentation : http://doc.babylonjs.com/tutorials/lights
Name | Type | Description | |
---|---|---|---|
name | string | ||
position | Vector3 | ||
direction | Vector3 | ||
angle | number | ||
exponent | number |
Allows scaling the angle of the light for shadow generation only.
Returns the string "SpotLight".
Returns the integer 2.
Sets the passed Effect object with the SpotLight transfomed position (or position if not parented) and normalized direction.
Return the SpotLight.
Name | Type | Description | |
---|---|---|---|
effect | Effect | ||
lightIndex | string |