diff options
author | Lynne <dev@lynne.ee> | 2021-01-09 17:27:16 +0100 |
---|---|---|
committer | Lynne <dev@lynne.ee> | 2021-01-14 01:44:18 +0100 |
commit | 238b2d4155d9779d770fccb3594076bb32742c82 (patch) | |
tree | 22c9e2e26fe214cf508bbc248f64b539b726e6e6 /libavcodec/ac3enc_template.c | |
parent | 784c08af3005390cb1d74add13b58edf1663cd40 (diff) | |
download | ffmpeg-238b2d4155d9779d770fccb3594076bb32742c82.tar.gz |
ac3enc: halve the MDCT window size by using vector_fmul_reverse
This brings the encoder in-line with the rest of ours and saves
on a bit of memory.
Diffstat (limited to 'libavcodec/ac3enc_template.c')
-rw-r--r-- | libavcodec/ac3enc_template.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/libavcodec/ac3enc_template.c b/libavcodec/ac3enc_template.c index 4f1e181e0b..5ecef3b178 100644 --- a/libavcodec/ac3enc_template.c +++ b/libavcodec/ac3enc_template.c @@ -92,7 +92,10 @@ static void apply_mdct(AC3EncodeContext *s) const SampleType *input_samples = &s->planar_samples[ch][blk * AC3_BLOCK_SIZE]; s->fdsp->vector_fmul(s->windowed_samples, input_samples, - s->mdct_window, AC3_WINDOW_SIZE); + s->mdct_window, AC3_BLOCK_SIZE); + s->fdsp->vector_fmul_reverse(s->windowed_samples + AC3_BLOCK_SIZE, + &input_samples[AC3_BLOCK_SIZE], + s->mdct_window, AC3_BLOCK_SIZE); s->mdct.mdct_calc(&s->mdct, block->mdct_coef[ch+1], s->windowed_samples); |