diff options
Diffstat (limited to 'apps/codecs/libwmapro/wmapro_mdct.c')
-rw-r--r-- | apps/codecs/libwmapro/wmapro_mdct.c | 51 |
1 files changed, 0 insertions, 51 deletions
diff --git a/apps/codecs/libwmapro/wmapro_mdct.c b/apps/codecs/libwmapro/wmapro_mdct.c deleted file mode 100644 index 2fa7040257..0000000000 --- a/apps/codecs/libwmapro/wmapro_mdct.c +++ /dev/null | |||
@@ -1,51 +0,0 @@ | |||
1 | #include <inttypes.h> | ||
2 | #include "wmapro_mdct.h" | ||
3 | #include "mdct_tables.h" /* for sincos_lookup_wmap */ | ||
4 | #include "../lib/mdct_lookup.h" /* for revtab */ | ||
5 | #include "../lib/fft.h" /* for FFT data structures */ | ||
6 | #include "codeclib.h" | ||
7 | #include "codeclib_misc.h" /* for XNPROD31 */ | ||
8 | |||
9 | #include "wmapro_math.h" | ||
10 | |||
11 | void imdct_half(unsigned int nbits, int32_t *output, const int32_t *input){ | ||
12 | int k, n8, n4, n2, n, j; | ||
13 | const int32_t *in1, *in2; | ||
14 | FFTComplex *z = (FFTComplex *)output; | ||
15 | |||
16 | n = 1 << nbits; | ||
17 | n2 = n >> 1; | ||
18 | n4 = n >> 2; | ||
19 | n8 = n >> 3; | ||
20 | |||
21 | const int32_t *T = sincos_lookup_wmap + ((n2) - (1<<7)); | ||
22 | |||
23 | /* pre rotation */ | ||
24 | const int revtab_shift = (14- nbits); | ||
25 | in1 = input; | ||
26 | in2 = input + n2 - 1; | ||
27 | for(k = 0; k < n4; k++) { | ||
28 | j=revtab[k]>>revtab_shift; | ||
29 | XNPROD31(*in2<<2, *in1<<2, T[1]<<14, T[0]<<14, &z[j].re, &z[j].im ); | ||
30 | in1 += 2; | ||
31 | in2 -= 2; | ||
32 | T += 2; | ||
33 | } | ||
34 | |||
35 | ff_fft_calc_c(nbits-2, z); | ||
36 | |||
37 | /* post rotation + reordering */ | ||
38 | T = sincos_lookup_wmap + ((n2) - (1<<7)) + n4; | ||
39 | const int32_t *V = T; | ||
40 | for(k = 0; k < n8; k++) { | ||
41 | int32_t r0, i0, r1, i1; | ||
42 | XNPROD31(z[n8-k-1].im, z[n8-k-1].re, T[0]<<8, T[1]<<8, &r0, &i1 ); | ||
43 | XNPROD31(z[n8+k ].im, z[n8+k ].re, V[0]<<8, V[1]<<8, &r1, &i0 ); | ||
44 | z[n8-k-1].re = r0; | ||
45 | z[n8-k-1].im = i0; | ||
46 | z[n8+k ].re = r1; | ||
47 | z[n8+k ].im = i1; | ||
48 | T-=2; | ||
49 | V+=2; | ||
50 | } | ||
51 | } | ||