public static class BinaryArithmeticStream.In extends BinaryArithmeticStream
BinaryArithmeticStream.Huffman, BinaryArithmeticStream.In, BinaryArithmeticStream.Outhigh, low, MAX_PROBABILITY| Constructor and Description |
|---|
In(java.io.InputStream in) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
readBit(int probability)
Read a bit.
|
int |
readGolomb(int divisor)
Read a value that is stored as a Golomb code.
|
public In(java.io.InputStream in) throws java.io.IOException
java.io.IOExceptionpublic boolean readBit(int probability)
throws java.io.IOException
probability - the probability that the value is truejava.io.IOExceptionpublic int readGolomb(int divisor)
throws java.io.IOException
divisor - the divisorjava.io.IOException