Commit 80fbefd4 authored by vitor's avatar vitor

Call DCT by function pointer. Needed for any future ASM implementation and

allows further cleanup.


git-svn-id: file:///var/local/repositories/ffmpeg/trunk@22617 9553f0bf-9b14-0410-a0b8-cfaf0461ba5b
parent 87307cb8
......@@ -105,7 +105,7 @@ static void ff_dct_calc_c(DCTContext *ctx, FFTSample *data)
void ff_dct_calc(DCTContext *s, FFTSample *data)
{
ff_dct_calc_c(s, data);
s->dct_calc(s, data);
}
av_cold int ff_dct_init(DCTContext *s, int nbits, int inverse)
......@@ -130,6 +130,8 @@ av_cold int ff_dct_init(DCTContext *s, int nbits, int inverse)
for (i = 0; i < n/2; i++)
s->csc2[i] = 0.5 / sin((M_PI / (2*n) * (2*i + 1)));
s->dct_calc = ff_dct_calc_c;
return 0;
}
......
......@@ -220,6 +220,7 @@ struct DCTContext {
RDFTContext rdft;
const float *costab;
FFTSample *csc2;
void (*dct_calc)(struct DCTContext *s, FFTSample *data);
};
/**
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment