From 0f999cfddb0746602288eabddf38679fd25a2ff7 Mon Sep 17 00:00:00 2001 From: Justin Ruggles Date: Tue, 15 Mar 2011 22:29:04 -0400 Subject: ac3enc: add float_to_fixed24() with x86-optimized versions to AC3DSPContext and use in scale_coefficients() for the floating-point AC-3 encoder. --- libavcodec/ac3enc_float.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'libavcodec/ac3enc_float.c') diff --git a/libavcodec/ac3enc_float.c b/libavcodec/ac3enc_float.c index 8668b2e033..4b13e4c723 100644 --- a/libavcodec/ac3enc_float.c +++ b/libavcodec/ac3enc_float.c @@ -103,9 +103,8 @@ static int normalize_samples(AC3EncodeContext *s) */ static void scale_coefficients(AC3EncodeContext *s) { - int i; - for (i = 0; i < AC3_MAX_COEFS * AC3_MAX_BLOCKS * s->channels; i++) - s->fixed_coef_buffer[i] = SCALE_FLOAT(s->mdct_coef_buffer[i], 24); + s->ac3dsp.float_to_fixed24(s->fixed_coef_buffer, s->mdct_coef_buffer, + AC3_MAX_COEFS * AC3_MAX_BLOCKS * s->channels); } -- cgit v1.2.3