|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object | +--mediaframe.mpeg1.Huffmann
The Huffmann class represents VLC (Hufmann) decoder.
It's data base are some arrays which logically constitute a binary tree.
| Field Summary | |
static int[] |
dct_coeff_len_tab1
The huffman tree (length part) for the DCT coefficients (huffman index 1...1024). |
static int[] |
dct_coeff_len_tab2
The huffman tree (length part) for the DCT coefficients (huffman index 1024..65535). |
static int[] |
dct_coeff_val_tab1
The huffman tree (value part) for the DCT coefficients (huffman index 1...1024). |
static int[] |
dct_coeff_val_tab2
The huffman tree (length part) for the DCT coefficients (huffman index 1024..65535). |
static int |
DCT_ESCAPE
DCT_ESCAPE constanta (byte value) in a bit stream. |
static int |
EOB
End of block constanta (byte value) in a bit stream. |
private io_tool |
mpeg_stream
The input movie's data bit stream. |
static Tables |
tables
The Huffman tables for decoding a bit stream. |
| Constructor Summary | |
(package private) |
Huffmann(io_tool stream)
Constructs a VLC (Hufmann) decoder and loads Huffman tables. |
| Method Summary | |
int[] |
decode(int max_length,
int[][] tab)
The method "decode" is the VLC (Hufmann) decoder. |
int |
decodeCoeff()
Decodes one AC coefficient from a bit stream. |
static Tables |
loadTables()
Loads a Huffman tables from a resource file. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
private io_tool mpeg_stream
public static final Tables tables
public static final int DCT_ESCAPE
public static final int EOB
public static int[] dct_coeff_val_tab1
public static int[] dct_coeff_val_tab2
public static int[] dct_coeff_len_tab1
public static int[] dct_coeff_len_tab2
| Constructor Detail |
Huffmann(io_tool stream)
stream - the input movie's data bit stream.| Method Detail |
public final int[] decode(int max_length,
int[][] tab)
throws java.lang.InterruptedException,
java.io.EOFException
max_length - maximum amount of bits that could be readed from a stream to decode values.tab - the huffman table for decoding bit stream.
java.lang.InterruptedException - raises if another process interrupts the current process.
EOFException - raises if the end of the file has been reached.
public final int decodeCoeff()
throws java.lang.InterruptedException,
java.io.EOFException
java.lang.InterruptedException - raises if another process interrupts the current process.
EOFException - raises if the end of the file has been reached.public static Tables loadTables()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||