diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2008-05-25 02:23:16 +0400 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2008-05-25 02:23:16 +0400 |
commit | 40756c172c9d31f2d3999d24b70c5640bdafbb24 (patch) | |
tree | 55ce7b8e6f48122cd0ee02705e17b1666ad5d886 /libavcodec/cook.c | |
parent | c2c3dedf6e280c0e520b868976648e055f226f5d (diff) |
Merge init_rootpow2table and init_pow2table.
Originally committed as revision 13364 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/cook.c')
-rw-r--r-- | libavcodec/cook.c | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/libavcodec/cook.c b/libavcodec/cook.c index 37d1dffaa2..3b3f6e8ad1 100644 --- a/libavcodec/cook.c +++ b/libavcodec/cook.c @@ -185,18 +185,11 @@ static void dump_short_table(short* table, int size, int delimiter) { /* table generator */ static void init_pow2table(COOKContext *q){ int i; + q->rootpow2tab[63] = q->pow2tab[63] = 1.0; for (i=1 ; i<64 ; i++){ q->pow2tab[63+i]=(float)((uint64_t)1<<i); q->pow2tab[63-i]=1.0/(float)((uint64_t)1<<i); - } -} - -/* table generator */ -static void init_rootpow2table(COOKContext *q){ - int i; - q->rootpow2tab[63] = 1.0; - for (i=1 ; i<64 ; i++){ q->rootpow2tab[63+i]=sqrt((float)((uint64_t)1<<i)); q->rootpow2tab[63-i]=sqrt(1.0/(float)((uint64_t)1<<i)); } @@ -1124,7 +1117,6 @@ static int cook_decode_init(AVCodecContext *avctx) q->numvector_size = (1 << q->log2_numvector_size); /* Generate tables */ - init_rootpow2table(q); init_pow2table(q); init_gain_table(q); init_cplscales_table(q); |