Constructor and Description |
---|
MaterialState()
Constructs material state.
|
Modifier and Type | Method and Description |
---|---|
void |
apply()
Applies this OpenGL state.
|
java.awt.Color |
getAmbientBack()
Gets the ambient color for back faces.
|
java.awt.Color |
getAmbientFront()
Gets the ambient color for front faces.
|
int |
getAttributeBits()
Gets the OpenGL attribute bits for this state.
|
int |
getColorMaterialBack()
Gets the color material mode for back faces.
|
int |
getColorMaterialFront()
Gets the color material mode for front faces.
|
java.awt.Color |
getDiffuseBack()
Gets the diffuse color for back faces.
|
java.awt.Color |
getDiffuseFront()
Gets the diffuse color for front faces.
|
java.awt.Color |
getEmissiveBack()
Gets the emissive color for back faces.
|
java.awt.Color |
getEmissiveFront()
Gets the emissive color for front faces.
|
float |
getShininessBack()
Gets the shininess for back faces.
|
float |
getShininessFront()
Gets the shininess for front faces.
|
java.awt.Color |
getSpecularBack()
Gets the specular color for back faces.
|
java.awt.Color |
getSpecularFront()
Gets the specular color for front faces.
|
boolean |
hasAmbientBack()
Determines whether ambient color for back faces is set.
|
boolean |
hasAmbientFront()
Determines whether ambient color for front faces is set.
|
boolean |
hasColorMaterialBack()
Determines whether color material mode for back faces is set.
|
boolean |
hasColorMaterialFront()
Determines whether color material mode for front faces is set.
|
boolean |
hasDiffuseBack()
Determines whether diffuse color for back faces is set.
|
boolean |
hasDiffuseFront()
Determines whether diffuse color for front faces is set.
|
boolean |
hasEmissiveBack()
Determines whether emissive color for back faces is set.
|
boolean |
hasEmissiveFront()
Determines whether emissive color for front faces is set.
|
boolean |
hasShininessBack()
Determines whether shininess for back faces is set.
|
boolean |
hasShininessFront()
Determines whether shininess for front faces is set.
|
boolean |
hasSpecularBack()
Determines whether specular color for back faces is set.
|
boolean |
hasSpecularFront()
Determines whether specular color for front faces is set.
|
void |
setAmbient(java.awt.Color ambient)
Sets the ambient color for front and back faces.
|
void |
setAmbientBack(java.awt.Color ambient)
Sets the ambient color for back faces.
|
void |
setAmbientFront(java.awt.Color ambient)
Sets the ambient color for front faces.
|
void |
setColorMaterial(int mode)
Sets the color material mode for front and back faces.
|
void |
setColorMaterialBack(int mode)
Sets the color material mode for back faces.
|
void |
setColorMaterialFront(int mode)
Sets the color material mode for front faces.
|
void |
setDiffuse(java.awt.Color diffuse)
Sets the diffuse color for front and back faces.
|
void |
setDiffuseBack(java.awt.Color diffuse)
Sets the diffuse color for back faces.
|
void |
setDiffuseFront(java.awt.Color diffuse)
Sets the diffuse color for front faces.
|
void |
setEmissive(java.awt.Color emissive)
Sets the emissive color for front and back faces.
|
void |
setEmissiveBack(java.awt.Color emissive)
Sets the emissive color for back faces.
|
void |
setEmissiveFront(java.awt.Color emissive)
Sets the emissive color for front faces.
|
void |
setShininess(float shininess)
Sets the shininess for front and back faces.
|
void |
setShininessBack(float shininess)
Sets the shininess for back faces.
|
void |
setShininessFront(float shininess)
Sets the shininess for front faces.
|
void |
setSpecular(java.awt.Color specular)
Sets the specular color for front and back faces.
|
void |
setSpecularBack(java.awt.Color specular)
Sets the specular color for back faces.
|
void |
setSpecularFront(java.awt.Color specular)
Sets the specular color for front faces.
|
void |
unsetAmbient()
Unsets the ambient color for front and back faces.
|
void |
unsetAmbientBack()
Unsets the ambient color for back faces.
|
void |
unsetAmbientFront()
Unsets the ambient color for front faces.
|
void |
unsetColorMaterial()
Unsets the color material mode for front and back faces.
|
void |
unsetColorMaterialBack()
Unsets the color material mode for back faces.
|
void |
unsetColorMaterialFront()
Unsets the color material mode for front faces.
|
void |
unsetDiffuse()
Unsets the diffuse color for front and back faces.
|
void |
unsetDiffuseBack()
Unsets the diffuse color for back faces.
|
void |
unsetDiffuseFront()
Unsets the diffuse color for front faces.
|
void |
unsetEmissive()
Unsets the emissive color for front and back faces.
|
void |
unsetEmissiveBack()
Unsets the emissive color for back faces.
|
void |
unsetEmissiveFront()
Unsets the emissive color for front faces.
|
void |
unsetShininess()
Unsets the shininess for front and back faces.
|
void |
unsetShininessBack()
Unsets the shininess for back faces.
|
void |
unsetShininessFront()
Unsets the shininess for front faces.
|
void |
unsetSpecular()
Unsets the specular color for front and back faces.
|
void |
unsetSpecularBack()
Unsets the specular color for back faces.
|
void |
unsetSpecularFront()
Unsets the specular color for front faces.
|
public boolean hasAmbientFront()
public boolean hasAmbientBack()
public java.awt.Color getAmbientFront()
public java.awt.Color getAmbientBack()
public void setAmbient(java.awt.Color ambient)
ambient
- the ambient color.public void setAmbientFront(java.awt.Color ambient)
ambient
- the ambient color.public void setAmbientBack(java.awt.Color ambient)
ambient
- the ambient color.public void unsetAmbient()
public void unsetAmbientFront()
public void unsetAmbientBack()
public boolean hasDiffuseFront()
public boolean hasDiffuseBack()
public java.awt.Color getDiffuseFront()
public java.awt.Color getDiffuseBack()
public void setDiffuse(java.awt.Color diffuse)
diffuse
- the diffuse color.public void setDiffuseFront(java.awt.Color diffuse)
diffuse
- the diffuse color.public void setDiffuseBack(java.awt.Color diffuse)
diffuse
- the diffuse color.public void unsetDiffuse()
public void unsetDiffuseFront()
public void unsetDiffuseBack()
public boolean hasSpecularFront()
public boolean hasSpecularBack()
public java.awt.Color getSpecularFront()
public java.awt.Color getSpecularBack()
public void setSpecular(java.awt.Color specular)
specular
- the specular color.public void setSpecularFront(java.awt.Color specular)
specular
- the specular color.public void setSpecularBack(java.awt.Color specular)
specular
- the specular color.public void unsetSpecular()
public void unsetSpecularFront()
public void unsetSpecularBack()
public boolean hasEmissiveFront()
public boolean hasEmissiveBack()
public java.awt.Color getEmissiveFront()
public java.awt.Color getEmissiveBack()
public void setEmissive(java.awt.Color emissive)
emissive
- the emissive color.public void setEmissiveFront(java.awt.Color emissive)
emissive
- the emissive color.public void setEmissiveBack(java.awt.Color emissive)
emissive
- the emissive color.public void unsetEmissive()
public void unsetEmissiveFront()
public void unsetEmissiveBack()
public boolean hasShininessFront()
public boolean hasShininessBack()
public float getShininessFront()
public float getShininessBack()
public void setShininess(float shininess)
shininess
- the shininess.public void setShininessFront(float shininess)
shininess
- the shininess.public void setShininessBack(float shininess)
shininess
- the shininess.public void unsetShininess()
public void unsetShininessFront()
public void unsetShininessBack()
public boolean hasColorMaterialFront()
public boolean hasColorMaterialBack()
public int getColorMaterialFront()
public int getColorMaterialBack()
public void setColorMaterial(int mode)
mode
- the color material mode.public void setColorMaterialFront(int mode)
mode
- the color material mode.public void setColorMaterialBack(int mode)
mode
- the color material mode.public void unsetColorMaterial()
public void unsetColorMaterialFront()
public void unsetColorMaterialBack()
public void apply()
State
public int getAttributeBits()
State
State.apply()
. If these bits are passed to glPushAttrib before
calling State.apply()
, then glPopAttrib will restore any OpenGL
state that is changed by that method.getAttributeBits
in interface State