public class Light
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
Light.LightSpace |
static class |
Light.LightType |
Constructor and Description |
---|
Light() |
Light(float[] iposition,
float[] iambient,
float[] idiffuse,
float[] ispecular) |
Modifier and Type | Method and Description |
---|---|
float[] |
getAmbient() |
float |
getConstantAttenuation() |
float[] |
getDiffuse() |
float[] |
getDirection() |
int |
getId() |
Light.LightSpace |
getLightSpace() |
float |
getLinearAttenuation() |
float[] |
getPosition() |
float |
getQuadraticAttenuation() |
float[] |
getSpecular() |
float |
getSpotCutoff() |
float |
getSpotExponent() |
Light.LightType |
getType() |
boolean |
isEnabled() |
void |
setAmbient(float[] a) |
void |
setAmbient(float x,
float y,
float z,
float w) |
void |
setAttenuation(float constant,
float linear,
float quadratic) |
void |
setConstantAttenuation(float a) |
void |
setDiffuse(float[] d) |
void |
setDiffuse(float x,
float y,
float z,
float w) |
void |
setDirection(float[] dir) |
void |
setDirection(float x,
float y,
float z) |
void |
setEnabled(boolean set) |
void |
setId(int id) |
void |
setLightSpace(Light.LightSpace lightSpace) |
void |
setLinearAttenuation(float c) |
void |
setPosition(float[] pos) |
void |
setPosition(float x,
float y,
float z) |
void |
setQuadraticAttenuation(float c) |
void |
setSpecular(float[] s) |
void |
setSpecular(float x,
float y,
float z,
float w) |
void |
setSpotCutoff(float rad)
Sets the angular cut-off
|
void |
setSpotExponent(float c) |
void |
setType(Light.LightType type) |
public Light()
public Light(float[] iposition, float[] iambient, float[] idiffuse, float[] ispecular)
public void setPosition(float[] pos)
public void setPosition(float x, float y, float z)
public void setDirection(float[] dir)
public void setDirection(float x, float y, float z)
public void setType(Light.LightType type)
public Light.LightType getType()
public void setAmbient(float[] a)
public void setAmbient(float x, float y, float z, float w)
public void setDiffuse(float[] d)
public void setDiffuse(float x, float y, float z, float w)
public void setSpecular(float[] s)
public void setSpecular(float x, float y, float z, float w)
public float[] getPosition()
public float[] getDirection()
public void setSpotCutoff(float rad)
rad
- angular cut-off (radians)public float getSpotCutoff()
public float getSpotExponent()
public void setSpotExponent(float c)
public void setConstantAttenuation(float a)
public float getConstantAttenuation()
public void setLinearAttenuation(float c)
public float getLinearAttenuation()
public void setQuadraticAttenuation(float c)
public float getQuadraticAttenuation()
public void setAttenuation(float constant, float linear, float quadratic)
public float[] getAmbient()
public float[] getSpecular()
public float[] getDiffuse()
public void setLightSpace(Light.LightSpace lightSpace)
public Light.LightSpace getLightSpace()
public void setId(int id)
public int getId()
public boolean isEnabled()
public void setEnabled(boolean set)