Mercurial > libavcodec.hg
comparison dsputil.h @ 8636:9766c268bc9f libavcodec
Clean up FFT related comments.
author | alexc |
---|---|
date | Thu, 22 Jan 2009 19:46:23 +0000 |
parents | 04423b2f6e0b |
children | 68fd157bab48 |
comparison
equal
deleted
inserted
replaced
8635:6b164adb1907 | 8636:9766c268bc9f |
---|---|
672 void (*fft_calc)(struct FFTContext *s, FFTComplex *z); | 672 void (*fft_calc)(struct FFTContext *s, FFTComplex *z); |
673 void (*imdct_calc)(struct MDCTContext *s, FFTSample *output, const FFTSample *input); | 673 void (*imdct_calc)(struct MDCTContext *s, FFTSample *output, const FFTSample *input); |
674 void (*imdct_half)(struct MDCTContext *s, FFTSample *output, const FFTSample *input); | 674 void (*imdct_half)(struct MDCTContext *s, FFTSample *output, const FFTSample *input); |
675 } FFTContext; | 675 } FFTContext; |
676 | 676 |
677 /** | |
678 * Sets up a complex FFT. | |
679 * @param nbits log2 of the length of the input array | |
680 * @param inverse if 0 perform the forward transform, if 1 perform the inverse | |
681 */ | |
677 int ff_fft_init(FFTContext *s, int nbits, int inverse); | 682 int ff_fft_init(FFTContext *s, int nbits, int inverse); |
678 void ff_fft_permute_c(FFTContext *s, FFTComplex *z); | 683 void ff_fft_permute_c(FFTContext *s, FFTComplex *z); |
679 void ff_fft_permute_sse(FFTContext *s, FFTComplex *z); | 684 void ff_fft_permute_sse(FFTContext *s, FFTComplex *z); |
680 void ff_fft_calc_c(FFTContext *s, FFTComplex *z); | 685 void ff_fft_calc_c(FFTContext *s, FFTComplex *z); |
681 void ff_fft_calc_sse(FFTContext *s, FFTComplex *z); | 686 void ff_fft_calc_sse(FFTContext *s, FFTComplex *z); |
682 void ff_fft_calc_3dn(FFTContext *s, FFTComplex *z); | 687 void ff_fft_calc_3dn(FFTContext *s, FFTComplex *z); |
683 void ff_fft_calc_3dn2(FFTContext *s, FFTComplex *z); | 688 void ff_fft_calc_3dn2(FFTContext *s, FFTComplex *z); |
684 void ff_fft_calc_altivec(FFTContext *s, FFTComplex *z); | 689 void ff_fft_calc_altivec(FFTContext *s, FFTComplex *z); |
685 | 690 |
691 /** | |
692 * Do the permutation needed BEFORE calling ff_fft_calc(). | |
693 */ | |
686 static inline void ff_fft_permute(FFTContext *s, FFTComplex *z) | 694 static inline void ff_fft_permute(FFTContext *s, FFTComplex *z) |
687 { | 695 { |
688 s->fft_permute(s, z); | 696 s->fft_permute(s, z); |
689 } | 697 } |
698 /** | |
699 * Do a complex FFT with the parameters defined in ff_fft_init(). The | |
700 * input data must be permuted before. No 1.0/sqrt(n) normalization is done. | |
701 */ | |
690 static inline void ff_fft_calc(FFTContext *s, FFTComplex *z) | 702 static inline void ff_fft_calc(FFTContext *s, FFTComplex *z) |
691 { | 703 { |
692 s->fft_calc(s, z); | 704 s->fft_calc(s, z); |
693 } | 705 } |
694 void ff_fft_end(FFTContext *s); | 706 void ff_fft_end(FFTContext *s); |