diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2014-06-22 17:58:28 +0200 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2014-06-22 17:58:28 +0200 |
commit | 99497b4683e5054bcdc5b6802a27d717df9e04f3 (patch) | |
tree | 130022374c1a92b72288272bd0927ae6ac7d825b /libavcodec/ac3enc_template.c | |
parent | 0dae193d3ecf5d0dc687f5ad708419bf7600de9a (diff) | |
parent | 9a9e2f1c8aa4539a261625145e5c1f46a8106ac2 (diff) | |
download | ffmpeg-99497b4683e5054bcdc5b6802a27d717df9e04f3.tar.gz |
Merge commit '9a9e2f1c8aa4539a261625145e5c1f46a8106ac2'
* commit '9a9e2f1c8aa4539a261625145e5c1f46a8106ac2':
dsputil: Split audio operations off into a separate context
Conflicts:
configure
libavcodec/takdec.c
libavcodec/x86/Makefile
libavcodec/x86/dsputil.asm
libavcodec/x86/dsputil_init.c
libavcodec/x86/dsputil_mmx.c
libavcodec/x86/dsputil_x86.h
Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/ac3enc_template.c')
-rw-r--r-- | libavcodec/ac3enc_template.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/libavcodec/ac3enc_template.c b/libavcodec/ac3enc_template.c index 4527519175..192d16f57e 100644 --- a/libavcodec/ac3enc_template.c +++ b/libavcodec/ac3enc_template.c @@ -30,6 +30,8 @@ #include "libavutil/attributes.h" #include "libavutil/internal.h" + +#include "audiodsp.h" #include "internal.h" #include "ac3enc.h" #include "eac3enc.h" @@ -40,7 +42,8 @@ static void scale_coefficients(AC3EncodeContext *s); static int normalize_samples(AC3EncodeContext *s); -static void clip_coefficients(DSPContext *dsp, CoefType *coef, unsigned int len); +static void clip_coefficients(AudioDSPContext *adsp, CoefType *coef, + unsigned int len); static CoefType calc_cpl_coord(CoefSumType energy_ch, CoefSumType energy_cpl); @@ -164,7 +167,7 @@ static void apply_channel_coupling(AC3EncodeContext *s) } /* coefficients must be clipped in order to be encoded */ - clip_coefficients(&s->dsp, cpl_coef, num_cpl_coefs); + clip_coefficients(&s->adsp, cpl_coef, num_cpl_coefs); } /* calculate energy in each band in coupling channel and each fbw channel */ @@ -407,7 +410,7 @@ int AC3_NAME(encode_frame)(AVCodecContext *avctx, AVPacket *avpkt, if (s->fixed_point) scale_coefficients(s); - clip_coefficients(&s->dsp, s->blocks[0].mdct_coef[1], + clip_coefficients(&s->adsp, s->blocks[0].mdct_coef[1], AC3_MAX_COEFS * s->num_blocks * s->channels); s->cpl_on = s->cpl_enabled; |