From 69fc4da3606046672340bc81053db30e80dc36d4 Mon Sep 17 00:00:00 2001 From: Robert Swain Date: Thu, 14 Aug 2008 14:40:16 +0000 Subject: Add declarations for the sine tables used in wma.c (half window sizes: 128, 256, 512, 1024 and 2048) to mdct.c. Make them accessible via dsputil.h. Make wma.c use these shared tables. Originally committed as revision 14758 to svn://svn.ffmpeg.org/ffmpeg/trunk --- libavcodec/wma.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'libavcodec/wma.c') diff --git a/libavcodec/wma.c b/libavcodec/wma.c index c0261b1175..423852bc3a 100644 --- a/libavcodec/wma.c +++ b/libavcodec/wma.c @@ -66,7 +66,6 @@ int ff_wma_init(AVCodecContext * avctx, int flags2) { WMACodecContext *s = avctx->priv_data; int i; - float *window; float bps1, high_freq; volatile float bps; int sample_rate1; @@ -303,9 +302,8 @@ int ff_wma_init(AVCodecContext * avctx, int flags2) for(i = 0; i < s->nb_block_sizes; i++) { int n; n = 1 << (s->frame_len_bits - i); - window = av_malloc(sizeof(float) * n); - ff_sine_window_init(window, n); - s->windows[i] = window; + ff_sine_window_init(ff_sine_windows[i], n); + s->windows[i] = ff_sine_windows[i]; } s->reset_block_lengths = 1; -- cgit v1.2.3