|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.vodafone.v10.graphics.j3d.Effect3D
Graphical effects information class.
This class stores information on light source, shading type, and whether
semi-transparency is enabled.
Field Summary | |
static int |
NORMAL_SHADING
Normal shading |
static int |
TOON_SHADING
Toon shading |
Constructor Summary | |
Effect3D()
FigureLayout constructor No light used, NORMAL_SHADING, semi-transparency feature enabled. |
|
Effect3D(Light light,
int shading,
boolean isEnabled,
Texture sphereMap)
FigureLayout constructor Set to null if sphere mapping is not used. |
Method Summary | |
Light |
getLight()
Gets the light source. |
int |
getShading()
Gets the shading type. |
Texture |
getSphereMap()
Gets the sphere mapping. |
int |
getThreshold()
Gets the current threshold for toon shading. |
int |
getThresholdHigh()
Gets the current "RGB setting when level is above threshold" for toon shading. |
int |
getThresholdLow()
Gets the current "RGB setting when level is below threshold" for toon shading. |
boolean |
isSemiTransparentEnabled()
Gets the semi-transparency feature status. |
void |
setLight(Light light)
Sets the light source. |
void |
setSemiTransparentEnabled(boolean isEnabled)
Sets the semi-transparency feature to enabled or disabled. |
void |
setShading(int shading)
Sets the shading type. |
void |
setSphereMap(Texture sphereMap)
Sets sphere mapping. If not used, null is set. |
void |
setThreshold(int threshold,
int high,
int low)
Sets the toon shading threshold level. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final int NORMAL_SHADING
public static final int TOON_SHADING
Constructor Detail |
public Effect3D()
public Effect3D(Light light, int shading, boolean isEnabled, Texture sphereMap)
light
- Light source (null if light not used)shading
- Shading typeenableSemiTransparent
- true: Semi-transparency feature enabledsphereMap
- New sphere mappingIllegalArgumentException
- if shading type is illegal.IllegalArgumentException
- if sphereMap is not a sphere mapping texture.Method Detail |
public Light getLight()
public void setLight(Light light)
light
- Light (null if none used)public int getShading()
public void setShading(int shading)
shading
- The shading typeIllegalArgumentException
- if the shading type is illegalpublic int getThreshold()
public int getThresholdHigh()
public int getThresholdLow()
public void setThreshold(int threshold, int high, int low)
threshold
- Threshold level (0 to 255)high
- RGB setting when level is above threshold (0 to 255; 100% at 255)low
- RGB setting when level is below threshold (0 to 255; 100% at 255)IllegalArgumentException
- if a value outside range is set.public boolean isSemiTransparentEnabled()
public void setSemiTransparentEnabled(boolean isEnabled)
isEnabled
- true: Semi-transparency feature enabledpublic Texture getSphereMap()
public void setSphereMap(Texture sphereMap)
sphereMap
- New sphere mappingIllegalArgumentException
- if sphereMap is not a sphere mapping texture.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |