Class SpotLight
- java.lang.Object
-
- de.coreengine.rendering.renderable.light.AmbientLight
-
- de.coreengine.rendering.renderable.light.PointLight
-
- de.coreengine.rendering.renderable.light.SpotLight
-
public class SpotLight extends PointLight
Class that represents a spot light, basical a point light with a specific direction and light cone angle- Author:
- Darius Dinger
-
-
Constructor Summary
Constructors Constructor Description SpotLight()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description javax.vecmath.Vector3f
getDirection()
Getting the direction, the light is pointing to as vector (x, y, z).
f.e.javax.vecmath.Vector2f
getLightCone()
Getting the light cone of the spotlight as vec2f for read and writing.-
Methods inherited from class de.coreengine.rendering.renderable.light.PointLight
getAttenuation, getPosition
-
Methods inherited from class de.coreengine.rendering.renderable.light.AmbientLight
getColor, getIntensity, setIntensity
-
-
-
-
Method Detail
-
getDirection
public javax.vecmath.Vector3f getDirection()
Getting the direction, the light is pointing to as vector (x, y, z).
f.e. (0, 1, 0) is pointing upwards.- Returns:
- Direction of the light
-
getLightCone
public javax.vecmath.Vector2f getLightCone()
Getting the light cone of the spotlight as vec2f for read and writing. The x value is the inner light cone and the y value is the outer light cone. Tha light fades between the inner and outer cone out.
90 degrees = 0.0 | 0 degrees = 1.0.- Returns:
- Getting the angle of the spotlights cone
-
-