Class RangeCompressor
java.lang.Object
org.web3d.vrml.export.compressors.BinaryFieldEncoder
org.web3d.vrml.export.compressors.RangeCompressor
- All Implemented Interfaces:
FieldCompressor
,FieldDecompressor
A FieldCompressor that works by compressing the range of data. Floats are
converted to ints before range compression.
- Version:
- $Revision: 1.4 $
- Author:
- Alan Hudson
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
compress
(DataOutputStream dos, int fieldType, float[] data) Compress this field and deposit the output to the bitstreamvoid
compress
(DataOutputStream dos, int fieldType, int[] data) Compress this field and deposit the output to the bitstreamMethods inherited from class org.web3d.vrml.export.compressors.BinaryFieldEncoder
canSupport, compress, compress, compress, compress, compress, compress, compress, compress, compress, compress, compress, compress, decompressBoolean, decompressBoolean, decompressDouble, decompressDouble, decompressDouble, decompressFloat, decompressFloat, decompressFloat, decompressInt, decompressInt, decompressLong, decompressLong, decompressString, decompressString, nextLength
-
Constructor Details
-
RangeCompressor
public RangeCompressor()
-
-
Method Details
-
compress
Compress this field and deposit the output to the bitstream- Specified by:
compress
in interfaceFieldCompressor
- Overrides:
compress
in classBinaryFieldEncoder
- Parameters:
dos
- The stream to output the resultfieldType
- The type of field to compress from FieldConstants.data
- The field data- Throws:
IOException
-
compress
Compress this field and deposit the output to the bitstream- Specified by:
compress
in interfaceFieldCompressor
- Overrides:
compress
in classBinaryFieldEncoder
- Parameters:
dos
- The stream to output the resultfieldType
- The type of field to compress from FieldConstants.data
- The field data- Throws:
IOException
-