summaryrefslogtreecommitdiff
path: root/libavcodec/fft.h
diff options
context:
space:
mode:
authorMåns Rullgård <mans@mansr.com>2010-03-20 21:27:03 +0000
committerMåns Rullgård <mans@mansr.com>2010-03-20 21:27:03 +0000
commit2881c83127c680defd1d596200897dd6b6db7977 (patch)
treee5648157f06e6958560b05c2a5a10d8c490785a3 /libavcodec/fft.h
parentb297129bdb0e779824db9b50440570212df58353 (diff)
Call rdft by function pointer
Call the RDFT by a function pointer like other FFT related transforms. This makes instruction set optimized versions possible. Based on patch by Alex Converse. Originally committed as revision 22609 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/fft.h')
-rw-r--r--libavcodec/fft.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/libavcodec/fft.h b/libavcodec/fft.h
index 636f76b824..0c13bb634a 100644
--- a/libavcodec/fft.h
+++ b/libavcodec/fft.h
@@ -196,6 +196,7 @@ struct RDFTContext {
const FFTSample *tcos;
SINTABLE_CONST FFTSample *tsin;
FFTContext fft;
+ void (*rdft_calc)(struct RDFTContext *s, FFTSample *z);
};
/**
@@ -204,9 +205,13 @@ struct RDFTContext {
* @param trans the type of transform
*/
int ff_rdft_init(RDFTContext *s, int nbits, enum RDFTransformType trans);
-void ff_rdft_calc(RDFTContext *s, FFTSample *data);
void ff_rdft_end(RDFTContext *s);
+static av_always_inline void ff_rdft_calc(RDFTContext *s, FFTSample *data)
+{
+ s->rdft_calc(s, data);
+}
+
/* Discrete Cosine Transform */
struct DCTContext {