|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.proteinshader.gui.viewing.Lighting
public class Lighting
Sets up OpenGL lighting for the Renderer.
| Field Summary | |
|---|---|
static float[] |
AMBIENT_LIGHT
The ambient light is { 0.2f, 0.2f, 0.2f, 0.0f }. |
static float[] |
DIFFUSE_LIGHT
The diffuse light is { 0.95f, 0.95f, 0.95f, 0.0f }. |
static float[] |
LIGHT0_POSITION
The position of light zero is {200.0f, 200.0f, 200.0f, 1.0f}. |
static float[] |
SPECULAR_LIGHT
The specular light is { 0.95f, 0.95f, 0.95f, 0.0f }. |
| Constructor Summary | |
|---|---|
Lighting()
Constructs a Lighting object. |
|
| Method Summary | |
|---|---|
void |
disableLighting(GL gl)
Disables the lighting. |
void |
enableLightOne(GL gl,
float x,
float y,
float z)
Light one is set to the xyz-coordinates given as arguments Light one is a positional light and is intended to be used for specular lighting. |
void |
enableLightZero(GL gl)
Light zero is set to the position given in LIGHT0_POSITIONS. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final float[] LIGHT0_POSITION
public static final float[] AMBIENT_LIGHT
public static final float[] DIFFUSE_LIGHT
public static final float[] SPECULAR_LIGHT
| Constructor Detail |
|---|
public Lighting()
| Method Detail |
|---|
public void enableLightZero(GL gl)
gl - the current GL object.
public void enableLightOne(GL gl,
float x,
float y,
float z)
gl - the current GL object.x - the x-coordinate for light one.y - the y-coordinate for light one.z - the z-coordinate for light one.public void disableLighting(GL gl)
gl - the current GL object.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||