Package jgl.context.attrib
Class gl_lighting
- java.lang.Object
-
- jgl.context.attrib.gl_lighting
-
public class gl_lighting extends Object
gl_lighting is the lighting class of jGL 2.4.- Version:
- 0.3, 15 Mar 2001
- Author:
- Robin Bing-Yu Chen
-
-
Field Summary
Fields Modifier and Type Field Description boolean
ColorMaterial
GL_COLOR_MATERIAL: True if color tracking is enabledint
ColorMaterialFace
GL_COLOR_MATERIAL_FACE: Face(s) affected by color trackingint
ColorMaterialParameter
GL_COLOR_MATERIAL_PARAMETER: Material properties tracking current colorboolean
Enable
GL_LIGHTING: True is lighting is enabled, also in gl_enablegl_light[]
Light
For light ifloat[]
LightModelAmbient
GL_LIGHT_MODEL_AMBIENT: Ambient scene colorboolean
LightModelLocalViewer
GL_LIGHT_MODEL_LOCAL_VIEWER: Viewer is localboolean
LightModelTwoSide
GL_LIGHT_MODEL_TWO_SIDE: Use two-sided lightinggl_material[]
Material
For material colorint
ShadeModel
GL_SHADE_MODEL: glShadeModel() setting
-
Constructor Summary
Constructors Constructor Description gl_lighting()
gl_lighting(gl_lighting cc)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
color_vertex(float[] vertex, float[] normal)
float[]
get_light(int light, int pname)
float[]
get_material(int face, int pname)
void
set_color(float r, float g, float b, float a)
void
set_color_material(int face, int mode)
void
set_light(int light, int pname, float[] params)
void
set_light_model(int pname, float[] params)
void
set_material(int face, int pname, float[] params)
-
-
-
Field Detail
-
ShadeModel
public int ShadeModel
GL_SHADE_MODEL: glShadeModel() setting
-
Enable
public boolean Enable
GL_LIGHTING: True is lighting is enabled, also in gl_enable
-
ColorMaterial
public boolean ColorMaterial
GL_COLOR_MATERIAL: True if color tracking is enabled
-
ColorMaterialParameter
public int ColorMaterialParameter
GL_COLOR_MATERIAL_PARAMETER: Material properties tracking current color
-
ColorMaterialFace
public int ColorMaterialFace
GL_COLOR_MATERIAL_FACE: Face(s) affected by color tracking
-
LightModelAmbient
public float[] LightModelAmbient
GL_LIGHT_MODEL_AMBIENT: Ambient scene color
-
LightModelLocalViewer
public boolean LightModelLocalViewer
GL_LIGHT_MODEL_LOCAL_VIEWER: Viewer is local
-
LightModelTwoSide
public boolean LightModelTwoSide
GL_LIGHT_MODEL_TWO_SIDE: Use two-sided lighting
-
Material
public gl_material[] Material
For material color
-
Light
public gl_light[] Light
For light i
-
-
Constructor Detail
-
gl_lighting
public gl_lighting(gl_lighting cc)
-
gl_lighting
public gl_lighting()
-
-
Method Detail
-
set_material
public void set_material(int face, int pname, float[] params)
-
get_material
public float[] get_material(int face, int pname)
-
set_color_material
public void set_color_material(int face, int mode)
-
set_color
public void set_color(float r, float g, float b, float a)
-
set_light_model
public void set_light_model(int pname, float[] params)
-
set_light
public void set_light(int light, int pname, float[] params)
-
get_light
public float[] get_light(int light, int pname)
-
color_vertex
public int color_vertex(float[] vertex, float[] normal)
-
-