|
Xj3D VRML/X3D Code API | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.web3d.vrml.export.compressors.BitPacker
Pack a stream of integers of variables bits into a packed form. Loosely copied from Johnathon Blow's "Packing Integers" article.
| Constructor Summary | |
BitPacker(int maxLength)
Construct a bit packer. |
|
| Method Summary | |
void |
getResult(byte[] result)
Get the result of the packing. |
void |
pack(int value,
int num_bits)
Pack this value using num_bits. |
int |
size()
Get the size of the result. |
void |
writeStream(java.io.DataOutputStream dos)
Write this stream out to a stream. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public BitPacker(int maxLength)
maxLength - The maximum length in bytes of the stream to pack.| Method Detail |
public int size()
public void getResult(byte[] result)
public void pack(int value,
int num_bits)
public void writeStream(java.io.DataOutputStream dos)
throws java.io.IOException
java.io.IOException
|
Xj3D VRML/X3D Code API | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||