aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/wma.h
diff options
context:
space:
mode:
authorSascha Sommer <saschasommer@freenet.de>2009-06-20 09:05:28 +0000
committerSascha Sommer <saschasommer@freenet.de>2009-06-20 09:05:28 +0000
commit9970c61b4b85e1df8e109aef2ba003673823e722 (patch)
treeeeff3ab6f3fc7ca34b808877eda7fd93839bf60e /libavcodec/wma.h
parent9ed3afcb7fe524dee315e800d17f94aa34b8d0b1 (diff)
downloadffmpeg-9970c61b4b85e1df8e109aef2ba003673823e722.tar.gz
Introduce WMACoef typedef for decoded coefficients
and change default type to float so that the run level decoding functionality can be shared with wmapro Originally committed as revision 19231 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/wma.h')
-rw-r--r--libavcodec/wma.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/libavcodec/wma.h b/libavcodec/wma.h
index 7ac85038d1..5a16331363 100644
--- a/libavcodec/wma.h
+++ b/libavcodec/wma.h
@@ -51,6 +51,8 @@
#define VLCBITS 9
#define VLCMAX ((22+VLCBITS-1)/VLCBITS)
+typedef float WMACoef; ///< type for decoded coefficients, int16_t would be enough for wma 1/2
+
typedef struct CoefVLCTable {
int n; ///< total number of codes
int max_level;
@@ -111,7 +113,7 @@ typedef struct WMACodecContext {
int exponents_bsize[MAX_CHANNELS]; ///< log2 ratio frame/exp. length
DECLARE_ALIGNED_16(float, exponents[MAX_CHANNELS][BLOCK_MAX_SIZE]);
float max_exponent[MAX_CHANNELS];
- int16_t coefs1[MAX_CHANNELS][BLOCK_MAX_SIZE];
+ WMACoef coefs1[MAX_CHANNELS][BLOCK_MAX_SIZE];
DECLARE_ALIGNED_16(float, coefs[MAX_CHANNELS][BLOCK_MAX_SIZE]);
DECLARE_ALIGNED_16(FFTSample, output[BLOCK_MAX_SIZE * 2]);
MDCTContext mdct_ctx[BLOCK_NB_SIZES];
@@ -151,7 +153,7 @@ int ff_wma_end(AVCodecContext *avctx);
int ff_wma_run_level_decode(AVCodecContext* avctx, GetBitContext* gb,
VLC *vlc,
const uint16_t *level_table, const uint16_t *run_table,
- int version, int16_t *ptr, int offset,
+ int version, WMACoef *ptr, int offset,
int num_coefs, int block_len, int frame_len_bits,
int coef_nb_bits);