the location of the spotlight, in world coordinates
the direction that the light points in
the angle of the hotspot (inner cone), in radians, measured from the center of the hotspot to the edge of the hotspot cone; acceptable values are 0 < hotspotAngle < outerAngle
the angle of the outer cone, in radians, measured from the center of the hotspot to the edge of the outer cone; acceptable values are hotspotAngle < outerAngle < Pi/2
the length and width, in pixels, of the shadow map to generate
the constant attenuation factor
the linear attenuation factor
the quadratic attenuation factor
Calculates the vector of the ray of light that reaches a point.
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 direction that the light points in
the angle of the hotspot (inner cone), in radians, measured from the center of the hotspot to the edge of the hotspot cone; acceptable values are 0 < hotspotAngle < outerAngle
the location of the spotlight, in world coordinates
the angle of the outer cone, in radians, measured from the center of the hotspot to the edge of the outer cone; acceptable values are hotspotAngle < outerAngle < Pi/2
Renders the shadow map for the given objects.
Renders the shadow map for the given objects. Remove objects from the list of surfaces if you wish for them not to cast any shadows. If this function is never called before final rendering, no shadows will be generated for this light.
the root node of the hierarchy to render shadows for
the length and width, in pixels, of the shadow map to generate
Creates a spotlight with cone geometry, emanating from a point towards a specific direction, with a given hotspot angle and outer angle.
the location of the spotlight, in world coordinates
the direction that the light points in
the angle of the hotspot (inner cone), in radians, measured from the center of the hotspot to the edge of the hotspot cone; acceptable values are 0 < hotspotAngle < outerAngle
the angle of the outer cone, in radians, measured from the center of the hotspot to the edge of the outer cone; acceptable values are hotspotAngle < outerAngle < Pi/2
the length and width, in pixels, of the shadow map to generate
the constant attenuation factor
the linear attenuation factor
the quadratic attenuation factor