public class ObjectFileCompressor extends ObjectFile
RESIZE, REVERSE, STRIPIFY, TRIANGULATELOAD_ALL, LOAD_BACKGROUND_NODES, LOAD_BEHAVIOR_NODES, LOAD_FOG_NODES, LOAD_LIGHT_NODES, LOAD_SOUND_NODES, LOAD_VIEW_GROUPS| Constructor and Description |
|---|
ObjectFileCompressor() |
ObjectFileCompressor(int flags) |
ObjectFileCompressor(int flags,
float radians) |
| Modifier and Type | Method and Description |
|---|---|
CompressedGeometryData |
compress(java.io.Reader reader)
Compress the specified .obj file into a CompressedGeometryData node
component.
|
void |
compress(java.io.Reader reader,
CompressedGeometryFile file)
Compress the specified .obj file and add it to the end of an open
compressed geometry file.
|
CompressedGeometryData |
compress(java.lang.String objFileName)
Compress the specified .obj file into a CompressedGeometryData node
component.
|
void |
compress(java.lang.String objFileName,
CompressedGeometryFile file)
Compress the specified .obj file and add it to the end of an open
compressed geometry file.
|
CompressedGeometryData |
compress(java.net.URL url)
Compress the specified .obj file into a CompressedGeometryData node
component.
|
void |
compress(java.net.URL url,
CompressedGeometryFile file)
Compress the specified .obj file and add it to the end of an open
compressed geometry file.
|
void |
setFlags(int flags)
Set parameters for loading the model.
|
void |
setQuantization(int positionQuant,
int colorQuant,
int normalQuant)
Set the position, normal, and color quantization values for compression.
|
createAppearance, getBasePath, getBaseUrl, getFlags, load, load, load, setBasePath, setBaseUrlpublic ObjectFileCompressor()
public ObjectFileCompressor(int flags)
public ObjectFileCompressor(int flags,
float radians)
public void setFlags(int flags)
ObjectFilesetFlags in interface LoadersetFlags in class ObjectFilepublic void setQuantization(int positionQuant,
int colorQuant,
int normalQuant)
positionQuant - number of bits to quantize each position's X, Y,
and Z components, ranging from 1 to 16 with a default of 10colorQuant - number of bits to quantize each color's R, G, B, and
alpha components, ranging from 2 to 16 with a default of 8normalQuant - number of bits for quantizing each normal's U and V
components, ranging from 0 to 6 with a default of 3public CompressedGeometryData compress(java.lang.String objFileName)
objFileName - String object representing the path to a .obj filepublic void compress(java.lang.String objFileName,
CompressedGeometryFile file)
throws java.io.IOException
objFileName - String object representing the path to a .obj filefile - a currently open CompressedGeometryFile objectjava.io.IOException - - if write failspublic CompressedGeometryData compress(java.io.Reader reader)
reader - an open .obj filepublic void compress(java.io.Reader reader,
CompressedGeometryFile file)
throws java.io.IOException
reader - an open .obj filefile - an open CompressedGeometryFile objectjava.io.IOException - - if write failspublic CompressedGeometryData compress(java.net.URL url)
url - Uniform Resource Locator for the .obj filepublic void compress(java.net.URL url,
CompressedGeometryFile file)
throws java.io.IOException
url - Uniform Resource Locator for the .obj filefile - a currently open CompressedGeometryFile objectjava.io.IOException - - if write fails