class GeneralizedVertexList extends java.lang.Object implements GeneralizedStripFlags
GeneralizedStrip,
GeometryDecompressor| Modifier and Type | Class and Description |
|---|---|
(package private) class |
GeneralizedVertexList.Vertex
A class with fields corresponding to all the data that can be bundled
with the vertices of generalized strips.
|
| Modifier and Type | Field and Description |
|---|---|
private int |
frontFace |
private boolean |
hasColor3 |
private boolean |
hasColor4 |
private boolean |
hasNormals |
(package private) int |
stripCount
Count of number of strips generated after conversion to GeometryArray.
|
(package private) int |
triangleCount
Count of number of triangles generated after conversion to GeometryArray.
|
(package private) int |
vertexCount
Count of number of vertices generated after conversion to GeometryArray.
|
(package private) int |
vertexFormat
Bits describing the data bundled with each vertex.
|
private java.util.ArrayList |
vertices |
FRONTFACE_CCW, FRONTFACE_CW, REPLACE_MIDDLE, REPLACE_OLDEST, RESTART_CCW, RESTART_CW| Constructor and Description |
|---|
GeneralizedVertexList(int vertexFormat,
int frontFace)
Creates a new GeneralizedVertexList for the specified vertex format.
|
GeneralizedVertexList(int vertexFormat,
int frontFace,
int initSize)
Creates a new GeneralizedVertexList for the specified vertex format.
|
| Modifier and Type | Method and Description |
|---|---|
(package private) void |
addVertex(Point3f pos,
Vector3f norm,
Color4f color,
int flag)
Copy vertex data to a new Vertex object and add it to this list.
|
private void |
copyVertexData(GeometryArray ga,
GeneralizedStrip.IntList indices) |
int |
getFlag(int index)
Return the flag associated with the vertex at the specified index.
|
int |
getFlagCount()
Return the number of flags.
|
(package private) void |
setVertexFormat(int vertexFormat)
Sets the vertex format for this vertex list.
|
(package private) int |
size()
Return the number of vertices in this list.
|
(package private) LineStripArray |
toLineStripArray()
Output a LineStripArray.
|
(package private) PointArray |
toPointArray()
Output a PointArray.
|
(package private) GeometryStripArray[] |
toStripAndFanArrays()
Output triangle strip and triangle fan arrays.
|
(package private) GeometryArray[] |
toStripAndTriangleArrays()
Output triangle strip and and triangle arrays.
|
(package private) TriangleArray |
toTriangleArray()
Output a TriangleArray.
|
(package private) TriangleStripArray |
toTriangleStripArray()
Output a TriangleStripArray.
|
private java.util.ArrayList vertices
private boolean hasColor3
private boolean hasColor4
private boolean hasNormals
private int frontFace
int stripCount
int vertexCount
int triangleCount
int vertexFormat
GeneralizedVertexList(int vertexFormat,
int frontFace,
int initSize)
vertexFormat - a mask indicating which components are
present in each vertex, as used by GeometryArray.frontFace - a flag, either GeneralizedStripFlags.FRONTFACE_CW or
GeneralizedStripFlags.FRONTFACE_CCW, indicating front face windinginitSize - initial number of elementsGeometryArrayGeneralizedVertexList(int vertexFormat,
int frontFace)
vertexFormat - a mask indicating which components are
present in each vertex, as used by GeometryArray.frontFace - a flag, either GeneralizedStripFlags.FRONTFACE_CW or
GeneralizedStripFlags.FRONTFACE_CCW, indicating front face windingGeometryArrayvoid setVertexFormat(int vertexFormat)
vertexFormat - a mask indicating which components are
present in each vertex, as used by GeometryArray.void addVertex(Point3f pos, Vector3f norm, Color4f color, int flag)
int size()
public int getFlagCount()
GeneralizedStripFlagsgetFlagCount in interface GeneralizedStripFlagspublic int getFlag(int index)
GeneralizedStripFlagsgetFlag in interface GeneralizedStripFlagsprivate void copyVertexData(GeometryArray ga, GeneralizedStrip.IntList indices)
PointArray toPointArray()
TriangleArray toTriangleArray()
LineStripArray toLineStripArray()
TriangleStripArray toTriangleStripArray()
GeometryStripArray[] toStripAndFanArrays()
GeometryArray[] toStripAndTriangleArrays()
Copyright 1996-2008 Sun Microsystems, Inc. All Rights Reserved. Use is subject to license terms.