[FFmpeg-cvslog] r17598 - trunk/libavcodec/aac.c
alexc
subversion
Thu Feb 26 02:50:00 CET 2009
Author: alexc
Date: Thu Feb 26 02:50:00 2009
New Revision: 17598
Log:
Use const to better allow the compiler to optimize AAC independent coupling.
Modified:
trunk/libavcodec/aac.c
Modified: trunk/libavcodec/aac.c
==============================================================================
--- trunk/libavcodec/aac.c Thu Feb 26 02:38:51 2009 (r17597)
+++ trunk/libavcodec/aac.c Thu Feb 26 02:50:00 2009 (r17598)
@@ -1456,8 +1456,13 @@ static void apply_dependent_coupling(AAC
*/
static void apply_independent_coupling(AACContext * ac, SingleChannelElement * target, ChannelElement * cce, int index) {
int i;
+ const float gain = cce->coup.gain[index][0];
+ const float bias = ac->add_bias;
+ const float* src = cce->ch[0].ret;
+ float* dest = target->ret;
+
for (i = 0; i < 1024; i++)
- target->ret[i] += cce->coup.gain[index][0] * (cce->ch[0].ret[i] - ac->add_bias);
+ dest[i] += gain * (src[i] - bias);
}
/**
More information about the ffmpeg-cvslog
mailing list