edu.uprm.ece.terrainrenderer
Class Light
java.lang.Object
edu.uprm.ece.terrainrenderer.Light
public class Light
- extends java.lang.Object
- Author:
- Ricardo Veguilla (veguilla@ece.uprm.edu)
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AMBIENT
public static int AMBIENT
DIFFUSE
public static int DIFFUSE
SPECULAR
public static int SPECULAR
POSITION
public static int POSITION
DIRECTION
public static int DIRECTION
EXPONENT
public static int EXPONENT
CUTOFF
public static int CUTOFF
CONST_ATTENUATION
public static int CONST_ATTENUATION
LINEAR_ATTENUATION
public static int LINEAR_ATTENUATION
QUADRATIC_ATTENUATION
public static int QUADRATIC_ATTENUATION
ambient
java.awt.Color ambient
diffuse
java.awt.Color diffuse
specular
java.awt.Color specular
position
Vertex position
angle
Angle angle
direction
Vector direction
right
Vector right
up
Vector up
exponent
float exponent
cutoff
float cutoff
constantAttenuation
float constantAttenuation
linearAttenuation
float linearAttenuation
quadraticAttenuation
float quadraticAttenuation
id
int id
Light
public Light()
Light
public Light(Vertex position)
getAmbient
public java.awt.Color getAmbient()
- Returns:
- Returns the ambient.
init
public void init(int id)
draw
public void draw(javax.media.opengl.GL gl)
setAmbient
public void setAmbient(java.awt.Color ambient)
- Parameters:
ambient
- The ambient to set.
getAngle
public Angle getAngle()
- Returns:
- Returns the angle.
setAngle
public void setAngle(Angle angle)
- Parameters:
angle
- The angle to set.
getConstantAttenuation
public float getConstantAttenuation()
- Returns:
- Returns the constantAttenuation.
setConstantAttenuation
public void setConstantAttenuation(float constAttenuation)
- Parameters:
constantAttenuation
- The constantAttenuation to set.
getCutoff
public float getCutoff()
- Returns:
- Returns the cutoff.
setCutoff
public void setCutoff(float cutoff)
- Parameters:
cutoff
- The cutoff to set.
getDiffuse
public java.awt.Color getDiffuse()
- Returns:
- Returns the diffuse.
setDiffuse
public void setDiffuse(java.awt.Color diffuse)
- Parameters:
diffuse
- The diffuse to set.
getDirection
public Vector getDirection()
- Returns:
- Returns the direction.
setDirection
public void setDirection(Vector direction)
- Parameters:
direction
- The direction to set.
getExponent
public float getExponent()
- Returns:
- Returns the exponent.
setExponent
public void setExponent(float exponent)
- Parameters:
exponent
- The exponent to set.
getId
public int getId()
- Returns:
- Returns the id.
setId
public void setId(int id)
- Parameters:
id
- The id to set.
getLinearAttenuation
public float getLinearAttenuation()
- Returns:
- Returns the linearAttenuation.
setLinearAttenuation
public void setLinearAttenuation(float linearAttenuation)
- Parameters:
linearAttenuation
- The linearAttenuation to set.
getPosition
public Vertex getPosition()
- Returns:
- Returns the position.
setPosition
public void setPosition(Vertex position)
- Parameters:
position
- The position to set.
getQuadraticAttenuation
public float getQuadraticAttenuation()
- Returns:
- Returns the quadraticAttenuation.
setQuadraticAttenuation
public void setQuadraticAttenuation(float quadraticAttenuation)
- Parameters:
quadraticAttenuation
- The quadraticAttenuation to set.
getRight
public Vector getRight()
- Returns:
- Returns the right.
setRight
public void setRight(Vector right)
- Parameters:
right
- The right to set.
getSpecular
public java.awt.Color getSpecular()
- Returns:
- Returns the specular.
setSpecular
public void setSpecular(java.awt.Color specular)
- Parameters:
specular
- The specular to set.
getUp
public Vector getUp()
- Returns:
- Returns the up.
setUp
public void setUp(Vector up)
- Parameters:
up
- The up to set.