|
Xj3D 2.0 VRML/X3D Code API | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface OGLGlobalEffectsHandler
A generic interface for the control of global effects like background fog and view management for the OpenGL renderer.
The input system takes care of the basic per-frame management, but needs to tell the collection of objects that represent the global structure about the new position or control settings. The architecture assumes that the actual matrices responsible for the view handling and backgrounds are managed separately from the VRML scene graph. This is to avoid issues with nodes appearing under SharedGroups etc.
| Field Summary | |
|---|---|
static int |
FOG_DISABLE
Constant used to set the fog state to disabled. |
static int |
FOG_EXPONENTIAL
Constant used to set the fog state to exponential. |
static int |
FOG_LINEAR
Constant used to set the fog state to linear. |
| Method Summary | |
|---|---|
void |
enableFog(int state)
Update the fog type in use. |
void |
setBackgroundMatrix(javax.vecmath.Matrix4f transform)
Set the background rotation matrix this new matrix. |
void |
setFogDetails(float visLimit,
float r,
float g,
float b)
Update the fog with different setups. |
void |
setFogMatrix(javax.vecmath.Matrix4f transform)
Set the fog coordinate matrix this new matrix. |
void |
setLayerId(int id)
Set or reset the layer ID to the new ID value. |
void |
setViewMatrix(javax.vecmath.Matrix4f transform)
Update the view matrix to be this new matrix. |
void |
updateBackgroundGround(float[] color,
float[] angles,
int num)
Update the background ground color sphere to the new values. |
void |
updateBackgroundSky(float[] color,
float[] angles,
int num)
Update the background sky color sphere to the new values. |
void |
updateBackgroundTextures(org.j3d.aviatrix3d.Texture2D[] textures,
boolean[] flags)
Update the background textures to this new set. |
void |
updateBackgroundTransparency(float transparency)
Update the background transparency to this new value. |
| Field Detail |
|---|
static final int FOG_DISABLE
static final int FOG_LINEAR
static final int FOG_EXPONENTIAL
| Method Detail |
|---|
void setLayerId(int id)
id - A non-negative ID for the layervoid setViewMatrix(javax.vecmath.Matrix4f transform)
transform - The new view matrix settingsvoid setBackgroundMatrix(javax.vecmath.Matrix4f transform)
transform - The new background matrix settingsvoid setFogMatrix(javax.vecmath.Matrix4f transform)
transform - The new fog matrix settingsvoid updateBackgroundTransparency(float transparency)
transparency - A value between 0 and 1
void updateBackgroundTextures(org.j3d.aviatrix3d.Texture2D[] textures,
boolean[] flags)
textures - The list of textures to useflags - The list of flags indicating a texture change
void updateBackgroundGround(float[] color,
float[] angles,
int num)
color - The color values to use as a flat arrayangles - The angles to use at each colour boundarynum - The number of color values to read from the arrays
void updateBackgroundSky(float[] color,
float[] angles,
int num)
color - The color values to use as a flat arrayangles - The angles to use at each colour boundarynum - The number of color values to read from the arraysvoid enableFog(int state)
state - The fog to use right now
void setFogDetails(float visLimit,
float r,
float g,
float b)
visLimit - The visibility limit. Zero to disable itr - The red component of the fog colorg - The green component of the fog colorb - The blue component of the fog color
|
Xj3D 2.0 VRML/X3D Code API | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||