|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjavax.media.j3d.GeometryDecompressor
javax.media.j3d.GeometryDecompressorRetained
class GeometryDecompressorRetained
This class implements a retained geometry backend for the abstract GeometryDecompressor.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class javax.media.j3d.GeometryDecompressor |
---|
GeometryDecompressor.HuffmanTableEntry, GeometryDecompressor.MeshBufferEntry |
Field Summary | |
---|---|
private static boolean |
benchmark
|
private boolean |
boundsOnly
|
private int |
bufferDataType
|
private static float |
bytesPerVertexFudge
|
private Color4f |
curColor
|
private Vector3f |
curNormal
|
private int |
dataPresent
|
private static boolean |
debug
|
private long |
endTime
|
private static int |
FRONTFACE_CCW
|
private Point3d |
lbounds
|
private boolean |
positionsOnly
|
private static boolean |
printInfo
|
private int |
size
|
private long |
startTime
|
private static boolean |
statistics
|
private static int |
TYPE_LINE
|
private static int |
TYPE_POINT
|
private static int |
TYPE_TRIANGLE
|
private Point3d |
ubounds
|
private GeneralizedVertexList |
vlist
|
Fields inherited from class javax.media.j3d.GeometryDecompressor |
---|
majorVersionNumber, minorMinorVersionNumber, minorVersionNumber |
Constructor Summary | |
---|---|
GeometryDecompressorRetained()
|
Method Summary | |
---|---|
private void |
beginPrint()
|
(package private) GeometryRetained |
decompress(CompressedGeometryRetained cgr)
Decompress the geometry data in a CompressedGeometryRetained. |
private void |
endPrint()
|
(package private) void |
getBoundingBox(BoundingBox bb)
Get the bounds of the decompressed geometry. |
(package private) void |
outputColor(Color4f color)
Any global colors output by the decompressor are stored as per-vertex color in the retained data used internally by the renderer. |
(package private) void |
outputNormal(Vector3f normal)
Set the current normal that will be copied to each succeeding vertex output by the decompressor. |
(package private) void |
outputVertex(Point3f position,
Vector3f normal,
Color4f color,
int vertexReplaceCode)
Process a decompressed vertex. |
(package private) void |
outputVertexFormat(boolean bundlingNorm,
boolean bundlingColor,
boolean doingAlpha)
Initialize the vertex output list based on the vertex format provided by the SetState decompression command. |
private void |
printBench()
|
private void |
printStats()
|
(package private) void |
setDecompressBoundsOnly(boolean boundsOnly)
If the given argument is true, sets the decompressor to output only the bounding box of the decompressed geometry. |
(package private) void |
setDecompressPositionsOnly(boolean positionsOnly)
If the given argument is true, sets the decompressor to output only the decompressed positions, their connections, and the bounding box. |
Methods inherited from class javax.media.j3d.GeometryDecompressor |
---|
checkVersion, decompress |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private static final boolean debug
private static final boolean benchmark
private static final boolean statistics
private static final boolean printInfo
private int bufferDataType
private int dataPresent
private int size
private Color4f curColor
private Vector3f curNormal
private GeneralizedVertexList vlist
private Point3d lbounds
private Point3d ubounds
private boolean boundsOnly
private boolean positionsOnly
private static final float bytesPerVertexFudge
private long startTime
private long endTime
private static final int TYPE_POINT
private static final int TYPE_LINE
private static final int TYPE_TRIANGLE
private static final int FRONTFACE_CCW
Constructor Detail |
---|
GeometryDecompressorRetained()
Method Detail |
---|
void setDecompressBoundsOnly(boolean boundsOnly)
boundsOnly
- set to true if the decompressor should output only the
geometric bounding box.void setDecompressPositionsOnly(boolean positionsOnly)
positionsOnly
- set to true if the decompressor should output only
position, connection, and bounding box data.GeometryRetained decompress(CompressedGeometryRetained cgr)
cgr
- CompressedGeometryRetained containing compressed geometry
void getBoundingBox(BoundingBox bb)
bb
- BoundingBox to receive boundsvoid outputVertexFormat(boolean bundlingNorm, boolean bundlingColor, boolean doingAlpha)
outputVertexFormat
in class GeometryDecompressor
bundlingNorm
- true indicates normals are bundled with verticesbundlingColor
- true indicates colors are bundled with verticesdoingAlpha
- true indicates alpha values are bundled with verticesvoid outputVertex(Point3f position, Vector3f normal, Color4f color, int vertexReplaceCode)
outputVertex
in class GeometryDecompressor
position
- The coordinates of the vertex.normal
- The normal bundled with the vertex. May be null.color
- The color bundled with the vertex. May be null.
Alpha may be present.vertexReplaceCode
- Specifies the generalized strip flag
that is bundled with each vertex.GeneralizedStripFlags
,
CompressedGeometryHeader
void outputColor(Color4f color)
outputColor
in class GeometryDecompressor
color
- The current global color.void outputNormal(Vector3f normal)
outputNormal
in class GeometryDecompressor
normal
- The current global normal.private void beginPrint()
private void endPrint()
private void printBench()
private void printStats()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |