Name | lightFalloff() |
||||||
---|---|---|---|---|---|---|---|
Description | Sets the falloff rates for point lights, spot lights, and ambient lights. The parameters are used to determine the falloff with the following equation: d = distance from light position to vertex position Like fill(), it affects only the elements which are created after it in the code. The default value if LightFalloff(1.0, 0.0, 0.0). Thinking about an ambient light with a falloff can be tricky. It is used, for example, if you wanted a region of your scene to be lit ambiently one color and another region to be lit ambiently by another color, you would use an ambient light with location and falloff. You can think of it as a point light that doesn't care which direction a surface is facing. |
||||||
Syntax | lightFalloff(constant,linear,quadratic) |
||||||
Parameters |
|
||||||
Returns | None | ||||||
Usage | Web & Application | ||||||
Related | lights() ambientLight() pointLight() spotLight() lightSpecular() |