|
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.PolygonAttributes
Describes attributes used when rendering a polygon.
Field Summary | |
static int |
CULL_BACK
The cull mode says to draw back faces only |
static int |
CULL_BOTH
The cull mode says to not draw any faces |
static int |
CULL_FRONT
The cull mode says to draw front faces only |
static int |
CULL_NONE
The cull mode says to draw both front and back faces |
static int |
DRAW_FILLED
Draw the face filled as a solid object |
static int |
DRAW_LINE
Draw the face as outline lines only |
static int |
DRAW_POINT
Draw the face as the points of the vertices only |
Fields inherited from class org.j3d.aviatrix3d.NodeComponent |
liveCount |
Fields inherited from class org.j3d.aviatrix3d.SceneGraphObject |
alive, updateHandler, WRITE_TIMING_MSG |
Constructor Summary | |
PolygonAttributes()
Constructs a attribute set with default values. |
Method Summary | |
int |
getCulledFace()
Get the current face culled flag. |
int |
getDrawMode(boolean front)
Get the draw mode for the specified face. |
void |
getPolygonOffset(float[] values)
Get the current polygon offset details. |
boolean |
isCCW()
Check the state of the CCW flag setting for this geometry. |
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 to the given drawable. |
void |
setCCW(boolean state)
Set the CCW flag. |
void |
setCulledFace(int face)
Set which face is to be culled. |
void |
setDrawMode(boolean front,
int mode)
Set the draw mode for either the front or back face. |
void |
setPolygonOffset(float factor,
float units)
Set the polygon offset details. |
void |
setStipplePattern(byte[] pattern)
Set the stipple mask to be used on the polygon. |
Methods inherited from class org.j3d.aviatrix3d.NodeComponent |
addParent, getParents, hasChanged, numParents, removeParent |
Methods inherited from class org.j3d.aviatrix3d.SceneGraphObject |
checkForCyclicChild, checkForCyclicParent, dataChanged, getUserData, isLive, setLive, setUpdateHandler, setUserData |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final int CULL_NONE
public static final int CULL_FRONT
public static final int CULL_BACK
public static final int CULL_BOTH
public static final int DRAW_POINT
public static final int DRAW_LINE
public static final int DRAW_FILLED
Constructor Detail |
public PolygonAttributes()
Method Detail |
public 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 withpublic void setCCW(boolean state) throws InvalidWriteTimingException
state
- True to use CCW triangles, false for CW
InvalidWriteTimingException
- An attempt was made to write outside
of the NodeUpdateListener callback methodpublic boolean isCCW()
public void setCulledFace(int face) throws InvalidWriteTimingException
face
- The face that should be culled
InvalidWriteTimingException
- An attempt was made to write outside
of the NodeUpdateListener callback methodpublic int getCulledFace()
public void setDrawMode(boolean front, int mode) throws java.lang.IllegalArgumentException, InvalidWriteTimingException
front
- true if this is the front-face settingmode
- The mode to use for this face
java.lang.IllegalArgumentException
- Invalid mode supplied
InvalidWriteTimingException
- An attempt was made to write outside
of the NodeUpdateListener callback methodpublic int getDrawMode(boolean front)
front
- true if requesting the front-face settingpublic void setPolygonOffset(float factor, float units) throws InvalidWriteTimingException
factor
- The offset factor mulitplierunits
- The offset unit multiplier
InvalidWriteTimingException
- An attempt was made to write outside
of the NodeUpdateListener callback methodpublic void getPolygonOffset(float[] values)
values
- The array to copy the current values intopublic void setStipplePattern(byte[] pattern) throws InvalidWriteTimingException
pattern
- The bytes of the pattern or null
InvalidWriteTimingException
- An attempt was made to write outside
of the NodeUpdateListener callback method
|
j3d.org Aviatrix3D | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |