Mercurial > libavcodec.hg
view ac3enc.h @ 199:0f1dba8fc617 libavcodec
(commited by michael / arpi was crazy enough to give me his password)
fixed a bug in get_vlc() when using the ALT_BITSTREAM_READER (rv10 & mpeg12 decoders where not working)
some optimizations
replaced a if() with a >>
changed get_bits1() a bit so it hopefully is faster on p4
author | arpi_esp |
---|---|
date | Sat, 12 Jan 2002 20:21:51 +0000 |
parents | 986e461dc072 |
children | 289eb941b8ba |
line wrap: on
line source
#define AC3_FRAME_SIZE (6*256) #define AC3_MAX_CODED_FRAME_SIZE 3840 /* in bytes */ #define AC3_MAX_CHANNELS 2 /* we handle at most two channels, although AC3 allows 6 channels */ typedef struct AC3EncodeContext { PutBitContext pb; int nb_channels; int bit_rate; int sample_rate; int bsid; int frame_size_min; /* minimum frame size in case rounding is necessary */ int frame_size; /* current frame size in words */ int halfratecod; int frmsizecod; int fscod; /* frequency */ int acmod; int bsmod; short last_samples[AC3_MAX_CHANNELS][256]; int chbwcod[AC3_MAX_CHANNELS]; int nb_coefs[AC3_MAX_CHANNELS]; /* bitrate allocation control */ int sgaincod, sdecaycod, fdecaycod, dbkneecod, floorcod; int sgain, sdecay, fdecay, dbknee, floor; int csnroffst; int fgaincod[AC3_MAX_CHANNELS]; int fsnroffst[AC3_MAX_CHANNELS]; /* mantissa encoding */ int mant1_cnt, mant2_cnt, mant4_cnt; } AC3EncodeContext;