the location of the point light, in world coordinates
the constant attenuation factor
the linear attenuation factor
the quadratic attenuation factor
Calculates the vector of the ray of light that reaches a point.
Calculates the vector of the ray of light that reaches a point. The length of the vector is the intensity of the light. The direction of the vector is the direction from the light to the point.
the point to illuminate
the light ray
Helper function to calculate attenuation.
Helper function to calculate attenuation.
the distance to attenuate for
the attenuation multiplier
the constant attenuation factor
the linear attenuation factor
the quadratic attenuation factor
the location of the point light, in world coordinates
Represents light emanating from a point source, attenuated across a distance.
Attenuation for the light source is controlled by a constant factor, a linear factor, and a quadratic factor. For best results, the three should add up to 1.0.
the location of the point light, in world coordinates
the constant attenuation factor
the linear attenuation factor
the quadratic attenuation factor