mirror of https://git.ffmpeg.org/ffmpeg.git
lavc/atrac3plusdsp: change pow(2,x) to exp2f(x)
Much faster generation possible; but array is small so don't want to bloat the binary. Reviewed-by: Michael Niedermayer <michael@niedermayer.cc> Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
This commit is contained in:
parent
89189b1010
commit
9254e6176c
|
@ -28,6 +28,7 @@
|
|||
#include <math.h>
|
||||
|
||||
#include "libavutil/float_dsp.h"
|
||||
#include "libavutil/libm.h"
|
||||
#include "avcodec.h"
|
||||
#include "sinewin.h"
|
||||
#include "fft.h"
|
||||
|
@ -107,7 +108,7 @@ av_cold void ff_atrac3p_init_wave_synth(void)
|
|||
|
||||
/* generate amplitude scalefactors table */
|
||||
for (i = 0; i < 64; i++)
|
||||
amp_sf_tab[i] = pow(2.0f, ((double)i - 3) / 4.0f);
|
||||
amp_sf_tab[i] = exp2f((i - 3) / 4.0f);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in New Issue