#include "libavcodec/fft.h"
#include "util_altivec.h"
#include "types_altivec.h"
Go to the source code of this file.
Defines | |
#define | CMULA(p, o0, o1, o2, o3) |
#define | STORE2(v, dst) |
#define | STORE8(p) |
#define | CMULB(d0, d1, o) |
Functions | |
void | ff_fft_calc_altivec (FFTContext *s, FFTComplex *z) |
Do a complex FFT with the parameters defined in ff_fft_init(). | |
void | ff_fft_calc_interleave_altivec (FFTContext *s, FFTComplex *z) |
static void | ff_imdct_half_altivec (FFTContext *s, FFTSample *output, const FFTSample *input) |
static void | ff_imdct_calc_altivec (FFTContext *s, FFTSample *output, const FFTSample *input) |
av_cold void | ff_fft_init_altivec (FFTContext *s) |
#define CMULA | ( | p, | ||
o0, | ||||
o1, | ||||
o2, | ||||
o3 | ||||
) |
a = pin[ k*2+p]; /* { z[k].re, z[k].im, z[k+1].re, z[k+1].im } */\ b = pin[-k*2-p-1]; /* { z[-k-2].re, z[-k-2].im, z[-k-1].re, z[-k-1].im } */\ re = vec_perm(a, b, vcprm(0,2,s0,s2)); /* { z[k].re, z[k+1].re, z[-k-2].re, z[-k-1].re } */\ im = vec_perm(a, b, vcprm(s3,s1,3,1)); /* { z[-k-1].im, z[-k-2].im, z[k+1].im, z[k].im } */\ cos = vec_perm(cos0, cos1, vcprm(o0,o1,s##o2,s##o3)); /* { cos[k], cos[k+1], cos[-k-2], cos[-k-1] } */\ sin = vec_perm(sin0, sin1, vcprm(o0,o1,s##o2,s##o3));\ r##p = im*cos - re*sin;\ i##p = re*cos + im*sin;
Referenced by ff_imdct_half_altivec().
#define CMULB | ( | d0, | ||
d1, | ||||
o | ||||
) |
#define STORE8 | ( | p | ) |
a = vec_perm(r##p, i##p, vcprm(0,s0,0,s0));\ b = vec_perm(r##p, i##p, vcprm(1,s1,1,s1));\ c = vec_perm(r##p, i##p, vcprm(2,s2,2,s2));\ d = vec_perm(r##p, i##p, vcprm(3,s3,3,s3));\ STORE2(a, revtabk[ p*2-4]);\ STORE2(b, revtabk[ p*2-3]);\ STORE2(c, revtabj[-p*2+2]);\ STORE2(d, revtabj[-p*2+3]);
Referenced by ff_imdct_half_altivec().
void ff_fft_calc_altivec | ( | FFTContext * | s, | |
FFTComplex * | z | |||
) |
Do a complex FFT with the parameters defined in ff_fft_init().
The input data must be permuted before with s->revtab table. No 1.0/sqrt(n) normalization is done. AltiVec-enabled This code assumes that the 'z' pointer is 16 bytes-aligned It also assumes all FFTComplex are 8 bytes-aligned pair of float
Referenced by ff_imdct_half_altivec().
void ff_fft_calc_interleave_altivec | ( | FFTContext * | s, | |
FFTComplex * | z | |||
) |
av_cold void ff_fft_init_altivec | ( | FFTContext * | s | ) |
Definition at line 140 of file fft_altivec.c.
Referenced by ff_fft_init().
static void ff_imdct_calc_altivec | ( | FFTContext * | s, | |
FFTSample * | output, | |||
const FFTSample * | input | |||
) | [static] |
Definition at line 119 of file fft_altivec.c.
static void ff_imdct_half_altivec | ( | FFTContext * | s, | |
FFTSample * | output, | |||
const FFTSample * | input | |||
) | [static] |
Definition at line 39 of file fft_altivec.c.
Referenced by ff_imdct_calc_altivec().