Logo Search packages:      
Sourcecode: jampal version File versions  Download package

Public Member Functions | Static Public Attributes | Protected Member Functions | Package Functions | Static Package Attributes | Private Member Functions | Private Attributes | Static Private Attributes

javazoom::jl::decoder::Bitstream Class Reference

Inheritance diagram for javazoom::jl::decoder::Bitstream:
Inheritance graph
Collaboration diagram for javazoom::jl::decoder::Bitstream:
Collaboration graph

List of all members.

Public Member Functions

 Bitstream (InputStream in)
void close () throws BitstreamException
void closeFrame ()
int get_bits (int number_of_bits)
InputStream getRawID3v2 ()
int header_pos ()
boolean isSyncCurrentPosition (int syncmode) throws BitstreamException
boolean isSyncMark (int headerstring, int syncmode, int word)
int readBits (int n)
int readCheckedBits (int n)
Header readFrame () throws BitstreamException
void unreadFrame () throws BitstreamException

Static Public Attributes

static final int BITSTREAM_ERROR = 0x100
static final int BITSTREAM_LAST = 0x1ff
static final int DECODER_ERROR = 0x200
static final int STREAM_EOF = BITSTREAM_ERROR + 4
static final int STREAM_ERROR = BITSTREAM_ERROR + 2
static final int UNKNOWN_ERROR = BITSTREAM_ERROR + 0

Protected Member Functions

BitstreamException newBitstreamException (int errorcode)
BitstreamException newBitstreamException (int errorcode, Throwable throwable)

Package Functions

void parse_frame () throws BitstreamException
void read_frame_data (int bytesize) throws BitstreamException
void set_syncword (int syncword0)
int syncHeader (byte syncmode) throws BitstreamException

Static Package Attributes

static byte INITIAL_SYNC = 0
static byte STRICT_SYNC = 1

Private Member Functions

void loadID3v2 (InputStream in)
void nextFrame () throws BitstreamException
int readBytes (byte[] b, int offs, int len) throws BitstreamException
void readFully (byte[] b, int offs, int len) throws BitstreamException
int readID3v2Header (InputStream in) throws IOException
Header readNextFrame () throws BitstreamException

Private Attributes

int bitindex
final int bitmask []
Crc16[] crc = new Crc16[1]
boolean firstframe = true
byte[] frame_bytes = new byte[BUFFER_INT_SIZE*4]
final int[] framebuffer = new int[BUFFER_INT_SIZE]
int framesize
final Header header = new Header()
int header_pos = 0
byte[] rawid3v2 = null
boolean single_ch_mode
final PushbackInputStream source
final byte syncbuf [] = new byte[4]
int syncword
int wordpointer

Static Private Attributes

static final int BUFFER_INT_SIZE = 433

Detailed Description

The Bistream class is responsible for parsing an MPEG audio bitstream.

REVIEW: much of the parsing currently occurs in the various decoders. This should be moved into this class and associated inner classes.

Definition at line 51 of file Bitstream.java.

The documentation for this class was generated from the following file:

Generated by  Doxygen 1.6.0   Back to index