|
j3d.org Aviatrix3D | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.j3d.aviatrix3d.SceneGraphObject
org.j3d.aviatrix3d.NodeComponent
org.j3d.aviatrix3d.Appearance
Describes the appearance of an object.
Field Summary |
Fields inherited from class org.j3d.aviatrix3d.NodeComponent |
liveCount |
Fields inherited from class org.j3d.aviatrix3d.SceneGraphObject |
alive, updateHandler, WRITE_TIMING_MSG |
Constructor Summary | |
Appearance()
The default constructor. |
Method Summary | |
protected void |
checkForCyclicChild(SceneGraphObject parent)
Check to see if this node is the same reference as the passed node that is a parent of this node. |
Material |
getMaterial()
Get the current material in use. |
PolygonAttributes |
getPolygonAttributes()
Get the current polygon rendering attributes in use. |
Shader |
getShader()
Get the current shader in use. |
void |
getTextureUnits(TextureUnit[] texUnits)
Get the texture units used by the material. |
boolean |
isVisible()
Check to see if this appearance is making the geometry visible or not. |
int |
numTextureUnits()
Get the current number of texture units that are valid |
void |
renderState(net.java.games.jogl.GL gl,
net.java.games.jogl.GLU glu)
Issue ogl commands needed for this component. |
void |
restoreState(net.java.games.jogl.GL gl,
net.java.games.jogl.GLU glu)
Restore all openGL state. |
protected void |
setLive(boolean state)
Notification that this object is live now. |
void |
setMaterial(Material mat)
Set the material to use. |
void |
setPolygonAttributes(PolygonAttributes attr)
Set the polygon rendering attributes to use. |
void |
setShader(Shader s)
Set the shader to use. |
void |
setTextureUnits(TextureUnit[] texUnits,
int num)
Set the texture units to use. |
protected void |
setUpdateHandler(NodeUpdateHandler handler)
Set the scenegraph update handler for this node. |
void |
setVisible(boolean state)
Set the visibility state of any geometry associated with this instance. |
Methods inherited from class org.j3d.aviatrix3d.NodeComponent |
addParent, getParents, hasChanged, numParents, removeParent |
Methods inherited from class org.j3d.aviatrix3d.SceneGraphObject |
checkForCyclicParent, dataChanged, getUserData, isLive, setUserData |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public Appearance()
Method Detail |
public void setVisible(boolean state)
state
- true to make the object visiblepublic boolean isVisible()
public void setMaterial(Material mat) throws InvalidWriteTimingException
mat
- The new material
InvalidWriteTimingException
- An attempt was made to write outside
of the NodeUpdateListener callback methodpublic Material getMaterial()
public void setPolygonAttributes(PolygonAttributes attr) throws InvalidWriteTimingException
attr
- The new attributes or null
InvalidWriteTimingException
- An attempt was made to write outside
of the NodeUpdateListener callback methodpublic PolygonAttributes getPolygonAttributes()
public void setShader(Shader s) throws InvalidWriteTimingException
s
- The new shader instance to use or null
InvalidWriteTimingException
- An attempt was made to write outside
of the NodeUpdateListener callback methodpublic Shader getShader()
public void setTextureUnits(TextureUnit[] texUnits, int num) throws InvalidWriteTimingException
texUnits
- The new Texture lists to setnum
- The number of valid entries in the array
InvalidWriteTimingException
- An attempt was made to write outside
of the NodeUpdateListener callback methodpublic int numTextureUnits()
public void getTextureUnits(TextureUnit[] texUnits)
protected void setUpdateHandler(NodeUpdateHandler handler)
setUpdateHandler
in class SceneGraphObject
handler
- The instance to use as a handlerpublic void renderState(net.java.games.jogl.GL gl, net.java.games.jogl.GLU glu)
renderState
in class NodeComponent
gl
- The gl context to draw withglu
- The utility context to draw withpublic void restoreState(net.java.games.jogl.GL gl, net.java.games.jogl.GLU glu)
restoreState
in class NodeComponent
gl
- The gl context to draw withglu
- The utility context to draw withprotected void setLive(boolean state)
setLive
in class SceneGraphObject
state
- true if this should be marked as live nowprotected void checkForCyclicChild(SceneGraphObject parent) throws CyclicSceneGraphStructureException
checkForCyclicChild
in class SceneGraphObject
parent
- The reference to check against this class
CyclicSceneGraphStructureException
- Equal parent and child
|
j3d.org Aviatrix3D | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |