diff options
99 files changed, 32962 insertions, 19688 deletions
diff --git a/src/libfaad/Makefile.am b/src/libfaad/Makefile.am index 888ff7c3c..eebcdbf81 100644 --- a/src/libfaad/Makefile.am +++ b/src/libfaad/Makefile.am @@ -16,25 +16,12 @@ xineplug_decode_faad_la_SOURCES = \ bits.c \ cfft.c \ common.c \ - data.c \ decoder.c \ - dither.c \ drc.c \ error.c \ filtbank.c \ - codebook/hcb_1.c \ - codebook/hcb_2.c \ - codebook/hcb_3.c \ - codebook/hcb_4.c \ - codebook/hcb_5.c \ - codebook/hcb_6.c \ - codebook/hcb_7.c \ - codebook/hcb_8.c \ - codebook/hcb_9.c \ - codebook/hcb_10.c \ - codebook/hcb_11.c \ - codebook/hcb_sf.c \ hcr.c \ + huffman.c \ ic_predict.c \ is.c \ lt_predict.c \ @@ -45,6 +32,16 @@ xineplug_decode_faad_la_SOURCES = \ pns.c \ pulse.c \ rvlc.c \ + sbr_dct.c \ + sbr_dec.c \ + sbr_e_nf.c \ + sbr_fbt.c \ + sbr_hfadj.c \ + sbr_hfgen.c \ + sbr_huff.c \ + sbr_qmf.c \ + sbr_syntax.c \ + sbr_tf_grid.c \ specrec.c \ ssr.c \ ssr_fb.c \ @@ -62,9 +59,7 @@ noinst_HEADERS = \ cfft.h \ cfft_tab.h \ common.h \ - data.h \ decoder.h \ - dither.h \ drc.h \ error.h \ faad.h \ @@ -83,6 +78,18 @@ noinst_HEADERS = \ pns.h \ pulse.h \ rvlc.h \ + sbr_dct.h \ + sbr_dec.h \ + sbr_e_nf.h \ + sbr_fbt.h \ + sbr_hfadj.h \ + sbr_hfgen.h \ + sbr_huff.h \ + sbr_noise.h \ + sbr_qmf.h \ + sbr_qmf_c.h \ + sbr_syntax.h \ + sbr_tf_grid.h \ sine_win.h \ specrec.h \ ssr.h \ diff --git a/src/libfaad/analysis.h b/src/libfaad/analysis.h index e160ac1db..2cfd05d50 100644 --- a/src/libfaad/analysis.h +++ b/src/libfaad/analysis.h @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: analysis.h,v 1.2 2002/12/16 18:59:51 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: analysis.h,v 1.3 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #ifndef __ANALYSIS_H__ diff --git a/src/libfaad/bits.c b/src/libfaad/bits.c index d08d69c77..ea0b8a78c 100644 --- a/src/libfaad/bits.c +++ b/src/libfaad/bits.c @@ -1,22 +1,28 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker -** +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. -** +** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. -** +** ** You should have received a copy of the GNU General Public License -** along with this program; if not, write to the Free Software +** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: bits.c,v 1.4 2003/04/12 14:58:46 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: bits.c,v 1.5 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #include "common.h" @@ -27,26 +33,32 @@ #include "bits.h" /* initialize buffer, call once before first getbits or showbits */ -void faad_initbits(bitfile *ld, void *_buffer, uint32_t buffer_size) +void faad_initbits(bitfile *ld, const void *_buffer, const uint32_t buffer_size) { uint32_t tmp; - ld->buffer = malloc((buffer_size+12)*sizeof(uint8_t)); + if (ld == NULL) + return; + + memset(ld, 0, sizeof(bitfile)); + + if (buffer_size == 0 || _buffer == NULL) + { + ld->error = 1; + ld->no_more_reading = 1; + return; + } + + ld->buffer = faad_malloc((buffer_size+12)*sizeof(uint8_t)); memset(ld->buffer, 0, (buffer_size+12)*sizeof(uint8_t)); memcpy(ld->buffer, _buffer, buffer_size*sizeof(uint8_t)); ld->buffer_size = buffer_size; tmp = getdword((uint32_t*)ld->buffer); -#ifndef ARCH_IS_BIG_ENDIAN - BSWAP(tmp); -#endif ld->bufa = tmp; tmp = getdword((uint32_t*)ld->buffer + 1); -#ifndef ARCH_IS_BIG_ENDIAN - BSWAP(tmp); -#endif ld->bufb = tmp; ld->start = (uint32_t*)ld->buffer; @@ -62,13 +74,12 @@ void faad_initbits(bitfile *ld, void *_buffer, uint32_t buffer_size) void faad_endbits(bitfile *ld) { if (ld) - if (ld->buffer) free(ld->buffer); + if (ld->buffer) faad_free(ld->buffer); } - uint32_t faad_get_processed_bits(bitfile *ld) { - return 8 * (4*(ld->tail - ld->start) - 4) - (ld->bits_left); + return (uint32_t)(8 * (4*(ld->tail - ld->start) - 4) - (ld->bits_left)); } uint8_t faad_byte_align(bitfile *ld) @@ -83,6 +94,22 @@ uint8_t faad_byte_align(bitfile *ld) return 0; } +void faad_flushbits_ex(bitfile *ld, uint32_t bits) +{ + uint32_t tmp; + + ld->bufa = ld->bufb; + tmp = getdword(ld->tail); + ld->tail++; + ld->bufb = tmp; + ld->bits_left += (32 - bits); + ld->bytes_used += 4; + if (ld->bytes_used == ld->buffer_size) + ld->no_more_reading = 1; + if (ld->bytes_used > ld->buffer_size) + ld->error = 1; +} + /* rewind to beginning */ void faad_rewindbits(bitfile *ld) { @@ -113,7 +140,7 @@ uint8_t *faad_getbitbuffer(bitfile *ld, uint32_t bits uint16_t bytes = (uint16_t)bits / 8; uint8_t remainder = (uint8_t)bits % 8; - uint8_t *buffer = (uint8_t*)malloc((bytes+1)*sizeof(uint8_t)); + uint8_t *buffer = (uint8_t*)faad_malloc((bytes+1)*sizeof(uint8_t)); for (i = 0; i < bytes; i++) { @@ -144,15 +171,9 @@ void faad_initbits_rev(bitfile *ld, void *buffer, ld->start = (uint32_t*)buffer + index - 2; tmp = getdword((uint32_t*)buffer + index); -#ifndef ARCH_IS_BIG_ENDIAN - BSWAP(tmp); -#endif ld->bufa = tmp; tmp = getdword((uint32_t*)buffer + index - 1); -#ifndef ARCH_IS_BIG_ENDIAN - BSWAP(tmp); -#endif ld->bufb = tmp; ld->tail = (uint32_t*)buffer + index; diff --git a/src/libfaad/bits.h b/src/libfaad/bits.h index dfb5ca659..2760ad022 100644 --- a/src/libfaad/bits.h +++ b/src/libfaad/bits.h @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: bits.h,v 1.4 2003/04/12 14:58:46 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: bits.h,v 1.5 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #ifndef __BITS_H__ @@ -67,12 +73,13 @@ static uint32_t bitmask[] = { 0xFFFFFFF, 0x1FFFFFFF, 0x3FFFFFFF, 0x7FFFFFFF }; -void faad_initbits(bitfile *ld, void *buffer, uint32_t buffer_size); +void faad_initbits(bitfile *ld, const void *buffer, const uint32_t buffer_size); void faad_endbits(bitfile *ld); void faad_initbits_rev(bitfile *ld, void *buffer, uint32_t bits_in_buffer); uint8_t faad_byte_align(bitfile *ld); uint32_t faad_get_processed_bits(bitfile *ld); +void faad_flushbits_ex(bitfile *ld, uint32_t bits); void faad_rewindbits(bitfile *ld); uint8_t *faad_getbitbuffer(bitfile *ld, uint32_t bits DEBUGDEC); @@ -82,14 +89,26 @@ static INLINE uint32_t getdword(void *mem) { #ifdef ARM uint32_t tmp; +#ifndef ARCH_IS_BIG_ENDIAN + ((uint8_t*)&tmp)[0] = ((uint8_t*)mem)[3]; + ((uint8_t*)&tmp)[1] = ((uint8_t*)mem)[2]; + ((uint8_t*)&tmp)[2] = ((uint8_t*)mem)[1]; + ((uint8_t*)&tmp)[3] = ((uint8_t*)mem)[0]; +#else ((uint8_t*)&tmp)[0] = ((uint8_t*)mem)[0]; ((uint8_t*)&tmp)[1] = ((uint8_t*)mem)[1]; ((uint8_t*)&tmp)[2] = ((uint8_t*)mem)[2]; ((uint8_t*)&tmp)[3] = ((uint8_t*)mem)[3]; +#endif return tmp; #else - return *(uint32_t*)mem; + uint32_t tmp; + tmp = *(uint32_t*)mem; +#ifndef ARCH_IS_BIG_ENDIAN + BSWAP(tmp); +#endif + return tmp; #endif } @@ -98,10 +117,10 @@ static INLINE uint32_t faad_showbits(bitfile *ld, uint32_t bits) if (bits <= ld->bits_left) { return (ld->bufa >> (ld->bits_left - bits)) & bitmask[bits]; - } else { - bits -= ld->bits_left; - return ((ld->bufa & bitmask[ld->bits_left]) << bits) | (ld->bufb >> (32 - bits)); } + + bits -= ld->bits_left; + return ((ld->bufa & bitmask[ld->bits_left]) << bits) | (ld->bufb >> (32 - bits)); } static INLINE void faad_flushbits(bitfile *ld, uint32_t bits) @@ -114,21 +133,7 @@ static INLINE void faad_flushbits(bitfile *ld, uint32_t bits) { ld->bits_left -= bits; } else { - uint32_t tmp; - - ld->bufa = ld->bufb; - tmp = getdword(ld->tail); - ld->tail++; -#ifndef ARCH_IS_BIG_ENDIAN - BSWAP(tmp); -#endif - ld->bufb = tmp; - ld->bits_left += (32 - bits); - ld->bytes_used += 4; - if (ld->bytes_used == ld->buffer_size) - ld->no_more_reading = 1; - if (ld->bytes_used > ld->buffer_size) - ld->error = 1; + faad_flushbits_ex(ld, bits); } } @@ -137,10 +142,7 @@ static INLINE uint32_t faad_getbits(bitfile *ld, uint32_t n DEBUGDEC) { uint32_t ret; - if (ld->no_more_reading) - return 0; - - if (n == 0) + if (ld->no_more_reading || n == 0) return 0; ret = faad_showbits(ld, n); @@ -162,7 +164,7 @@ static INLINE uint8_t faad_get1bit(bitfile *ld DEBUGDEC) return (uint8_t)faad_getbits(ld, 1 DEBUGVAR(print,var,dbg)); ld->bits_left--; - r = (ld->bufa >> ld->bits_left) & 1; + r = (uint8_t)((ld->bufa >> ld->bits_left) & 1); return r; } @@ -210,9 +212,6 @@ static INLINE void faad_flushbits_rev(bitfile *ld, uint32_t bits) ld->bufa = ld->bufb; tmp = getdword(ld->start); -#ifndef ARCH_IS_BIG_ENDIAN - BSWAP(tmp); -#endif ld->bufb = tmp; ld->start--; ld->bits_left += (32 - bits); @@ -247,6 +246,121 @@ static INLINE uint32_t faad_getbits_rev(bitfile *ld, uint32_t n return ret; } +#ifdef DRM +static uint8_t faad_check_CRC(bitfile *ld, uint16_t len) +{ + uint8_t CRC; + uint16_t r=255; /* Initialize to all ones */ + + /* CRC polynome used x^8 + x^4 + x^3 + x^2 +1 */ +#define GPOLY 0435 + + faad_rewindbits(ld); + + CRC = ~faad_getbits(ld, 8 + DEBUGVAR(1,999,"faad_check_CRC(): CRC")); /* CRC is stored inverted */ + + for (; len>0; len--) + { + r = ( (r << 1) ^ (( ( faad_get1bit(ld + DEBUGVAR(1,998,"")) & 1) ^ ((r >> 7) & 1)) * GPOLY )) & 0xFF; + } + + if (r != CRC) + { + return 8; + } else { + return 0; + } +} + +static uint8_t tabFlipbits[256] = { + 0,128,64,192,32,160,96,224,16,144,80,208,48,176,112,240, + 8,136,72,200,40,168,104,232,24,152,88,216,56,184,120,248, + 4,132,68,196,36,164,100,228,20,148,84,212,52,180,116,244, + 12,140,76,204,44,172,108,236,28,156,92,220,60,188,124,252, + 2,130,66,194,34,162,98,226,18,146,82,210,50,178,114,242, + 10,138,74,202,42,170,106,234,26,154,90,218,58,186,122,250, + 6,134,70,198,38,166,102,230,22,150,86,214,54,182,118,246, + 14,142,78,206,46,174,110,238,30,158,94,222,62,190,126,254, + 1,129,65,193,33,161,97,225,17,145,81,209,49,177,113,241, + 9,137,73,201,41,169,105,233,25,153,89,217,57,185,121,249, + 5,133,69,197,37,165,101,229,21,149,85,213,53,181,117,245, + 13,141,77,205,45,173,109,237,29,157,93,221,61,189,125,253, + 3,131,67,195,35,163,99,227,19,147,83,211,51,179,115,243, + 11,139,75,203,43,171,107,235,27,155,91,219,59,187,123,251, + 7,135,71,199,39,167,103,231,23,151,87,215,55,183,119,247, + 15,143,79,207,47,175,111,239,31,159,95,223,63,191,127,255 +}; +#endif + +#ifdef ERROR_RESILIENCE + +/* Modified bit reading functions for HCR */ + +typedef struct +{ + /* bit input */ + uint32_t bufa; + uint32_t bufb; + int8_t len; +} bits_t; + + +static INLINE uint32_t showbits_hcr(bits_t *ld, uint8_t bits) +{ + if (bits == 0) return 0; + if (ld->len <= 32) + { + /* huffman_spectral_data_2 needs to read more than may be available, bits maybe + > ld->len, deliver 0 than */ + if (ld->len >= bits) + return ((ld->bufa >> (ld->len - bits)) & (0xFFFFFFFF >> (32 - bits))); + else + return ((ld->bufa << (bits - ld->len)) & (0xFFFFFFFF >> (32 - bits))); + } else { + if ((ld->len - bits) < 32) + { + return ( (ld->bufb & (0xFFFFFFFF >> (64 - ld->len))) << (bits - ld->len + 32)) | + (ld->bufa >> (ld->len - bits)); + } else { + return ((ld->bufb >> (ld->len - bits - 32)) & (0xFFFFFFFF >> (32 - bits))); + } + } +} + +/* return 1 if position is outside of buffer, 0 otherwise */ +static INLINE int8_t flushbits_hcr( bits_t *ld, uint8_t bits) +{ + ld->len -= bits; + + if (ld->len <0) + { + ld->len = 0; + return 1; + } else { + return 0; + } +} + +static INLINE int8_t getbits_hcr(bits_t *ld, uint8_t n, uint32_t *result) +{ + *result = showbits_hcr(ld, n); + return flushbits_hcr(ld, n); +} + +static INLINE int8_t get1bit_hcr(bits_t *ld, uint8_t *result) +{ + uint32_t res; + int8_t ret; + + ret = getbits_hcr(ld, 1, &res); + *result = (int8_t)(res & 1); + return ret; +} + +#endif + #ifdef __cplusplus } diff --git a/src/libfaad/cfft.c b/src/libfaad/cfft.c index a18527dbc..bbdfc36df 100644 --- a/src/libfaad/cfft.c +++ b/src/libfaad/cfft.c @@ -1,22 +1,28 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker -** +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. -** +** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. -** +** ** You should have received a copy of the GNU General Public License -** along with this program; if not, write to the Free Software +** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: cfft.c,v 1.6 2003/04/12 14:58:46 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: cfft.c,v 1.7 2003/12/30 02:00:10 miguelfreitas Exp $ **/ /* @@ -37,27 +43,91 @@ #include "cfft_tab.h" -/* static declarations moved to avoid compiler warnings [MF] */ -static void passf2(uint16_t ido, uint16_t l1, complex_t *cc, complex_t *ch, - complex_t *wa, int8_t isign); -static void passf3(uint16_t ido, uint16_t l1, complex_t *cc, complex_t *ch, - complex_t *wa1, complex_t *wa2, int8_t isign); -static void passf4(uint16_t ido, uint16_t l1, complex_t *cc, complex_t *ch, - complex_t *wa1, complex_t *wa2, complex_t *wa3, int8_t isign); -static void passf5(uint16_t ido, uint16_t l1, complex_t *cc, complex_t *ch, - complex_t *wa1, complex_t *wa2, complex_t *wa3, complex_t *wa4, - int8_t isign); -INLINE void cfftf1(uint16_t n, complex_t *c, complex_t *ch, - uint16_t *ifac, complex_t *wa, int8_t isign); -static void cffti1(uint16_t n, complex_t *wa, uint16_t *ifac); - - /*---------------------------------------------------------------------- passf2, passf3, passf4, passf5. Complex FFT passes fwd and bwd. ----------------------------------------------------------------------*/ -static void passf2(uint16_t ido, uint16_t l1, complex_t *cc, complex_t *ch, - complex_t *wa, int8_t isign) +#ifdef USE_SSE +static void passf2pos_sse(const uint16_t ido, const uint16_t l1, const complex_t *cc, + complex_t *ch, const complex_t *wa) +{ + uint16_t i, k, ah, ac; + + if (ido == 1) + { + for (k = 0; k < l1; k++) + { + ah = 2*k; + ac = 4*k; + + RE(ch[ah]) = RE(cc[ac]) + RE(cc[ac+1]); + IM(ch[ah]) = IM(cc[ac]) + IM(cc[ac+1]); + + RE(ch[ah+l1]) = RE(cc[ac]) - RE(cc[ac+1]); + IM(ch[ah+l1]) = IM(cc[ac]) - IM(cc[ac+1]); + } + } else { + for (k = 0; k < l1; k++) + { + ah = k*ido; + ac = 2*k*ido; + + for (i = 0; i < ido; i+=4) + { + __m128 m1, m2, m3, m4, m5, m6, m7, m8, m9, m10, m11, m12, m13, m14; + __m128 m15, m16, m17, m18, m19, m20, m21, m22, m23, m24; + __m128 w1, w2, w3, w4; + + m1 = _mm_load_ps(&RE(cc[ac+i])); + m2 = _mm_load_ps(&RE(cc[ac+ido+i])); + m5 = _mm_load_ps(&RE(cc[ac+i+2])); + m6 = _mm_load_ps(&RE(cc[ac+ido+i+2])); + w1 = _mm_load_ps(&RE(wa[i])); + w3 = _mm_load_ps(&RE(wa[i+2])); + + m3 = _mm_add_ps(m1, m2); + m15 = _mm_add_ps(m5, m6); + + m4 = _mm_sub_ps(m1, m2); + m16 = _mm_sub_ps(m5, m6); + + _mm_store_ps(&RE(ch[ah+i]), m3); + _mm_store_ps(&RE(ch[ah+i+2]), m15); + + w2 = _mm_shuffle_ps(w1, w1, _MM_SHUFFLE(2, 3, 0, 1)); + w4 = _mm_shuffle_ps(w3, w3, _MM_SHUFFLE(2, 3, 0, 1)); + + m7 = _mm_mul_ps(m4, w1); + m17 = _mm_mul_ps(m16, w3); + m8 = _mm_mul_ps(m4, w2); + m18 = _mm_mul_ps(m16, w4); + + m9 = _mm_shuffle_ps(m7, m8, _MM_SHUFFLE(2, 0, 2, 0)); + m19 = _mm_shuffle_ps(m17, m18, _MM_SHUFFLE(2, 0, 2, 0)); + m10 = _mm_shuffle_ps(m7, m8, _MM_SHUFFLE(3, 1, 3, 1)); + m20 = _mm_shuffle_ps(m17, m18, _MM_SHUFFLE(3, 1, 3, 1)); + + m11 = _mm_add_ps(m9, m10); + m21 = _mm_add_ps(m19, m20); + m12 = _mm_sub_ps(m9, m10); + m22 = _mm_sub_ps(m19, m20); + + m13 = _mm_shuffle_ps(m11, m11, _MM_SHUFFLE(0, 0, 3, 2)); + m23 = _mm_shuffle_ps(m21, m21, _MM_SHUFFLE(0, 0, 3, 2)); + + m14 = _mm_unpacklo_ps(m12, m13); + m24 = _mm_unpacklo_ps(m22, m23); + + _mm_store_ps(&RE(ch[ah+i+l1*ido]), m14); + _mm_store_ps(&RE(ch[ah+i+2+l1*ido]), m24); + } + } + } +} +#endif + +static void passf2pos(const uint16_t ido, const uint16_t l1, const complex_t *cc, + complex_t *ch, const complex_t *wa) { uint16_t i, k, ah, ac; @@ -68,9 +138,9 @@ static void passf2(uint16_t ido, uint16_t l1, complex_t *cc, complex_t *ch, ah = 2*k; ac = 4*k; - RE(ch[ah]) = RE(cc[ac]) + RE(cc[ac+1]); - IM(ch[ah]) = IM(cc[ac]) + IM(cc[ac+1]); + RE(ch[ah]) = RE(cc[ac]) + RE(cc[ac+1]); RE(ch[ah+l1]) = RE(cc[ac]) - RE(cc[ac+1]); + IM(ch[ah]) = IM(cc[ac]) + IM(cc[ac+1]); IM(ch[ah+l1]) = IM(cc[ac]) - IM(cc[ac+1]); } } else { @@ -83,251 +153,685 @@ static void passf2(uint16_t ido, uint16_t l1, complex_t *cc, complex_t *ch, { complex_t t2; - RE(ch[ah]) = RE(cc[ac]) + RE(cc[ac+ido]); - IM(ch[ah]) = IM(cc[ac]) + IM(cc[ac+ido]); + RE(ch[ah+i]) = RE(cc[ac+i]) + RE(cc[ac+i+ido]); + RE(t2) = RE(cc[ac+i]) - RE(cc[ac+i+ido]); - RE(t2) = RE(cc[ac]) - RE(cc[ac+ido]); - IM(t2) = IM(cc[ac]) - IM(cc[ac+ido]); + IM(ch[ah+i]) = IM(cc[ac+i]) + IM(cc[ac+i+ido]); + IM(t2) = IM(cc[ac+i]) - IM(cc[ac+i+ido]); - RE(ch[ah+l1*ido]) = MUL_R_C(RE(t2),RE(wa[i])) - MUL_R_C(IM(t2),IM(wa[i]))*isign; - IM(ch[ah+l1*ido]) = MUL_R_C(IM(t2),RE(wa[i])) + MUL_R_C(RE(t2),IM(wa[i]))*isign; - ah++; - ac++; + ComplexMult(&IM(ch[ah+i+l1*ido]), &RE(ch[ah+i+l1*ido]), + IM(t2), RE(t2), RE(wa[i]), IM(wa[i])); } } } } +static void passf2neg(const uint16_t ido, const uint16_t l1, const complex_t *cc, + complex_t *ch, const complex_t *wa) +{ + uint16_t i, k, ah, ac; + + if (ido == 1) + { + for (k = 0; k < l1; k++) + { + ah = 2*k; + ac = 4*k; -static void passf3(uint16_t ido, uint16_t l1, complex_t *cc, complex_t *ch, - complex_t *wa1, complex_t *wa2, int8_t isign) + RE(ch[ah]) = RE(cc[ac]) + RE(cc[ac+1]); + RE(ch[ah+l1]) = RE(cc[ac]) - RE(cc[ac+1]); + IM(ch[ah]) = IM(cc[ac]) + IM(cc[ac+1]); + IM(ch[ah+l1]) = IM(cc[ac]) - IM(cc[ac+1]); + } + } else { + for (k = 0; k < l1; k++) + { + ah = k*ido; + ac = 2*k*ido; + + for (i = 0; i < ido; i++) + { + complex_t t2; + + RE(ch[ah+i]) = RE(cc[ac+i]) + RE(cc[ac+i+ido]); + RE(t2) = RE(cc[ac+i]) - RE(cc[ac+i+ido]); + + IM(ch[ah+i]) = IM(cc[ac+i]) + IM(cc[ac+i+ido]); + IM(t2) = IM(cc[ac+i]) - IM(cc[ac+i+ido]); + + ComplexMult(&RE(ch[ah+i+l1*ido]), &IM(ch[ah+i+l1*ido]), + RE(t2), IM(t2), RE(wa[i]), IM(wa[i])); + } + } + } +} + + +static void passf3(const uint16_t ido, const uint16_t l1, const complex_t *cc, + complex_t *ch, const complex_t *wa1, const complex_t *wa2, + const int8_t isign) { - static real_t taur = COEF_CONST(-0.5); - static real_t taui = COEF_CONST(0.866025403784439); + static real_t taur = FRAC_CONST(-0.5); + static real_t taui = FRAC_CONST(0.866025403784439); uint16_t i, k, ac, ah; complex_t c2, c3, d2, d3, t2; if (ido == 1) { - for (k = 0; k < l1; k++) + if (isign == 1) { - ac = 3*k+1; - ah = k; + for (k = 0; k < l1; k++) + { + ac = 3*k+1; + ah = k; - RE(t2) = RE(cc[ac]) + RE(cc[ac+1]); - IM(t2) = IM(cc[ac]) + IM(cc[ac+1]); - RE(c2) = RE(cc[ac-1]) + MUL_R_C(RE(t2),taur); - IM(c2) = IM(cc[ac-1]) + MUL_R_C(IM(t2),taur); + RE(t2) = RE(cc[ac]) + RE(cc[ac+1]); + IM(t2) = IM(cc[ac]) + IM(cc[ac+1]); + RE(c2) = RE(cc[ac-1]) + MUL_F(RE(t2),taur); + IM(c2) = IM(cc[ac-1]) + MUL_F(IM(t2),taur); - RE(ch[ah]) = RE(cc[ac-1]) + RE(t2); - IM(ch[ah]) = IM(cc[ac-1]) + IM(t2); + RE(ch[ah]) = RE(cc[ac-1]) + RE(t2); + IM(ch[ah]) = IM(cc[ac-1]) + IM(t2); - RE(c3) = MUL_R_C((RE(cc[ac]) - RE(cc[ac+1])), taui)*isign; - IM(c3) = MUL_R_C((IM(cc[ac]) - IM(cc[ac+1])), taui)*isign; + RE(c3) = MUL_F((RE(cc[ac]) - RE(cc[ac+1])), taui); + IM(c3) = MUL_F((IM(cc[ac]) - IM(cc[ac+1])), taui); - RE(ch[ah+l1]) = RE(c2) - IM(c3); - IM(ch[ah+l1]) = IM(c2) + RE(c3); - RE(ch[ah+2*l1]) = RE(c2) + IM(c3); - IM(ch[ah+2*l1]) = IM(c2) - RE(c3); + RE(ch[ah+l1]) = RE(c2) - IM(c3); + IM(ch[ah+l1]) = IM(c2) + RE(c3); + RE(ch[ah+2*l1]) = RE(c2) + IM(c3); + IM(ch[ah+2*l1]) = IM(c2) - RE(c3); + } + } else { + for (k = 0; k < l1; k++) + { + ac = 3*k+1; + ah = k; + + RE(t2) = RE(cc[ac]) + RE(cc[ac+1]); + IM(t2) = IM(cc[ac]) + IM(cc[ac+1]); + RE(c2) = RE(cc[ac-1]) + MUL_F(RE(t2),taur); + IM(c2) = IM(cc[ac-1]) + MUL_F(IM(t2),taur); + + RE(ch[ah]) = RE(cc[ac-1]) + RE(t2); + IM(ch[ah]) = IM(cc[ac-1]) + IM(t2); + + RE(c3) = MUL_F((RE(cc[ac]) - RE(cc[ac+1])), taui); + IM(c3) = MUL_F((IM(cc[ac]) - IM(cc[ac+1])), taui); + + RE(ch[ah+l1]) = RE(c2) + IM(c3); + IM(ch[ah+l1]) = IM(c2) - RE(c3); + RE(ch[ah+2*l1]) = RE(c2) - IM(c3); + IM(ch[ah+2*l1]) = IM(c2) + RE(c3); + } } } else { - for (k = 0; k < l1; k++) + if (isign == 1) { - for (i = 0; i < ido; i++) + for (k = 0; k < l1; k++) + { + for (i = 0; i < ido; i++) + { + ac = i + (3*k+1)*ido; + ah = i + k * ido; + + RE(t2) = RE(cc[ac]) + RE(cc[ac+ido]); + RE(c2) = RE(cc[ac-ido]) + MUL_F(RE(t2),taur); + IM(t2) = IM(cc[ac]) + IM(cc[ac+ido]); + IM(c2) = IM(cc[ac-ido]) + MUL_F(IM(t2),taur); + + RE(ch[ah]) = RE(cc[ac-ido]) + RE(t2); + IM(ch[ah]) = IM(cc[ac-ido]) + IM(t2); + + RE(c3) = MUL_F((RE(cc[ac]) - RE(cc[ac+ido])), taui); + IM(c3) = MUL_F((IM(cc[ac]) - IM(cc[ac+ido])), taui); + + RE(d2) = RE(c2) - IM(c3); + IM(d3) = IM(c2) - RE(c3); + RE(d3) = RE(c2) + IM(c3); + IM(d2) = IM(c2) + RE(c3); + + ComplexMult(&IM(ch[ah+l1*ido]), &RE(ch[ah+l1*ido]), + IM(d2), RE(d2), RE(wa1[i]), IM(wa1[i])); + ComplexMult(&IM(ch[ah+2*l1*ido]), &RE(ch[ah+2*l1*ido]), + IM(d3), RE(d3), RE(wa2[i]), IM(wa2[i])); + } + } + } else { + for (k = 0; k < l1; k++) { - ac = i + (3*k+1)*ido; - ah = i + k * ido; + for (i = 0; i < ido; i++) + { + ac = i + (3*k+1)*ido; + ah = i + k * ido; + + RE(t2) = RE(cc[ac]) + RE(cc[ac+ido]); + RE(c2) = RE(cc[ac-ido]) + MUL_F(RE(t2),taur); + IM(t2) = IM(cc[ac]) + IM(cc[ac+ido]); + IM(c2) = IM(cc[ac-ido]) + MUL_F(IM(t2),taur); + + RE(ch[ah]) = RE(cc[ac-ido]) + RE(t2); + IM(ch[ah]) = IM(cc[ac-ido]) + IM(t2); + + RE(c3) = MUL_F((RE(cc[ac]) - RE(cc[ac+ido])), taui); + IM(c3) = MUL_F((IM(cc[ac]) - IM(cc[ac+ido])), taui); + + RE(d2) = RE(c2) + IM(c3); + IM(d3) = IM(c2) + RE(c3); + RE(d3) = RE(c2) - IM(c3); + IM(d2) = IM(c2) - RE(c3); + + ComplexMult(&RE(ch[ah+l1*ido]), &IM(ch[ah+l1*ido]), + RE(d2), IM(d2), RE(wa1[i]), IM(wa1[i])); + ComplexMult(&RE(ch[ah+2*l1*ido]), &IM(ch[ah+2*l1*ido]), + RE(d3), IM(d3), RE(wa2[i]), IM(wa2[i])); + } + } + } + } +} - RE(t2) = RE(cc[ac]) + RE(cc[ac+ido]); - RE(c2) = RE(cc[ac-ido]) + MUL_R_C(RE(t2),taur); - IM(t2) = IM(cc[ac]) + IM(cc[ac+ido]); - IM(c2) = IM(cc[ac-ido]) + MUL_R_C(IM(t2),taur); +#ifdef USE_SSE +static void passf4pos_sse(const uint16_t ido, const uint16_t l1, const complex_t *cc, + complex_t *ch, const complex_t *wa1, const complex_t *wa2, + const complex_t *wa3) +{ + uint16_t i, k, ac, ah; - RE(ch[ah]) = RE(cc[ac-ido]) + RE(t2); - IM(ch[ah]) = IM(cc[ac-ido]) + IM(t2); + if (ido == 1) + { + for (k = 0; k < l1; k+=2) + { + __m128 m1, m2, m3, m4, m5, m6, m7, m8, m9, m10; + __m128 n1, n2, n3, n4, n5, n6, n7, n8, n9, n10; + __m128 neg1 = _mm_set_ps(-1.0, 1.0, 1.0, 1.0); - RE(c3) = MUL_R_C((RE(cc[ac]) - RE(cc[ac+ido])), taui)*isign; - IM(c3) = MUL_R_C((IM(cc[ac]) - IM(cc[ac+ido])), taui)*isign; + m1 = _mm_load_ps(&RE(cc[4*k])); + m2 = _mm_load_ps(&RE(cc[4*k+2])); + n1 = _mm_load_ps(&RE(cc[4*k+4])); + n2 = _mm_load_ps(&RE(cc[4*k+6])); - RE(d2) = RE(c2) - IM(c3); - IM(d3) = IM(c2) - RE(c3); - RE(d3) = RE(c2) + IM(c3); - IM(d2) = IM(c2) + RE(c3); + m3 = _mm_add_ps(m1, m2); - RE(ch[ah+l1*ido]) = MUL_R_C(RE(d2),RE(wa1[i])) - MUL_R_C(IM(d2),IM(wa1[i]))*isign; - IM(ch[ah+l1*ido]) = MUL_R_C(IM(d2),RE(wa1[i])) + MUL_R_C(RE(d2),IM(wa1[i]))*isign; - RE(ch[ah+l1*2*ido]) = MUL_R_C(RE(d3),RE(wa2[i])) - MUL_R_C(IM(d3),IM(wa2[i]))*isign; - IM(ch[ah+l1*2*ido]) = MUL_R_C(IM(d3),RE(wa2[i])) + MUL_R_C(RE(d3),IM(wa2[i]))*isign; + n4 = _mm_mul_ps(neg1, n1); + n5 = _mm_mul_ps(neg1, n2); + m4 = _mm_mul_ps(neg1, m1); + m5 = _mm_mul_ps(neg1, m2); + + n3 = _mm_add_ps(n1, n2); + m6 = _mm_sub_ps(m4, m5); + + m7 = _mm_shuffle_ps(m3, n3, _MM_SHUFFLE(1, 0, 1, 0)); + n6 = _mm_sub_ps(n4, n5); + m8 = _mm_shuffle_ps(m3, n3, _MM_SHUFFLE(3, 2, 3, 2)); + + n7 = _mm_shuffle_ps(m6, n6, _MM_SHUFFLE(1, 0, 1, 0)); + m9 = _mm_add_ps(m7, m8); + n8 = _mm_shuffle_ps(m6, n6, _MM_SHUFFLE(2, 3, 2, 3)); + + m10 = _mm_sub_ps(m7, m8); + n9 = _mm_add_ps(n7, n8); + + _mm_store_ps(&RE(ch[k]), m9); + n10 = _mm_sub_ps(n7, n8); + _mm_store_ps(&RE(ch[k+l1]), n9); + _mm_store_ps(&RE(ch[k+2*l1]), m10); + _mm_store_ps(&RE(ch[k+3*l1]), n10); + } + } else { + for (k = 0; k < l1; k++) + { + ac = 4*k*ido; + ah = k*ido; + + for (i = 0; i < ido; i+=2) + { + __m128 m1, m2, m3, m4, m5, m6, m7, m8, m9, m10, m11, m12, m13, m14, m15, m16; + __m128 n1, n2, n3, n4, n5, n6, n7, n8, n9, m17, m18, m19, m20, m21, m22, m23; + __m128 w1, w2, w3, w4, w5, w6, m24, m25, m26, m27, m28, m29, m30; + __m128 neg1 = _mm_set_ps(-1.0, 1.0, -1.0, 1.0); + + m1 = _mm_load_ps(&RE(cc[ac+i])); + m2 = _mm_load_ps(&RE(cc[ac+i+2*ido])); + m3 = _mm_add_ps(m1, m2); + m4 = _mm_sub_ps(m1, m2); + + n1 = _mm_load_ps(&RE(cc[ac+i+ido])); + n2 = _mm_load_ps(&RE(cc[ac+i+3*ido])); + n3 = _mm_add_ps(n1, n2); + + n4 = _mm_mul_ps(neg1, n1); + n5 = _mm_mul_ps(neg1, n2); + n6 = _mm_sub_ps(n4, n5); + + m5 = _mm_add_ps(m3, n3); + + n7 = _mm_shuffle_ps(n6, n6, _MM_SHUFFLE(2, 3, 0, 1)); + n8 = _mm_add_ps(m4, n7); + + m6 = _mm_sub_ps(m3, n3); + n9 = _mm_sub_ps(m4, n7); + + _mm_store_ps(&RE(ch[ah+i]), m5); + +#if 0 + static INLINE void ComplexMult(real_t *y1, real_t *y2, + real_t x1, real_t x2, real_t c1, real_t c2) + { + *y1 = MUL_F(x1, c1) + MUL_F(x2, c2); + *y2 = MUL_F(x2, c1) - MUL_F(x1, c2); + } + + m7.0 = RE(c2)*RE(wa1[i]) + m7.1 = IM(c2)*IM(wa1[i]) + m7.2 = RE(c6)*RE(wa1[i+1]) + m7.3 = IM(c6)*IM(wa1[i+1]) + + m8.0 = RE(c2)*IM(wa1[i]) + m8.1 = IM(c2)*RE(wa1[i]) + m8.2 = RE(c6)*IM(wa1[i+1]) + m8.3 = IM(c6)*RE(wa1[i+1]) + + RE(0) = m7.0 - m7.1 + IM(0) = m8.0 + m8.1 + RE(1) = m7.2 - m7.3 + IM(1) = m8.2 + m8.3 + +//// + RE(0) = RE(c2)*RE(wa1[i]) - IM(c2)*IM(wa1[i]) + IM(0) = RE(c2)*IM(wa1[i]) + IM(c2)*RE(wa1[i]) + RE(1) = RE(c6)*RE(wa1[i+1]) - IM(c6)*IM(wa1[i+1]) + IM(1) = RE(c6)*IM(wa1[i+1]) + IM(c6)*RE(wa1[i+1]) +#endif + + w1 = _mm_load_ps(&RE(wa1[i])); + w3 = _mm_load_ps(&RE(wa2[i])); + w5 = _mm_load_ps(&RE(wa3[i])); + + w2 = _mm_shuffle_ps(w1, w1, _MM_SHUFFLE(2, 3, 0, 1)); + w4 = _mm_shuffle_ps(w3, w3, _MM_SHUFFLE(2, 3, 0, 1)); + w6 = _mm_shuffle_ps(w5, w5, _MM_SHUFFLE(2, 3, 0, 1)); + + m7 = _mm_mul_ps(n8, w1); + m15 = _mm_mul_ps(m6, w3); + m23 = _mm_mul_ps(n9, w5); + m8 = _mm_mul_ps(n8, w2); + m16 = _mm_mul_ps(m6, w4); + m24 = _mm_mul_ps(n9, w6); + + m9 = _mm_shuffle_ps(m7, m8, _MM_SHUFFLE(2, 0, 2, 0)); + m17 = _mm_shuffle_ps(m15, m16, _MM_SHUFFLE(2, 0, 2, 0)); + m25 = _mm_shuffle_ps(m23, m24, _MM_SHUFFLE(2, 0, 2, 0)); + m10 = _mm_shuffle_ps(m7, m8, _MM_SHUFFLE(3, 1, 3, 1)); + m18 = _mm_shuffle_ps(m15, m16, _MM_SHUFFLE(3, 1, 3, 1)); + m26 = _mm_shuffle_ps(m23, m24, _MM_SHUFFLE(3, 1, 3, 1)); + + m11 = _mm_add_ps(m9, m10); + m19 = _mm_add_ps(m17, m18); + m27 = _mm_add_ps(m25, m26); + m12 = _mm_sub_ps(m9, m10); + m20 = _mm_sub_ps(m17, m18); + m28 = _mm_sub_ps(m25, m26); + + m13 = _mm_shuffle_ps(m11, m11, _MM_SHUFFLE(0, 0, 3, 2)); + m21 = _mm_shuffle_ps(m19, m19, _MM_SHUFFLE(0, 0, 3, 2)); + m29 = _mm_shuffle_ps(m27, m27, _MM_SHUFFLE(0, 0, 3, 2)); + m14 = _mm_unpacklo_ps(m12, m13); + m22 = _mm_unpacklo_ps(m20, m21); + m30 = _mm_unpacklo_ps(m28, m29); + + _mm_store_ps(&RE(ch[ah+i+l1*ido]), m14); + _mm_store_ps(&RE(ch[ah+i+2*l1*ido]), m22); + _mm_store_ps(&RE(ch[ah+i+3*l1*ido]), m30); } } } } +#endif - -static void passf4(uint16_t ido, uint16_t l1, complex_t *cc, complex_t *ch, - complex_t *wa1, complex_t *wa2, complex_t *wa3, int8_t isign) +static void passf4pos(const uint16_t ido, const uint16_t l1, const complex_t *cc, + complex_t *ch, const complex_t *wa1, const complex_t *wa2, + const complex_t *wa3) { uint16_t i, k, ac, ah; - complex_t c2, c3, c4, t1, t2, t3, t4; if (ido == 1) { for (k = 0; k < l1; k++) { + complex_t t1, t2, t3, t4; + ac = 4*k; ah = k; - RE(t2) = RE(cc[ac]) + RE(cc[ac+2]); - IM(t2) = IM(cc[ac]) + IM(cc[ac+2]); + RE(t2) = RE(cc[ac]) + RE(cc[ac+2]); + RE(t1) = RE(cc[ac]) - RE(cc[ac+2]); + IM(t2) = IM(cc[ac]) + IM(cc[ac+2]); + IM(t1) = IM(cc[ac]) - IM(cc[ac+2]); RE(t3) = RE(cc[ac+1]) + RE(cc[ac+3]); - IM(t3) = IM(cc[ac+1]) + IM(cc[ac+3]); - RE(t1) = RE(cc[ac]) - RE(cc[ac+2]); - IM(t1) = IM(cc[ac]) - IM(cc[ac+2]); - RE(t4) = IM(cc[ac+3]) - IM(cc[ac+1]); IM(t4) = RE(cc[ac+1]) - RE(cc[ac+3]); + IM(t3) = IM(cc[ac+3]) + IM(cc[ac+1]); + RE(t4) = IM(cc[ac+3]) - IM(cc[ac+1]); - RE(ch[ah]) = RE(t2) + RE(t3); - IM(ch[ah]) = IM(t2) + IM(t3); - RE(ch[ah+l1]) = RE(t1) + RE(t4)*isign; - IM(ch[ah+l1]) = IM(t1) + IM(t4)*isign; + RE(ch[ah]) = RE(t2) + RE(t3); RE(ch[ah+2*l1]) = RE(t2) - RE(t3); + + IM(ch[ah]) = IM(t2) + IM(t3); IM(ch[ah+2*l1]) = IM(t2) - IM(t3); - RE(ch[ah+3*l1]) = RE(t1) - RE(t4)*isign; - IM(ch[ah+3*l1]) = IM(t1) - IM(t4)*isign; + + RE(ch[ah+l1]) = RE(t1) + RE(t4); + RE(ch[ah+3*l1]) = RE(t1) - RE(t4); + + IM(ch[ah+l1]) = IM(t1) + IM(t4); + IM(ch[ah+3*l1]) = IM(t1) - IM(t4); } } else { for (k = 0; k < l1; k++) { + ac = 4*k*ido; + ah = k*ido; + for (i = 0; i < ido; i++) { - ac = i + 4*k*ido; - ah = i + k*ido; - - RE(t2) = RE(cc[ac]) + RE(cc[ac+2*ido]); - IM(t2) = IM(cc[ac]) + IM(cc[ac+2*ido]); - RE(t3) = RE(cc[ac+ido]) + RE(cc[ac+3*ido]); - IM(t3) = IM(cc[ac+ido]) + IM(cc[ac+3*ido]); - RE(t1) = RE(cc[ac]) - RE(cc[ac+2*ido]); - IM(t1) = IM(cc[ac]) - IM(cc[ac+2*ido]); - RE(t4) = IM(cc[ac+3*ido]) - IM(cc[ac+ido]); - IM(t4) = RE(cc[ac+ido]) - RE(cc[ac+3*ido]); - - RE(ch[ah]) = RE(t2) + RE(t3); - IM(ch[ah]) = IM(t2) + IM(t3); - - RE(c2) = RE(t1) + RE(t4)*isign; - IM(c2) = IM(t1) + IM(t4)*isign; - RE(c3) = RE(t2) - RE(t3); - IM(c3) = IM(t2) - IM(t3); - RE(c4) = RE(t1) - RE(t4)*isign; - IM(c4) = IM(t1) - IM(t4)*isign; - - RE(ch[ah+l1*ido]) = MUL_R_C(RE(c2),RE(wa1[i])) - MUL_R_C(IM(c2),IM(wa1[i]))*isign; - IM(ch[ah+l1*ido]) = MUL_R_C(IM(c2),RE(wa1[i])) + MUL_R_C(RE(c2),IM(wa1[i]))*isign; - RE(ch[ah+2*l1*ido]) = MUL_R_C(RE(c3),RE(wa2[i])) - MUL_R_C(IM(c3),IM(wa2[i]))*isign; - IM(ch[ah+2*l1*ido]) = MUL_R_C(IM(c3),RE(wa2[i])) + MUL_R_C(RE(c3),IM(wa2[i]))*isign; - RE(ch[ah+3*l1*ido]) = MUL_R_C(RE(c4),RE(wa3[i])) - MUL_R_C(IM(c4),IM(wa3[i]))*isign; - IM(ch[ah+3*l1*ido]) = MUL_R_C(IM(c4),RE(wa3[i])) + MUL_R_C(RE(c4),IM(wa3[i]))*isign; + complex_t c2, c3, c4, t1, t2, t3, t4; + + RE(t2) = RE(cc[ac+i]) + RE(cc[ac+i+2*ido]); + RE(t1) = RE(cc[ac+i]) - RE(cc[ac+i+2*ido]); + IM(t2) = IM(cc[ac+i]) + IM(cc[ac+i+2*ido]); + IM(t1) = IM(cc[ac+i]) - IM(cc[ac+i+2*ido]); + RE(t3) = RE(cc[ac+i+ido]) + RE(cc[ac+i+3*ido]); + IM(t4) = RE(cc[ac+i+ido]) - RE(cc[ac+i+3*ido]); + IM(t3) = IM(cc[ac+i+3*ido]) + IM(cc[ac+i+ido]); + RE(t4) = IM(cc[ac+i+3*ido]) - IM(cc[ac+i+ido]); + + RE(c2) = RE(t1) + RE(t4); + RE(c4) = RE(t1) - RE(t4); + + IM(c2) = IM(t1) + IM(t4); + IM(c4) = IM(t1) - IM(t4); + + RE(ch[ah+i]) = RE(t2) + RE(t3); + RE(c3) = RE(t2) - RE(t3); + + IM(ch[ah+i]) = IM(t2) + IM(t3); + IM(c3) = IM(t2) - IM(t3); + + ComplexMult(&IM(ch[ah+i+l1*ido]), &RE(ch[ah+i+l1*ido]), + IM(c2), RE(c2), RE(wa1[i]), IM(wa1[i])); + ComplexMult(&IM(ch[ah+i+2*l1*ido]), &RE(ch[ah+i+2*l1*ido]), + IM(c3), RE(c3), RE(wa2[i]), IM(wa2[i])); + ComplexMult(&IM(ch[ah+i+3*l1*ido]), &RE(ch[ah+i+3*l1*ido]), + IM(c4), RE(c4), RE(wa3[i]), IM(wa3[i])); } } } } - -static void passf5(uint16_t ido, uint16_t l1, complex_t *cc, complex_t *ch, - complex_t *wa1, complex_t *wa2, complex_t *wa3, complex_t *wa4, - int8_t isign) +static void passf4neg(const uint16_t ido, const uint16_t l1, const complex_t *cc, + complex_t *ch, const complex_t *wa1, const complex_t *wa2, + const complex_t *wa3) { - static real_t tr11 = COEF_CONST(0.309016994374947); - static real_t ti11 = COEF_CONST(0.951056516295154); - static real_t tr12 = COEF_CONST(-0.809016994374947); - static real_t ti12 = COEF_CONST(0.587785252292473); uint16_t i, k, ac, ah; - complex_t c2, c3, c4, c5, d3, d4, d5, d2, t2, t3, t4, t5; if (ido == 1) { for (k = 0; k < l1; k++) { - ac = 5*k + 1; + complex_t t1, t2, t3, t4; + + ac = 4*k; ah = k; - RE(t2) = RE(cc[ac]) + RE(cc[ac+3]); - IM(t2) = IM(cc[ac]) + IM(cc[ac+3]); - RE(t3) = RE(cc[ac+1]) + RE(cc[ac+2]); - IM(t3) = IM(cc[ac+1]) + IM(cc[ac+2]); - RE(t4) = RE(cc[ac+1]) - RE(cc[ac+2]); - IM(t4) = IM(cc[ac+1]) - IM(cc[ac+2]); - RE(t5) = RE(cc[ac]) - RE(cc[ac+3]); - IM(t5) = IM(cc[ac]) - IM(cc[ac+3]); - - RE(ch[ah]) = RE(cc[ac-1]) + RE(t2) + RE(t3); - IM(ch[ah]) = IM(cc[ac-1]) + IM(t2) + IM(t3); - - RE(c2) = RE(cc[ac-1]) + MUL_R_C(RE(t2),tr11) + MUL_R_C(RE(t3),tr12); - IM(c2) = IM(cc[ac-1]) + MUL_R_C(IM(t2),tr11) + MUL_R_C(IM(t3),tr12); - RE(c3) = RE(cc[ac-1]) + MUL_R_C(RE(t2),tr12) + MUL_R_C(RE(t3),tr11); - IM(c3) = IM(cc[ac-1]) + MUL_R_C(IM(t2),tr12) + MUL_R_C(IM(t3),tr11); - RE(c4) = (MUL_R_C(RE(t5),ti12)*isign - MUL_R_C(RE(t4),ti11)); - IM(c4) = (MUL_R_C(IM(t5),ti12)*isign - MUL_R_C(IM(t4),ti11)); - RE(c5) = (MUL_R_C(RE(t5),ti11)*isign + MUL_R_C(RE(t4),ti12)); - IM(c5) = (MUL_R_C(IM(t5),ti11)*isign + MUL_R_C(IM(t4),ti12)); - - RE(ch[ah+l1]) = RE(c2) - IM(c5); - IM(ch[ah+l1]) = IM(c2) + RE(c5); - RE(ch[ah+2*l1]) = RE(c3) - IM(c4); - IM(ch[ah+2*l1]) = IM(c3) + RE(c4); - RE(ch[ah+3*l1]) = RE(c3) + IM(c4); - IM(ch[ah+3*l1]) = IM(c3) - RE(c4); - RE(ch[ah+4*l1]) = RE(c2) + IM(c5); - IM(ch[ah+4*l1]) = IM(c2) - RE(c5); + RE(t2) = RE(cc[ac]) + RE(cc[ac+2]); + RE(t1) = RE(cc[ac]) - RE(cc[ac+2]); + IM(t2) = IM(cc[ac]) + IM(cc[ac+2]); + IM(t1) = IM(cc[ac]) - IM(cc[ac+2]); + RE(t3) = RE(cc[ac+1]) + RE(cc[ac+3]); + IM(t4) = RE(cc[ac+1]) - RE(cc[ac+3]); + IM(t3) = IM(cc[ac+3]) + IM(cc[ac+1]); + RE(t4) = IM(cc[ac+3]) - IM(cc[ac+1]); + + RE(ch[ah]) = RE(t2) + RE(t3); + RE(ch[ah+2*l1]) = RE(t2) - RE(t3); + + IM(ch[ah]) = IM(t2) + IM(t3); + IM(ch[ah+2*l1]) = IM(t2) - IM(t3); + + RE(ch[ah+l1]) = RE(t1) - RE(t4); + RE(ch[ah+3*l1]) = RE(t1) + RE(t4); + + IM(ch[ah+l1]) = IM(t1) - IM(t4); + IM(ch[ah+3*l1]) = IM(t1) + IM(t4); } } else { for (k = 0; k < l1; k++) { + ac = 4*k*ido; + ah = k*ido; + for (i = 0; i < ido; i++) { - ac = i + (k*5 + 1) * ido; - ah = i + k * ido; - - RE(t2) = RE(cc[ac]) + RE(cc[ac+3*ido]); - IM(t2) = IM(cc[ac]) + IM(cc[ac+3*ido]); - RE(t3) = RE(cc[ac+ido]) + RE(cc[ac+2*ido]); - IM(t3) = IM(cc[ac+ido]) + IM(cc[ac+2*ido]); - RE(t4) = RE(cc[ac+ido]) - RE(cc[ac+2*ido]); - IM(t4) = IM(cc[ac+ido]) - IM(cc[ac+2*ido]); - RE(t5) = RE(cc[ac]) - RE(cc[ac+3*ido]); - IM(t5) = IM(cc[ac]) - IM(cc[ac+3*ido]); - - RE(ch[ah]) = RE(cc[ac-ido]) + RE(t2) + RE(t3); - IM(ch[ah]) = IM(cc[ac-ido]) + IM(t2) + IM(t3); - - RE(c2) = RE(cc[ac-ido]) + MUL_R_C(RE(t2),tr11) + MUL_R_C(RE(t3),tr12); - IM(c2) = IM(cc[ac-ido]) + MUL_R_C(IM(t2),tr11) + MUL_R_C(IM(t3),tr12); - RE(c3) = RE(cc[ac-ido]) + MUL_R_C(RE(t2),tr12) + MUL_R_C(RE(t3),tr11); - IM(c3) = IM(cc[ac-ido]) + MUL_R_C(IM(t2),tr12) + MUL_R_C(IM(t3),tr11); - RE(c4) = (MUL_R_C(RE(t5),ti12)*isign - MUL_R_C(RE(t4),ti11)); - IM(c4) = (MUL_R_C(IM(t5),ti12)*isign - MUL_R_C(IM(t4),ti11)); - RE(c5) = (MUL_R_C(RE(t5),ti11)*isign + MUL_R_C(RE(t4),ti12)); - IM(c5) = (MUL_R_C(IM(t5),ti11)*isign + MUL_R_C(IM(t4),ti12)); - - IM(d2) = IM(c2) + RE(c5); - IM(d3) = IM(c3) + RE(c4); - RE(d4) = RE(c3) + IM(c4); - RE(d5) = RE(c2) + IM(c5); - RE(d2) = RE(c2) - IM(c5); - IM(d5) = IM(c2) - RE(c5); - RE(d3) = RE(c3) - IM(c4); - IM(d4) = IM(c3) - RE(c4); - - RE(ch[ah+l1*ido]) = MUL_R_C(RE(d2),RE(wa1[i])) - MUL_R_C(IM(d2),IM(wa1[i]))*isign; - IM(ch[ah+l1*ido]) = MUL_R_C(IM(d2),RE(wa1[i])) + MUL_R_C(RE(d2),IM(wa1[i]))*isign; - RE(ch[ah+2*l1*ido]) = MUL_R_C(RE(d3),RE(wa2[i])) - MUL_R_C(IM(d3),IM(wa2[i]))*isign; - IM(ch[ah+2*l1*ido]) = MUL_R_C(IM(d3),RE(wa2[i])) + MUL_R_C(RE(d3),IM(wa2[i]))*isign; - RE(ch[ah+3*l1*ido]) = MUL_R_C(RE(d4),RE(wa3[i])) - MUL_R_C(IM(d4),IM(wa3[i]))*isign; - IM(ch[ah+3*l1*ido]) = MUL_R_C(IM(d4),RE(wa3[i])) + MUL_R_C(RE(d4),IM(wa3[i]))*isign; - RE(ch[ah+4*l1*ido]) = MUL_R_C(RE(d5),RE(wa4[i])) - MUL_R_C(IM(d5),IM(wa4[i]))*isign; - IM(ch[ah+4*l1*ido]) = MUL_R_C(IM(d5),RE(wa4[i])) + MUL_R_C(RE(d5),IM(wa4[i]))*isign; + complex_t c2, c3, c4, t1, t2, t3, t4; + + RE(t2) = RE(cc[ac+i]) + RE(cc[ac+i+2*ido]); + RE(t1) = RE(cc[ac+i]) - RE(cc[ac+i+2*ido]); + IM(t2) = IM(cc[ac+i]) + IM(cc[ac+i+2*ido]); + IM(t1) = IM(cc[ac+i]) - IM(cc[ac+i+2*ido]); + RE(t3) = RE(cc[ac+i+ido]) + RE(cc[ac+i+3*ido]); + IM(t4) = RE(cc[ac+i+ido]) - RE(cc[ac+i+3*ido]); + IM(t3) = IM(cc[ac+i+3*ido]) + IM(cc[ac+i+ido]); + RE(t4) = IM(cc[ac+i+3*ido]) - IM(cc[ac+i+ido]); + + RE(c2) = RE(t1) - RE(t4); + RE(c4) = RE(t1) + RE(t4); + + IM(c2) = IM(t1) - IM(t4); + IM(c4) = IM(t1) + IM(t4); + + RE(ch[ah+i]) = RE(t2) + RE(t3); + RE(c3) = RE(t2) - RE(t3); + + IM(ch[ah+i]) = IM(t2) + IM(t3); + IM(c3) = IM(t2) - IM(t3); + + ComplexMult(&RE(ch[ah+i+l1*ido]), &IM(ch[ah+i+l1*ido]), + RE(c2), IM(c2), RE(wa1[i]), IM(wa1[i])); + ComplexMult(&RE(ch[ah+i+2*l1*ido]), &IM(ch[ah+i+2*l1*ido]), + RE(c3), IM(c3), RE(wa2[i]), IM(wa2[i])); + ComplexMult(&RE(ch[ah+i+3*l1*ido]), &IM(ch[ah+i+3*l1*ido]), + RE(c4), IM(c4), RE(wa3[i]), IM(wa3[i])); + } + } + } +} + +static void passf5(const uint16_t ido, const uint16_t l1, const complex_t *cc, + complex_t *ch, const complex_t *wa1, const complex_t *wa2, const complex_t *wa3, + const complex_t *wa4, const int8_t isign) +{ + static real_t tr11 = FRAC_CONST(0.309016994374947); + static real_t ti11 = FRAC_CONST(0.951056516295154); + static real_t tr12 = FRAC_CONST(-0.809016994374947); + static real_t ti12 = FRAC_CONST(0.587785252292473); + uint16_t i, k, ac, ah; + complex_t c2, c3, c4, c5, d3, d4, d5, d2, t2, t3, t4, t5; + + if (ido == 1) + { + if (isign == 1) + { + for (k = 0; k < l1; k++) + { + ac = 5*k + 1; + ah = k; + + RE(t2) = RE(cc[ac]) + RE(cc[ac+3]); + IM(t2) = IM(cc[ac]) + IM(cc[ac+3]); + RE(t3) = RE(cc[ac+1]) + RE(cc[ac+2]); + IM(t3) = IM(cc[ac+1]) + IM(cc[ac+2]); + RE(t4) = RE(cc[ac+1]) - RE(cc[ac+2]); + IM(t4) = IM(cc[ac+1]) - IM(cc[ac+2]); + RE(t5) = RE(cc[ac]) - RE(cc[ac+3]); + IM(t5) = IM(cc[ac]) - IM(cc[ac+3]); + + RE(ch[ah]) = RE(cc[ac-1]) + RE(t2) + RE(t3); + IM(ch[ah]) = IM(cc[ac-1]) + IM(t2) + IM(t3); + + RE(c2) = RE(cc[ac-1]) + MUL_F(RE(t2),tr11) + MUL_F(RE(t3),tr12); + IM(c2) = IM(cc[ac-1]) + MUL_F(IM(t2),tr11) + MUL_F(IM(t3),tr12); + RE(c3) = RE(cc[ac-1]) + MUL_F(RE(t2),tr12) + MUL_F(RE(t3),tr11); + IM(c3) = IM(cc[ac-1]) + MUL_F(IM(t2),tr12) + MUL_F(IM(t3),tr11); + + ComplexMult(&RE(c5), &RE(c4), + ti11, ti12, RE(t5), RE(t4)); + ComplexMult(&IM(c5), &IM(c4), + ti11, ti12, IM(t5), IM(t4)); + + RE(ch[ah+l1]) = RE(c2) - IM(c5); + IM(ch[ah+l1]) = IM(c2) + RE(c5); + RE(ch[ah+2*l1]) = RE(c3) - IM(c4); + IM(ch[ah+2*l1]) = IM(c3) + RE(c4); + RE(ch[ah+3*l1]) = RE(c3) + IM(c4); + IM(ch[ah+3*l1]) = IM(c3) - RE(c4); + RE(ch[ah+4*l1]) = RE(c2) + IM(c5); + IM(ch[ah+4*l1]) = IM(c2) - RE(c5); + } + } else { + for (k = 0; k < l1; k++) + { + ac = 5*k + 1; + ah = k; + + RE(t2) = RE(cc[ac]) + RE(cc[ac+3]); + IM(t2) = IM(cc[ac]) + IM(cc[ac+3]); + RE(t3) = RE(cc[ac+1]) + RE(cc[ac+2]); + IM(t3) = IM(cc[ac+1]) + IM(cc[ac+2]); + RE(t4) = RE(cc[ac+1]) - RE(cc[ac+2]); + IM(t4) = IM(cc[ac+1]) - IM(cc[ac+2]); + RE(t5) = RE(cc[ac]) - RE(cc[ac+3]); + IM(t5) = IM(cc[ac]) - IM(cc[ac+3]); + + RE(ch[ah]) = RE(cc[ac-1]) + RE(t2) + RE(t3); + IM(ch[ah]) = IM(cc[ac-1]) + IM(t2) + IM(t3); + + RE(c2) = RE(cc[ac-1]) + MUL_F(RE(t2),tr11) + MUL_F(RE(t3),tr12); + IM(c2) = IM(cc[ac-1]) + MUL_F(IM(t2),tr11) + MUL_F(IM(t3),tr12); + RE(c3) = RE(cc[ac-1]) + MUL_F(RE(t2),tr12) + MUL_F(RE(t3),tr11); + IM(c3) = IM(cc[ac-1]) + MUL_F(IM(t2),tr12) + MUL_F(IM(t3),tr11); + + ComplexMult(&RE(c4), &RE(c5), + ti12, ti11, RE(t5), RE(t4)); + ComplexMult(&IM(c4), &IM(c5), + ti12, ti12, IM(t5), IM(t4)); + + RE(ch[ah+l1]) = RE(c2) + IM(c5); + IM(ch[ah+l1]) = IM(c2) - RE(c5); + RE(ch[ah+2*l1]) = RE(c3) + IM(c4); + IM(ch[ah+2*l1]) = IM(c3) - RE(c4); + RE(ch[ah+3*l1]) = RE(c3) - IM(c4); + IM(ch[ah+3*l1]) = IM(c3) + RE(c4); + RE(ch[ah+4*l1]) = RE(c2) - IM(c5); + IM(ch[ah+4*l1]) = IM(c2) + RE(c5); + } + } + } else { + if (isign == 1) + { + for (k = 0; k < l1; k++) + { + for (i = 0; i < ido; i++) + { + ac = i + (k*5 + 1) * ido; + ah = i + k * ido; + + RE(t2) = RE(cc[ac]) + RE(cc[ac+3*ido]); + IM(t2) = IM(cc[ac]) + IM(cc[ac+3*ido]); + RE(t3) = RE(cc[ac+ido]) + RE(cc[ac+2*ido]); + IM(t3) = IM(cc[ac+ido]) + IM(cc[ac+2*ido]); + RE(t4) = RE(cc[ac+ido]) - RE(cc[ac+2*ido]); + IM(t4) = IM(cc[ac+ido]) - IM(cc[ac+2*ido]); + RE(t5) = RE(cc[ac]) - RE(cc[ac+3*ido]); + IM(t5) = IM(cc[ac]) - IM(cc[ac+3*ido]); + + RE(ch[ah]) = RE(cc[ac-ido]) + RE(t2) + RE(t3); + IM(ch[ah]) = IM(cc[ac-ido]) + IM(t2) + IM(t3); + + RE(c2) = RE(cc[ac-ido]) + MUL_F(RE(t2),tr11) + MUL_F(RE(t3),tr12); + IM(c2) = IM(cc[ac-ido]) + MUL_F(IM(t2),tr11) + MUL_F(IM(t3),tr12); + RE(c3) = RE(cc[ac-ido]) + MUL_F(RE(t2),tr12) + MUL_F(RE(t3),tr11); + IM(c3) = IM(cc[ac-ido]) + MUL_F(IM(t2),tr12) + MUL_F(IM(t3),tr11); + + ComplexMult(&RE(c5), &RE(c4), + ti11, ti12, RE(t5), RE(t4)); + ComplexMult(&IM(c5), &IM(c4), + ti11, ti12, IM(t5), IM(t4)); + + IM(d2) = IM(c2) + RE(c5); + IM(d3) = IM(c3) + RE(c4); + RE(d4) = RE(c3) + IM(c4); + RE(d5) = RE(c2) + IM(c5); + RE(d2) = RE(c2) - IM(c5); + IM(d5) = IM(c2) - RE(c5); + RE(d3) = RE(c3) - IM(c4); + IM(d4) = IM(c3) - RE(c4); + + ComplexMult(&IM(ch[ah+l1*ido]), &RE(ch[ah+l1*ido]), + IM(d2), RE(d2), RE(wa1[i]), IM(wa1[i])); + ComplexMult(&IM(ch[ah+2*l1*ido]), &RE(ch[ah+2*l1*ido]), + IM(d3), RE(d3), RE(wa2[i]), IM(wa2[i])); + ComplexMult(&IM(ch[ah+3*l1*ido]), &RE(ch[ah+3*l1*ido]), + IM(d4), RE(d4), RE(wa3[i]), IM(wa3[i])); + ComplexMult(&IM(ch[ah+4*l1*ido]), &RE(ch[ah+4*l1*ido]), + IM(d5), RE(d5), RE(wa4[i]), IM(wa4[i])); + } + } + } else { + for (k = 0; k < l1; k++) + { + for (i = 0; i < ido; i++) + { + ac = i + (k*5 + 1) * ido; + ah = i + k * ido; + + RE(t2) = RE(cc[ac]) + RE(cc[ac+3*ido]); + IM(t2) = IM(cc[ac]) + IM(cc[ac+3*ido]); + RE(t3) = RE(cc[ac+ido]) + RE(cc[ac+2*ido]); + IM(t3) = IM(cc[ac+ido]) + IM(cc[ac+2*ido]); + RE(t4) = RE(cc[ac+ido]) - RE(cc[ac+2*ido]); + IM(t4) = IM(cc[ac+ido]) - IM(cc[ac+2*ido]); + RE(t5) = RE(cc[ac]) - RE(cc[ac+3*ido]); + IM(t5) = IM(cc[ac]) - IM(cc[ac+3*ido]); + + RE(ch[ah]) = RE(cc[ac-ido]) + RE(t2) + RE(t3); + IM(ch[ah]) = IM(cc[ac-ido]) + IM(t2) + IM(t3); + + RE(c2) = RE(cc[ac-ido]) + MUL_F(RE(t2),tr11) + MUL_F(RE(t3),tr12); + IM(c2) = IM(cc[ac-ido]) + MUL_F(IM(t2),tr11) + MUL_F(IM(t3),tr12); + RE(c3) = RE(cc[ac-ido]) + MUL_F(RE(t2),tr12) + MUL_F(RE(t3),tr11); + IM(c3) = IM(cc[ac-ido]) + MUL_F(IM(t2),tr12) + MUL_F(IM(t3),tr11); + + ComplexMult(&RE(c4), &RE(c5), + ti12, ti11, RE(t5), RE(t4)); + ComplexMult(&IM(c4), &IM(c5), + ti12, ti12, IM(t5), IM(t4)); + + IM(d2) = IM(c2) - RE(c5); + IM(d3) = IM(c3) - RE(c4); + RE(d4) = RE(c3) - IM(c4); + RE(d5) = RE(c2) - IM(c5); + RE(d2) = RE(c2) + IM(c5); + IM(d5) = IM(c2) + RE(c5); + RE(d3) = RE(c3) + IM(c4); + IM(d4) = IM(c3) + RE(c4); + + ComplexMult(&RE(ch[ah+l1*ido]), &IM(ch[ah+l1*ido]), + RE(d2), IM(d2), RE(wa1[i]), IM(wa1[i])); + ComplexMult(&RE(ch[ah+2*l1*ido]), &IM(ch[ah+2*l1*ido]), + RE(d3), IM(d3), RE(wa2[i]), IM(wa2[i])); + ComplexMult(&RE(ch[ah+3*l1*ido]), &IM(ch[ah+3*l1*ido]), + RE(d4), IM(d4), RE(wa3[i]), IM(wa3[i])); + ComplexMult(&RE(ch[ah+4*l1*ido]), &IM(ch[ah+4*l1*ido]), + RE(d5), IM(d5), RE(wa4[i]), IM(wa4[i])); + } } } } @@ -338,8 +842,9 @@ static void passf5(uint16_t ido, uint16_t l1, complex_t *cc, complex_t *ch, cfftf1, cfftf, cfftb, cffti1, cffti. Complex FFTs. ----------------------------------------------------------------------*/ -INLINE void cfftf1(uint16_t n, complex_t *c, complex_t *ch, - uint16_t *ifac, complex_t *wa, int8_t isign) +#ifdef USE_SSE +INLINE void cfftf1pos_sse(uint16_t n, complex_t *c, complex_t *ch, + const uint16_t *ifac, const complex_t *wa, const int8_t isign) { uint16_t i; uint16_t k1, l1, l2; @@ -359,11 +864,22 @@ INLINE void cfftf1(uint16_t n, complex_t *c, complex_t *ch, switch (ip) { + case 4: + ix2 = iw + ido; + ix3 = ix2 + ido; + + if (na == 0) + passf4pos_sse((const uint16_t)ido, (const uint16_t)l1, (const complex_t*)c, ch, &wa[iw], &wa[ix2], &wa[ix3]); + else + passf4pos_sse((const uint16_t)ido, (const uint16_t)l1, (const complex_t*)ch, c, &wa[iw], &wa[ix2], &wa[ix3]); + + na = 1 - na; + break; case 2: if (na == 0) - passf2(ido, l1, c, ch, &wa[iw], isign); + passf2pos_sse((const uint16_t)ido, (const uint16_t)l1, (const complex_t*)c, ch, &wa[iw]); else - passf2(ido, l1, ch, c, &wa[iw], isign); + passf2pos_sse((const uint16_t)ido, (const uint16_t)l1, (const complex_t*)ch, c, &wa[iw]); na = 1 - na; break; @@ -371,20 +887,88 @@ INLINE void cfftf1(uint16_t n, complex_t *c, complex_t *ch, ix2 = iw + ido; if (na == 0) - passf3(ido, l1, c, ch, &wa[iw], &wa[ix2], isign); + passf3((const uint16_t)ido, (const uint16_t)l1, (const complex_t*)c, ch, &wa[iw], &wa[ix2], isign); else - passf3(ido, l1, ch, c, &wa[iw], &wa[ix2], isign); + passf3((const uint16_t)ido, (const uint16_t)l1, (const complex_t*)ch, c, &wa[iw], &wa[ix2], isign); na = 1 - na; break; + case 5: + ix2 = iw + ido; + ix3 = ix2 + ido; + ix4 = ix3 + ido; + + if (na == 0) + passf5((const uint16_t)ido, (const uint16_t)l1, (const complex_t*)c, ch, &wa[iw], &wa[ix2], &wa[ix3], &wa[ix4], isign); + else + passf5((const uint16_t)ido, (const uint16_t)l1, (const complex_t*)ch, c, &wa[iw], &wa[ix2], &wa[ix3], &wa[ix4], isign); + + na = 1 - na; + break; + } + + l1 = l2; + iw += (ip-1) * ido; + } + + if (na == 0) + return; + + for (i = 0; i < n; i++) + { + RE(c[i]) = RE(ch[i]); + IM(c[i]) = IM(ch[i]); + } +} +#endif + +INLINE void cfftf1pos(uint16_t n, complex_t *c, complex_t *ch, + const uint16_t *ifac, const complex_t *wa, const int8_t isign) +{ + uint16_t i; + uint16_t k1, l1, l2; + uint16_t na, nf, ip, iw, ix2, ix3, ix4, ido, idl1; + + nf = ifac[1]; + na = 0; + l1 = 1; + iw = 0; + + for (k1 = 2; k1 <= nf+1; k1++) + { + ip = ifac[k1]; + l2 = ip*l1; + ido = n / l2; + idl1 = ido*l1; + + switch (ip) + { case 4: ix2 = iw + ido; ix3 = ix2 + ido; if (na == 0) - passf4(ido, l1, c, ch, &wa[iw], &wa[ix2], &wa[ix3], isign); + passf4pos((const uint16_t)ido, (const uint16_t)l1, (const complex_t*)c, ch, &wa[iw], &wa[ix2], &wa[ix3]); else - passf4(ido, l1, ch, c, &wa[iw], &wa[ix2], &wa[ix3], isign); + passf4pos((const uint16_t)ido, (const uint16_t)l1, (const complex_t*)ch, c, &wa[iw], &wa[ix2], &wa[ix3]); + + na = 1 - na; + break; + case 2: + if (na == 0) + passf2pos((const uint16_t)ido, (const uint16_t)l1, (const complex_t*)c, ch, &wa[iw]); + else + passf2pos((const uint16_t)ido, (const uint16_t)l1, (const complex_t*)ch, c, &wa[iw]); + + na = 1 - na; + break; + case 3: + ix2 = iw + ido; + + if (na == 0) + passf3((const uint16_t)ido, (const uint16_t)l1, (const complex_t*)c, ch, &wa[iw], &wa[ix2], isign); + else + passf3((const uint16_t)ido, (const uint16_t)l1, (const complex_t*)ch, c, &wa[iw], &wa[ix2], isign); na = 1 - na; break; @@ -394,9 +978,87 @@ INLINE void cfftf1(uint16_t n, complex_t *c, complex_t *ch, ix4 = ix3 + ido; if (na == 0) - passf5(ido, l1, c, ch, &wa[iw], &wa[ix2], &wa[ix3], &wa[ix4], isign); + passf5((const uint16_t)ido, (const uint16_t)l1, (const complex_t*)c, ch, &wa[iw], &wa[ix2], &wa[ix3], &wa[ix4], isign); else - passf5(ido, l1, ch, c, &wa[iw], &wa[ix2], &wa[ix3], &wa[ix4], isign); + passf5((const uint16_t)ido, (const uint16_t)l1, (const complex_t*)ch, c, &wa[iw], &wa[ix2], &wa[ix3], &wa[ix4], isign); + + na = 1 - na; + break; + } + + l1 = l2; + iw += (ip-1) * ido; + } + + if (na == 0) + return; + + for (i = 0; i < n; i++) + { + RE(c[i]) = RE(ch[i]); + IM(c[i]) = IM(ch[i]); + } +} + +INLINE void cfftf1neg(uint16_t n, complex_t *c, complex_t *ch, + const uint16_t *ifac, const complex_t *wa, const int8_t isign) +{ + uint16_t i; + uint16_t k1, l1, l2; + uint16_t na, nf, ip, iw, ix2, ix3, ix4, ido, idl1; + + nf = ifac[1]; + na = 0; + l1 = 1; + iw = 0; + + for (k1 = 2; k1 <= nf+1; k1++) + { + ip = ifac[k1]; + l2 = ip*l1; + ido = n / l2; + idl1 = ido*l1; + + switch (ip) + { + case 4: + ix2 = iw + ido; + ix3 = ix2 + ido; + + if (na == 0) + passf4neg((const uint16_t)ido, (const uint16_t)l1, (const complex_t*)c, ch, &wa[iw], &wa[ix2], &wa[ix3]); + else + passf4neg((const uint16_t)ido, (const uint16_t)l1, (const complex_t*)ch, c, &wa[iw], &wa[ix2], &wa[ix3]); + + na = 1 - na; + break; + case 2: + if (na == 0) + passf2neg((const uint16_t)ido, (const uint16_t)l1, (const complex_t*)c, ch, &wa[iw]); + else + passf2neg((const uint16_t)ido, (const uint16_t)l1, (const complex_t*)ch, c, &wa[iw]); + + na = 1 - na; + break; + case 3: + ix2 = iw + ido; + + if (na == 0) + passf3((const uint16_t)ido, (const uint16_t)l1, (const complex_t*)c, ch, &wa[iw], &wa[ix2], isign); + else + passf3((const uint16_t)ido, (const uint16_t)l1, (const complex_t*)ch, c, &wa[iw], &wa[ix2], isign); + + na = 1 - na; + break; + case 5: + ix2 = iw + ido; + ix3 = ix2 + ido; + ix4 = ix3 + ido; + + if (na == 0) + passf5((const uint16_t)ido, (const uint16_t)l1, (const complex_t*)c, ch, &wa[iw], &wa[ix2], &wa[ix3], &wa[ix4], isign); + else + passf5((const uint16_t)ido, (const uint16_t)l1, (const complex_t*)ch, c, &wa[iw], &wa[ix2], &wa[ix3], &wa[ix4], isign); na = 1 - na; break; @@ -418,14 +1080,21 @@ INLINE void cfftf1(uint16_t n, complex_t *c, complex_t *ch, void cfftf(cfft_info *cfft, complex_t *c) { - cfftf1(cfft->n, c, cfft->work, cfft->ifac, cfft->tab, -1); + cfftf1neg(cfft->n, c, cfft->work, (const uint16_t*)cfft->ifac, (const complex_t*)cfft->tab, -1); } void cfftb(cfft_info *cfft, complex_t *c) { - cfftf1(cfft->n, c, cfft->work, cfft->ifac, cfft->tab, +1); + cfftf1pos(cfft->n, c, cfft->work, (const uint16_t*)cfft->ifac, (const complex_t*)cfft->tab, +1); } +#ifdef USE_SSE +void cfftb_sse(cfft_info *cfft, complex_t *c) +{ + cfftf1pos_sse(cfft->n, c, cfft->work, (const uint16_t*)cfft->ifac, (const complex_t*)cfft->tab, +1); +} +#endif + static void cffti1(uint16_t n, complex_t *wa, uint16_t *ifac) { static uint16_t ntryh[4] = {3, 4, 2, 5}; @@ -478,7 +1147,7 @@ startloop: ifac[1] = nf; #ifndef FIXED_POINT - argh = 2.0*M_PI / (real_t)n; + argh = (real_t)2.0*(real_t)M_PI / (real_t)n; i = 0; l1 = 1; @@ -504,8 +1173,8 @@ startloop: i++; fi++; arg = fi * argld; - RE(wa[i]) = cos(arg); - IM(wa[i]) = sin(arg); + RE(wa[i]) = (real_t)cos(arg); + IM(wa[i]) = (real_t)sin(arg); } if (ip > 5) @@ -521,13 +1190,13 @@ startloop: cfft_info *cffti(uint16_t n) { - cfft_info *cfft = (cfft_info*)malloc(sizeof(cfft_info)); + cfft_info *cfft = (cfft_info*)faad_malloc(sizeof(cfft_info)); cfft->n = n; - cfft->work = (complex_t*)malloc(n*sizeof(complex_t)); + cfft->work = (complex_t*)faad_malloc(n*sizeof(complex_t)); #ifndef FIXED_POINT - cfft->tab = (complex_t*)malloc(n*sizeof(complex_t)); + cfft->tab = (complex_t*)faad_malloc(n*sizeof(complex_t)); cffti1(n, cfft->tab, cfft->ifac); #else @@ -535,14 +1204,19 @@ cfft_info *cffti(uint16_t n) switch (n) { - case 60: cfft->tab = cfft_tab_60; break; case 64: cfft->tab = cfft_tab_64; break; - case 480: cfft->tab = cfft_tab_480; break; case 512: cfft->tab = cfft_tab_512; break; #ifdef LD_DEC - case 240: cfft->tab = cfft_tab_240; break; case 256: cfft->tab = cfft_tab_256; break; #endif + +#ifdef ALLOW_SMALL_FRAMELENGTH + case 60: cfft->tab = cfft_tab_60; break; + case 480: cfft->tab = cfft_tab_480; break; +#ifdef LD_DEC + case 240: cfft->tab = cfft_tab_240; break; +#endif +#endif } #endif @@ -551,11 +1225,11 @@ cfft_info *cffti(uint16_t n) void cfftu(cfft_info *cfft) { - if (cfft->work) free(cfft->work); + if (cfft->work) faad_free(cfft->work); #ifndef FIXED_POINT - if (cfft->tab) free(cfft->tab); + if (cfft->tab) faad_free(cfft->tab); #endif - if (cfft) free(cfft); + if (cfft) faad_free(cfft); } diff --git a/src/libfaad/cfft.h b/src/libfaad/cfft.h index 4b2d9f544..74c42a91a 100644 --- a/src/libfaad/cfft.h +++ b/src/libfaad/cfft.h @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: cfft.h,v 1.4 2003/04/12 14:58:46 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: cfft.h,v 1.5 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #ifndef __CFFT_H__ @@ -26,6 +32,14 @@ extern "C" { #endif +typedef struct +{ + uint16_t n; + uint16_t ifac[15]; + complex_t *work; + complex_t *tab; +} cfft_info; + void cfftf(cfft_info *cfft, complex_t *c); void cfftb(cfft_info *cfft, complex_t *c); @@ -33,7 +47,29 @@ cfft_info *cffti(uint16_t n); void cfftu(cfft_info *cfft); -/* static declarations moved to avoid compiler warnings [MF] */ +#ifdef USE_SSE +void cfftb_sse(cfft_info *cfft, complex_t *c); +static void passf2pos_sse(const uint16_t ido, const uint16_t l1, const complex_t *cc, + complex_t *ch, const complex_t *wa); +static void passf4pos_sse(const uint16_t ido, const uint16_t l1, const complex_t *cc, complex_t *ch, + const complex_t *wa1, const complex_t *wa2, const complex_t *wa3); +#endif +static void passf2pos(const uint16_t ido, const uint16_t l1, const complex_t *cc, + complex_t *ch, const complex_t *wa); +static void passf2neg(const uint16_t ido, const uint16_t l1, const complex_t *cc, + complex_t *ch, const complex_t *wa); +static void passf3(const uint16_t ido, const uint16_t l1, const complex_t *cc, + complex_t *ch, const complex_t *wa1, const complex_t *wa2, const int8_t isign); +static void passf4pos(const uint16_t ido, const uint16_t l1, const complex_t *cc, complex_t *ch, + const complex_t *wa1, const complex_t *wa2, const complex_t *wa3); +static void passf4neg(const uint16_t ido, const uint16_t l1, const complex_t *cc, complex_t *ch, + const complex_t *wa1, const complex_t *wa2, const complex_t *wa3); +static void passf5(const uint16_t ido, const uint16_t l1, const complex_t *cc, complex_t *ch, + const complex_t *wa1, const complex_t *wa2, const complex_t *wa3, + const complex_t *wa4, const int8_t isign); +INLINE void cfftf1(uint16_t n, complex_t *c, complex_t *ch, + const uint16_t *ifac, const complex_t *wa, const int8_t isign); +static void cffti1(uint16_t n, complex_t *wa, uint16_t *ifac); #ifdef __cplusplus diff --git a/src/libfaad/cfft_tab.h b/src/libfaad/cfft_tab.h index f504fd074..dabc0dcc3 100644 --- a/src/libfaad/cfft_tab.h +++ b/src/libfaad/cfft_tab.h @@ -1,22 +1,28 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker -** +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. -** +** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. -** +** ** You should have received a copy of the GNU General Public License -** along with this program; if not, write to the Free Software +** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: cfft_tab.h,v 1.1 2002/12/16 18:59:56 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: cfft_tab.h,v 1.2 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #ifndef __CFFT_TAB_H__ @@ -28,1643 +34,1649 @@ extern "C" { #ifdef FIXED_POINT -complex_t cfft_tab_512[] = +ALIGN static const complex_t cfft_tab_512[] = { - { 0x10000000, 0x0 }, - { 0xFFFB110, 0x3243A4 }, - { 0xFFEC430, 0x648558 }, - { 0xFFD3970, 0x96C32C }, - { 0xFFB10F0, 0xC8FB30 }, - { 0xFF84AB0, 0xFB2B75 }, - { 0xFF4E6D0, 0x12D520A }, - { 0xFF0E580, 0x15F6D02 }, - { 0xFEC46D0, 0x1917A6C }, - { 0xFE70B00, 0x1C3785C }, - { 0xFE13240, 0x1F564E6 }, - { 0xFDABCC0, 0x2273E1C }, - { 0xFD3AAC0, 0x259020C }, - { 0xFCBFC90, 0x28AAED8 }, - { 0xFC3B280, 0x2BC428C }, - { 0xFBACCD0, 0x2EDBB3C }, - { 0xFB14BE0, 0x31F1708 }, - { 0xFA73020, 0x3505408 }, - { 0xF9C79D0, 0x381704C }, - { 0xF912980, 0x3B26A00 }, - { 0xF853F80, 0x3E33F34 }, - { 0xF78BC50, 0x413EE08 }, - { 0xF6BA070, 0x44474A0 }, - { 0xF5DEC60, 0x474D110 }, - { 0xF4FA0B0, 0x4A50188 }, - { 0xF40BDD0, 0x4D50430 }, - { 0xF314470, 0x504D728 }, - { 0xF213520, 0x5347898 }, - { 0xF109080, 0x563E6A0 }, - { 0xEFF5730, 0x5931F78 }, - { 0xEED89E0, 0x5C22150 }, - { 0xEDB2930, 0x5F0EA50 }, - { 0xEC835E0, 0x61F78B0 }, - { 0xEB4B0C0, 0x64DCAA0 }, - { 0xEA09A60, 0x67BDE58 }, - { 0xE8BF3B0, 0x6A9B210 }, - { 0xE76BD80, 0x6D74400 }, - { 0xE60F880, 0x7049278 }, - { 0xE4AA590, 0x7319BA8 }, - { 0xE33C5A0, 0x75E5DD8 }, - { 0xE1C5970, 0x78AD750 }, - { 0xE046210, 0x7B70650 }, - { 0xDEBE050, 0x7E2E940 }, - { 0xDD2D530, 0x80E7E40 }, - { 0xDB941A0, 0x839C3D0 }, - { 0xD9F26A0, 0x864B830 }, - { 0xD848530, 0x88F59B0 }, - { 0xD695E50, 0x8B9A6B0 }, - { 0xD4DB310, 0x8E39DA0 }, - { 0xD318480, 0x90D3CD0 }, - { 0xD14D3D0, 0x93682B0 }, - { 0xCF7A1F0, 0x95F6DA0 }, - { 0xCD9F020, 0x987FC00 }, - { 0xCBBBF80, 0x9B02C50 }, - { 0xC9D1120, 0x9D7FD20 }, - { 0xC7DE650, 0x9FF6CB0 }, - { 0xC5E4030, 0xA2679A0 }, - { 0xC3E2000, 0xA4D2250 }, - { 0xC1D8700, 0xA736560 }, - { 0xBFC7670, 0xA994150 }, - { 0xBDAEF90, 0xABEB4A0 }, - { 0xBB8F3B0, 0xAE3BDE0 }, - { 0xB968420, 0xB085BB0 }, - { 0xB73A220, 0xB2C8CA0 }, - { 0xB504F30, 0xB504F30 }, - { 0xB2C8C90, 0xB73A230 }, - { 0xB085BA0, 0xB968420 }, - { 0xAE3BDE0, 0xBB8F3B0 }, - { 0xABEB490, 0xBDAEFA0 }, - { 0xA994140, 0xBFC7670 }, - { 0xA736550, 0xC1D8710 }, - { 0xA4D2250, 0xC3E2010 }, - { 0xA267990, 0xC5E4030 }, - { 0x9FF6CA0, 0xC7DE660 }, - { 0x9D7FD10, 0xC9D1120 }, - { 0x9B02C50, 0xCBBBF80 }, - { 0x987FC00, 0xCD9F020 }, - { 0x95F6D90, 0xCF7A1F0 }, - { 0x93682A0, 0xD14D3D0 }, - { 0x90D3CD0, 0xD318490 }, - { 0x8E39D90, 0xD4DB320 }, - { 0x8B9A6B0, 0xD695E50 }, - { 0x88F59B0, 0xD848530 }, - { 0x864B820, 0xD9F26A0 }, - { 0x839C3C0, 0xDB941B0 }, - { 0x80E7E50, 0xDD2D530 }, - { 0x7E2E938, 0xDEBE050 }, - { 0x7B70648, 0xE046220 }, - { 0x78AD738, 0xE1C5980 }, - { 0x75E5DD8, 0xE33C5A0 }, - { 0x7319BA0, 0xE4AA590 }, - { 0x7049268, 0xE60F880 }, - { 0x6D74408, 0xE76BD80 }, - { 0x6A9B208, 0xE8BF3C0 }, - { 0x67BDE48, 0xEA09A70 }, - { 0x64DCA80, 0xEB4B0C0 }, - { 0x61F78A8, 0xEC835E0 }, - { 0x5F0EA40, 0xEDB2930 }, - { 0x5C22138, 0xEED89E0 }, - { 0x5931F78, 0xEFF5730 }, - { 0x563E698, 0xF109080 }, - { 0x5347880, 0xF213530 }, - { 0x504D710, 0xF314480 }, - { 0x4D50430, 0xF40BDD0 }, - { 0x4A50180, 0xF4FA0B0 }, - { 0x474D0F8, 0xF5DEC70 }, - { 0x4447498, 0xF6BA070 }, - { 0x413EE00, 0xF78BC50 }, - { 0x3E33F20, 0xF853F80 }, - { 0x3B26A04, 0xF912980 }, - { 0x3817048, 0xF9C79D0 }, - { 0x35053F8, 0xFA73020 }, - { 0x31F16F0, 0xFB14BF0 }, - { 0x2EDBB3C, 0xFBACCD0 }, - { 0x2BC4280, 0xFC3B280 }, - { 0x28AAEC4, 0xFCBFC90 }, - { 0x2590214, 0xFD3AAC0 }, - { 0x2273E14, 0xFDABCC0 }, - { 0x1F564D8, 0xFE13240 }, - { 0x1C37844, 0xFE70B00 }, - { 0x1917A6A, 0xFEC46D0 }, - { 0x15F6CF6, 0xFF0E580 }, - { 0x12D51F6, 0xFF4E6D0 }, - { 0xFB2B77, 0xFF84AB0 }, - { 0xC8FB29, 0xFFB10F0 }, - { 0x96C31C, 0xFFD3980 }, - { 0x64853F, 0xFFEC430 }, - { 0x3243A1, 0xFFFB110 }, - { 0xFFFFFFF5, 0x10000000 }, - { 0xFFCDBC47, 0xFFFB110 }, - { 0xFF9B7AAA, 0xFFEC430 }, - { 0xFF693CCD, 0xFFD3970 }, - { 0xFF3704BF, 0xFFB10F0 }, - { 0xFF04D472, 0xFF84AB0 }, - { 0xFED2ADF4, 0xFF4E6D0 }, - { 0xFEA092F2, 0xFF0E580 }, - { 0xFE6E857E, 0xFEC46D0 }, - { 0xFE3C87A4, 0xFE70B00 }, - { 0xFE0A9B12, 0xFE13230 }, - { 0xFDD8C1D4, 0xFDABCB0 }, - { 0xFDA6FDD8, 0xFD3AAC0 }, - { 0xFD755124, 0xFCBFC90 }, - { 0xFD43BD68, 0xFC3B280 }, - { 0xFD1244AC, 0xFBACCD0 }, - { 0xFCE0E8F8, 0xFB14BE0 }, - { 0xFCAFABF0, 0xFA73020 }, - { 0xFC7E8FA0, 0xF9C79D0 }, - { 0xFC4D95E8, 0xF912970 }, - { 0xFC1CC0CC, 0xF853F80 }, - { 0xFBEC11F0, 0xF78BC50 }, - { 0xFBBB8B50, 0xF6BA070 }, - { 0xFB8B2EF0, 0xF5DEC60 }, - { 0xFB5AFE68, 0xF4FA0A0 }, - { 0xFB2AFBB8, 0xF40BDD0 }, - { 0xFAFB28E0, 0xF314470 }, - { 0xFACB8768, 0xF213520 }, - { 0xFA9C1950, 0xF109080 }, - { 0xFA6CE070, 0xEFF5720 }, - { 0xFA3DDEB0, 0xEED89E0 }, - { 0xFA0F15A8, 0xEDB2930 }, - { 0xF9E08740, 0xEC835E0 }, - { 0xF9B23568, 0xEB4B0C0 }, - { 0xF98421A8, 0xEA09A60 }, - { 0xF9564E00, 0xE8BF3C0 }, - { 0xF928BC00, 0xE76BD80 }, - { 0xF8FB6D88, 0xE60F870 }, - { 0xF8CE6450, 0xE4AA590 }, - { 0xF8A1A210, 0xE33C590 }, - { 0xF8752898, 0xE1C5970 }, - { 0xF848F988, 0xE046200 }, - { 0xF81D16D0, 0xDEBE060 }, - { 0xF7F181C0, 0xDD2D530 }, - { 0xF7C63C30, 0xDB941A0 }, - { 0xF79B47D0, 0xD9F2690 }, - { 0xF770A640, 0xD848520 }, - { 0xF7465930, 0xD695E40 }, - { 0xF71C6240, 0xD4DB300 }, - { 0xF6F2C340, 0xD318490 }, - { 0xF6C97D60, 0xD14D3D0 }, - { 0xF6A09260, 0xCF7A1F0 }, - { 0xF67803F0, 0xCD9F020 }, - { 0xF64FD390, 0xCBBBF70 }, - { 0xF62802D0, 0xC9D1110 }, - { 0xF6009330, 0xC7DE630 }, - { 0xF5D98670, 0xC5E4040 }, - { 0xF5B2DDB0, 0xC3E2000 }, - { 0xF58C9AA0, 0xC1D8700 }, - { 0xF566BEB0, 0xBFC7660 }, - { 0xF5414B50, 0xBDAEF80 }, - { 0xF51C4200, 0xBB8F390 }, - { 0xF4F7A430, 0xB968400 }, - { 0xF4D37370, 0xB73A230 }, - { 0xF4AFB0D0, 0xB504F30 }, - { 0xF48C5DD0, 0xB2C8C90 }, - { 0xF4697BD0, 0xB085BA0 }, - { 0xF4470C40, 0xAE3BDD0 }, - { 0xF4251050, 0xABEB480 }, - { 0xF4038970, 0xA994120 }, - { 0xF3E27900, 0xA736560 }, - { 0xF3C1DFF0, 0xA4D2250 }, - { 0xF3A1BFC0, 0xA267990 }, - { 0xF38219A0, 0x9FF6CA0 }, - { 0xF362EED0, 0x9D7FD00 }, - { 0xF3444070, 0x9B02C40 }, - { 0xF3260FC0, 0x987FBD0 }, - { 0xF3085E10, 0x95F6D90 }, - { 0xF2EB2C30, 0x93682A0 }, - { 0xF2CE7B70, 0x90D3CC0 }, - { 0xF2B24CE0, 0x8E39D90 }, - { 0xF296A1A0, 0x8B9A690 }, - { 0xF27B7AC0, 0x88F5980 }, - { 0xF260D940, 0x864B800 }, - { 0xF246BE60, 0x839C3D0 }, - { 0xF22D2AD0, 0x80E7E40 }, - { 0xF2141FA0, 0x7E2E928 }, - { 0xF1FB9DE0, 0x7B70640 }, - { 0xF1E3A670, 0x78AD730 }, - { 0xF1CC3A50, 0x75E5DB0 }, - { 0xF1B55A70, 0x7319BB0 }, - { 0xF19F0780, 0x7049278 }, - { 0xF1894280, 0x6D743F8 }, - { 0xF1740C40, 0x6A9B1F8 }, - { 0xF15F6590, 0x67BDE38 }, - { 0xF14B4F40, 0x64DCA78 }, - { 0xF137CA00, 0x61F7880 }, - { 0xF124D6D0, 0x5F0EA58 }, - { 0xF1127620, 0x5C22150 }, - { 0xF100A8D0, 0x5931F70 }, - { 0xF0EF6F70, 0x563E690 }, - { 0xF0DECAD0, 0x5347878 }, - { 0xF0CEBB80, 0x504D700 }, - { 0xF0BF4220, 0x4D50408 }, - { 0xF0B05F50, 0x4A50198 }, - { 0xF0A213A0, 0x474D110 }, - { 0xF0945F90, 0x4447490 }, - { 0xF08743B0, 0x413EDF0 }, - { 0xF07AC080, 0x3E33F14 }, - { 0xF06ED680, 0x3B269D8 }, - { 0xF0638620, 0x3817020 }, - { 0xF058CFE0, 0x350540C }, - { 0xF04EB410, 0x31F1704 }, - { 0xF0453330, 0x2EDBB30 }, - { 0xF03C4D80, 0x2BC4274 }, - { 0xF0340370, 0x28AAEB8 }, - { 0xF02C5540, 0x25901E8 }, - { 0xF0254340, 0x2273DE8 }, - { 0xF01ECDD0, 0x1F564EC }, - { 0xF018F500, 0x1C3785A }, - { 0xF013B930, 0x1917A60 }, - { 0xF00F1A80, 0x15F6CEA }, - { 0xF00B1920, 0x12D51EA }, - { 0xF007B550, 0xFB2B4B }, - { 0xF004EF10, 0xC8FAFD }, - { 0xF002C690, 0x96C330 }, - { 0xF0013BD0, 0x648553 }, - { 0xF0004EF0, 0x324395 }, - { 0x10000000, 0x0 }, - { 0xFFEC430, 0x648558 }, - { 0xFFB10F0, 0xC8FB30 }, - { 0xFF4E6D0, 0x12D520A }, - { 0xFEC46D0, 0x1917A6C }, - { 0xFE13240, 0x1F564E6 }, - { 0xFD3AAC0, 0x259020C }, - { 0xFC3B280, 0x2BC428C }, - { 0xFB14BE0, 0x31F1708 }, - { 0xF9C79D0, 0x381704C }, - { 0xF853F80, 0x3E33F34 }, - { 0xF6BA070, 0x44474A0 }, - { 0xF4FA0B0, 0x4A50188 }, - { 0xF314470, 0x504D728 }, - { 0xF109080, 0x563E6A0 }, - { 0xEED89E0, 0x5C22150 }, - { 0xEC835E0, 0x61F78B0 }, - { 0xEA09A60, 0x67BDE58 }, - { 0xE76BD80, 0x6D74400 }, - { 0xE4AA590, 0x7319BA8 }, - { 0xE1C5970, 0x78AD750 }, - { 0xDEBE050, 0x7E2E940 }, - { 0xDB941A0, 0x839C3D0 }, - { 0xD848530, 0x88F59B0 }, - { 0xD4DB310, 0x8E39DA0 }, - { 0xD14D3D0, 0x93682B0 }, - { 0xCD9F020, 0x987FC00 }, - { 0xC9D1120, 0x9D7FD20 }, - { 0xC5E4030, 0xA2679A0 }, - { 0xC1D8700, 0xA736560 }, - { 0xBDAEF90, 0xABEB4A0 }, - { 0xB968420, 0xB085BB0 }, - { 0xB504F30, 0xB504F30 }, - { 0xB085BA0, 0xB968420 }, - { 0xABEB490, 0xBDAEFA0 }, - { 0xA736550, 0xC1D8710 }, - { 0xA267990, 0xC5E4030 }, - { 0x9D7FD10, 0xC9D1120 }, - { 0x987FC00, 0xCD9F020 }, - { 0x93682A0, 0xD14D3D0 }, - { 0x8E39D90, 0xD4DB320 }, - { 0x88F59B0, 0xD848530 }, - { 0x839C3C0, 0xDB941B0 }, - { 0x7E2E938, 0xDEBE050 }, - { 0x78AD738, 0xE1C5980 }, - { 0x7319BA0, 0xE4AA590 }, - { 0x6D74408, 0xE76BD80 }, - { 0x67BDE48, 0xEA09A70 }, - { 0x61F78A8, 0xEC835E0 }, - { 0x5C22138, 0xEED89E0 }, - { 0x563E698, 0xF109080 }, - { 0x504D710, 0xF314480 }, - { 0x4A50180, 0xF4FA0B0 }, - { 0x4447498, 0xF6BA070 }, - { 0x3E33F20, 0xF853F80 }, - { 0x3817048, 0xF9C79D0 }, - { 0x31F16F0, 0xFB14BF0 }, - { 0x2BC4280, 0xFC3B280 }, - { 0x2590214, 0xFD3AAC0 }, - { 0x1F564D8, 0xFE13240 }, - { 0x1917A6A, 0xFEC46D0 }, - { 0x12D51F6, 0xFF4E6D0 }, - { 0xC8FB29, 0xFFB10F0 }, - { 0x64853F, 0xFFEC430 }, - { 0x10000000, 0x0 }, - { 0xFFB10F0, 0xC8FB30 }, - { 0xFEC46D0, 0x1917A6C }, - { 0xFD3AAC0, 0x259020C }, - { 0xFB14BE0, 0x31F1708 }, - { 0xF853F80, 0x3E33F34 }, - { 0xF4FA0B0, 0x4A50188 }, - { 0xF109080, 0x563E6A0 }, - { 0xEC835E0, 0x61F78B0 }, - { 0xE76BD80, 0x6D74400 }, - { 0xE1C5970, 0x78AD750 }, - { 0xDB941A0, 0x839C3D0 }, - { 0xD4DB310, 0x8E39DA0 }, - { 0xCD9F020, 0x987FC00 }, - { 0xC5E4030, 0xA2679A0 }, - { 0xBDAEF90, 0xABEB4A0 }, - { 0xB504F30, 0xB504F30 }, - { 0xABEB490, 0xBDAEFA0 }, - { 0xA267990, 0xC5E4030 }, - { 0x987FC00, 0xCD9F020 }, - { 0x8E39D90, 0xD4DB320 }, - { 0x839C3C0, 0xDB941B0 }, - { 0x78AD738, 0xE1C5980 }, - { 0x6D74408, 0xE76BD80 }, - { 0x61F78A8, 0xEC835E0 }, - { 0x563E698, 0xF109080 }, - { 0x4A50180, 0xF4FA0B0 }, - { 0x3E33F20, 0xF853F80 }, - { 0x31F16F0, 0xFB14BF0 }, - { 0x2590214, 0xFD3AAC0 }, - { 0x1917A6A, 0xFEC46D0 }, - { 0xC8FB29, 0xFFB10F0 }, - { 0xFFFFFFF5, 0x10000000 }, - { 0xFF3704BF, 0xFFB10F0 }, - { 0xFE6E857E, 0xFEC46D0 }, - { 0xFDA6FDD8, 0xFD3AAC0 }, - { 0xFCE0E8F8, 0xFB14BE0 }, - { 0xFC1CC0CC, 0xF853F80 }, - { 0xFB5AFE68, 0xF4FA0A0 }, - { 0xFA9C1950, 0xF109080 }, - { 0xF9E08740, 0xEC835E0 }, - { 0xF928BC00, 0xE76BD80 }, - { 0xF8752898, 0xE1C5970 }, - { 0xF7C63C30, 0xDB941A0 }, - { 0xF71C6240, 0xD4DB300 }, - { 0xF67803F0, 0xCD9F020 }, - { 0xF5D98670, 0xC5E4040 }, - { 0xF5414B50, 0xBDAEF80 }, - { 0xF4AFB0D0, 0xB504F30 }, - { 0xF4251050, 0xABEB480 }, - { 0xF3A1BFC0, 0xA267990 }, - { 0xF3260FC0, 0x987FBD0 }, - { 0xF2B24CE0, 0x8E39D90 }, - { 0xF246BE60, 0x839C3D0 }, - { 0xF1E3A670, 0x78AD730 }, - { 0xF1894280, 0x6D743F8 }, - { 0xF137CA00, 0x61F7880 }, - { 0xF0EF6F70, 0x563E690 }, - { 0xF0B05F50, 0x4A50198 }, - { 0xF07AC080, 0x3E33F14 }, - { 0xF04EB410, 0x31F1704 }, - { 0xF02C5540, 0x25901E8 }, - { 0xF013B930, 0x1917A60 }, - { 0xF004EF10, 0xC8FAFD }, - { 0x10000000, 0x0 }, - { 0xFF4E6D0, 0x12D520A }, - { 0xFD3AAC0, 0x259020C }, - { 0xF9C79D0, 0x381704C }, - { 0xF4FA0B0, 0x4A50188 }, - { 0xEED89E0, 0x5C22150 }, - { 0xE76BD80, 0x6D74400 }, - { 0xDEBE050, 0x7E2E940 }, - { 0xD4DB310, 0x8E39DA0 }, - { 0xC9D1130, 0x9D7FD10 }, - { 0xBDAEF90, 0xABEB4A0 }, - { 0xB085BA0, 0xB968420 }, - { 0xA267990, 0xC5E4030 }, - { 0x93682B0, 0xD14D3D0 }, - { 0x839C3C0, 0xDB941B0 }, - { 0x7319BA0, 0xE4AA590 }, - { 0x61F78A8, 0xEC835E0 }, - { 0x504D728, 0xF314470 }, - { 0x3E33F40, 0xF853F80 }, - { 0x2BC4280, 0xFC3B280 }, - { 0x1917A6A, 0xFEC46D0 }, - { 0x64855F, 0xFFEC430 }, - { 0xFF3704BF, 0xFFB10F0 }, - { 0xFE0A9B12, 0xFE13230 }, - { 0xFCE0E8F8, 0xFB14BE0 }, - { 0xFBBB8B70, 0xF6BA070 }, - { 0xFA9C1970, 0xF109080 }, - { 0xF98421A8, 0xEA09A60 }, - { 0xF8752898, 0xE1C5970 }, - { 0xF770A640, 0xD848520 }, - { 0xF67803F0, 0xCD9F020 }, - { 0xF58C9AA0, 0xC1D8700 }, - { 0xF4AFB0D0, 0xB504F30 }, - { 0xF3E27900, 0xA736560 }, - { 0xF3260FE0, 0x987FC10 }, - { 0xF27B7AE0, 0x88F59C0 }, - { 0xF1E3A690, 0x78AD768 }, - { 0xF15F6590, 0x67BDE38 }, - { 0xF0EF6F70, 0x563E690 }, - { 0xF0945F90, 0x4447490 }, - { 0xF04EB410, 0x31F1704 }, - { 0xF01ECDD0, 0x1F564EC }, - { 0xF004EF10, 0xC8FB3D }, - { 0xF0013BD0, 0xFF9B7ABE }, - { 0xF013B930, 0xFE6E8572 }, - { 0xF03C4D80, 0xFD43BD5C }, - { 0xF07AC080, 0xFC1CC0C0 }, - { 0xF0CEBB90, 0xFAFB28D0 }, - { 0xF137CA20, 0xF9E08758 }, - { 0xF1B55A70, 0xF8CE6460 }, - { 0xF246BE50, 0xF7C63C40 }, - { 0xF2EB2C20, 0xF6C97D70 }, - { 0xF3A1BFB0, 0xF5D98680 }, - { 0xF4697BF0, 0xF4F7A440 }, - { 0xF5414B70, 0xF4251060 }, - { 0xF62802F0, 0xF362EED0 }, - { 0xF71C62A0, 0xF2B24CC0 }, - { 0xF81D16C8, 0xF2141FB0 }, - { 0xF928BC28, 0xF1894270 }, - { 0xFA3DDEA0, 0xF1127630 }, - { 0xFB5AFE98, 0xF0B05F50 }, - { 0xFC7E8F90, 0xF0638630 }, - { 0xFDA6FE04, 0xF02C5540 }, - { 0xFED2ADC2, 0xF00B1930 }, - { 0x10000000, 0x0 }, - { 0xFEC46D0, 0x1917A6C }, - { 0xFB14BE0, 0x31F1708 }, - { 0xF4FA0B0, 0x4A50188 }, - { 0xEC835E0, 0x61F78B0 }, - { 0xE1C5970, 0x78AD750 }, - { 0xD4DB310, 0x8E39DA0 }, - { 0xC5E4030, 0xA2679A0 }, - { 0xB504F30, 0xB504F30 }, - { 0xA267990, 0xC5E4030 }, - { 0x8E39D90, 0xD4DB320 }, - { 0x78AD738, 0xE1C5980 }, - { 0x61F78A8, 0xEC835E0 }, - { 0x4A50180, 0xF4FA0B0 }, - { 0x31F16F0, 0xFB14BF0 }, - { 0x1917A6A, 0xFEC46D0 }, - { 0x10000000, 0x0 }, - { 0xFB14BE0, 0x31F1708 }, - { 0xEC835E0, 0x61F78B0 }, - { 0xD4DB310, 0x8E39DA0 }, - { 0xB504F30, 0xB504F30 }, - { 0x8E39D90, 0xD4DB320 }, - { 0x61F78A8, 0xEC835E0 }, - { 0x31F16F0, 0xFB14BF0 }, - { 0xFFFFFFF5, 0x10000000 }, - { 0xFCE0E8F8, 0xFB14BE0 }, - { 0xF9E08740, 0xEC835E0 }, - { 0xF71C6240, 0xD4DB300 }, - { 0xF4AFB0D0, 0xB504F30 }, - { 0xF2B24CE0, 0x8E39D90 }, - { 0xF137CA00, 0x61F7880 }, - { 0xF04EB410, 0x31F1704 }, - { 0x10000000, 0x0 }, - { 0xF4FA0B0, 0x4A50188 }, - { 0xD4DB310, 0x8E39DA0 }, - { 0xA267990, 0xC5E4030 }, - { 0x61F78A8, 0xEC835E0 }, - { 0x1917A6A, 0xFEC46D0 }, - { 0xFCE0E8F8, 0xFB14BE0 }, - { 0xF8752898, 0xE1C5970 }, - { 0xF4AFB0D0, 0xB504F30 }, - { 0xF1E3A690, 0x78AD768 }, - { 0xF04EB410, 0x31F1704 }, - { 0xF013B930, 0xFE6E8572 }, - { 0xF137CA20, 0xF9E08758 }, - { 0xF3A1BFB0, 0xF5D98680 }, - { 0xF71C62A0, 0xF2B24CC0 }, - { 0xFB5AFE98, 0xF0B05F50 }, - { 0x10000000, 0x0 }, - { 0xEC835E0, 0x61F78B0 }, - { 0xB504F30, 0xB504F30 }, - { 0x61F78A8, 0xEC835E0 }, - { 0x10000000, 0x0 }, - { 0xB504F30, 0xB504F30 }, - { 0xFFFFFFF5, 0x10000000 }, - { 0xF4AFB0D0, 0xB504F30 }, - { 0x10000000, 0x0 }, - { 0x61F78A8, 0xEC835E0 }, - { 0xF4AFB0D0, 0xB504F30 }, - { 0xF137CA20, 0xF9E08758 }, - { 0x10000000, 0x0 }, - { 0x10000000, 0x0 }, - { 0x10000000, 0x0 }, - { 0x3, 0xF0000000 } + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.999924719333649), FRAC_CONST(0.012271538376808) }, + { FRAC_CONST(0.999698817729950), FRAC_CONST(0.024541229009628) }, + { FRAC_CONST(0.999322354793549), FRAC_CONST(0.036807224154472) }, + { FRAC_CONST(0.998795449733734), FRAC_CONST(0.049067676067352) }, + { FRAC_CONST(0.998118102550507), FRAC_CONST(0.061320740729570) }, + { FRAC_CONST(0.997290432453156), FRAC_CONST(0.073564566671848) }, + { FRAC_CONST(0.996312618255615), FRAC_CONST(0.085797317326069) }, + { FRAC_CONST(0.995184719562531), FRAC_CONST(0.098017141222954) }, + { FRAC_CONST(0.993906974792480), FRAC_CONST(0.110222205519676) }, + { FRAC_CONST(0.992479562759399), FRAC_CONST(0.122410677373409) }, + { FRAC_CONST(0.990902662277222), FRAC_CONST(0.134580716490746) }, + { FRAC_CONST(0.989176511764526), FRAC_CONST(0.146730467677116) }, + { FRAC_CONST(0.987301409244537), FRAC_CONST(0.158858150243759) }, + { FRAC_CONST(0.985277652740479), FRAC_CONST(0.170961901545525) }, + { FRAC_CONST(0.983105480670929), FRAC_CONST(0.183039888739586) }, + { FRAC_CONST(0.980785250663757), FRAC_CONST(0.195090323686600) }, + { FRAC_CONST(0.978317379951477), FRAC_CONST(0.207111388444901) }, + { FRAC_CONST(0.975702106952667), FRAC_CONST(0.219101235270500) }, + { FRAC_CONST(0.972939968109131), FRAC_CONST(0.231058120727539) }, + { FRAC_CONST(0.970031261444092), FRAC_CONST(0.242980197072029) }, + { FRAC_CONST(0.966976463794708), FRAC_CONST(0.254865676164627) }, + { FRAC_CONST(0.963776051998138), FRAC_CONST(0.266712784767151) }, + { FRAC_CONST(0.960430502891541), FRAC_CONST(0.278519690036774) }, + { FRAC_CONST(0.956940352916718), FRAC_CONST(0.290284663438797) }, + { FRAC_CONST(0.953306019306183), FRAC_CONST(0.302005946636200) }, + { FRAC_CONST(0.949528157711029), FRAC_CONST(0.313681751489639) }, + { FRAC_CONST(0.945607304573059), FRAC_CONST(0.325310319662094) }, + { FRAC_CONST(0.941544055938721), FRAC_CONST(0.336889863014221) }, + { FRAC_CONST(0.937339007854462), FRAC_CONST(0.348418682813644) }, + { FRAC_CONST(0.932992815971375), FRAC_CONST(0.359895050525665) }, + { FRAC_CONST(0.928506076335907), FRAC_CONST(0.371317207813263) }, + { FRAC_CONST(0.923879504203796), FRAC_CONST(0.382683455944061) }, + { FRAC_CONST(0.919113874435425), FRAC_CONST(0.393992066383362) }, + { FRAC_CONST(0.914209723472595), FRAC_CONST(0.405241340398788) }, + { FRAC_CONST(0.909167945384979), FRAC_CONST(0.416429579257965) }, + { FRAC_CONST(0.903989315032959), FRAC_CONST(0.427555084228516) }, + { FRAC_CONST(0.898674488067627), FRAC_CONST(0.438616245985031) }, + { FRAC_CONST(0.893224298954010), FRAC_CONST(0.449611335992813) }, + { FRAC_CONST(0.887639641761780), FRAC_CONST(0.460538715124130) }, + { FRAC_CONST(0.881921231746674), FRAC_CONST(0.471396744251251) }, + { FRAC_CONST(0.876070082187653), FRAC_CONST(0.482183754444122) }, + { FRAC_CONST(0.870086967945099), FRAC_CONST(0.492898225784302) }, + { FRAC_CONST(0.863972842693329), FRAC_CONST(0.503538370132446) }, + { FRAC_CONST(0.857728600502014), FRAC_CONST(0.514102756977081) }, + { FRAC_CONST(0.851355195045471), FRAC_CONST(0.524589717388153) }, + { FRAC_CONST(0.844853579998016), FRAC_CONST(0.534997642040253) }, + { FRAC_CONST(0.838224709033966), FRAC_CONST(0.545324981212616) }, + { FRAC_CONST(0.831469595432281), FRAC_CONST(0.555570244789124) }, + { FRAC_CONST(0.824589252471924), FRAC_CONST(0.565731823444366) }, + { FRAC_CONST(0.817584812641144), FRAC_CONST(0.575808227062225) }, + { FRAC_CONST(0.810457170009613), FRAC_CONST(0.585797905921936) }, + { FRAC_CONST(0.803207516670227), FRAC_CONST(0.595699310302734) }, + { FRAC_CONST(0.795836925506592), FRAC_CONST(0.605511009693146) }, + { FRAC_CONST(0.788346409797668), FRAC_CONST(0.615231633186340) }, + { FRAC_CONST(0.780737221240997), FRAC_CONST(0.624859511852264) }, + { FRAC_CONST(0.773010432720184), FRAC_CONST(0.634393334388733) }, + { FRAC_CONST(0.765167236328125), FRAC_CONST(0.643831551074982) }, + { FRAC_CONST(0.757208824157715), FRAC_CONST(0.653172850608826) }, + { FRAC_CONST(0.749136388301849), FRAC_CONST(0.662415802478790) }, + { FRAC_CONST(0.740951120853424), FRAC_CONST(0.671558976173401) }, + { FRAC_CONST(0.732654273509979), FRAC_CONST(0.680601000785828) }, + { FRAC_CONST(0.724247097969055), FRAC_CONST(0.689540565013886) }, + { FRAC_CONST(0.715730786323547), FRAC_CONST(0.698376297950745) }, + { FRAC_CONST(0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(0.698376238346100), FRAC_CONST(0.715730845928192) }, + { FRAC_CONST(0.689540505409241), FRAC_CONST(0.724247097969055) }, + { FRAC_CONST(0.680601000785828), FRAC_CONST(0.732654273509979) }, + { FRAC_CONST(0.671558916568756), FRAC_CONST(0.740951180458069) }, + { FRAC_CONST(0.662415742874146), FRAC_CONST(0.749136388301849) }, + { FRAC_CONST(0.653172791004181), FRAC_CONST(0.757208883762360) }, + { FRAC_CONST(0.643831551074982), FRAC_CONST(0.765167295932770) }, + { FRAC_CONST(0.634393274784088), FRAC_CONST(0.773010432720184) }, + { FRAC_CONST(0.624859452247620), FRAC_CONST(0.780737280845642) }, + { FRAC_CONST(0.615231573581696), FRAC_CONST(0.788346409797668) }, + { FRAC_CONST(0.605511009693146), FRAC_CONST(0.795836925506592) }, + { FRAC_CONST(0.595699310302734), FRAC_CONST(0.803207516670227) }, + { FRAC_CONST(0.585797846317291), FRAC_CONST(0.810457170009613) }, + { FRAC_CONST(0.575808167457581), FRAC_CONST(0.817584812641144) }, + { FRAC_CONST(0.565731823444366), FRAC_CONST(0.824589312076569) }, + { FRAC_CONST(0.555570185184479), FRAC_CONST(0.831469655036926) }, + { FRAC_CONST(0.545324981212616), FRAC_CONST(0.838224709033966) }, + { FRAC_CONST(0.534997642040253), FRAC_CONST(0.844853579998016) }, + { FRAC_CONST(0.524589657783508), FRAC_CONST(0.851355195045471) }, + { FRAC_CONST(0.514102697372437), FRAC_CONST(0.857728660106659) }, + { FRAC_CONST(0.503538429737091), FRAC_CONST(0.863972842693329) }, + { FRAC_CONST(0.492898195981979), FRAC_CONST(0.870086967945099) }, + { FRAC_CONST(0.482183724641800), FRAC_CONST(0.876070141792297) }, + { FRAC_CONST(0.471396654844284), FRAC_CONST(0.881921291351318) }, + { FRAC_CONST(0.460538715124130), FRAC_CONST(0.887639641761780) }, + { FRAC_CONST(0.449611306190491), FRAC_CONST(0.893224298954010) }, + { FRAC_CONST(0.438616186380386), FRAC_CONST(0.898674488067627) }, + { FRAC_CONST(0.427555114030838), FRAC_CONST(0.903989315032959) }, + { FRAC_CONST(0.416429549455643), FRAC_CONST(0.909168004989624) }, + { FRAC_CONST(0.405241280794144), FRAC_CONST(0.914209783077240) }, + { FRAC_CONST(0.393991947174072), FRAC_CONST(0.919113874435425) }, + { FRAC_CONST(0.382683426141739), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(0.371317148208618), FRAC_CONST(0.928506076335907) }, + { FRAC_CONST(0.359894961118698), FRAC_CONST(0.932992815971375) }, + { FRAC_CONST(0.348418682813644), FRAC_CONST(0.937339007854462) }, + { FRAC_CONST(0.336889833211899), FRAC_CONST(0.941544055938721) }, + { FRAC_CONST(0.325310230255127), FRAC_CONST(0.945607364177704) }, + { FRAC_CONST(0.313681662082672), FRAC_CONST(0.949528217315674) }, + { FRAC_CONST(0.302005946636200), FRAC_CONST(0.953306019306183) }, + { FRAC_CONST(0.290284633636475), FRAC_CONST(0.956940352916718) }, + { FRAC_CONST(0.278519600629807), FRAC_CONST(0.960430562496185) }, + { FRAC_CONST(0.266712754964828), FRAC_CONST(0.963776051998138) }, + { FRAC_CONST(0.254865646362305), FRAC_CONST(0.966976463794708) }, + { FRAC_CONST(0.242980122566223), FRAC_CONST(0.970031261444092) }, + { FRAC_CONST(0.231058135628700), FRAC_CONST(0.972939968109131) }, + { FRAC_CONST(0.219101220369339), FRAC_CONST(0.975702106952667) }, + { FRAC_CONST(0.207111328840256), FRAC_CONST(0.978317379951477) }, + { FRAC_CONST(0.195090234279633), FRAC_CONST(0.980785310268402) }, + { FRAC_CONST(0.183039888739586), FRAC_CONST(0.983105480670929) }, + { FRAC_CONST(0.170961856842041), FRAC_CONST(0.985277652740479) }, + { FRAC_CONST(0.158858075737953), FRAC_CONST(0.987301409244537) }, + { FRAC_CONST(0.146730497479439), FRAC_CONST(0.989176511764526) }, + { FRAC_CONST(0.134580686688423), FRAC_CONST(0.990902662277222) }, + { FRAC_CONST(0.122410625219345), FRAC_CONST(0.992479562759399) }, + { FRAC_CONST(0.110222116112709), FRAC_CONST(0.993906974792480) }, + { FRAC_CONST(0.098017133772373), FRAC_CONST(0.995184719562531) }, + { FRAC_CONST(0.085797272622585), FRAC_CONST(0.996312618255615) }, + { FRAC_CONST(0.073564492166042), FRAC_CONST(0.997290432453156) }, + { FRAC_CONST(0.061320748180151), FRAC_CONST(0.998118102550507) }, + { FRAC_CONST(0.049067649990320), FRAC_CONST(0.998795449733734) }, + { FRAC_CONST(0.036807164549828), FRAC_CONST(0.999322414398193) }, + { FRAC_CONST(0.024541135877371), FRAC_CONST(0.999698817729950) }, + { FRAC_CONST(0.012271529063582), FRAC_CONST(0.999924719333649) }, + { FRAC_CONST(-0.000000043711388), FRAC_CONST(1.000000000000000) }, + { FRAC_CONST(-0.012271616607904), FRAC_CONST(0.999924719333649) }, + { FRAC_CONST(-0.024541223421693), FRAC_CONST(0.999698817729950) }, + { FRAC_CONST(-0.036807250231504), FRAC_CONST(0.999322354793549) }, + { FRAC_CONST(-0.049067739397287), FRAC_CONST(0.998795449733734) }, + { FRAC_CONST(-0.061320833861828), FRAC_CONST(0.998118102550507) }, + { FRAC_CONST(-0.073564574122429), FRAC_CONST(0.997290432453156) }, + { FRAC_CONST(-0.085797362029552), FRAC_CONST(0.996312618255615) }, + { FRAC_CONST(-0.098017223179340), FRAC_CONST(0.995184719562531) }, + { FRAC_CONST(-0.110222205519676), FRAC_CONST(0.993906974792480) }, + { FRAC_CONST(-0.122410707175732), FRAC_CONST(0.992479503154755) }, + { FRAC_CONST(-0.134580776095390), FRAC_CONST(0.990902602672577) }, + { FRAC_CONST(-0.146730571985245), FRAC_CONST(0.989176511764526) }, + { FRAC_CONST(-0.158858165144920), FRAC_CONST(0.987301409244537) }, + { FRAC_CONST(-0.170961946249008), FRAC_CONST(0.985277652740479) }, + { FRAC_CONST(-0.183039978146553), FRAC_CONST(0.983105480670929) }, + { FRAC_CONST(-0.195090323686600), FRAC_CONST(0.980785250663757) }, + { FRAC_CONST(-0.207111418247223), FRAC_CONST(0.978317379951477) }, + { FRAC_CONST(-0.219101309776306), FRAC_CONST(0.975702106952667) }, + { FRAC_CONST(-0.231058210134506), FRAC_CONST(0.972939908504486) }, + { FRAC_CONST(-0.242980197072029), FRAC_CONST(0.970031261444092) }, + { FRAC_CONST(-0.254865705966949), FRAC_CONST(0.966976463794708) }, + { FRAC_CONST(-0.266712844371796), FRAC_CONST(0.963776051998138) }, + { FRAC_CONST(-0.278519690036774), FRAC_CONST(0.960430502891541) }, + { FRAC_CONST(-0.290284723043442), FRAC_CONST(0.956940293312073) }, + { FRAC_CONST(-0.302006036043167), FRAC_CONST(0.953306019306183) }, + { FRAC_CONST(-0.313681721687317), FRAC_CONST(0.949528157711029) }, + { FRAC_CONST(-0.325310319662094), FRAC_CONST(0.945607304573059) }, + { FRAC_CONST(-0.336889922618866), FRAC_CONST(0.941544055938721) }, + { FRAC_CONST(-0.348418772220612), FRAC_CONST(0.937338948249817) }, + { FRAC_CONST(-0.359895050525665), FRAC_CONST(0.932992815971375) }, + { FRAC_CONST(-0.371317237615585), FRAC_CONST(0.928506076335907) }, + { FRAC_CONST(-0.382683515548706), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(-0.393992036581039), FRAC_CONST(0.919113874435425) }, + { FRAC_CONST(-0.405241340398788), FRAC_CONST(0.914209723472595) }, + { FRAC_CONST(-0.416429519653320), FRAC_CONST(0.909168004989624) }, + { FRAC_CONST(-0.427555084228516), FRAC_CONST(0.903989315032959) }, + { FRAC_CONST(-0.438616245985031), FRAC_CONST(0.898674428462982) }, + { FRAC_CONST(-0.449611365795136), FRAC_CONST(0.893224298954010) }, + { FRAC_CONST(-0.460538804531097), FRAC_CONST(0.887639582157135) }, + { FRAC_CONST(-0.471396833658218), FRAC_CONST(0.881921231746674) }, + { FRAC_CONST(-0.482183903455734), FRAC_CONST(0.876070022583008) }, + { FRAC_CONST(-0.492898166179657), FRAC_CONST(0.870087027549744) }, + { FRAC_CONST(-0.503538370132446), FRAC_CONST(0.863972842693329) }, + { FRAC_CONST(-0.514102756977081), FRAC_CONST(0.857728600502014) }, + { FRAC_CONST(-0.524589717388153), FRAC_CONST(0.851355135440826) }, + { FRAC_CONST(-0.534997701644897), FRAC_CONST(0.844853520393372) }, + { FRAC_CONST(-0.545325100421906), FRAC_CONST(0.838224649429321) }, + { FRAC_CONST(-0.555570363998413), FRAC_CONST(0.831469535827637) }, + { FRAC_CONST(-0.565731763839722), FRAC_CONST(0.824589312076569) }, + { FRAC_CONST(-0.575808167457581), FRAC_CONST(0.817584812641144) }, + { FRAC_CONST(-0.585797905921936), FRAC_CONST(0.810457170009613) }, + { FRAC_CONST(-0.595699369907379), FRAC_CONST(0.803207516670227) }, + { FRAC_CONST(-0.605511128902435), FRAC_CONST(0.795836865901947) }, + { FRAC_CONST(-0.615231692790985), FRAC_CONST(0.788346350193024) }, + { FRAC_CONST(-0.624859631061554), FRAC_CONST(0.780737102031708) }, + { FRAC_CONST(-0.634393274784088), FRAC_CONST(0.773010492324829) }, + { FRAC_CONST(-0.643831551074982), FRAC_CONST(0.765167236328125) }, + { FRAC_CONST(-0.653172850608826), FRAC_CONST(0.757208824157715) }, + { FRAC_CONST(-0.662415802478790), FRAC_CONST(0.749136328697205) }, + { FRAC_CONST(-0.671559035778046), FRAC_CONST(0.740951061248779) }, + { FRAC_CONST(-0.680601119995117), FRAC_CONST(0.732654154300690) }, + { FRAC_CONST(-0.689540684223175), FRAC_CONST(0.724246978759766) }, + { FRAC_CONST(-0.698376238346100), FRAC_CONST(0.715730845928192) }, + { FRAC_CONST(-0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(-0.715730845928192), FRAC_CONST(0.698376238346100) }, + { FRAC_CONST(-0.724247157573700), FRAC_CONST(0.689540505409241) }, + { FRAC_CONST(-0.732654333114624), FRAC_CONST(0.680600941181183) }, + { FRAC_CONST(-0.740951240062714), FRAC_CONST(0.671558856964111) }, + { FRAC_CONST(-0.749136507511139), FRAC_CONST(0.662415623664856) }, + { FRAC_CONST(-0.757208824157715), FRAC_CONST(0.653172850608826) }, + { FRAC_CONST(-0.765167295932770), FRAC_CONST(0.643831551074982) }, + { FRAC_CONST(-0.773010492324829), FRAC_CONST(0.634393274784088) }, + { FRAC_CONST(-0.780737280845642), FRAC_CONST(0.624859452247620) }, + { FRAC_CONST(-0.788346469402313), FRAC_CONST(0.615231513977051) }, + { FRAC_CONST(-0.795836985111237), FRAC_CONST(0.605510950088501) }, + { FRAC_CONST(-0.803207635879517), FRAC_CONST(0.595699131488800) }, + { FRAC_CONST(-0.810457170009613), FRAC_CONST(0.585797846317291) }, + { FRAC_CONST(-0.817584812641144), FRAC_CONST(0.575808167457581) }, + { FRAC_CONST(-0.824589312076569), FRAC_CONST(0.565731763839722) }, + { FRAC_CONST(-0.831469655036926), FRAC_CONST(0.555570185184479) }, + { FRAC_CONST(-0.838224768638611), FRAC_CONST(0.545324862003326) }, + { FRAC_CONST(-0.844853639602661), FRAC_CONST(0.534997463226318) }, + { FRAC_CONST(-0.851355314254761), FRAC_CONST(0.524589538574219) }, + { FRAC_CONST(-0.857728600502014), FRAC_CONST(0.514102756977081) }, + { FRAC_CONST(-0.863972842693329), FRAC_CONST(0.503538370132446) }, + { FRAC_CONST(-0.870087027549744), FRAC_CONST(0.492898136377335) }, + { FRAC_CONST(-0.876070141792297), FRAC_CONST(0.482183694839478) }, + { FRAC_CONST(-0.881921350955963), FRAC_CONST(0.471396625041962) }, + { FRAC_CONST(-0.887639701366425), FRAC_CONST(0.460538566112518) }, + { FRAC_CONST(-0.893224298954010), FRAC_CONST(0.449611365795136) }, + { FRAC_CONST(-0.898674488067627), FRAC_CONST(0.438616245985031) }, + { FRAC_CONST(-0.903989315032959), FRAC_CONST(0.427555054426193) }, + { FRAC_CONST(-0.909168004989624), FRAC_CONST(0.416429489850998) }, + { FRAC_CONST(-0.914209783077240), FRAC_CONST(0.405241221189499) }, + { FRAC_CONST(-0.919113874435425), FRAC_CONST(0.393991917371750) }, + { FRAC_CONST(-0.923879623413086), FRAC_CONST(0.382683277130127) }, + { FRAC_CONST(-0.928506076335907), FRAC_CONST(0.371317237615585) }, + { FRAC_CONST(-0.932992815971375), FRAC_CONST(0.359895050525665) }, + { FRAC_CONST(-0.937339007854462), FRAC_CONST(0.348418653011322) }, + { FRAC_CONST(-0.941544115543365), FRAC_CONST(0.336889803409576) }, + { FRAC_CONST(-0.945607364177704), FRAC_CONST(0.325310200452805) }, + { FRAC_CONST(-0.949528217315674), FRAC_CONST(0.313681602478027) }, + { FRAC_CONST(-0.953306078910828), FRAC_CONST(0.302005797624588) }, + { FRAC_CONST(-0.956940352916718), FRAC_CONST(0.290284723043442) }, + { FRAC_CONST(-0.960430502891541), FRAC_CONST(0.278519690036774) }, + { FRAC_CONST(-0.963776051998138), FRAC_CONST(0.266712725162506) }, + { FRAC_CONST(-0.966976463794708), FRAC_CONST(0.254865586757660) }, + { FRAC_CONST(-0.970031261444092), FRAC_CONST(0.242980077862740) }, + { FRAC_CONST(-0.972939968109131), FRAC_CONST(0.231057971715927) }, + { FRAC_CONST(-0.975702166557312), FRAC_CONST(0.219101071357727) }, + { FRAC_CONST(-0.978317379951477), FRAC_CONST(0.207111403346062) }, + { FRAC_CONST(-0.980785310268402), FRAC_CONST(0.195090308785439) }, + { FRAC_CONST(-0.983105480670929), FRAC_CONST(0.183039844036102) }, + { FRAC_CONST(-0.985277652740479), FRAC_CONST(0.170961812138557) }, + { FRAC_CONST(-0.987301409244537), FRAC_CONST(0.158858031034470) }, + { FRAC_CONST(-0.989176511764526), FRAC_CONST(0.146730333566666) }, + { FRAC_CONST(-0.990902662277222), FRAC_CONST(0.134580522775650) }, + { FRAC_CONST(-0.992479503154755), FRAC_CONST(0.122410699725151) }, + { FRAC_CONST(-0.993906974792480), FRAC_CONST(0.110222198069096) }, + { FRAC_CONST(-0.995184719562531), FRAC_CONST(0.098017096519470) }, + { FRAC_CONST(-0.996312618255615), FRAC_CONST(0.085797227919102) }, + { FRAC_CONST(-0.997290492057800), FRAC_CONST(0.073564447462559) }, + { FRAC_CONST(-0.998118102550507), FRAC_CONST(0.061320584267378) }, + { FRAC_CONST(-0.998795449733734), FRAC_CONST(0.049067486077547) }, + { FRAC_CONST(-0.999322354793549), FRAC_CONST(0.036807239055634) }, + { FRAC_CONST(-0.999698817729950), FRAC_CONST(0.024541210383177) }, + { FRAC_CONST(-0.999924719333649), FRAC_CONST(0.012271485291421) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.999698817729950), FRAC_CONST(0.024541229009628) }, + { FRAC_CONST(0.998795449733734), FRAC_CONST(0.049067676067352) }, + { FRAC_CONST(0.997290432453156), FRAC_CONST(0.073564566671848) }, + { FRAC_CONST(0.995184719562531), FRAC_CONST(0.098017141222954) }, + { FRAC_CONST(0.992479562759399), FRAC_CONST(0.122410677373409) }, + { FRAC_CONST(0.989176511764526), FRAC_CONST(0.146730467677116) }, + { FRAC_CONST(0.985277652740479), FRAC_CONST(0.170961901545525) }, + { FRAC_CONST(0.980785250663757), FRAC_CONST(0.195090323686600) }, + { FRAC_CONST(0.975702106952667), FRAC_CONST(0.219101235270500) }, + { FRAC_CONST(0.970031261444092), FRAC_CONST(0.242980197072029) }, + { FRAC_CONST(0.963776051998138), FRAC_CONST(0.266712784767151) }, + { FRAC_CONST(0.956940352916718), FRAC_CONST(0.290284663438797) }, + { FRAC_CONST(0.949528157711029), FRAC_CONST(0.313681751489639) }, + { FRAC_CONST(0.941544055938721), FRAC_CONST(0.336889863014221) }, + { FRAC_CONST(0.932992815971375), FRAC_CONST(0.359895050525665) }, + { FRAC_CONST(0.923879504203796), FRAC_CONST(0.382683455944061) }, + { FRAC_CONST(0.914209723472595), FRAC_CONST(0.405241340398788) }, + { FRAC_CONST(0.903989315032959), FRAC_CONST(0.427555084228516) }, + { FRAC_CONST(0.893224298954010), FRAC_CONST(0.449611335992813) }, + { FRAC_CONST(0.881921231746674), FRAC_CONST(0.471396744251251) }, + { FRAC_CONST(0.870086967945099), FRAC_CONST(0.492898225784302) }, + { FRAC_CONST(0.857728600502014), FRAC_CONST(0.514102756977081) }, + { FRAC_CONST(0.844853579998016), FRAC_CONST(0.534997642040253) }, + { FRAC_CONST(0.831469595432281), FRAC_CONST(0.555570244789124) }, + { FRAC_CONST(0.817584812641144), FRAC_CONST(0.575808227062225) }, + { FRAC_CONST(0.803207516670227), FRAC_CONST(0.595699310302734) }, + { FRAC_CONST(0.788346409797668), FRAC_CONST(0.615231633186340) }, + { FRAC_CONST(0.773010432720184), FRAC_CONST(0.634393334388733) }, + { FRAC_CONST(0.757208824157715), FRAC_CONST(0.653172850608826) }, + { FRAC_CONST(0.740951120853424), FRAC_CONST(0.671558976173401) }, + { FRAC_CONST(0.724247097969055), FRAC_CONST(0.689540565013886) }, + { FRAC_CONST(0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(0.689540505409241), FRAC_CONST(0.724247097969055) }, + { FRAC_CONST(0.671558916568756), FRAC_CONST(0.740951180458069) }, + { FRAC_CONST(0.653172791004181), FRAC_CONST(0.757208883762360) }, + { FRAC_CONST(0.634393274784088), FRAC_CONST(0.773010432720184) }, + { FRAC_CONST(0.615231573581696), FRAC_CONST(0.788346409797668) }, + { FRAC_CONST(0.595699310302734), FRAC_CONST(0.803207516670227) }, + { FRAC_CONST(0.575808167457581), FRAC_CONST(0.817584812641144) }, + { FRAC_CONST(0.555570185184479), FRAC_CONST(0.831469655036926) }, + { FRAC_CONST(0.534997642040253), FRAC_CONST(0.844853579998016) }, + { FRAC_CONST(0.514102697372437), FRAC_CONST(0.857728660106659) }, + { FRAC_CONST(0.492898195981979), FRAC_CONST(0.870086967945099) }, + { FRAC_CONST(0.471396654844284), FRAC_CONST(0.881921291351318) }, + { FRAC_CONST(0.449611306190491), FRAC_CONST(0.893224298954010) }, + { FRAC_CONST(0.427555114030838), FRAC_CONST(0.903989315032959) }, + { FRAC_CONST(0.405241280794144), FRAC_CONST(0.914209783077240) }, + { FRAC_CONST(0.382683426141739), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(0.359894961118698), FRAC_CONST(0.932992815971375) }, + { FRAC_CONST(0.336889833211899), FRAC_CONST(0.941544055938721) }, + { FRAC_CONST(0.313681662082672), FRAC_CONST(0.949528217315674) }, + { FRAC_CONST(0.290284633636475), FRAC_CONST(0.956940352916718) }, + { FRAC_CONST(0.266712754964828), FRAC_CONST(0.963776051998138) }, + { FRAC_CONST(0.242980122566223), FRAC_CONST(0.970031261444092) }, + { FRAC_CONST(0.219101220369339), FRAC_CONST(0.975702106952667) }, + { FRAC_CONST(0.195090234279633), FRAC_CONST(0.980785310268402) }, + { FRAC_CONST(0.170961856842041), FRAC_CONST(0.985277652740479) }, + { FRAC_CONST(0.146730497479439), FRAC_CONST(0.989176511764526) }, + { FRAC_CONST(0.122410625219345), FRAC_CONST(0.992479562759399) }, + { FRAC_CONST(0.098017133772373), FRAC_CONST(0.995184719562531) }, + { FRAC_CONST(0.073564492166042), FRAC_CONST(0.997290432453156) }, + { FRAC_CONST(0.049067649990320), FRAC_CONST(0.998795449733734) }, + { FRAC_CONST(0.024541135877371), FRAC_CONST(0.999698817729950) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.998795449733734), FRAC_CONST(0.049067676067352) }, + { FRAC_CONST(0.995184719562531), FRAC_CONST(0.098017141222954) }, + { FRAC_CONST(0.989176511764526), FRAC_CONST(0.146730467677116) }, + { FRAC_CONST(0.980785250663757), FRAC_CONST(0.195090323686600) }, + { FRAC_CONST(0.970031261444092), FRAC_CONST(0.242980197072029) }, + { FRAC_CONST(0.956940352916718), FRAC_CONST(0.290284663438797) }, + { FRAC_CONST(0.941544055938721), FRAC_CONST(0.336889863014221) }, + { FRAC_CONST(0.923879504203796), FRAC_CONST(0.382683455944061) }, + { FRAC_CONST(0.903989315032959), FRAC_CONST(0.427555084228516) }, + { FRAC_CONST(0.881921231746674), FRAC_CONST(0.471396744251251) }, + { FRAC_CONST(0.857728600502014), FRAC_CONST(0.514102756977081) }, + { FRAC_CONST(0.831469595432281), FRAC_CONST(0.555570244789124) }, + { FRAC_CONST(0.803207516670227), FRAC_CONST(0.595699310302734) }, + { FRAC_CONST(0.773010432720184), FRAC_CONST(0.634393334388733) }, + { FRAC_CONST(0.740951120853424), FRAC_CONST(0.671558976173401) }, + { FRAC_CONST(0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(0.671558916568756), FRAC_CONST(0.740951180458069) }, + { FRAC_CONST(0.634393274784088), FRAC_CONST(0.773010432720184) }, + { FRAC_CONST(0.595699310302734), FRAC_CONST(0.803207516670227) }, + { FRAC_CONST(0.555570185184479), FRAC_CONST(0.831469655036926) }, + { FRAC_CONST(0.514102697372437), FRAC_CONST(0.857728660106659) }, + { FRAC_CONST(0.471396654844284), FRAC_CONST(0.881921291351318) }, + { FRAC_CONST(0.427555114030838), FRAC_CONST(0.903989315032959) }, + { FRAC_CONST(0.382683426141739), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(0.336889833211899), FRAC_CONST(0.941544055938721) }, + { FRAC_CONST(0.290284633636475), FRAC_CONST(0.956940352916718) }, + { FRAC_CONST(0.242980122566223), FRAC_CONST(0.970031261444092) }, + { FRAC_CONST(0.195090234279633), FRAC_CONST(0.980785310268402) }, + { FRAC_CONST(0.146730497479439), FRAC_CONST(0.989176511764526) }, + { FRAC_CONST(0.098017133772373), FRAC_CONST(0.995184719562531) }, + { FRAC_CONST(0.049067649990320), FRAC_CONST(0.998795449733734) }, + { FRAC_CONST(-0.000000043711388), FRAC_CONST(1.000000000000000) }, + { FRAC_CONST(-0.049067739397287), FRAC_CONST(0.998795449733734) }, + { FRAC_CONST(-0.098017223179340), FRAC_CONST(0.995184719562531) }, + { FRAC_CONST(-0.146730571985245), FRAC_CONST(0.989176511764526) }, + { FRAC_CONST(-0.195090323686600), FRAC_CONST(0.980785250663757) }, + { FRAC_CONST(-0.242980197072029), FRAC_CONST(0.970031261444092) }, + { FRAC_CONST(-0.290284723043442), FRAC_CONST(0.956940293312073) }, + { FRAC_CONST(-0.336889922618866), FRAC_CONST(0.941544055938721) }, + { FRAC_CONST(-0.382683515548706), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(-0.427555084228516), FRAC_CONST(0.903989315032959) }, + { FRAC_CONST(-0.471396833658218), FRAC_CONST(0.881921231746674) }, + { FRAC_CONST(-0.514102756977081), FRAC_CONST(0.857728600502014) }, + { FRAC_CONST(-0.555570363998413), FRAC_CONST(0.831469535827637) }, + { FRAC_CONST(-0.595699369907379), FRAC_CONST(0.803207516670227) }, + { FRAC_CONST(-0.634393274784088), FRAC_CONST(0.773010492324829) }, + { FRAC_CONST(-0.671559035778046), FRAC_CONST(0.740951061248779) }, + { FRAC_CONST(-0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(-0.740951240062714), FRAC_CONST(0.671558856964111) }, + { FRAC_CONST(-0.773010492324829), FRAC_CONST(0.634393274784088) }, + { FRAC_CONST(-0.803207635879517), FRAC_CONST(0.595699131488800) }, + { FRAC_CONST(-0.831469655036926), FRAC_CONST(0.555570185184479) }, + { FRAC_CONST(-0.857728600502014), FRAC_CONST(0.514102756977081) }, + { FRAC_CONST(-0.881921350955963), FRAC_CONST(0.471396625041962) }, + { FRAC_CONST(-0.903989315032959), FRAC_CONST(0.427555054426193) }, + { FRAC_CONST(-0.923879623413086), FRAC_CONST(0.382683277130127) }, + { FRAC_CONST(-0.941544115543365), FRAC_CONST(0.336889803409576) }, + { FRAC_CONST(-0.956940352916718), FRAC_CONST(0.290284723043442) }, + { FRAC_CONST(-0.970031261444092), FRAC_CONST(0.242980077862740) }, + { FRAC_CONST(-0.980785310268402), FRAC_CONST(0.195090308785439) }, + { FRAC_CONST(-0.989176511764526), FRAC_CONST(0.146730333566666) }, + { FRAC_CONST(-0.995184719562531), FRAC_CONST(0.098017096519470) }, + { FRAC_CONST(-0.998795449733734), FRAC_CONST(0.049067486077547) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.997290432453156), FRAC_CONST(0.073564566671848) }, + { FRAC_CONST(0.989176511764526), FRAC_CONST(0.146730467677116) }, + { FRAC_CONST(0.975702106952667), FRAC_CONST(0.219101235270500) }, + { FRAC_CONST(0.956940352916718), FRAC_CONST(0.290284663438797) }, + { FRAC_CONST(0.932992815971375), FRAC_CONST(0.359895050525665) }, + { FRAC_CONST(0.903989315032959), FRAC_CONST(0.427555084228516) }, + { FRAC_CONST(0.870086967945099), FRAC_CONST(0.492898225784302) }, + { FRAC_CONST(0.831469595432281), FRAC_CONST(0.555570244789124) }, + { FRAC_CONST(0.788346469402313), FRAC_CONST(0.615231573581696) }, + { FRAC_CONST(0.740951120853424), FRAC_CONST(0.671558976173401) }, + { FRAC_CONST(0.689540505409241), FRAC_CONST(0.724247097969055) }, + { FRAC_CONST(0.634393274784088), FRAC_CONST(0.773010432720184) }, + { FRAC_CONST(0.575808227062225), FRAC_CONST(0.817584812641144) }, + { FRAC_CONST(0.514102697372437), FRAC_CONST(0.857728660106659) }, + { FRAC_CONST(0.449611306190491), FRAC_CONST(0.893224298954010) }, + { FRAC_CONST(0.382683426141739), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(0.313681751489639), FRAC_CONST(0.949528157711029) }, + { FRAC_CONST(0.242980241775513), FRAC_CONST(0.970031261444092) }, + { FRAC_CONST(0.170961856842041), FRAC_CONST(0.985277652740479) }, + { FRAC_CONST(0.098017133772373), FRAC_CONST(0.995184719562531) }, + { FRAC_CONST(0.024541255086660), FRAC_CONST(0.999698817729950) }, + { FRAC_CONST(-0.049067739397287), FRAC_CONST(0.998795449733734) }, + { FRAC_CONST(-0.122410707175732), FRAC_CONST(0.992479503154755) }, + { FRAC_CONST(-0.195090323686600), FRAC_CONST(0.980785250663757) }, + { FRAC_CONST(-0.266712725162506), FRAC_CONST(0.963776051998138) }, + { FRAC_CONST(-0.336889803409576), FRAC_CONST(0.941544055938721) }, + { FRAC_CONST(-0.405241340398788), FRAC_CONST(0.914209723472595) }, + { FRAC_CONST(-0.471396833658218), FRAC_CONST(0.881921231746674) }, + { FRAC_CONST(-0.534997701644897), FRAC_CONST(0.844853520393372) }, + { FRAC_CONST(-0.595699369907379), FRAC_CONST(0.803207516670227) }, + { FRAC_CONST(-0.653172850608826), FRAC_CONST(0.757208824157715) }, + { FRAC_CONST(-0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(-0.757208824157715), FRAC_CONST(0.653172850608826) }, + { FRAC_CONST(-0.803207516670227), FRAC_CONST(0.595699369907379) }, + { FRAC_CONST(-0.844853520393372), FRAC_CONST(0.534997701644897) }, + { FRAC_CONST(-0.881921231746674), FRAC_CONST(0.471396833658218) }, + { FRAC_CONST(-0.914209783077240), FRAC_CONST(0.405241221189499) }, + { FRAC_CONST(-0.941544115543365), FRAC_CONST(0.336889803409576) }, + { FRAC_CONST(-0.963776051998138), FRAC_CONST(0.266712725162506) }, + { FRAC_CONST(-0.980785310268402), FRAC_CONST(0.195090308785439) }, + { FRAC_CONST(-0.992479503154755), FRAC_CONST(0.122410699725151) }, + { FRAC_CONST(-0.998795449733734), FRAC_CONST(0.049067724496126) }, + { FRAC_CONST(-0.999698817729950), FRAC_CONST(-0.024541147053242) }, + { FRAC_CONST(-0.995184719562531), FRAC_CONST(-0.098017267882824) }, + { FRAC_CONST(-0.985277652740479), FRAC_CONST(-0.170961990952492) }, + { FRAC_CONST(-0.970031261444092), FRAC_CONST(-0.242980241775513) }, + { FRAC_CONST(-0.949528157711029), FRAC_CONST(-0.313681781291962) }, + { FRAC_CONST(-0.923879504203796), FRAC_CONST(-0.382683426141739) }, + { FRAC_CONST(-0.893224298954010), FRAC_CONST(-0.449611306190491) }, + { FRAC_CONST(-0.857728660106659), FRAC_CONST(-0.514102697372437) }, + { FRAC_CONST(-0.817584872245789), FRAC_CONST(-0.575808107852936) }, + { FRAC_CONST(-0.773010551929474), FRAC_CONST(-0.634393215179443) }, + { FRAC_CONST(-0.724247038364410), FRAC_CONST(-0.689540624618530) }, + { FRAC_CONST(-0.671558916568756), FRAC_CONST(-0.740951180458069) }, + { FRAC_CONST(-0.615231573581696), FRAC_CONST(-0.788346469402313) }, + { FRAC_CONST(-0.555570006370544), FRAC_CONST(-0.831469774246216) }, + { FRAC_CONST(-0.492898195981979), FRAC_CONST(-0.870086967945099) }, + { FRAC_CONST(-0.427554935216904), FRAC_CONST(-0.903989374637604) }, + { FRAC_CONST(-0.359895110130310), FRAC_CONST(-0.932992756366730) }, + { FRAC_CONST(-0.290284544229507), FRAC_CONST(-0.956940352916718) }, + { FRAC_CONST(-0.219101369380951), FRAC_CONST(-0.975702106952667) }, + { FRAC_CONST(-0.146730408072472), FRAC_CONST(-0.989176511764526) }, + { FRAC_CONST(-0.073564760386944), FRAC_CONST(-0.997290432453156) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.995184719562531), FRAC_CONST(0.098017141222954) }, + { FRAC_CONST(0.980785250663757), FRAC_CONST(0.195090323686600) }, + { FRAC_CONST(0.956940352916718), FRAC_CONST(0.290284663438797) }, + { FRAC_CONST(0.923879504203796), FRAC_CONST(0.382683455944061) }, + { FRAC_CONST(0.881921231746674), FRAC_CONST(0.471396744251251) }, + { FRAC_CONST(0.831469595432281), FRAC_CONST(0.555570244789124) }, + { FRAC_CONST(0.773010432720184), FRAC_CONST(0.634393334388733) }, + { FRAC_CONST(0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(0.634393274784088), FRAC_CONST(0.773010432720184) }, + { FRAC_CONST(0.555570185184479), FRAC_CONST(0.831469655036926) }, + { FRAC_CONST(0.471396654844284), FRAC_CONST(0.881921291351318) }, + { FRAC_CONST(0.382683426141739), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(0.290284633636475), FRAC_CONST(0.956940352916718) }, + { FRAC_CONST(0.195090234279633), FRAC_CONST(0.980785310268402) }, + { FRAC_CONST(0.098017133772373), FRAC_CONST(0.995184719562531) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.980785250663757), FRAC_CONST(0.195090323686600) }, + { FRAC_CONST(0.923879504203796), FRAC_CONST(0.382683455944061) }, + { FRAC_CONST(0.831469595432281), FRAC_CONST(0.555570244789124) }, + { FRAC_CONST(0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(0.555570185184479), FRAC_CONST(0.831469655036926) }, + { FRAC_CONST(0.382683426141739), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(0.195090234279633), FRAC_CONST(0.980785310268402) }, + { FRAC_CONST(-0.000000043711388), FRAC_CONST(1.000000000000000) }, + { FRAC_CONST(-0.195090323686600), FRAC_CONST(0.980785250663757) }, + { FRAC_CONST(-0.382683515548706), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(-0.555570363998413), FRAC_CONST(0.831469535827637) }, + { FRAC_CONST(-0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(-0.831469655036926), FRAC_CONST(0.555570185184479) }, + { FRAC_CONST(-0.923879623413086), FRAC_CONST(0.382683277130127) }, + { FRAC_CONST(-0.980785310268402), FRAC_CONST(0.195090308785439) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.956940352916718), FRAC_CONST(0.290284663438797) }, + { FRAC_CONST(0.831469595432281), FRAC_CONST(0.555570244789124) }, + { FRAC_CONST(0.634393274784088), FRAC_CONST(0.773010432720184) }, + { FRAC_CONST(0.382683426141739), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(0.098017133772373), FRAC_CONST(0.995184719562531) }, + { FRAC_CONST(-0.195090323686600), FRAC_CONST(0.980785250663757) }, + { FRAC_CONST(-0.471396833658218), FRAC_CONST(0.881921231746674) }, + { FRAC_CONST(-0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(-0.881921231746674), FRAC_CONST(0.471396833658218) }, + { FRAC_CONST(-0.980785310268402), FRAC_CONST(0.195090308785439) }, + { FRAC_CONST(-0.995184719562531), FRAC_CONST(-0.098017267882824) }, + { FRAC_CONST(-0.923879504203796), FRAC_CONST(-0.382683426141739) }, + { FRAC_CONST(-0.773010551929474), FRAC_CONST(-0.634393215179443) }, + { FRAC_CONST(-0.555570006370544), FRAC_CONST(-0.831469774246216) }, + { FRAC_CONST(-0.290284544229507), FRAC_CONST(-0.956940352916718) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.923879504203796), FRAC_CONST(0.382683455944061) }, + { FRAC_CONST(0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(0.382683426141739), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(-0.000000043711388), FRAC_CONST(1.000000000000000) }, + { FRAC_CONST(-0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.382683426141739), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(-0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(-0.923879504203796), FRAC_CONST(-0.382683426141739) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.000000011924881), FRAC_CONST(-1.000000000000000) } }; -complex_t cfft_tab_480[] = +#ifdef ALLOW_SMALL_FRAMELENGTH +ALIGN static const complex_t cfft_tab_480[] = { - { 0x10000000, 0x0 }, - { 0xFFFA630, 0x359D6F }, - { 0xFFE98B0, 0x6B3885 }, - { 0xFFCD790, 0xA0CEE7 }, - { 0xFFA62F0, 0xD65E3B }, - { 0xFF73AF0, 0x10BE428 }, - { 0xFF35F90, 0x1415E54 }, - { 0xFEED120, 0x176CA68 }, - { 0xFE98FD0, 0x1AC260A }, - { 0xFE39BC0, 0x1E16EE6 }, - { 0xFDCF550, 0x216A2A4 }, - { 0xFD59CB0, 0x24BBEEC }, - { 0xFCD9250, 0x280C170 }, - { 0xFC4D670, 0x2B5A7D4 }, - { 0xFBB6980, 0x2EA6FCC }, - { 0xFB14BE0, 0x31F1708 }, - { 0xFA67E20, 0x3539B38 }, - { 0xF9B0090, 0x387FA0C }, - { 0xF8ED3C0, 0x3BC3138 }, - { 0xF81F840, 0x3F03E70 }, - { 0xF746EA0, 0x4241F70 }, - { 0xF663770, 0x457D1F0 }, - { 0xF575360, 0x48B53B0 }, - { 0xF47C300, 0x4BEA268 }, - { 0xF378710, 0x4F1BBD0 }, - { 0xF26A030, 0x5249DB0 }, - { 0xF150F40, 0x55745E0 }, - { 0xF02D4F0, 0x589B210 }, - { 0xEEFF200, 0x5BBE008 }, - { 0xEDC6770, 0x5EDCDA0 }, - { 0xEC835E0, 0x61F78B0 }, - { 0xEB35E60, 0x650DEF8 }, - { 0xE9DE1D0, 0x681FE48 }, - { 0xE87C120, 0x6B2D490 }, - { 0xE70FD40, 0x6E35FA0 }, - { 0xE599740, 0x7139D58 }, - { 0xE419010, 0x7438B90 }, - { 0xE28E8D0, 0x7732838 }, - { 0xE0FA280, 0x7A27140 }, - { 0xDF5BE60, 0x7D16488 }, - { 0xDDB3D70, 0x8000000 }, - { 0xDC020F0, 0x82E41B0 }, - { 0xDA46A00, 0x85C2770 }, - { 0xD8819E0, 0x889AF60 }, - { 0xD6B31D0, 0x8B6D770 }, - { 0xD4DB310, 0x8E39DA0 }, - { 0xD2F9EF0, 0x9100000 }, - { 0xD10F6B0, 0x93BFCA0 }, - { 0xCF1BBD0, 0x9679180 }, - { 0xCD1EF80, 0x992BCD0 }, - { 0xCB19340, 0x9BD7CA0 }, - { 0xC90A870, 0x9E7CF10 }, - { 0xC6F3090, 0xA11B240 }, - { 0xC4D2D10, 0xA3B2460 }, - { 0xC2A9F70, 0xA6423B0 }, - { 0xC078920, 0xA8CAE40 }, - { 0xBE3EBD0, 0xAB4C250 }, - { 0xBBFC8F0, 0xADC5E30 }, - { 0xB9B2230, 0xB038010 }, - { 0xB75F900, 0xB2A2660 }, - { 0xB504F30, 0xB504F30 }, - { 0xB2A2650, 0xB75F910 }, - { 0xB038010, 0xB9B2230 }, - { 0xADC5E20, 0xBBFC900 }, - { 0xAB4C240, 0xBE3EBE0 }, - { 0xA8CAE30, 0xC078930 }, - { 0xA6423A0, 0xC2A9F70 }, - { 0xA3B2460, 0xC4D2D20 }, - { 0xA11B240, 0xC6F30A0 }, - { 0x9E7CF10, 0xC90A880 }, - { 0x9BD7C90, 0xCB19350 }, - { 0x992BCD0, 0xCD1EF90 }, - { 0x9679180, 0xCF1BBD0 }, - { 0x93BFC90, 0xD10F6C0 }, - { 0x9100000, 0xD2F9EF0 }, - { 0x8E39D90, 0xD4DB320 }, - { 0x8B6D760, 0xD6B31E0 }, - { 0x889AF60, 0xD8819E0 }, - { 0x85C2760, 0xDA46A10 }, - { 0x82E41B0, 0xDC020F0 }, - { 0x7FFFFF8, 0xDDB3D80 }, - { 0x7D16470, 0xDF5BE70 }, - { 0x7A27138, 0xE0FA290 }, - { 0x7732828, 0xE28E8D0 }, - { 0x7438B90, 0xE419010 }, - { 0x7139D48, 0xE599740 }, - { 0x6E35F88, 0xE70FD50 }, - { 0x6B2D490, 0xE87C120 }, - { 0x681FE40, 0xE9DE1E0 }, - { 0x650DEE0, 0xEB35E70 }, - { 0x61F78A8, 0xEC835E0 }, - { 0x5EDCD98, 0xEDC6770 }, - { 0x5BBDFF0, 0xEEFF210 }, - { 0x589B208, 0xF02D4F0 }, - { 0x55745D0, 0xF150F40 }, - { 0x5249DB8, 0xF26A030 }, - { 0x4F1BBC8, 0xF378710 }, - { 0x4BEA250, 0xF47C300 }, - { 0x48B53A8, 0xF575360 }, - { 0x457D1E0, 0xF663780 }, - { 0x4241F78, 0xF746EA0 }, - { 0x3F03E68, 0xF81F840 }, - { 0x3BC3124, 0xF8ED3C0 }, - { 0x387FA0C, 0xF9B0090 }, - { 0x3539B2C, 0xFA67E20 }, - { 0x31F16F0, 0xFB14BF0 }, - { 0x2EA6FCC, 0xFBB6980 }, - { 0x2B5A7C4, 0xFC4D670 }, - { 0x280C154, 0xFCD9250 }, - { 0x24BBEE4, 0xFD59CB0 }, - { 0x216A290, 0xFDCF550 }, - { 0x1E16EE6, 0xFE39BC0 }, - { 0x1AC25FE, 0xFE98FD0 }, - { 0x176CA50, 0xFEED120 }, - { 0x1415E50, 0xFF35F90 }, - { 0x10BE418, 0xFF73AF0 }, - { 0xD65E3F, 0xFFA62F0 }, - { 0xA0CEDF, 0xFFCD790 }, - { 0x6B3871, 0xFFE98B0 }, - { 0x359D70, 0xFFFA630 }, - { 0xFFFFFFF5, 0x10000000 }, - { 0xFFCA6279, 0xFFFA630 }, - { 0xFF94C777, 0xFFE98B0 }, - { 0xFF5F3109, 0xFFCD790 }, - { 0xFF29A1AA, 0xFFA62F0 }, - { 0xFEF41BD0, 0xFF73AF0 }, - { 0xFEBEA198, 0xFF35F90 }, - { 0xFE893598, 0xFEED120 }, - { 0xFE53D9EA, 0xFE98FD0 }, - { 0xFE1E9102, 0xFE39BC0 }, - { 0xFDE95D58, 0xFDCF550 }, - { 0xFDB44104, 0xFD59CB0 }, - { 0xFD7F3E98, 0xFCD9250 }, - { 0xFD4A5824, 0xFC4D670 }, - { 0xFD159020, 0xFBB6980 }, - { 0xFCE0E8F8, 0xFB14BE0 }, - { 0xFCAC64BC, 0xFA67E10 }, - { 0xFC7805E0, 0xF9B0080 }, - { 0xFC43CEC4, 0xF8ED3C0 }, - { 0xFC0FC180, 0xF81F840 }, - { 0xFBDBE070, 0xF746EA0 }, - { 0xFBA82E08, 0xF663770 }, - { 0xFB74AC40, 0xF575350 }, - { 0xFB415DA0, 0xF47C300 }, - { 0xFB0E4428, 0xF378700 }, - { 0xFADB6230, 0xF26A030 }, - { 0xFAA8BA20, 0xF150F40 }, - { 0xFA764DE8, 0xF02D4E0 }, - { 0xFA441FF8, 0xEEFF210 }, - { 0xFA123250, 0xEDC6760 }, - { 0xF9E08740, 0xEC835E0 }, - { 0xF9AF2110, 0xEB35E70 }, - { 0xF97E01A8, 0xE9DE1D0 }, - { 0xF94D2B58, 0xE87C110 }, - { 0xF91CA060, 0xE70FD40 }, - { 0xF8EC62C0, 0xE599740 }, - { 0xF8BC7458, 0xE419000 }, - { 0xF88CD7C0, 0xE28E8C0 }, - { 0xF85D8ED0, 0xE0FA290 }, - { 0xF82E9B60, 0xDF5BE50 }, - { 0xF7FFFFF0, 0xDDB3D70 }, - { 0xF7D1BE60, 0xDC020F0 }, - { 0xF7A3D870, 0xDA469F0 }, - { 0xF7765090, 0xD8819E0 }, - { 0xF7492890, 0xD6B31D0 }, - { 0xF71C6240, 0xD4DB300 }, - { 0xF6EFFFF0, 0xD2F9EE0 }, - { 0xF6C40360, 0xD10F6C0 }, - { 0xF6986E90, 0xCF1BBD0 }, - { 0xF66D4320, 0xCD1EF70 }, - { 0xF6428360, 0xCB19340 }, - { 0xF6183100, 0xC90A880 }, - { 0xF5EE4DA0, 0xC6F3080 }, - { 0xF5C4DB90, 0xC4D2D10 }, - { 0xF59BDC60, 0xC2A9F70 }, - { 0xF57351B0, 0xC078910 }, - { 0xF54B3DA0, 0xBE3EBD0 }, - { 0xF523A1D0, 0xBBFC8F0 }, - { 0xF4FC7FD0, 0xB9B2210 }, - { 0xF4D5D9A0, 0xB75F8F0 }, - { 0xF4AFB0D0, 0xB504F30 }, - { 0xF48A06E0, 0xB2A2630 }, - { 0xF464DDC0, 0xB038000 }, - { 0xF4403700, 0xADC5E20 }, - { 0xF41C1410, 0xAB4C220 }, - { 0xF3F876C0, 0xA8CAE20 }, - { 0xF3D56080, 0xA6423A0 }, - { 0xF3B2D2F0, 0xA3B2470 }, - { 0xF390CF50, 0xA11B220 }, - { 0xF36F5780, 0x9E7CF00 }, - { 0xF34E6CC0, 0x9BD7CA0 }, - { 0xF32E1060, 0x992BCB0 }, - { 0xF30E4420, 0x9679170 }, - { 0xF2EF0940, 0x93BFCA0 }, - { 0xF2D060F0, 0x90FFFE0 }, - { 0xF2B24CE0, 0x8E39D90 }, - { 0xF294CE30, 0x8B6D770 }, - { 0xF277E600, 0x889AF30 }, - { 0xF25B95F0, 0x85C2760 }, - { 0xF23FDF10, 0x82E41A0 }, - { 0xF224C290, 0x8000010 }, - { 0xF20A4190, 0x7D16468 }, - { 0xF1F05D70, 0x7A27130 }, - { 0xF1D71730, 0x7732840 }, - { 0xF1BE6FE0, 0x7438B68 }, - { 0xF1A668C0, 0x7139D40 }, - { 0xF18F02C0, 0x6E35FA0 }, - { 0xF1783ED0, 0x6B2D468 }, - { 0xF1621E20, 0x681FE38 }, - { 0xF14CA190, 0x650DEF0 }, - { 0xF137CA00, 0x61F7880 }, - { 0xF1239890, 0x5EDCD88 }, - { 0xF1100DF0, 0x5BBE000 }, - { 0xF0FD2B00, 0x589B1E0 }, - { 0xF0EAF0B0, 0x55745C0 }, - { 0xF0D95FC0, 0x5249DB0 }, - { 0xF0C878E0, 0x4F1BB98 }, - { 0xF0B83CF0, 0x4BEA240 }, - { 0xF0A8ACA0, 0x48B53A0 }, - { 0xF099C890, 0x457D1F8 }, - { 0xF08B9150, 0x4241F50 }, - { 0xF07E07B0, 0x3F03E60 }, - { 0xF0712C40, 0x3BC3138 }, - { 0xF064FF70, 0x387F9E0 }, - { 0xF05981E0, 0x3539B20 }, - { 0xF04EB410, 0x31F1704 }, - { 0xF0449680, 0x2EA6FA0 }, - { 0xF03B2990, 0x2B5A7B8 }, - { 0xF0326DB0, 0x280C168 }, - { 0xF02A6340, 0x24BBEB8 }, - { 0xF0230AB0, 0x216A284 }, - { 0xF01C6440, 0x1E16EDA }, - { 0xF0167030, 0x1AC2612 }, - { 0xF0112ED0, 0x176CA44 }, - { 0xF00CA060, 0x1415E44 }, - { 0xF008C510, 0x10BE42C }, - { 0xF0059D00, 0xD65E13 }, - { 0xF0032870, 0xA0CED3 }, - { 0xF0016750, 0x6B3886 }, - { 0xF00059D0, 0x359D44 }, - { 0x10000000, 0x0 }, - { 0xFFE98B0, 0x6B3885 }, - { 0xFFA62F0, 0xD65E3B }, - { 0xFF35F90, 0x1415E54 }, - { 0xFE98FD0, 0x1AC260A }, - { 0xFDCF550, 0x216A2A4 }, - { 0xFCD9250, 0x280C170 }, - { 0xFBB6980, 0x2EA6FCC }, - { 0xFA67E20, 0x3539B38 }, - { 0xF8ED3C0, 0x3BC3138 }, - { 0xF746EA0, 0x4241F70 }, - { 0xF575360, 0x48B53B0 }, - { 0xF378710, 0x4F1BBD0 }, - { 0xF150F40, 0x55745E0 }, - { 0xEEFF200, 0x5BBE008 }, - { 0xEC835E0, 0x61F78B0 }, - { 0xE9DE1D0, 0x681FE48 }, - { 0xE70FD40, 0x6E35FA0 }, - { 0xE419010, 0x7438B90 }, - { 0xE0FA280, 0x7A27140 }, - { 0xDDB3D70, 0x8000000 }, - { 0xDA46A00, 0x85C2770 }, - { 0xD6B31D0, 0x8B6D770 }, - { 0xD2F9EF0, 0x9100000 }, - { 0xCF1BBD0, 0x9679180 }, - { 0xCB19340, 0x9BD7CA0 }, - { 0xC6F3090, 0xA11B240 }, - { 0xC2A9F70, 0xA6423B0 }, - { 0xBE3EBD0, 0xAB4C250 }, - { 0xB9B2230, 0xB038010 }, - { 0xB504F30, 0xB504F30 }, - { 0xB038010, 0xB9B2230 }, - { 0xAB4C240, 0xBE3EBE0 }, - { 0xA6423A0, 0xC2A9F70 }, - { 0xA11B240, 0xC6F30A0 }, - { 0x9BD7C90, 0xCB19350 }, - { 0x9679180, 0xCF1BBD0 }, - { 0x9100000, 0xD2F9EF0 }, - { 0x8B6D760, 0xD6B31E0 }, - { 0x85C2760, 0xDA46A10 }, - { 0x7FFFFF8, 0xDDB3D80 }, - { 0x7A27138, 0xE0FA290 }, - { 0x7438B90, 0xE419010 }, - { 0x6E35F88, 0xE70FD50 }, - { 0x681FE40, 0xE9DE1E0 }, - { 0x61F78A8, 0xEC835E0 }, - { 0x5BBDFF0, 0xEEFF210 }, - { 0x55745D0, 0xF150F40 }, - { 0x4F1BBC8, 0xF378710 }, - { 0x48B53A8, 0xF575360 }, - { 0x4241F78, 0xF746EA0 }, - { 0x3BC3124, 0xF8ED3C0 }, - { 0x3539B2C, 0xFA67E20 }, - { 0x2EA6FCC, 0xFBB6980 }, - { 0x280C154, 0xFCD9250 }, - { 0x216A290, 0xFDCF550 }, - { 0x1AC25FE, 0xFE98FD0 }, - { 0x1415E50, 0xFF35F90 }, - { 0xD65E3F, 0xFFA62F0 }, - { 0x6B3871, 0xFFE98B0 }, - { 0xFFFFFFF5, 0x10000000 }, - { 0xFF94C777, 0xFFE98B0 }, - { 0xFF29A1AA, 0xFFA62F0 }, - { 0xFEBEA198, 0xFF35F90 }, - { 0xFE53D9EA, 0xFE98FD0 }, - { 0xFDE95D58, 0xFDCF550 }, - { 0xFD7F3E98, 0xFCD9250 }, - { 0xFD159020, 0xFBB6980 }, - { 0xFCAC64BC, 0xFA67E10 }, - { 0xFC43CEC4, 0xF8ED3C0 }, - { 0xFBDBE070, 0xF746EA0 }, - { 0xFB74AC40, 0xF575350 }, - { 0xFB0E4428, 0xF378700 }, - { 0xFAA8BA20, 0xF150F40 }, - { 0xFA441FF8, 0xEEFF210 }, - { 0xF9E08740, 0xEC835E0 }, - { 0xF97E01A8, 0xE9DE1D0 }, - { 0xF91CA060, 0xE70FD40 }, - { 0xF8BC7458, 0xE419000 }, - { 0xF85D8ED0, 0xE0FA290 }, - { 0x10000000, 0x0 }, - { 0xFFA62F0, 0xD65E3B }, - { 0xFE98FD0, 0x1AC260A }, - { 0xFCD9250, 0x280C170 }, - { 0xFA67E20, 0x3539B38 }, - { 0xF746EA0, 0x4241F70 }, - { 0xF378710, 0x4F1BBD0 }, - { 0xEEFF200, 0x5BBE008 }, - { 0xE9DE1D0, 0x681FE48 }, - { 0xE419010, 0x7438B90 }, - { 0xDDB3D70, 0x8000000 }, - { 0xD6B31D0, 0x8B6D770 }, - { 0xCF1BBD0, 0x9679180 }, - { 0xC6F3090, 0xA11B240 }, - { 0xBE3EBD0, 0xAB4C250 }, - { 0xB504F30, 0xB504F30 }, - { 0xAB4C240, 0xBE3EBE0 }, - { 0xA11B240, 0xC6F30A0 }, - { 0x9679180, 0xCF1BBD0 }, - { 0x8B6D760, 0xD6B31E0 }, - { 0x7FFFFF8, 0xDDB3D80 }, - { 0x7438B90, 0xE419010 }, - { 0x681FE40, 0xE9DE1E0 }, - { 0x5BBDFF0, 0xEEFF210 }, - { 0x4F1BBC8, 0xF378710 }, - { 0x4241F78, 0xF746EA0 }, - { 0x3539B2C, 0xFA67E20 }, - { 0x280C154, 0xFCD9250 }, - { 0x1AC25FE, 0xFE98FD0 }, - { 0xD65E3F, 0xFFA62F0 }, - { 0xFFFFFFF5, 0x10000000 }, - { 0xFF29A1AA, 0xFFA62F0 }, - { 0xFE53D9EA, 0xFE98FD0 }, - { 0xFD7F3E98, 0xFCD9250 }, - { 0xFCAC64BC, 0xFA67E10 }, - { 0xFBDBE070, 0xF746EA0 }, - { 0xFB0E4428, 0xF378700 }, - { 0xFA441FF8, 0xEEFF210 }, - { 0xF97E01A8, 0xE9DE1D0 }, - { 0xF8BC7458, 0xE419000 }, - { 0xF7FFFFF0, 0xDDB3D70 }, - { 0xF7492890, 0xD6B31D0 }, - { 0xF6986E90, 0xCF1BBD0 }, - { 0xF5EE4DA0, 0xC6F3080 }, - { 0xF54B3DA0, 0xBE3EBD0 }, - { 0xF4AFB0D0, 0xB504F30 }, - { 0xF41C1410, 0xAB4C220 }, - { 0xF390CF50, 0xA11B220 }, - { 0xF30E4420, 0x9679170 }, - { 0xF294CE30, 0x8B6D770 }, - { 0xF224C290, 0x8000010 }, - { 0xF1BE6FE0, 0x7438B68 }, - { 0xF1621E20, 0x681FE38 }, - { 0xF1100DF0, 0x5BBE000 }, - { 0xF0C878E0, 0x4F1BB98 }, - { 0xF08B9150, 0x4241F50 }, - { 0xF05981E0, 0x3539B20 }, - { 0xF0326DB0, 0x280C168 }, - { 0xF0167030, 0x1AC2612 }, - { 0xF0059D00, 0xD65E13 }, - { 0xF0000000, 0xFFFFFFE9 }, - { 0xF0059D10, 0xFF29A1BE }, - { 0xF0167040, 0xFE53D9BE }, - { 0xF0326DC0, 0xFD7F3E6C }, - { 0xF05981F0, 0xFCAC64B0 }, - { 0xF08B9160, 0xFBDBE088 }, - { 0xF0C878F0, 0xFB0E4438 }, - { 0xF1100E00, 0xFA441FD0 }, - { 0xF1621E30, 0xF97E01A0 }, - { 0xF1BE6FF0, 0xF8BC7468 }, - { 0xF224C2B0, 0xF7FFFFD0 }, - { 0xF294CE40, 0xF7492870 }, - { 0xF30E4440, 0xF6986E60 }, - { 0xF390CF70, 0xF5EE4DB0 }, - { 0xF41C1430, 0xF54B3DB0 }, - { 0xF4AFB0F0, 0xF4AFB0B0 }, - { 0xF54B3DD0, 0xF41C1420 }, - { 0xF5EE4DD0, 0xF390CF60 }, - { 0xF6986EB0, 0xF30E4410 }, - { 0xF7492880, 0xF294CE30 }, - { 0x10000000, 0x0 }, - { 0xFF35F90, 0x1415E54 }, - { 0xFCD9250, 0x280C170 }, - { 0xF8ED3C0, 0x3BC3138 }, - { 0xF378710, 0x4F1BBD0 }, - { 0xEC835E0, 0x61F78B0 }, - { 0xE419010, 0x7438B90 }, - { 0xDA46A00, 0x85C2770 }, - { 0xCF1BBD0, 0x9679180 }, - { 0xC2A9F70, 0xA6423B0 }, - { 0xB504F30, 0xB504F30 }, - { 0xA6423A0, 0xC2A9F70 }, - { 0x9679180, 0xCF1BBD0 }, - { 0x85C2760, 0xDA46A10 }, - { 0x7438B90, 0xE419010 }, - { 0x61F78A8, 0xEC835E0 }, - { 0x4F1BBC8, 0xF378710 }, - { 0x3BC3124, 0xF8ED3C0 }, - { 0x280C154, 0xFCD9250 }, - { 0x1415E50, 0xFF35F90 }, - { 0x10000000, 0x0 }, - { 0xFCD9250, 0x280C170 }, - { 0xF378710, 0x4F1BBD0 }, - { 0xE419010, 0x7438B90 }, - { 0xCF1BBD0, 0x9679180 }, - { 0xB504F30, 0xB504F30 }, - { 0x9679180, 0xCF1BBD0 }, - { 0x7438B90, 0xE419010 }, - { 0x4F1BBC8, 0xF378710 }, - { 0x280C154, 0xFCD9250 }, - { 0xFFFFFFF5, 0x10000000 }, - { 0xFD7F3E98, 0xFCD9250 }, - { 0xFB0E4428, 0xF378700 }, - { 0xF8BC7458, 0xE419000 }, - { 0xF6986E90, 0xCF1BBD0 }, - { 0xF4AFB0D0, 0xB504F30 }, - { 0xF30E4420, 0x9679170 }, - { 0xF1BE6FE0, 0x7438B68 }, - { 0xF0C878E0, 0x4F1BB98 }, - { 0xF0326DB0, 0x280C168 }, - { 0x10000000, 0x0 }, - { 0xF8ED3C0, 0x3BC3138 }, - { 0xE419010, 0x7438B90 }, - { 0xC2A9F70, 0xA6423B0 }, - { 0x9679180, 0xCF1BBD0 }, - { 0x61F78A8, 0xEC835E0 }, - { 0x280C154, 0xFCD9250 }, - { 0xFEBEA198, 0xFF35F90 }, - { 0xFB0E4428, 0xF378700 }, - { 0xF7A3D870, 0xDA469F0 }, - { 0xF4AFB0D0, 0xB504F30 }, - { 0xF25B95F0, 0x85C2760 }, - { 0xF0C878E0, 0x4F1BB98 }, - { 0xF00CA060, 0x1415E44 }, - { 0xF0326DC0, 0xFD7F3E6C }, - { 0xF137CA20, 0xF9E08758 }, - { 0xF30E4440, 0xF6986E60 }, - { 0xF59BDC80, 0xF3D56070 }, - { 0xF8BC74C0, 0xF1BE6FD0 }, - { 0xFC43CEB4, 0xF0712C40 }, - { 0x10000000, 0x0 }, - { 0xF378710, 0x4F1BBD0 }, - { 0xCF1BBD0, 0x9679180 }, - { 0x9679180, 0xCF1BBD0 }, - { 0x4F1BBC8, 0xF378710 }, - { 0x10000000, 0x0 }, - { 0xCF1BBD0, 0x9679180 }, - { 0x4F1BBC8, 0xF378710 }, - { 0xFB0E4428, 0xF378700 }, - { 0xF30E4420, 0x9679170 }, - { 0x10000000, 0x0 }, - { 0x9679180, 0xCF1BBD0 }, - { 0xFB0E4428, 0xF378700 }, - { 0xF0C878E0, 0x4F1BB98 }, - { 0xF30E4440, 0xF6986E60 }, - { 0x10000000, 0x0 }, - { 0x10000000, 0x0 }, - { 0x10000000, 0x0 }, - { 0x10000000, 0x0 }, - { 0x4F1BBF0, 0xF0C87900 } + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.999914348125458), FRAC_CONST(0.013089596293867) }, + { FRAC_CONST(0.999657332897186), FRAC_CONST(0.026176949962974) }, + { FRAC_CONST(0.999229013919830), FRAC_CONST(0.039259817451239) }, + { FRAC_CONST(0.998629510402679), FRAC_CONST(0.052335958927870) }, + { FRAC_CONST(0.997858941555023), FRAC_CONST(0.065403133630753) }, + { FRAC_CONST(0.996917307376862), FRAC_CONST(0.078459098935127) }, + { FRAC_CONST(0.995804905891418), FRAC_CONST(0.091501623392105) }, + { FRAC_CONST(0.994521915912628), FRAC_CONST(0.104528464376926) }, + { FRAC_CONST(0.993068456649780), FRAC_CONST(0.117537401616573) }, + { FRAC_CONST(0.991444885730743), FRAC_CONST(0.130526199936867) }, + { FRAC_CONST(0.989651381969452), FRAC_CONST(0.143492624163628) }, + { FRAC_CONST(0.987688362598419), FRAC_CONST(0.156434476375580) }, + { FRAC_CONST(0.985556066036224), FRAC_CONST(0.169349506497383) }, + { FRAC_CONST(0.983254909515381), FRAC_CONST(0.182235524058342) }, + { FRAC_CONST(0.980785250663757), FRAC_CONST(0.195090323686600) }, + { FRAC_CONST(0.978147625923157), FRAC_CONST(0.207911700010300) }, + { FRAC_CONST(0.975342333316803), FRAC_CONST(0.220697447657585) }, + { FRAC_CONST(0.972369909286499), FRAC_CONST(0.233445376157761) }, + { FRAC_CONST(0.969230890274048), FRAC_CONST(0.246153295040131) }, + { FRAC_CONST(0.965925812721252), FRAC_CONST(0.258819043636322) }, + { FRAC_CONST(0.962455213069916), FRAC_CONST(0.271440446376801) }, + { FRAC_CONST(0.958819746971130), FRAC_CONST(0.284015357494354) }, + { FRAC_CONST(0.955019950866699), FRAC_CONST(0.296541601419449) }, + { FRAC_CONST(0.951056540012360), FRAC_CONST(0.309017002582550) }, + { FRAC_CONST(0.946930110454559), FRAC_CONST(0.321439445018768) }, + { FRAC_CONST(0.942641496658325), FRAC_CONST(0.333806872367859) }, + { FRAC_CONST(0.938191354274750), FRAC_CONST(0.346117079257965) }, + { FRAC_CONST(0.933580398559570), FRAC_CONST(0.358367949724197) }, + { FRAC_CONST(0.928809583187103), FRAC_CONST(0.370557427406311) }, + { FRAC_CONST(0.923879504203796), FRAC_CONST(0.382683455944061) }, + { FRAC_CONST(0.918791174888611), FRAC_CONST(0.394743889570236) }, + { FRAC_CONST(0.913545429706573), FRAC_CONST(0.406736642122269) }, + { FRAC_CONST(0.908143162727356), FRAC_CONST(0.418659746646881) }, + { FRAC_CONST(0.902585268020630), FRAC_CONST(0.430511116981506) }, + { FRAC_CONST(0.896872758865356), FRAC_CONST(0.442288726568222) }, + { FRAC_CONST(0.891006529331207), FRAC_CONST(0.453990519046783) }, + { FRAC_CONST(0.884987652301788), FRAC_CONST(0.465614527463913) }, + { FRAC_CONST(0.878817081451416), FRAC_CONST(0.477158784866333) }, + { FRAC_CONST(0.872496008872986), FRAC_CONST(0.488621264696121) }, + { FRAC_CONST(0.866025388240814), FRAC_CONST(0.500000000000000) }, + { FRAC_CONST(0.859406411647797), FRAC_CONST(0.511293113231659) }, + { FRAC_CONST(0.852640151977539), FRAC_CONST(0.522498548030853) }, + { FRAC_CONST(0.845727801322937), FRAC_CONST(0.533614516258240) }, + { FRAC_CONST(0.838670551776886), FRAC_CONST(0.544639050960541) }, + { FRAC_CONST(0.831469595432281), FRAC_CONST(0.555570244789124) }, + { FRAC_CONST(0.824126183986664), FRAC_CONST(0.566406250000000) }, + { FRAC_CONST(0.816641509532928), FRAC_CONST(0.577145218849182) }, + { FRAC_CONST(0.809017002582550), FRAC_CONST(0.587785243988037) }, + { FRAC_CONST(0.801253795623779), FRAC_CONST(0.598324596881866) }, + { FRAC_CONST(0.793353319168091), FRAC_CONST(0.608761429786682) }, + { FRAC_CONST(0.785316884517670), FRAC_CONST(0.619093954563141) }, + { FRAC_CONST(0.777145922183990), FRAC_CONST(0.629320383071899) }, + { FRAC_CONST(0.768841803073883), FRAC_CONST(0.639438986778259) }, + { FRAC_CONST(0.760405957698822), FRAC_CONST(0.649448096752167) }, + { FRAC_CONST(0.751839756965637), FRAC_CONST(0.659345865249634) }, + { FRAC_CONST(0.743144810199738), FRAC_CONST(0.669130623340607) }, + { FRAC_CONST(0.734322488307953), FRAC_CONST(0.678800761699677) }, + { FRAC_CONST(0.725374400615692), FRAC_CONST(0.688354551792145) }, + { FRAC_CONST(0.716301918029785), FRAC_CONST(0.697790503501892) }, + { FRAC_CONST(0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(0.697790443897247), FRAC_CONST(0.716301977634430) }, + { FRAC_CONST(0.688354551792145), FRAC_CONST(0.725374400615692) }, + { FRAC_CONST(0.678800702095032), FRAC_CONST(0.734322547912598) }, + { FRAC_CONST(0.669130563735962), FRAC_CONST(0.743144869804382) }, + { FRAC_CONST(0.659345805644989), FRAC_CONST(0.751839816570282) }, + { FRAC_CONST(0.649448037147522), FRAC_CONST(0.760405957698822) }, + { FRAC_CONST(0.639438986778259), FRAC_CONST(0.768841862678528) }, + { FRAC_CONST(0.629320383071899), FRAC_CONST(0.777145981788635) }, + { FRAC_CONST(0.619093954563141), FRAC_CONST(0.785316944122314) }, + { FRAC_CONST(0.608761370182037), FRAC_CONST(0.793353378772736) }, + { FRAC_CONST(0.598324596881866), FRAC_CONST(0.801253855228424) }, + { FRAC_CONST(0.587785243988037), FRAC_CONST(0.809017002582550) }, + { FRAC_CONST(0.577145159244537), FRAC_CONST(0.816641569137573) }, + { FRAC_CONST(0.566406250000000), FRAC_CONST(0.824126183986664) }, + { FRAC_CONST(0.555570185184479), FRAC_CONST(0.831469655036926) }, + { FRAC_CONST(0.544638991355896), FRAC_CONST(0.838670611381531) }, + { FRAC_CONST(0.533614516258240), FRAC_CONST(0.845727801322937) }, + { FRAC_CONST(0.522498488426209), FRAC_CONST(0.852640211582184) }, + { FRAC_CONST(0.511293113231659), FRAC_CONST(0.859406411647797) }, + { FRAC_CONST(0.499999970197678), FRAC_CONST(0.866025447845459) }, + { FRAC_CONST(0.488621175289154), FRAC_CONST(0.872496068477631) }, + { FRAC_CONST(0.477158755064011), FRAC_CONST(0.878817141056061) }, + { FRAC_CONST(0.465614467859268), FRAC_CONST(0.884987652301788) }, + { FRAC_CONST(0.453990519046783), FRAC_CONST(0.891006529331207) }, + { FRAC_CONST(0.442288666963577), FRAC_CONST(0.896872758865356) }, + { FRAC_CONST(0.430511027574539), FRAC_CONST(0.902585327625275) }, + { FRAC_CONST(0.418659746646881), FRAC_CONST(0.908143162727356) }, + { FRAC_CONST(0.406736612319946), FRAC_CONST(0.913545489311218) }, + { FRAC_CONST(0.394743800163269), FRAC_CONST(0.918791234493256) }, + { FRAC_CONST(0.382683426141739), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(0.370557397603989), FRAC_CONST(0.928809583187103) }, + { FRAC_CONST(0.358367860317230), FRAC_CONST(0.933580458164215) }, + { FRAC_CONST(0.346117049455643), FRAC_CONST(0.938191354274750) }, + { FRAC_CONST(0.333806812763214), FRAC_CONST(0.942641496658325) }, + { FRAC_CONST(0.321439474821091), FRAC_CONST(0.946930110454559) }, + { FRAC_CONST(0.309016972780228), FRAC_CONST(0.951056540012360) }, + { FRAC_CONST(0.296541512012482), FRAC_CONST(0.955019950866699) }, + { FRAC_CONST(0.284015327692032), FRAC_CONST(0.958819746971130) }, + { FRAC_CONST(0.271440386772156), FRAC_CONST(0.962455272674561) }, + { FRAC_CONST(0.258819073438644), FRAC_CONST(0.965925812721252) }, + { FRAC_CONST(0.246153265237808), FRAC_CONST(0.969230890274048) }, + { FRAC_CONST(0.233445301651955), FRAC_CONST(0.972369909286499) }, + { FRAC_CONST(0.220697447657585), FRAC_CONST(0.975342333316803) }, + { FRAC_CONST(0.207911655306816), FRAC_CONST(0.978147625923157) }, + { FRAC_CONST(0.195090234279633), FRAC_CONST(0.980785310268402) }, + { FRAC_CONST(0.182235524058342), FRAC_CONST(0.983254909515381) }, + { FRAC_CONST(0.169349446892738), FRAC_CONST(0.985556066036224) }, + { FRAC_CONST(0.156434372067451), FRAC_CONST(0.987688362598419) }, + { FRAC_CONST(0.143492594361305), FRAC_CONST(0.989651381969452) }, + { FRAC_CONST(0.130526125431061), FRAC_CONST(0.991444885730743) }, + { FRAC_CONST(0.117537401616573), FRAC_CONST(0.993068456649780) }, + { FRAC_CONST(0.104528419673443), FRAC_CONST(0.994521915912628) }, + { FRAC_CONST(0.091501533985138), FRAC_CONST(0.995804905891418) }, + { FRAC_CONST(0.078459084033966), FRAC_CONST(0.996917307376862) }, + { FRAC_CONST(0.065403074026108), FRAC_CONST(0.997858941555023) }, + { FRAC_CONST(0.052335973829031), FRAC_CONST(0.998629510402679) }, + { FRAC_CONST(0.039259787648916), FRAC_CONST(0.999229013919830) }, + { FRAC_CONST(0.026176875457168), FRAC_CONST(0.999657332897186) }, + { FRAC_CONST(0.013089597225189), FRAC_CONST(0.999914348125458) }, + { FRAC_CONST(-0.000000043711388), FRAC_CONST(1.000000000000000) }, + { FRAC_CONST(-0.013089684769511), FRAC_CONST(0.999914348125458) }, + { FRAC_CONST(-0.026176963001490), FRAC_CONST(0.999657332897186) }, + { FRAC_CONST(-0.039259877055883), FRAC_CONST(0.999229013919830) }, + { FRAC_CONST(-0.052336059510708), FRAC_CONST(0.998629510402679) }, + { FRAC_CONST(-0.065403163433075), FRAC_CONST(0.997858941555023) }, + { FRAC_CONST(-0.078459173440933), FRAC_CONST(0.996917307376862) }, + { FRAC_CONST(-0.091501623392105), FRAC_CONST(0.995804905891418) }, + { FRAC_CONST(-0.104528509080410), FRAC_CONST(0.994521915912628) }, + { FRAC_CONST(-0.117537491023541), FRAC_CONST(0.993068456649780) }, + { FRAC_CONST(-0.130526214838028), FRAC_CONST(0.991444885730743) }, + { FRAC_CONST(-0.143492683768272), FRAC_CONST(0.989651381969452) }, + { FRAC_CONST(-0.156434446573257), FRAC_CONST(0.987688362598419) }, + { FRAC_CONST(-0.169349536299706), FRAC_CONST(0.985556066036224) }, + { FRAC_CONST(-0.182235598564148), FRAC_CONST(0.983254909515381) }, + { FRAC_CONST(-0.195090323686600), FRAC_CONST(0.980785250663757) }, + { FRAC_CONST(-0.207911744713783), FRAC_CONST(0.978147566318512) }, + { FRAC_CONST(-0.220697522163391), FRAC_CONST(0.975342273712158) }, + { FRAC_CONST(-0.233445391058922), FRAC_CONST(0.972369909286499) }, + { FRAC_CONST(-0.246153354644775), FRAC_CONST(0.969230890274048) }, + { FRAC_CONST(-0.258819162845612), FRAC_CONST(0.965925812721252) }, + { FRAC_CONST(-0.271440476179123), FRAC_CONST(0.962455213069916) }, + { FRAC_CONST(-0.284015417098999), FRAC_CONST(0.958819687366486) }, + { FRAC_CONST(-0.296541571617126), FRAC_CONST(0.955019950866699) }, + { FRAC_CONST(-0.309017032384872), FRAC_CONST(0.951056480407715) }, + { FRAC_CONST(-0.321439564228058), FRAC_CONST(0.946930110454559) }, + { FRAC_CONST(-0.333806872367859), FRAC_CONST(0.942641496658325) }, + { FRAC_CONST(-0.346117109060287), FRAC_CONST(0.938191294670105) }, + { FRAC_CONST(-0.358367949724197), FRAC_CONST(0.933580458164215) }, + { FRAC_CONST(-0.370557487010956), FRAC_CONST(0.928809523582459) }, + { FRAC_CONST(-0.382683515548706), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(-0.394743859767914), FRAC_CONST(0.918791234493256) }, + { FRAC_CONST(-0.406736701726913), FRAC_CONST(0.913545429706573) }, + { FRAC_CONST(-0.418659836053848), FRAC_CONST(0.908143103122711) }, + { FRAC_CONST(-0.430511116981506), FRAC_CONST(0.902585268020630) }, + { FRAC_CONST(-0.442288637161255), FRAC_CONST(0.896872758865356) }, + { FRAC_CONST(-0.453990608453751), FRAC_CONST(0.891006469726563) }, + { FRAC_CONST(-0.465614557266235), FRAC_CONST(0.884987592697144) }, + { FRAC_CONST(-0.477158725261688), FRAC_CONST(0.878817141056061) }, + { FRAC_CONST(-0.488621354103088), FRAC_CONST(0.872495949268341) }, + { FRAC_CONST(-0.500000059604645), FRAC_CONST(0.866025388240814) }, + { FRAC_CONST(-0.511293053627014), FRAC_CONST(0.859406411647797) }, + { FRAC_CONST(-0.522498667240143), FRAC_CONST(0.852640092372894) }, + { FRAC_CONST(-0.533614575862885), FRAC_CONST(0.845727801322937) }, + { FRAC_CONST(-0.544639050960541), FRAC_CONST(0.838670551776886) }, + { FRAC_CONST(-0.555570363998413), FRAC_CONST(0.831469535827637) }, + { FRAC_CONST(-0.566406309604645), FRAC_CONST(0.824126124382019) }, + { FRAC_CONST(-0.577145218849182), FRAC_CONST(0.816641569137573) }, + { FRAC_CONST(-0.587785184383392), FRAC_CONST(0.809017002582550) }, + { FRAC_CONST(-0.598324656486511), FRAC_CONST(0.801253736019135) }, + { FRAC_CONST(-0.608761429786682), FRAC_CONST(0.793353319168091) }, + { FRAC_CONST(-0.619093894958496), FRAC_CONST(0.785316944122314) }, + { FRAC_CONST(-0.629320502281189), FRAC_CONST(0.777145862579346) }, + { FRAC_CONST(-0.639439046382904), FRAC_CONST(0.768841803073883) }, + { FRAC_CONST(-0.649448037147522), FRAC_CONST(0.760405957698822) }, + { FRAC_CONST(-0.659345924854279), FRAC_CONST(0.751839697360992) }, + { FRAC_CONST(-0.669130682945251), FRAC_CONST(0.743144810199738) }, + { FRAC_CONST(-0.678800761699677), FRAC_CONST(0.734322488307953) }, + { FRAC_CONST(-0.688354671001434), FRAC_CONST(0.725374281406403) }, + { FRAC_CONST(-0.697790503501892), FRAC_CONST(0.716301858425140) }, + { FRAC_CONST(-0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(-0.716302037239075), FRAC_CONST(0.697790324687958) }, + { FRAC_CONST(-0.725374460220337), FRAC_CONST(0.688354492187500) }, + { FRAC_CONST(-0.734322547912598), FRAC_CONST(0.678800702095032) }, + { FRAC_CONST(-0.743144929409027), FRAC_CONST(0.669130444526672) }, + { FRAC_CONST(-0.751839876174927), FRAC_CONST(0.659345746040344) }, + { FRAC_CONST(-0.760406017303467), FRAC_CONST(0.649448037147522) }, + { FRAC_CONST(-0.768841803073883), FRAC_CONST(0.639439046382904) }, + { FRAC_CONST(-0.777146041393280), FRAC_CONST(0.629320263862610) }, + { FRAC_CONST(-0.785316944122314), FRAC_CONST(0.619093894958496) }, + { FRAC_CONST(-0.793353319168091), FRAC_CONST(0.608761429786682) }, + { FRAC_CONST(-0.801253914833069), FRAC_CONST(0.598324477672577) }, + { FRAC_CONST(-0.809017062187195), FRAC_CONST(0.587785184383392) }, + { FRAC_CONST(-0.816641569137573), FRAC_CONST(0.577145218849182) }, + { FRAC_CONST(-0.824126303195953), FRAC_CONST(0.566406130790710) }, + { FRAC_CONST(-0.831469655036926), FRAC_CONST(0.555570185184479) }, + { FRAC_CONST(-0.838670551776886), FRAC_CONST(0.544639050960541) }, + { FRAC_CONST(-0.845727920532227), FRAC_CONST(0.533614337444305) }, + { FRAC_CONST(-0.852640211582184), FRAC_CONST(0.522498488426209) }, + { FRAC_CONST(-0.859406411647797), FRAC_CONST(0.511293053627014) }, + { FRAC_CONST(-0.866025388240814), FRAC_CONST(0.500000059604645) }, + { FRAC_CONST(-0.872496068477631), FRAC_CONST(0.488621145486832) }, + { FRAC_CONST(-0.878817141056061), FRAC_CONST(0.477158725261688) }, + { FRAC_CONST(-0.884987652301788), FRAC_CONST(0.465614557266235) }, + { FRAC_CONST(-0.891006588935852), FRAC_CONST(0.453990370035172) }, + { FRAC_CONST(-0.896872758865356), FRAC_CONST(0.442288637161255) }, + { FRAC_CONST(-0.902585268020630), FRAC_CONST(0.430511116981506) }, + { FRAC_CONST(-0.908143222332001), FRAC_CONST(0.418659597635269) }, + { FRAC_CONST(-0.913545489311218), FRAC_CONST(0.406736582517624) }, + { FRAC_CONST(-0.918791234493256), FRAC_CONST(0.394743859767914) }, + { FRAC_CONST(-0.923879623413086), FRAC_CONST(0.382683277130127) }, + { FRAC_CONST(-0.928809583187103), FRAC_CONST(0.370557337999344) }, + { FRAC_CONST(-0.933580458164215), FRAC_CONST(0.358367919921875) }, + { FRAC_CONST(-0.938191413879395), FRAC_CONST(0.346116900444031) }, + { FRAC_CONST(-0.942641556262970), FRAC_CONST(0.333806753158569) }, + { FRAC_CONST(-0.946930170059204), FRAC_CONST(0.321439445018768) }, + { FRAC_CONST(-0.951056599617004), FRAC_CONST(0.309016793966293) }, + { FRAC_CONST(-0.955020010471344), FRAC_CONST(0.296541452407837) }, + { FRAC_CONST(-0.958819746971130), FRAC_CONST(0.284015297889709) }, + { FRAC_CONST(-0.962455213069916), FRAC_CONST(0.271440476179123) }, + { FRAC_CONST(-0.965925872325897), FRAC_CONST(0.258818924427032) }, + { FRAC_CONST(-0.969230949878693), FRAC_CONST(0.246153235435486) }, + { FRAC_CONST(-0.972369909286499), FRAC_CONST(0.233445376157761) }, + { FRAC_CONST(-0.975342333316803), FRAC_CONST(0.220697283744812) }, + { FRAC_CONST(-0.978147625923157), FRAC_CONST(0.207911610603333) }, + { FRAC_CONST(-0.980785310268402), FRAC_CONST(0.195090308785439) }, + { FRAC_CONST(-0.983254909515381), FRAC_CONST(0.182235360145569) }, + { FRAC_CONST(-0.985556066036224), FRAC_CONST(0.169349402189255) }, + { FRAC_CONST(-0.987688362598419), FRAC_CONST(0.156434446573257) }, + { FRAC_CONST(-0.989651441574097), FRAC_CONST(0.143492430448532) }, + { FRAC_CONST(-0.991444885730743), FRAC_CONST(0.130526080727577) }, + { FRAC_CONST(-0.993068456649780), FRAC_CONST(0.117537356913090) }, + { FRAC_CONST(-0.994521915912628), FRAC_CONST(0.104528494179249) }, + { FRAC_CONST(-0.995804965496063), FRAC_CONST(0.091501489281654) }, + { FRAC_CONST(-0.996917366981506), FRAC_CONST(0.078459039330482) }, + { FRAC_CONST(-0.997858941555023), FRAC_CONST(0.065403148531914) }, + { FRAC_CONST(-0.998629570007324), FRAC_CONST(0.052335809916258) }, + { FRAC_CONST(-0.999229013919830), FRAC_CONST(0.039259742945433) }, + { FRAC_CONST(-0.999657332897186), FRAC_CONST(0.026176951825619) }, + { FRAC_CONST(-0.999914348125458), FRAC_CONST(0.013089434243739) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.999657332897186), FRAC_CONST(0.026176949962974) }, + { FRAC_CONST(0.998629510402679), FRAC_CONST(0.052335958927870) }, + { FRAC_CONST(0.996917307376862), FRAC_CONST(0.078459098935127) }, + { FRAC_CONST(0.994521915912628), FRAC_CONST(0.104528464376926) }, + { FRAC_CONST(0.991444885730743), FRAC_CONST(0.130526199936867) }, + { FRAC_CONST(0.987688362598419), FRAC_CONST(0.156434476375580) }, + { FRAC_CONST(0.983254909515381), FRAC_CONST(0.182235524058342) }, + { FRAC_CONST(0.978147625923157), FRAC_CONST(0.207911700010300) }, + { FRAC_CONST(0.972369909286499), FRAC_CONST(0.233445376157761) }, + { FRAC_CONST(0.965925812721252), FRAC_CONST(0.258819043636322) }, + { FRAC_CONST(0.958819746971130), FRAC_CONST(0.284015357494354) }, + { FRAC_CONST(0.951056540012360), FRAC_CONST(0.309017002582550) }, + { FRAC_CONST(0.942641496658325), FRAC_CONST(0.333806872367859) }, + { FRAC_CONST(0.933580398559570), FRAC_CONST(0.358367949724197) }, + { FRAC_CONST(0.923879504203796), FRAC_CONST(0.382683455944061) }, + { FRAC_CONST(0.913545429706573), FRAC_CONST(0.406736642122269) }, + { FRAC_CONST(0.902585268020630), FRAC_CONST(0.430511116981506) }, + { FRAC_CONST(0.891006529331207), FRAC_CONST(0.453990519046783) }, + { FRAC_CONST(0.878817081451416), FRAC_CONST(0.477158784866333) }, + { FRAC_CONST(0.866025388240814), FRAC_CONST(0.500000000000000) }, + { FRAC_CONST(0.852640151977539), FRAC_CONST(0.522498548030853) }, + { FRAC_CONST(0.838670551776886), FRAC_CONST(0.544639050960541) }, + { FRAC_CONST(0.824126183986664), FRAC_CONST(0.566406250000000) }, + { FRAC_CONST(0.809017002582550), FRAC_CONST(0.587785243988037) }, + { FRAC_CONST(0.793353319168091), FRAC_CONST(0.608761429786682) }, + { FRAC_CONST(0.777145922183990), FRAC_CONST(0.629320383071899) }, + { FRAC_CONST(0.760405957698822), FRAC_CONST(0.649448096752167) }, + { FRAC_CONST(0.743144810199738), FRAC_CONST(0.669130623340607) }, + { FRAC_CONST(0.725374400615692), FRAC_CONST(0.688354551792145) }, + { FRAC_CONST(0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(0.688354551792145), FRAC_CONST(0.725374400615692) }, + { FRAC_CONST(0.669130563735962), FRAC_CONST(0.743144869804382) }, + { FRAC_CONST(0.649448037147522), FRAC_CONST(0.760405957698822) }, + { FRAC_CONST(0.629320383071899), FRAC_CONST(0.777145981788635) }, + { FRAC_CONST(0.608761370182037), FRAC_CONST(0.793353378772736) }, + { FRAC_CONST(0.587785243988037), FRAC_CONST(0.809017002582550) }, + { FRAC_CONST(0.566406250000000), FRAC_CONST(0.824126183986664) }, + { FRAC_CONST(0.544638991355896), FRAC_CONST(0.838670611381531) }, + { FRAC_CONST(0.522498488426209), FRAC_CONST(0.852640211582184) }, + { FRAC_CONST(0.499999970197678), FRAC_CONST(0.866025447845459) }, + { FRAC_CONST(0.477158755064011), FRAC_CONST(0.878817141056061) }, + { FRAC_CONST(0.453990519046783), FRAC_CONST(0.891006529331207) }, + { FRAC_CONST(0.430511027574539), FRAC_CONST(0.902585327625275) }, + { FRAC_CONST(0.406736612319946), FRAC_CONST(0.913545489311218) }, + { FRAC_CONST(0.382683426141739), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(0.358367860317230), FRAC_CONST(0.933580458164215) }, + { FRAC_CONST(0.333806812763214), FRAC_CONST(0.942641496658325) }, + { FRAC_CONST(0.309016972780228), FRAC_CONST(0.951056540012360) }, + { FRAC_CONST(0.284015327692032), FRAC_CONST(0.958819746971130) }, + { FRAC_CONST(0.258819073438644), FRAC_CONST(0.965925812721252) }, + { FRAC_CONST(0.233445301651955), FRAC_CONST(0.972369909286499) }, + { FRAC_CONST(0.207911655306816), FRAC_CONST(0.978147625923157) }, + { FRAC_CONST(0.182235524058342), FRAC_CONST(0.983254909515381) }, + { FRAC_CONST(0.156434372067451), FRAC_CONST(0.987688362598419) }, + { FRAC_CONST(0.130526125431061), FRAC_CONST(0.991444885730743) }, + { FRAC_CONST(0.104528419673443), FRAC_CONST(0.994521915912628) }, + { FRAC_CONST(0.078459084033966), FRAC_CONST(0.996917307376862) }, + { FRAC_CONST(0.052335973829031), FRAC_CONST(0.998629510402679) }, + { FRAC_CONST(0.026176875457168), FRAC_CONST(0.999657332897186) }, + { FRAC_CONST(-0.000000043711388), FRAC_CONST(1.000000000000000) }, + { FRAC_CONST(-0.026176963001490), FRAC_CONST(0.999657332897186) }, + { FRAC_CONST(-0.052336059510708), FRAC_CONST(0.998629510402679) }, + { FRAC_CONST(-0.078459173440933), FRAC_CONST(0.996917307376862) }, + { FRAC_CONST(-0.104528509080410), FRAC_CONST(0.994521915912628) }, + { FRAC_CONST(-0.130526214838028), FRAC_CONST(0.991444885730743) }, + { FRAC_CONST(-0.156434446573257), FRAC_CONST(0.987688362598419) }, + { FRAC_CONST(-0.182235598564148), FRAC_CONST(0.983254909515381) }, + { FRAC_CONST(-0.207911744713783), FRAC_CONST(0.978147566318512) }, + { FRAC_CONST(-0.233445391058922), FRAC_CONST(0.972369909286499) }, + { FRAC_CONST(-0.258819162845612), FRAC_CONST(0.965925812721252) }, + { FRAC_CONST(-0.284015417098999), FRAC_CONST(0.958819687366486) }, + { FRAC_CONST(-0.309017032384872), FRAC_CONST(0.951056480407715) }, + { FRAC_CONST(-0.333806872367859), FRAC_CONST(0.942641496658325) }, + { FRAC_CONST(-0.358367949724197), FRAC_CONST(0.933580458164215) }, + { FRAC_CONST(-0.382683515548706), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(-0.406736701726913), FRAC_CONST(0.913545429706573) }, + { FRAC_CONST(-0.430511116981506), FRAC_CONST(0.902585268020630) }, + { FRAC_CONST(-0.453990608453751), FRAC_CONST(0.891006469726563) }, + { FRAC_CONST(-0.477158725261688), FRAC_CONST(0.878817141056061) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.998629510402679), FRAC_CONST(0.052335958927870) }, + { FRAC_CONST(0.994521915912628), FRAC_CONST(0.104528464376926) }, + { FRAC_CONST(0.987688362598419), FRAC_CONST(0.156434476375580) }, + { FRAC_CONST(0.978147625923157), FRAC_CONST(0.207911700010300) }, + { FRAC_CONST(0.965925812721252), FRAC_CONST(0.258819043636322) }, + { FRAC_CONST(0.951056540012360), FRAC_CONST(0.309017002582550) }, + { FRAC_CONST(0.933580398559570), FRAC_CONST(0.358367949724197) }, + { FRAC_CONST(0.913545429706573), FRAC_CONST(0.406736642122269) }, + { FRAC_CONST(0.891006529331207), FRAC_CONST(0.453990519046783) }, + { FRAC_CONST(0.866025388240814), FRAC_CONST(0.500000000000000) }, + { FRAC_CONST(0.838670551776886), FRAC_CONST(0.544639050960541) }, + { FRAC_CONST(0.809017002582550), FRAC_CONST(0.587785243988037) }, + { FRAC_CONST(0.777145922183990), FRAC_CONST(0.629320383071899) }, + { FRAC_CONST(0.743144810199738), FRAC_CONST(0.669130623340607) }, + { FRAC_CONST(0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(0.669130563735962), FRAC_CONST(0.743144869804382) }, + { FRAC_CONST(0.629320383071899), FRAC_CONST(0.777145981788635) }, + { FRAC_CONST(0.587785243988037), FRAC_CONST(0.809017002582550) }, + { FRAC_CONST(0.544638991355896), FRAC_CONST(0.838670611381531) }, + { FRAC_CONST(0.499999970197678), FRAC_CONST(0.866025447845459) }, + { FRAC_CONST(0.453990519046783), FRAC_CONST(0.891006529331207) }, + { FRAC_CONST(0.406736612319946), FRAC_CONST(0.913545489311218) }, + { FRAC_CONST(0.358367860317230), FRAC_CONST(0.933580458164215) }, + { FRAC_CONST(0.309016972780228), FRAC_CONST(0.951056540012360) }, + { FRAC_CONST(0.258819073438644), FRAC_CONST(0.965925812721252) }, + { FRAC_CONST(0.207911655306816), FRAC_CONST(0.978147625923157) }, + { FRAC_CONST(0.156434372067451), FRAC_CONST(0.987688362598419) }, + { FRAC_CONST(0.104528419673443), FRAC_CONST(0.994521915912628) }, + { FRAC_CONST(0.052335973829031), FRAC_CONST(0.998629510402679) }, + { FRAC_CONST(-0.000000043711388), FRAC_CONST(1.000000000000000) }, + { FRAC_CONST(-0.052336059510708), FRAC_CONST(0.998629510402679) }, + { FRAC_CONST(-0.104528509080410), FRAC_CONST(0.994521915912628) }, + { FRAC_CONST(-0.156434446573257), FRAC_CONST(0.987688362598419) }, + { FRAC_CONST(-0.207911744713783), FRAC_CONST(0.978147566318512) }, + { FRAC_CONST(-0.258819162845612), FRAC_CONST(0.965925812721252) }, + { FRAC_CONST(-0.309017032384872), FRAC_CONST(0.951056480407715) }, + { FRAC_CONST(-0.358367949724197), FRAC_CONST(0.933580458164215) }, + { FRAC_CONST(-0.406736701726913), FRAC_CONST(0.913545429706573) }, + { FRAC_CONST(-0.453990608453751), FRAC_CONST(0.891006469726563) }, + { FRAC_CONST(-0.500000059604645), FRAC_CONST(0.866025388240814) }, + { FRAC_CONST(-0.544639050960541), FRAC_CONST(0.838670551776886) }, + { FRAC_CONST(-0.587785184383392), FRAC_CONST(0.809017002582550) }, + { FRAC_CONST(-0.629320502281189), FRAC_CONST(0.777145862579346) }, + { FRAC_CONST(-0.669130682945251), FRAC_CONST(0.743144810199738) }, + { FRAC_CONST(-0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(-0.743144929409027), FRAC_CONST(0.669130444526672) }, + { FRAC_CONST(-0.777146041393280), FRAC_CONST(0.629320263862610) }, + { FRAC_CONST(-0.809017062187195), FRAC_CONST(0.587785184383392) }, + { FRAC_CONST(-0.838670551776886), FRAC_CONST(0.544639050960541) }, + { FRAC_CONST(-0.866025388240814), FRAC_CONST(0.500000059604645) }, + { FRAC_CONST(-0.891006588935852), FRAC_CONST(0.453990370035172) }, + { FRAC_CONST(-0.913545489311218), FRAC_CONST(0.406736582517624) }, + { FRAC_CONST(-0.933580458164215), FRAC_CONST(0.358367919921875) }, + { FRAC_CONST(-0.951056599617004), FRAC_CONST(0.309016793966293) }, + { FRAC_CONST(-0.965925872325897), FRAC_CONST(0.258818924427032) }, + { FRAC_CONST(-0.978147625923157), FRAC_CONST(0.207911610603333) }, + { FRAC_CONST(-0.987688362598419), FRAC_CONST(0.156434446573257) }, + { FRAC_CONST(-0.994521915912628), FRAC_CONST(0.104528494179249) }, + { FRAC_CONST(-0.998629570007324), FRAC_CONST(0.052335809916258) }, + { FRAC_CONST(-1.000000000000000), FRAC_CONST(-0.000000087422777) }, + { FRAC_CONST(-0.998629510402679), FRAC_CONST(-0.052335985004902) }, + { FRAC_CONST(-0.994521856307983), FRAC_CONST(-0.104528672993183) }, + { FRAC_CONST(-0.987688302993774), FRAC_CONST(-0.156434610486031) }, + { FRAC_CONST(-0.978147566318512), FRAC_CONST(-0.207911789417267) }, + { FRAC_CONST(-0.965925812721252), FRAC_CONST(-0.258819073438644) }, + { FRAC_CONST(-0.951056540012360), FRAC_CONST(-0.309016972780228) }, + { FRAC_CONST(-0.933580398559570), FRAC_CONST(-0.358368098735809) }, + { FRAC_CONST(-0.913545429706573), FRAC_CONST(-0.406736731529236) }, + { FRAC_CONST(-0.891006529331207), FRAC_CONST(-0.453990548849106) }, + { FRAC_CONST(-0.866025269031525), FRAC_CONST(-0.500000178813934) }, + { FRAC_CONST(-0.838670492172241), FRAC_CONST(-0.544639170169830) }, + { FRAC_CONST(-0.809016942977905), FRAC_CONST(-0.587785363197327) }, + { FRAC_CONST(-0.777145922183990), FRAC_CONST(-0.629320442676544) }, + { FRAC_CONST(-0.743144810199738), FRAC_CONST(-0.669130623340607) }, + { FRAC_CONST(-0.707106649875641), FRAC_CONST(-0.707106888294220) }, + { FRAC_CONST(-0.669130504131317), FRAC_CONST(-0.743144869804382) }, + { FRAC_CONST(-0.629320323467255), FRAC_CONST(-0.777145981788635) }, + { FRAC_CONST(-0.587785065174103), FRAC_CONST(-0.809017121791840) }, + { FRAC_CONST(-0.544639110565186), FRAC_CONST(-0.838670551776886) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.996917307376862), FRAC_CONST(0.078459098935127) }, + { FRAC_CONST(0.987688362598419), FRAC_CONST(0.156434476375580) }, + { FRAC_CONST(0.972369909286499), FRAC_CONST(0.233445376157761) }, + { FRAC_CONST(0.951056540012360), FRAC_CONST(0.309017002582550) }, + { FRAC_CONST(0.923879504203796), FRAC_CONST(0.382683455944061) }, + { FRAC_CONST(0.891006529331207), FRAC_CONST(0.453990519046783) }, + { FRAC_CONST(0.852640151977539), FRAC_CONST(0.522498548030853) }, + { FRAC_CONST(0.809017002582550), FRAC_CONST(0.587785243988037) }, + { FRAC_CONST(0.760405957698822), FRAC_CONST(0.649448096752167) }, + { FRAC_CONST(0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(0.649448037147522), FRAC_CONST(0.760405957698822) }, + { FRAC_CONST(0.587785243988037), FRAC_CONST(0.809017002582550) }, + { FRAC_CONST(0.522498488426209), FRAC_CONST(0.852640211582184) }, + { FRAC_CONST(0.453990519046783), FRAC_CONST(0.891006529331207) }, + { FRAC_CONST(0.382683426141739), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(0.309016972780228), FRAC_CONST(0.951056540012360) }, + { FRAC_CONST(0.233445301651955), FRAC_CONST(0.972369909286499) }, + { FRAC_CONST(0.156434372067451), FRAC_CONST(0.987688362598419) }, + { FRAC_CONST(0.078459084033966), FRAC_CONST(0.996917307376862) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.987688362598419), FRAC_CONST(0.156434476375580) }, + { FRAC_CONST(0.951056540012360), FRAC_CONST(0.309017002582550) }, + { FRAC_CONST(0.891006529331207), FRAC_CONST(0.453990519046783) }, + { FRAC_CONST(0.809017002582550), FRAC_CONST(0.587785243988037) }, + { FRAC_CONST(0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(0.587785243988037), FRAC_CONST(0.809017002582550) }, + { FRAC_CONST(0.453990519046783), FRAC_CONST(0.891006529331207) }, + { FRAC_CONST(0.309016972780228), FRAC_CONST(0.951056540012360) }, + { FRAC_CONST(0.156434372067451), FRAC_CONST(0.987688362598419) }, + { FRAC_CONST(-0.000000043711388), FRAC_CONST(1.000000000000000) }, + { FRAC_CONST(-0.156434446573257), FRAC_CONST(0.987688362598419) }, + { FRAC_CONST(-0.309017032384872), FRAC_CONST(0.951056480407715) }, + { FRAC_CONST(-0.453990608453751), FRAC_CONST(0.891006469726563) }, + { FRAC_CONST(-0.587785184383392), FRAC_CONST(0.809017002582550) }, + { FRAC_CONST(-0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(-0.809017062187195), FRAC_CONST(0.587785184383392) }, + { FRAC_CONST(-0.891006588935852), FRAC_CONST(0.453990370035172) }, + { FRAC_CONST(-0.951056599617004), FRAC_CONST(0.309016793966293) }, + { FRAC_CONST(-0.987688362598419), FRAC_CONST(0.156434446573257) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.972369909286499), FRAC_CONST(0.233445376157761) }, + { FRAC_CONST(0.891006529331207), FRAC_CONST(0.453990519046783) }, + { FRAC_CONST(0.760405957698822), FRAC_CONST(0.649448096752167) }, + { FRAC_CONST(0.587785243988037), FRAC_CONST(0.809017002582550) }, + { FRAC_CONST(0.382683426141739), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(0.156434372067451), FRAC_CONST(0.987688362598419) }, + { FRAC_CONST(-0.078459173440933), FRAC_CONST(0.996917307376862) }, + { FRAC_CONST(-0.309017032384872), FRAC_CONST(0.951056480407715) }, + { FRAC_CONST(-0.522498667240143), FRAC_CONST(0.852640092372894) }, + { FRAC_CONST(-0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(-0.852640211582184), FRAC_CONST(0.522498488426209) }, + { FRAC_CONST(-0.951056599617004), FRAC_CONST(0.309016793966293) }, + { FRAC_CONST(-0.996917366981506), FRAC_CONST(0.078459039330482) }, + { FRAC_CONST(-0.987688302993774), FRAC_CONST(-0.156434610486031) }, + { FRAC_CONST(-0.923879504203796), FRAC_CONST(-0.382683426141739) }, + { FRAC_CONST(-0.809016942977905), FRAC_CONST(-0.587785363197327) }, + { FRAC_CONST(-0.649447917938232), FRAC_CONST(-0.760406076908112) }, + { FRAC_CONST(-0.453990221023560), FRAC_CONST(-0.891006648540497) }, + { FRAC_CONST(-0.233445450663567), FRAC_CONST(-0.972369909286499) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.951056540012360), FRAC_CONST(0.309017002582550) }, + { FRAC_CONST(0.809017002582550), FRAC_CONST(0.587785243988037) }, + { FRAC_CONST(0.587785243988037), FRAC_CONST(0.809017002582550) }, + { FRAC_CONST(0.309016972780228), FRAC_CONST(0.951056540012360) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.809017002582550), FRAC_CONST(0.587785243988037) }, + { FRAC_CONST(0.309016972780228), FRAC_CONST(0.951056540012360) }, + { FRAC_CONST(-0.309017032384872), FRAC_CONST(0.951056480407715) }, + { FRAC_CONST(-0.809017062187195), FRAC_CONST(0.587785184383392) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.587785243988037), FRAC_CONST(0.809017002582550) }, + { FRAC_CONST(-0.309017032384872), FRAC_CONST(0.951056480407715) }, + { FRAC_CONST(-0.951056599617004), FRAC_CONST(0.309016793966293) }, + { FRAC_CONST(-0.809016942977905), FRAC_CONST(-0.587785363197327) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.309017121791840), FRAC_CONST(-0.951056480407715) } }; +#endif -complex_t cfft_tab_64[] = +ALIGN static const complex_t cfft_tab_64[] = { - { 0x10000000, 0x0 }, - { 0xFEC46D0, 0x1917A6C }, - { 0xFB14BE0, 0x31F1708 }, - { 0xF4FA0B0, 0x4A50188 }, - { 0xEC835E0, 0x61F78B0 }, - { 0xE1C5970, 0x78AD750 }, - { 0xD4DB310, 0x8E39DA0 }, - { 0xC5E4030, 0xA2679A0 }, - { 0xB504F30, 0xB504F30 }, - { 0xA267990, 0xC5E4030 }, - { 0x8E39D90, 0xD4DB320 }, - { 0x78AD738, 0xE1C5980 }, - { 0x61F78A8, 0xEC835E0 }, - { 0x4A50180, 0xF4FA0B0 }, - { 0x31F16F0, 0xFB14BF0 }, - { 0x1917A6A, 0xFEC46D0 }, - { 0x10000000, 0x0 }, - { 0xFB14BE0, 0x31F1708 }, - { 0xEC835E0, 0x61F78B0 }, - { 0xD4DB310, 0x8E39DA0 }, - { 0xB504F30, 0xB504F30 }, - { 0x8E39D90, 0xD4DB320 }, - { 0x61F78A8, 0xEC835E0 }, - { 0x31F16F0, 0xFB14BF0 }, - { 0xFFFFFFF5, 0x10000000 }, - { 0xFCE0E8F8, 0xFB14BE0 }, - { 0xF9E08740, 0xEC835E0 }, - { 0xF71C6240, 0xD4DB300 }, - { 0xF4AFB0D0, 0xB504F30 }, - { 0xF2B24CE0, 0x8E39D90 }, - { 0xF137CA00, 0x61F7880 }, - { 0xF04EB410, 0x31F1704 }, - { 0x10000000, 0x0 }, - { 0xF4FA0B0, 0x4A50188 }, - { 0xD4DB310, 0x8E39DA0 }, - { 0xA267990, 0xC5E4030 }, - { 0x61F78A8, 0xEC835E0 }, - { 0x1917A6A, 0xFEC46D0 }, - { 0xFCE0E8F8, 0xFB14BE0 }, - { 0xF8752898, 0xE1C5970 }, - { 0xF4AFB0D0, 0xB504F30 }, - { 0xF1E3A690, 0x78AD768 }, - { 0xF04EB410, 0x31F1704 }, - { 0xF013B930, 0xFE6E8572 }, - { 0xF137CA20, 0xF9E08758 }, - { 0xF3A1BFB0, 0xF5D98680 }, - { 0xF71C62A0, 0xF2B24CC0 }, - { 0xFB5AFE98, 0xF0B05F50 }, - { 0x10000000, 0x0 }, - { 0xEC835E0, 0x61F78B0 }, - { 0xB504F30, 0xB504F30 }, - { 0x61F78A8, 0xEC835E0 }, - { 0x10000000, 0x0 }, - { 0xB504F30, 0xB504F30 }, - { 0xFFFFFFF5, 0x10000000 }, - { 0xF4AFB0D0, 0xB504F30 }, - { 0x10000000, 0x0 }, - { 0x61F78A8, 0xEC835E0 }, - { 0xF4AFB0D0, 0xB504F30 }, - { 0xF137CA20, 0xF9E08758 }, - { 0x10000000, 0x0 }, - { 0x10000000, 0x0 }, - { 0x10000000, 0x0 }, - { 0x3, 0xF0000000 } + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.995184719562531), FRAC_CONST(0.098017141222954) }, + { FRAC_CONST(0.980785250663757), FRAC_CONST(0.195090323686600) }, + { FRAC_CONST(0.956940352916718), FRAC_CONST(0.290284663438797) }, + { FRAC_CONST(0.923879504203796), FRAC_CONST(0.382683455944061) }, + { FRAC_CONST(0.881921231746674), FRAC_CONST(0.471396744251251) }, + { FRAC_CONST(0.831469595432281), FRAC_CONST(0.555570244789124) }, + { FRAC_CONST(0.773010432720184), FRAC_CONST(0.634393334388733) }, + { FRAC_CONST(0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(0.634393274784088), FRAC_CONST(0.773010432720184) }, + { FRAC_CONST(0.555570185184479), FRAC_CONST(0.831469655036926) }, + { FRAC_CONST(0.471396654844284), FRAC_CONST(0.881921291351318) }, + { FRAC_CONST(0.382683426141739), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(0.290284633636475), FRAC_CONST(0.956940352916718) }, + { FRAC_CONST(0.195090234279633), FRAC_CONST(0.980785310268402) }, + { FRAC_CONST(0.098017133772373), FRAC_CONST(0.995184719562531) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.980785250663757), FRAC_CONST(0.195090323686600) }, + { FRAC_CONST(0.923879504203796), FRAC_CONST(0.382683455944061) }, + { FRAC_CONST(0.831469595432281), FRAC_CONST(0.555570244789124) }, + { FRAC_CONST(0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(0.555570185184479), FRAC_CONST(0.831469655036926) }, + { FRAC_CONST(0.382683426141739), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(0.195090234279633), FRAC_CONST(0.980785310268402) }, + { FRAC_CONST(-0.000000043711388), FRAC_CONST(1.000000000000000) }, + { FRAC_CONST(-0.195090323686600), FRAC_CONST(0.980785250663757) }, + { FRAC_CONST(-0.382683515548706), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(-0.555570363998413), FRAC_CONST(0.831469535827637) }, + { FRAC_CONST(-0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(-0.831469655036926), FRAC_CONST(0.555570185184479) }, + { FRAC_CONST(-0.923879623413086), FRAC_CONST(0.382683277130127) }, + { FRAC_CONST(-0.980785310268402), FRAC_CONST(0.195090308785439) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.956940352916718), FRAC_CONST(0.290284663438797) }, + { FRAC_CONST(0.831469595432281), FRAC_CONST(0.555570244789124) }, + { FRAC_CONST(0.634393274784088), FRAC_CONST(0.773010432720184) }, + { FRAC_CONST(0.382683426141739), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(0.098017133772373), FRAC_CONST(0.995184719562531) }, + { FRAC_CONST(-0.195090323686600), FRAC_CONST(0.980785250663757) }, + { FRAC_CONST(-0.471396833658218), FRAC_CONST(0.881921231746674) }, + { FRAC_CONST(-0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(-0.881921231746674), FRAC_CONST(0.471396833658218) }, + { FRAC_CONST(-0.980785310268402), FRAC_CONST(0.195090308785439) }, + { FRAC_CONST(-0.995184719562531), FRAC_CONST(-0.098017267882824) }, + { FRAC_CONST(-0.923879504203796), FRAC_CONST(-0.382683426141739) }, + { FRAC_CONST(-0.773010551929474), FRAC_CONST(-0.634393215179443) }, + { FRAC_CONST(-0.555570006370544), FRAC_CONST(-0.831469774246216) }, + { FRAC_CONST(-0.290284544229507), FRAC_CONST(-0.956940352916718) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.923879504203796), FRAC_CONST(0.382683455944061) }, + { FRAC_CONST(0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(0.382683426141739), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(-0.000000043711388), FRAC_CONST(1.000000000000000) }, + { FRAC_CONST(-0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.382683426141739), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(-0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(-0.923879504203796), FRAC_CONST(-0.382683426141739) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.000000011924881), FRAC_CONST(-1.000000000000000) } }; -complex_t cfft_tab_60[] = +#ifdef ALLOW_SMALL_FRAMELENGTH +ALIGN static const complex_t cfft_tab_60[] = { - { 0x10000000, 0x0 }, - { 0xFE98FD0, 0x1AC260A }, - { 0xFA67E20, 0x3539B38 }, - { 0xF378710, 0x4F1BBD0 }, - { 0xE9DE1D0, 0x681FE48 }, - { 0xDDB3D70, 0x8000000 }, - { 0xCF1BBD0, 0x9679180 }, - { 0xBE3EBD0, 0xAB4C250 }, - { 0xAB4C240, 0xBE3EBE0 }, - { 0x9679180, 0xCF1BBD0 }, - { 0x7FFFFF8, 0xDDB3D80 }, - { 0x681FE40, 0xE9DE1E0 }, - { 0x4F1BBC8, 0xF378710 }, - { 0x3539B2C, 0xFA67E20 }, - { 0x1AC25FE, 0xFE98FD0 }, - { 0xFFFFFFF5, 0x10000000 }, - { 0xFE53D9EA, 0xFE98FD0 }, - { 0xFCAC64BC, 0xFA67E10 }, - { 0xFB0E4428, 0xF378700 }, - { 0xF97E01A8, 0xE9DE1D0 }, - { 0x10000000, 0x0 }, - { 0xFA67E20, 0x3539B38 }, - { 0xE9DE1D0, 0x681FE48 }, - { 0xCF1BBD0, 0x9679180 }, - { 0xAB4C240, 0xBE3EBE0 }, - { 0x7FFFFF8, 0xDDB3D80 }, - { 0x4F1BBC8, 0xF378710 }, - { 0x1AC25FE, 0xFE98FD0 }, - { 0xFE53D9EA, 0xFE98FD0 }, - { 0xFB0E4428, 0xF378700 }, - { 0xF7FFFFF0, 0xDDB3D70 }, - { 0xF54B3DA0, 0xBE3EBD0 }, - { 0xF30E4420, 0x9679170 }, - { 0xF1621E20, 0x681FE38 }, - { 0xF05981E0, 0x3539B20 }, - { 0xF0000000, 0xFFFFFFE9 }, - { 0xF05981F0, 0xFCAC64B0 }, - { 0xF1621E30, 0xF97E01A0 }, - { 0xF30E4440, 0xF6986E60 }, - { 0xF54B3DD0, 0xF41C1420 }, - { 0x10000000, 0x0 }, - { 0xF378710, 0x4F1BBD0 }, - { 0xCF1BBD0, 0x9679180 }, - { 0x9679180, 0xCF1BBD0 }, - { 0x4F1BBC8, 0xF378710 }, - { 0x10000000, 0x0 }, - { 0xCF1BBD0, 0x9679180 }, - { 0x4F1BBC8, 0xF378710 }, - { 0xFB0E4428, 0xF378700 }, - { 0xF30E4420, 0x9679170 }, - { 0x10000000, 0x0 }, - { 0x9679180, 0xCF1BBD0 }, - { 0xFB0E4428, 0xF378700 }, - { 0xF0C878E0, 0x4F1BB98 }, - { 0xF30E4440, 0xF6986E60 }, - { 0x10000000, 0x0 }, - { 0x10000000, 0x0 }, - { 0x10000000, 0x0 }, - { 0x10000000, 0x0 }, - { 0x4F1BBF0, 0xF0C87900 } + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.994521915912628), FRAC_CONST(0.104528464376926) }, + { FRAC_CONST(0.978147625923157), FRAC_CONST(0.207911700010300) }, + { FRAC_CONST(0.951056540012360), FRAC_CONST(0.309017002582550) }, + { FRAC_CONST(0.913545429706573), FRAC_CONST(0.406736642122269) }, + { FRAC_CONST(0.866025388240814), FRAC_CONST(0.500000000000000) }, + { FRAC_CONST(0.809017002582550), FRAC_CONST(0.587785243988037) }, + { FRAC_CONST(0.743144810199738), FRAC_CONST(0.669130623340607) }, + { FRAC_CONST(0.669130563735962), FRAC_CONST(0.743144869804382) }, + { FRAC_CONST(0.587785243988037), FRAC_CONST(0.809017002582550) }, + { FRAC_CONST(0.499999970197678), FRAC_CONST(0.866025447845459) }, + { FRAC_CONST(0.406736612319946), FRAC_CONST(0.913545489311218) }, + { FRAC_CONST(0.309016972780228), FRAC_CONST(0.951056540012360) }, + { FRAC_CONST(0.207911655306816), FRAC_CONST(0.978147625923157) }, + { FRAC_CONST(0.104528419673443), FRAC_CONST(0.994521915912628) }, + { FRAC_CONST(-0.000000043711388), FRAC_CONST(1.000000000000000) }, + { FRAC_CONST(-0.104528509080410), FRAC_CONST(0.994521915912628) }, + { FRAC_CONST(-0.207911744713783), FRAC_CONST(0.978147566318512) }, + { FRAC_CONST(-0.309017032384872), FRAC_CONST(0.951056480407715) }, + { FRAC_CONST(-0.406736701726913), FRAC_CONST(0.913545429706573) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.978147625923157), FRAC_CONST(0.207911700010300) }, + { FRAC_CONST(0.913545429706573), FRAC_CONST(0.406736642122269) }, + { FRAC_CONST(0.809017002582550), FRAC_CONST(0.587785243988037) }, + { FRAC_CONST(0.669130563735962), FRAC_CONST(0.743144869804382) }, + { FRAC_CONST(0.499999970197678), FRAC_CONST(0.866025447845459) }, + { FRAC_CONST(0.309016972780228), FRAC_CONST(0.951056540012360) }, + { FRAC_CONST(0.104528419673443), FRAC_CONST(0.994521915912628) }, + { FRAC_CONST(-0.104528509080410), FRAC_CONST(0.994521915912628) }, + { FRAC_CONST(-0.309017032384872), FRAC_CONST(0.951056480407715) }, + { FRAC_CONST(-0.500000059604645), FRAC_CONST(0.866025388240814) }, + { FRAC_CONST(-0.669130682945251), FRAC_CONST(0.743144810199738) }, + { FRAC_CONST(-0.809017062187195), FRAC_CONST(0.587785184383392) }, + { FRAC_CONST(-0.913545489311218), FRAC_CONST(0.406736582517624) }, + { FRAC_CONST(-0.978147625923157), FRAC_CONST(0.207911610603333) }, + { FRAC_CONST(-1.000000000000000), FRAC_CONST(-0.000000087422777) }, + { FRAC_CONST(-0.978147566318512), FRAC_CONST(-0.207911789417267) }, + { FRAC_CONST(-0.913545429706573), FRAC_CONST(-0.406736731529236) }, + { FRAC_CONST(-0.809016942977905), FRAC_CONST(-0.587785363197327) }, + { FRAC_CONST(-0.669130504131317), FRAC_CONST(-0.743144869804382) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.951056540012360), FRAC_CONST(0.309017002582550) }, + { FRAC_CONST(0.809017002582550), FRAC_CONST(0.587785243988037) }, + { FRAC_CONST(0.587785243988037), FRAC_CONST(0.809017002582550) }, + { FRAC_CONST(0.309016972780228), FRAC_CONST(0.951056540012360) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.809017002582550), FRAC_CONST(0.587785243988037) }, + { FRAC_CONST(0.309016972780228), FRAC_CONST(0.951056540012360) }, + { FRAC_CONST(-0.309017032384872), FRAC_CONST(0.951056480407715) }, + { FRAC_CONST(-0.809017062187195), FRAC_CONST(0.587785184383392) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.587785243988037), FRAC_CONST(0.809017002582550) }, + { FRAC_CONST(-0.309017032384872), FRAC_CONST(0.951056480407715) }, + { FRAC_CONST(-0.951056599617004), FRAC_CONST(0.309016793966293) }, + { FRAC_CONST(-0.809016942977905), FRAC_CONST(-0.587785363197327) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.309017121791840), FRAC_CONST(-0.951056480407715) } }; +#endif #ifdef LD_DEC -complex_t cfft_tab_256[] = +ALIGN static const complex_t cfft_tab_256[] = { - { 0x10000000, 0x0 }, - { 0xFFEC430, 0x648558 }, - { 0xFFB10F0, 0xC8FB30 }, - { 0xFF4E6D0, 0x12D520A }, - { 0xFEC46D0, 0x1917A6C }, - { 0xFE13240, 0x1F564E6 }, - { 0xFD3AAC0, 0x259020C }, - { 0xFC3B280, 0x2BC428C }, - { 0xFB14BE0, 0x31F1708 }, - { 0xF9C79D0, 0x381704C }, - { 0xF853F80, 0x3E33F34 }, - { 0xF6BA070, 0x44474A0 }, - { 0xF4FA0B0, 0x4A50188 }, - { 0xF314470, 0x504D728 }, - { 0xF109080, 0x563E6A0 }, - { 0xEED89E0, 0x5C22150 }, - { 0xEC835E0, 0x61F78B0 }, - { 0xEA09A60, 0x67BDE58 }, - { 0xE76BD80, 0x6D74400 }, - { 0xE4AA590, 0x7319BA8 }, - { 0xE1C5970, 0x78AD750 }, - { 0xDEBE050, 0x7E2E940 }, - { 0xDB941A0, 0x839C3D0 }, - { 0xD848530, 0x88F59B0 }, - { 0xD4DB310, 0x8E39DA0 }, - { 0xD14D3D0, 0x93682B0 }, - { 0xCD9F020, 0x987FC00 }, - { 0xC9D1120, 0x9D7FD20 }, - { 0xC5E4030, 0xA2679A0 }, - { 0xC1D8700, 0xA736560 }, - { 0xBDAEF90, 0xABEB4A0 }, - { 0xB968420, 0xB085BB0 }, - { 0xB504F30, 0xB504F30 }, - { 0xB085BA0, 0xB968420 }, - { 0xABEB490, 0xBDAEFA0 }, - { 0xA736550, 0xC1D8710 }, - { 0xA267990, 0xC5E4030 }, - { 0x9D7FD10, 0xC9D1120 }, - { 0x987FC00, 0xCD9F020 }, - { 0x93682A0, 0xD14D3D0 }, - { 0x8E39D90, 0xD4DB320 }, - { 0x88F59B0, 0xD848530 }, - { 0x839C3C0, 0xDB941B0 }, - { 0x7E2E938, 0xDEBE050 }, - { 0x78AD738, 0xE1C5980 }, - { 0x7319BA0, 0xE4AA590 }, - { 0x6D74408, 0xE76BD80 }, - { 0x67BDE48, 0xEA09A70 }, - { 0x61F78A8, 0xEC835E0 }, - { 0x5C22138, 0xEED89E0 }, - { 0x563E698, 0xF109080 }, - { 0x504D710, 0xF314480 }, - { 0x4A50180, 0xF4FA0B0 }, - { 0x4447498, 0xF6BA070 }, - { 0x3E33F20, 0xF853F80 }, - { 0x3817048, 0xF9C79D0 }, - { 0x31F16F0, 0xFB14BF0 }, - { 0x2BC4280, 0xFC3B280 }, - { 0x2590214, 0xFD3AAC0 }, - { 0x1F564D8, 0xFE13240 }, - { 0x1917A6A, 0xFEC46D0 }, - { 0x12D51F6, 0xFF4E6D0 }, - { 0xC8FB29, 0xFFB10F0 }, - { 0x64853F, 0xFFEC430 }, - { 0x10000000, 0x0 }, - { 0xFFB10F0, 0xC8FB30 }, - { 0xFEC46D0, 0x1917A6C }, - { 0xFD3AAC0, 0x259020C }, - { 0xFB14BE0, 0x31F1708 }, - { 0xF853F80, 0x3E33F34 }, - { 0xF4FA0B0, 0x4A50188 }, - { 0xF109080, 0x563E6A0 }, - { 0xEC835E0, 0x61F78B0 }, - { 0xE76BD80, 0x6D74400 }, - { 0xE1C5970, 0x78AD750 }, - { 0xDB941A0, 0x839C3D0 }, - { 0xD4DB310, 0x8E39DA0 }, - { 0xCD9F020, 0x987FC00 }, - { 0xC5E4030, 0xA2679A0 }, - { 0xBDAEF90, 0xABEB4A0 }, - { 0xB504F30, 0xB504F30 }, - { 0xABEB490, 0xBDAEFA0 }, - { 0xA267990, 0xC5E4030 }, - { 0x987FC00, 0xCD9F020 }, - { 0x8E39D90, 0xD4DB320 }, - { 0x839C3C0, 0xDB941B0 }, - { 0x78AD738, 0xE1C5980 }, - { 0x6D74408, 0xE76BD80 }, - { 0x61F78A8, 0xEC835E0 }, - { 0x563E698, 0xF109080 }, - { 0x4A50180, 0xF4FA0B0 }, - { 0x3E33F20, 0xF853F80 }, - { 0x31F16F0, 0xFB14BF0 }, - { 0x2590214, 0xFD3AAC0 }, - { 0x1917A6A, 0xFEC46D0 }, - { 0xC8FB29, 0xFFB10F0 }, - { 0xFFFFFFF5, 0x10000000 }, - { 0xFF3704BF, 0xFFB10F0 }, - { 0xFE6E857E, 0xFEC46D0 }, - { 0xFDA6FDD8, 0xFD3AAC0 }, - { 0xFCE0E8F8, 0xFB14BE0 }, - { 0xFC1CC0CC, 0xF853F80 }, - { 0xFB5AFE68, 0xF4FA0A0 }, - { 0xFA9C1950, 0xF109080 }, - { 0xF9E08740, 0xEC835E0 }, - { 0xF928BC00, 0xE76BD80 }, - { 0xF8752898, 0xE1C5970 }, - { 0xF7C63C30, 0xDB941A0 }, - { 0xF71C6240, 0xD4DB300 }, - { 0xF67803F0, 0xCD9F020 }, - { 0xF5D98670, 0xC5E4040 }, - { 0xF5414B50, 0xBDAEF80 }, - { 0xF4AFB0D0, 0xB504F30 }, - { 0xF4251050, 0xABEB480 }, - { 0xF3A1BFC0, 0xA267990 }, - { 0xF3260FC0, 0x987FBD0 }, - { 0xF2B24CE0, 0x8E39D90 }, - { 0xF246BE60, 0x839C3D0 }, - { 0xF1E3A670, 0x78AD730 }, - { 0xF1894280, 0x6D743F8 }, - { 0xF137CA00, 0x61F7880 }, - { 0xF0EF6F70, 0x563E690 }, - { 0xF0B05F50, 0x4A50198 }, - { 0xF07AC080, 0x3E33F14 }, - { 0xF04EB410, 0x31F1704 }, - { 0xF02C5540, 0x25901E8 }, - { 0xF013B930, 0x1917A60 }, - { 0xF004EF10, 0xC8FAFD }, - { 0x10000000, 0x0 }, - { 0xFF4E6D0, 0x12D520A }, - { 0xFD3AAC0, 0x259020C }, - { 0xF9C79D0, 0x381704C }, - { 0xF4FA0B0, 0x4A50188 }, - { 0xEED89E0, 0x5C22150 }, - { 0xE76BD80, 0x6D74400 }, - { 0xDEBE050, 0x7E2E940 }, - { 0xD4DB310, 0x8E39DA0 }, - { 0xC9D1130, 0x9D7FD10 }, - { 0xBDAEF90, 0xABEB4A0 }, - { 0xB085BA0, 0xB968420 }, - { 0xA267990, 0xC5E4030 }, - { 0x93682B0, 0xD14D3D0 }, - { 0x839C3C0, 0xDB941B0 }, - { 0x7319BA0, 0xE4AA590 }, - { 0x61F78A8, 0xEC835E0 }, - { 0x504D728, 0xF314470 }, - { 0x3E33F40, 0xF853F80 }, - { 0x2BC4280, 0xFC3B280 }, - { 0x1917A6A, 0xFEC46D0 }, - { 0x64855F, 0xFFEC430 }, - { 0xFF3704BF, 0xFFB10F0 }, - { 0xFE0A9B12, 0xFE13230 }, - { 0xFCE0E8F8, 0xFB14BE0 }, - { 0xFBBB8B70, 0xF6BA070 }, - { 0xFA9C1970, 0xF109080 }, - { 0xF98421A8, 0xEA09A60 }, - { 0xF8752898, 0xE1C5970 }, - { 0xF770A640, 0xD848520 }, - { 0xF67803F0, 0xCD9F020 }, - { 0xF58C9AA0, 0xC1D8700 }, - { 0xF4AFB0D0, 0xB504F30 }, - { 0xF3E27900, 0xA736560 }, - { 0xF3260FE0, 0x987FC10 }, - { 0xF27B7AE0, 0x88F59C0 }, - { 0xF1E3A690, 0x78AD768 }, - { 0xF15F6590, 0x67BDE38 }, - { 0xF0EF6F70, 0x563E690 }, - { 0xF0945F90, 0x4447490 }, - { 0xF04EB410, 0x31F1704 }, - { 0xF01ECDD0, 0x1F564EC }, - { 0xF004EF10, 0xC8FB3D }, - { 0xF0013BD0, 0xFF9B7ABE }, - { 0xF013B930, 0xFE6E8572 }, - { 0xF03C4D80, 0xFD43BD5C }, - { 0xF07AC080, 0xFC1CC0C0 }, - { 0xF0CEBB90, 0xFAFB28D0 }, - { 0xF137CA20, 0xF9E08758 }, - { 0xF1B55A70, 0xF8CE6460 }, - { 0xF246BE50, 0xF7C63C40 }, - { 0xF2EB2C20, 0xF6C97D70 }, - { 0xF3A1BFB0, 0xF5D98680 }, - { 0xF4697BF0, 0xF4F7A440 }, - { 0xF5414B70, 0xF4251060 }, - { 0xF62802F0, 0xF362EED0 }, - { 0xF71C62A0, 0xF2B24CC0 }, - { 0xF81D16C8, 0xF2141FB0 }, - { 0xF928BC28, 0xF1894270 }, - { 0xFA3DDEA0, 0xF1127630 }, - { 0xFB5AFE98, 0xF0B05F50 }, - { 0xFC7E8F90, 0xF0638630 }, - { 0xFDA6FE04, 0xF02C5540 }, - { 0xFED2ADC2, 0xF00B1930 }, - { 0x10000000, 0x0 }, - { 0xFEC46D0, 0x1917A6C }, - { 0xFB14BE0, 0x31F1708 }, - { 0xF4FA0B0, 0x4A50188 }, - { 0xEC835E0, 0x61F78B0 }, - { 0xE1C5970, 0x78AD750 }, - { 0xD4DB310, 0x8E39DA0 }, - { 0xC5E4030, 0xA2679A0 }, - { 0xB504F30, 0xB504F30 }, - { 0xA267990, 0xC5E4030 }, - { 0x8E39D90, 0xD4DB320 }, - { 0x78AD738, 0xE1C5980 }, - { 0x61F78A8, 0xEC835E0 }, - { 0x4A50180, 0xF4FA0B0 }, - { 0x31F16F0, 0xFB14BF0 }, - { 0x1917A6A, 0xFEC46D0 }, - { 0x10000000, 0x0 }, - { 0xFB14BE0, 0x31F1708 }, - { 0xEC835E0, 0x61F78B0 }, - { 0xD4DB310, 0x8E39DA0 }, - { 0xB504F30, 0xB504F30 }, - { 0x8E39D90, 0xD4DB320 }, - { 0x61F78A8, 0xEC835E0 }, - { 0x31F16F0, 0xFB14BF0 }, - { 0xFFFFFFF5, 0x10000000 }, - { 0xFCE0E8F8, 0xFB14BE0 }, - { 0xF9E08740, 0xEC835E0 }, - { 0xF71C6240, 0xD4DB300 }, - { 0xF4AFB0D0, 0xB504F30 }, - { 0xF2B24CE0, 0x8E39D90 }, - { 0xF137CA00, 0x61F7880 }, - { 0xF04EB410, 0x31F1704 }, - { 0x10000000, 0x0 }, - { 0xF4FA0B0, 0x4A50188 }, - { 0xD4DB310, 0x8E39DA0 }, - { 0xA267990, 0xC5E4030 }, - { 0x61F78A8, 0xEC835E0 }, - { 0x1917A6A, 0xFEC46D0 }, - { 0xFCE0E8F8, 0xFB14BE0 }, - { 0xF8752898, 0xE1C5970 }, - { 0xF4AFB0D0, 0xB504F30 }, - { 0xF1E3A690, 0x78AD768 }, - { 0xF04EB410, 0x31F1704 }, - { 0xF013B930, 0xFE6E8572 }, - { 0xF137CA20, 0xF9E08758 }, - { 0xF3A1BFB0, 0xF5D98680 }, - { 0xF71C62A0, 0xF2B24CC0 }, - { 0xFB5AFE98, 0xF0B05F50 }, - { 0x10000000, 0x0 }, - { 0xEC835E0, 0x61F78B0 }, - { 0xB504F30, 0xB504F30 }, - { 0x61F78A8, 0xEC835E0 }, - { 0x10000000, 0x0 }, - { 0xB504F30, 0xB504F30 }, - { 0xFFFFFFF5, 0x10000000 }, - { 0xF4AFB0D0, 0xB504F30 }, - { 0x10000000, 0x0 }, - { 0x61F78A8, 0xEC835E0 }, - { 0xF4AFB0D0, 0xB504F30 }, - { 0xF137CA20, 0xF9E08758 }, - { 0x10000000, 0x0 }, - { 0x10000000, 0x0 }, - { 0x10000000, 0x0 }, - { 0x3, 0xF0000000 } + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.999698817729950), FRAC_CONST(0.024541229009628) }, + { FRAC_CONST(0.998795449733734), FRAC_CONST(0.049067676067352) }, + { FRAC_CONST(0.997290432453156), FRAC_CONST(0.073564566671848) }, + { FRAC_CONST(0.995184719562531), FRAC_CONST(0.098017141222954) }, + { FRAC_CONST(0.992479562759399), FRAC_CONST(0.122410677373409) }, + { FRAC_CONST(0.989176511764526), FRAC_CONST(0.146730467677116) }, + { FRAC_CONST(0.985277652740479), FRAC_CONST(0.170961901545525) }, + { FRAC_CONST(0.980785250663757), FRAC_CONST(0.195090323686600) }, + { FRAC_CONST(0.975702106952667), FRAC_CONST(0.219101235270500) }, + { FRAC_CONST(0.970031261444092), FRAC_CONST(0.242980197072029) }, + { FRAC_CONST(0.963776051998138), FRAC_CONST(0.266712784767151) }, + { FRAC_CONST(0.956940352916718), FRAC_CONST(0.290284663438797) }, + { FRAC_CONST(0.949528157711029), FRAC_CONST(0.313681751489639) }, + { FRAC_CONST(0.941544055938721), FRAC_CONST(0.336889863014221) }, + { FRAC_CONST(0.932992815971375), FRAC_CONST(0.359895050525665) }, + { FRAC_CONST(0.923879504203796), FRAC_CONST(0.382683455944061) }, + { FRAC_CONST(0.914209723472595), FRAC_CONST(0.405241340398788) }, + { FRAC_CONST(0.903989315032959), FRAC_CONST(0.427555084228516) }, + { FRAC_CONST(0.893224298954010), FRAC_CONST(0.449611335992813) }, + { FRAC_CONST(0.881921231746674), FRAC_CONST(0.471396744251251) }, + { FRAC_CONST(0.870086967945099), FRAC_CONST(0.492898225784302) }, + { FRAC_CONST(0.857728600502014), FRAC_CONST(0.514102756977081) }, + { FRAC_CONST(0.844853579998016), FRAC_CONST(0.534997642040253) }, + { FRAC_CONST(0.831469595432281), FRAC_CONST(0.555570244789124) }, + { FRAC_CONST(0.817584812641144), FRAC_CONST(0.575808227062225) }, + { FRAC_CONST(0.803207516670227), FRAC_CONST(0.595699310302734) }, + { FRAC_CONST(0.788346409797668), FRAC_CONST(0.615231633186340) }, + { FRAC_CONST(0.773010432720184), FRAC_CONST(0.634393334388733) }, + { FRAC_CONST(0.757208824157715), FRAC_CONST(0.653172850608826) }, + { FRAC_CONST(0.740951120853424), FRAC_CONST(0.671558976173401) }, + { FRAC_CONST(0.724247097969055), FRAC_CONST(0.689540565013886) }, + { FRAC_CONST(0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(0.689540505409241), FRAC_CONST(0.724247097969055) }, + { FRAC_CONST(0.671558916568756), FRAC_CONST(0.740951180458069) }, + { FRAC_CONST(0.653172791004181), FRAC_CONST(0.757208883762360) }, + { FRAC_CONST(0.634393274784088), FRAC_CONST(0.773010432720184) }, + { FRAC_CONST(0.615231573581696), FRAC_CONST(0.788346409797668) }, + { FRAC_CONST(0.595699310302734), FRAC_CONST(0.803207516670227) }, + { FRAC_CONST(0.575808167457581), FRAC_CONST(0.817584812641144) }, + { FRAC_CONST(0.555570185184479), FRAC_CONST(0.831469655036926) }, + { FRAC_CONST(0.534997642040253), FRAC_CONST(0.844853579998016) }, + { FRAC_CONST(0.514102697372437), FRAC_CONST(0.857728660106659) }, + { FRAC_CONST(0.492898195981979), FRAC_CONST(0.870086967945099) }, + { FRAC_CONST(0.471396654844284), FRAC_CONST(0.881921291351318) }, + { FRAC_CONST(0.449611306190491), FRAC_CONST(0.893224298954010) }, + { FRAC_CONST(0.427555114030838), FRAC_CONST(0.903989315032959) }, + { FRAC_CONST(0.405241280794144), FRAC_CONST(0.914209783077240) }, + { FRAC_CONST(0.382683426141739), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(0.359894961118698), FRAC_CONST(0.932992815971375) }, + { FRAC_CONST(0.336889833211899), FRAC_CONST(0.941544055938721) }, + { FRAC_CONST(0.313681662082672), FRAC_CONST(0.949528217315674) }, + { FRAC_CONST(0.290284633636475), FRAC_CONST(0.956940352916718) }, + { FRAC_CONST(0.266712754964828), FRAC_CONST(0.963776051998138) }, + { FRAC_CONST(0.242980122566223), FRAC_CONST(0.970031261444092) }, + { FRAC_CONST(0.219101220369339), FRAC_CONST(0.975702106952667) }, + { FRAC_CONST(0.195090234279633), FRAC_CONST(0.980785310268402) }, + { FRAC_CONST(0.170961856842041), FRAC_CONST(0.985277652740479) }, + { FRAC_CONST(0.146730497479439), FRAC_CONST(0.989176511764526) }, + { FRAC_CONST(0.122410625219345), FRAC_CONST(0.992479562759399) }, + { FRAC_CONST(0.098017133772373), FRAC_CONST(0.995184719562531) }, + { FRAC_CONST(0.073564492166042), FRAC_CONST(0.997290432453156) }, + { FRAC_CONST(0.049067649990320), FRAC_CONST(0.998795449733734) }, + { FRAC_CONST(0.024541135877371), FRAC_CONST(0.999698817729950) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.998795449733734), FRAC_CONST(0.049067676067352) }, + { FRAC_CONST(0.995184719562531), FRAC_CONST(0.098017141222954) }, + { FRAC_CONST(0.989176511764526), FRAC_CONST(0.146730467677116) }, + { FRAC_CONST(0.980785250663757), FRAC_CONST(0.195090323686600) }, + { FRAC_CONST(0.970031261444092), FRAC_CONST(0.242980197072029) }, + { FRAC_CONST(0.956940352916718), FRAC_CONST(0.290284663438797) }, + { FRAC_CONST(0.941544055938721), FRAC_CONST(0.336889863014221) }, + { FRAC_CONST(0.923879504203796), FRAC_CONST(0.382683455944061) }, + { FRAC_CONST(0.903989315032959), FRAC_CONST(0.427555084228516) }, + { FRAC_CONST(0.881921231746674), FRAC_CONST(0.471396744251251) }, + { FRAC_CONST(0.857728600502014), FRAC_CONST(0.514102756977081) }, + { FRAC_CONST(0.831469595432281), FRAC_CONST(0.555570244789124) }, + { FRAC_CONST(0.803207516670227), FRAC_CONST(0.595699310302734) }, + { FRAC_CONST(0.773010432720184), FRAC_CONST(0.634393334388733) }, + { FRAC_CONST(0.740951120853424), FRAC_CONST(0.671558976173401) }, + { FRAC_CONST(0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(0.671558916568756), FRAC_CONST(0.740951180458069) }, + { FRAC_CONST(0.634393274784088), FRAC_CONST(0.773010432720184) }, + { FRAC_CONST(0.595699310302734), FRAC_CONST(0.803207516670227) }, + { FRAC_CONST(0.555570185184479), FRAC_CONST(0.831469655036926) }, + { FRAC_CONST(0.514102697372437), FRAC_CONST(0.857728660106659) }, + { FRAC_CONST(0.471396654844284), FRAC_CONST(0.881921291351318) }, + { FRAC_CONST(0.427555114030838), FRAC_CONST(0.903989315032959) }, + { FRAC_CONST(0.382683426141739), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(0.336889833211899), FRAC_CONST(0.941544055938721) }, + { FRAC_CONST(0.290284633636475), FRAC_CONST(0.956940352916718) }, + { FRAC_CONST(0.242980122566223), FRAC_CONST(0.970031261444092) }, + { FRAC_CONST(0.195090234279633), FRAC_CONST(0.980785310268402) }, + { FRAC_CONST(0.146730497479439), FRAC_CONST(0.989176511764526) }, + { FRAC_CONST(0.098017133772373), FRAC_CONST(0.995184719562531) }, + { FRAC_CONST(0.049067649990320), FRAC_CONST(0.998795449733734) }, + { FRAC_CONST(-0.000000043711388), FRAC_CONST(1.000000000000000) }, + { FRAC_CONST(-0.049067739397287), FRAC_CONST(0.998795449733734) }, + { FRAC_CONST(-0.098017223179340), FRAC_CONST(0.995184719562531) }, + { FRAC_CONST(-0.146730571985245), FRAC_CONST(0.989176511764526) }, + { FRAC_CONST(-0.195090323686600), FRAC_CONST(0.980785250663757) }, + { FRAC_CONST(-0.242980197072029), FRAC_CONST(0.970031261444092) }, + { FRAC_CONST(-0.290284723043442), FRAC_CONST(0.956940293312073) }, + { FRAC_CONST(-0.336889922618866), FRAC_CONST(0.941544055938721) }, + { FRAC_CONST(-0.382683515548706), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(-0.427555084228516), FRAC_CONST(0.903989315032959) }, + { FRAC_CONST(-0.471396833658218), FRAC_CONST(0.881921231746674) }, + { FRAC_CONST(-0.514102756977081), FRAC_CONST(0.857728600502014) }, + { FRAC_CONST(-0.555570363998413), FRAC_CONST(0.831469535827637) }, + { FRAC_CONST(-0.595699369907379), FRAC_CONST(0.803207516670227) }, + { FRAC_CONST(-0.634393274784088), FRAC_CONST(0.773010492324829) }, + { FRAC_CONST(-0.671559035778046), FRAC_CONST(0.740951061248779) }, + { FRAC_CONST(-0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(-0.740951240062714), FRAC_CONST(0.671558856964111) }, + { FRAC_CONST(-0.773010492324829), FRAC_CONST(0.634393274784088) }, + { FRAC_CONST(-0.803207635879517), FRAC_CONST(0.595699131488800) }, + { FRAC_CONST(-0.831469655036926), FRAC_CONST(0.555570185184479) }, + { FRAC_CONST(-0.857728600502014), FRAC_CONST(0.514102756977081) }, + { FRAC_CONST(-0.881921350955963), FRAC_CONST(0.471396625041962) }, + { FRAC_CONST(-0.903989315032959), FRAC_CONST(0.427555054426193) }, + { FRAC_CONST(-0.923879623413086), FRAC_CONST(0.382683277130127) }, + { FRAC_CONST(-0.941544115543365), FRAC_CONST(0.336889803409576) }, + { FRAC_CONST(-0.956940352916718), FRAC_CONST(0.290284723043442) }, + { FRAC_CONST(-0.970031261444092), FRAC_CONST(0.242980077862740) }, + { FRAC_CONST(-0.980785310268402), FRAC_CONST(0.195090308785439) }, + { FRAC_CONST(-0.989176511764526), FRAC_CONST(0.146730333566666) }, + { FRAC_CONST(-0.995184719562531), FRAC_CONST(0.098017096519470) }, + { FRAC_CONST(-0.998795449733734), FRAC_CONST(0.049067486077547) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.997290432453156), FRAC_CONST(0.073564566671848) }, + { FRAC_CONST(0.989176511764526), FRAC_CONST(0.146730467677116) }, + { FRAC_CONST(0.975702106952667), FRAC_CONST(0.219101235270500) }, + { FRAC_CONST(0.956940352916718), FRAC_CONST(0.290284663438797) }, + { FRAC_CONST(0.932992815971375), FRAC_CONST(0.359895050525665) }, + { FRAC_CONST(0.903989315032959), FRAC_CONST(0.427555084228516) }, + { FRAC_CONST(0.870086967945099), FRAC_CONST(0.492898225784302) }, + { FRAC_CONST(0.831469595432281), FRAC_CONST(0.555570244789124) }, + { FRAC_CONST(0.788346469402313), FRAC_CONST(0.615231573581696) }, + { FRAC_CONST(0.740951120853424), FRAC_CONST(0.671558976173401) }, + { FRAC_CONST(0.689540505409241), FRAC_CONST(0.724247097969055) }, + { FRAC_CONST(0.634393274784088), FRAC_CONST(0.773010432720184) }, + { FRAC_CONST(0.575808227062225), FRAC_CONST(0.817584812641144) }, + { FRAC_CONST(0.514102697372437), FRAC_CONST(0.857728660106659) }, + { FRAC_CONST(0.449611306190491), FRAC_CONST(0.893224298954010) }, + { FRAC_CONST(0.382683426141739), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(0.313681751489639), FRAC_CONST(0.949528157711029) }, + { FRAC_CONST(0.242980241775513), FRAC_CONST(0.970031261444092) }, + { FRAC_CONST(0.170961856842041), FRAC_CONST(0.985277652740479) }, + { FRAC_CONST(0.098017133772373), FRAC_CONST(0.995184719562531) }, + { FRAC_CONST(0.024541255086660), FRAC_CONST(0.999698817729950) }, + { FRAC_CONST(-0.049067739397287), FRAC_CONST(0.998795449733734) }, + { FRAC_CONST(-0.122410707175732), FRAC_CONST(0.992479503154755) }, + { FRAC_CONST(-0.195090323686600), FRAC_CONST(0.980785250663757) }, + { FRAC_CONST(-0.266712725162506), FRAC_CONST(0.963776051998138) }, + { FRAC_CONST(-0.336889803409576), FRAC_CONST(0.941544055938721) }, + { FRAC_CONST(-0.405241340398788), FRAC_CONST(0.914209723472595) }, + { FRAC_CONST(-0.471396833658218), FRAC_CONST(0.881921231746674) }, + { FRAC_CONST(-0.534997701644897), FRAC_CONST(0.844853520393372) }, + { FRAC_CONST(-0.595699369907379), FRAC_CONST(0.803207516670227) }, + { FRAC_CONST(-0.653172850608826), FRAC_CONST(0.757208824157715) }, + { FRAC_CONST(-0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(-0.757208824157715), FRAC_CONST(0.653172850608826) }, + { FRAC_CONST(-0.803207516670227), FRAC_CONST(0.595699369907379) }, + { FRAC_CONST(-0.844853520393372), FRAC_CONST(0.534997701644897) }, + { FRAC_CONST(-0.881921231746674), FRAC_CONST(0.471396833658218) }, + { FRAC_CONST(-0.914209783077240), FRAC_CONST(0.405241221189499) }, + { FRAC_CONST(-0.941544115543365), FRAC_CONST(0.336889803409576) }, + { FRAC_CONST(-0.963776051998138), FRAC_CONST(0.266712725162506) }, + { FRAC_CONST(-0.980785310268402), FRAC_CONST(0.195090308785439) }, + { FRAC_CONST(-0.992479503154755), FRAC_CONST(0.122410699725151) }, + { FRAC_CONST(-0.998795449733734), FRAC_CONST(0.049067724496126) }, + { FRAC_CONST(-0.999698817729950), FRAC_CONST(-0.024541147053242) }, + { FRAC_CONST(-0.995184719562531), FRAC_CONST(-0.098017267882824) }, + { FRAC_CONST(-0.985277652740479), FRAC_CONST(-0.170961990952492) }, + { FRAC_CONST(-0.970031261444092), FRAC_CONST(-0.242980241775513) }, + { FRAC_CONST(-0.949528157711029), FRAC_CONST(-0.313681781291962) }, + { FRAC_CONST(-0.923879504203796), FRAC_CONST(-0.382683426141739) }, + { FRAC_CONST(-0.893224298954010), FRAC_CONST(-0.449611306190491) }, + { FRAC_CONST(-0.857728660106659), FRAC_CONST(-0.514102697372437) }, + { FRAC_CONST(-0.817584872245789), FRAC_CONST(-0.575808107852936) }, + { FRAC_CONST(-0.773010551929474), FRAC_CONST(-0.634393215179443) }, + { FRAC_CONST(-0.724247038364410), FRAC_CONST(-0.689540624618530) }, + { FRAC_CONST(-0.671558916568756), FRAC_CONST(-0.740951180458069) }, + { FRAC_CONST(-0.615231573581696), FRAC_CONST(-0.788346469402313) }, + { FRAC_CONST(-0.555570006370544), FRAC_CONST(-0.831469774246216) }, + { FRAC_CONST(-0.492898195981979), FRAC_CONST(-0.870086967945099) }, + { FRAC_CONST(-0.427554935216904), FRAC_CONST(-0.903989374637604) }, + { FRAC_CONST(-0.359895110130310), FRAC_CONST(-0.932992756366730) }, + { FRAC_CONST(-0.290284544229507), FRAC_CONST(-0.956940352916718) }, + { FRAC_CONST(-0.219101369380951), FRAC_CONST(-0.975702106952667) }, + { FRAC_CONST(-0.146730408072472), FRAC_CONST(-0.989176511764526) }, + { FRAC_CONST(-0.073564760386944), FRAC_CONST(-0.997290432453156) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.995184719562531), FRAC_CONST(0.098017141222954) }, + { FRAC_CONST(0.980785250663757), FRAC_CONST(0.195090323686600) }, + { FRAC_CONST(0.956940352916718), FRAC_CONST(0.290284663438797) }, + { FRAC_CONST(0.923879504203796), FRAC_CONST(0.382683455944061) }, + { FRAC_CONST(0.881921231746674), FRAC_CONST(0.471396744251251) }, + { FRAC_CONST(0.831469595432281), FRAC_CONST(0.555570244789124) }, + { FRAC_CONST(0.773010432720184), FRAC_CONST(0.634393334388733) }, + { FRAC_CONST(0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(0.634393274784088), FRAC_CONST(0.773010432720184) }, + { FRAC_CONST(0.555570185184479), FRAC_CONST(0.831469655036926) }, + { FRAC_CONST(0.471396654844284), FRAC_CONST(0.881921291351318) }, + { FRAC_CONST(0.382683426141739), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(0.290284633636475), FRAC_CONST(0.956940352916718) }, + { FRAC_CONST(0.195090234279633), FRAC_CONST(0.980785310268402) }, + { FRAC_CONST(0.098017133772373), FRAC_CONST(0.995184719562531) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.980785250663757), FRAC_CONST(0.195090323686600) }, + { FRAC_CONST(0.923879504203796), FRAC_CONST(0.382683455944061) }, + { FRAC_CONST(0.831469595432281), FRAC_CONST(0.555570244789124) }, + { FRAC_CONST(0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(0.555570185184479), FRAC_CONST(0.831469655036926) }, + { FRAC_CONST(0.382683426141739), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(0.195090234279633), FRAC_CONST(0.980785310268402) }, + { FRAC_CONST(-0.000000043711388), FRAC_CONST(1.000000000000000) }, + { FRAC_CONST(-0.195090323686600), FRAC_CONST(0.980785250663757) }, + { FRAC_CONST(-0.382683515548706), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(-0.555570363998413), FRAC_CONST(0.831469535827637) }, + { FRAC_CONST(-0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(-0.831469655036926), FRAC_CONST(0.555570185184479) }, + { FRAC_CONST(-0.923879623413086), FRAC_CONST(0.382683277130127) }, + { FRAC_CONST(-0.980785310268402), FRAC_CONST(0.195090308785439) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.956940352916718), FRAC_CONST(0.290284663438797) }, + { FRAC_CONST(0.831469595432281), FRAC_CONST(0.555570244789124) }, + { FRAC_CONST(0.634393274784088), FRAC_CONST(0.773010432720184) }, + { FRAC_CONST(0.382683426141739), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(0.098017133772373), FRAC_CONST(0.995184719562531) }, + { FRAC_CONST(-0.195090323686600), FRAC_CONST(0.980785250663757) }, + { FRAC_CONST(-0.471396833658218), FRAC_CONST(0.881921231746674) }, + { FRAC_CONST(-0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(-0.881921231746674), FRAC_CONST(0.471396833658218) }, + { FRAC_CONST(-0.980785310268402), FRAC_CONST(0.195090308785439) }, + { FRAC_CONST(-0.995184719562531), FRAC_CONST(-0.098017267882824) }, + { FRAC_CONST(-0.923879504203796), FRAC_CONST(-0.382683426141739) }, + { FRAC_CONST(-0.773010551929474), FRAC_CONST(-0.634393215179443) }, + { FRAC_CONST(-0.555570006370544), FRAC_CONST(-0.831469774246216) }, + { FRAC_CONST(-0.290284544229507), FRAC_CONST(-0.956940352916718) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.923879504203796), FRAC_CONST(0.382683455944061) }, + { FRAC_CONST(0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(0.382683426141739), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(-0.000000043711388), FRAC_CONST(1.000000000000000) }, + { FRAC_CONST(-0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.382683426141739), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(-0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(-0.923879504203796), FRAC_CONST(-0.382683426141739) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.000000011924881), FRAC_CONST(-1.000000000000000) } }; -complex_t cfft_tab_240[] = +#ifdef ALLOW_SMALL_FRAMELENGTH +ALIGN static const complex_t cfft_tab_240[] = { - { 0x10000000, 0x0 }, - { 0xFFE98B0, 0x6B3885 }, - { 0xFFA62F0, 0xD65E3B }, - { 0xFF35F90, 0x1415E54 }, - { 0xFE98FD0, 0x1AC260A }, - { 0xFDCF550, 0x216A2A4 }, - { 0xFCD9250, 0x280C170 }, - { 0xFBB6980, 0x2EA6FCC }, - { 0xFA67E20, 0x3539B38 }, - { 0xF8ED3C0, 0x3BC3138 }, - { 0xF746EA0, 0x4241F70 }, - { 0xF575360, 0x48B53B0 }, - { 0xF378710, 0x4F1BBD0 }, - { 0xF150F40, 0x55745E0 }, - { 0xEEFF200, 0x5BBE008 }, - { 0xEC835E0, 0x61F78B0 }, - { 0xE9DE1D0, 0x681FE48 }, - { 0xE70FD40, 0x6E35FA0 }, - { 0xE419010, 0x7438B90 }, - { 0xE0FA280, 0x7A27140 }, - { 0xDDB3D70, 0x8000000 }, - { 0xDA46A00, 0x85C2770 }, - { 0xD6B31D0, 0x8B6D770 }, - { 0xD2F9EF0, 0x9100000 }, - { 0xCF1BBD0, 0x9679180 }, - { 0xCB19340, 0x9BD7CA0 }, - { 0xC6F3090, 0xA11B240 }, - { 0xC2A9F70, 0xA6423B0 }, - { 0xBE3EBD0, 0xAB4C250 }, - { 0xB9B2230, 0xB038010 }, - { 0xB504F30, 0xB504F30 }, - { 0xB038010, 0xB9B2230 }, - { 0xAB4C240, 0xBE3EBE0 }, - { 0xA6423A0, 0xC2A9F70 }, - { 0xA11B240, 0xC6F30A0 }, - { 0x9BD7C90, 0xCB19350 }, - { 0x9679180, 0xCF1BBD0 }, - { 0x9100000, 0xD2F9EF0 }, - { 0x8B6D760, 0xD6B31E0 }, - { 0x85C2760, 0xDA46A10 }, - { 0x7FFFFF8, 0xDDB3D80 }, - { 0x7A27138, 0xE0FA290 }, - { 0x7438B90, 0xE419010 }, - { 0x6E35F88, 0xE70FD50 }, - { 0x681FE40, 0xE9DE1E0 }, - { 0x61F78A8, 0xEC835E0 }, - { 0x5BBDFF0, 0xEEFF210 }, - { 0x55745D0, 0xF150F40 }, - { 0x4F1BBC8, 0xF378710 }, - { 0x48B53A8, 0xF575360 }, - { 0x4241F78, 0xF746EA0 }, - { 0x3BC3124, 0xF8ED3C0 }, - { 0x3539B2C, 0xFA67E20 }, - { 0x2EA6FCC, 0xFBB6980 }, - { 0x280C154, 0xFCD9250 }, - { 0x216A290, 0xFDCF550 }, - { 0x1AC25FE, 0xFE98FD0 }, - { 0x1415E50, 0xFF35F90 }, - { 0xD65E3F, 0xFFA62F0 }, - { 0x6B3871, 0xFFE98B0 }, - { 0xFFFFFFF5, 0x10000000 }, - { 0xFF94C777, 0xFFE98B0 }, - { 0xFF29A1AA, 0xFFA62F0 }, - { 0xFEBEA198, 0xFF35F90 }, - { 0xFE53D9EA, 0xFE98FD0 }, - { 0xFDE95D58, 0xFDCF550 }, - { 0xFD7F3E98, 0xFCD9250 }, - { 0xFD159020, 0xFBB6980 }, - { 0xFCAC64BC, 0xFA67E10 }, - { 0xFC43CEC4, 0xF8ED3C0 }, - { 0xFBDBE070, 0xF746EA0 }, - { 0xFB74AC40, 0xF575350 }, - { 0xFB0E4428, 0xF378700 }, - { 0xFAA8BA20, 0xF150F40 }, - { 0xFA441FF8, 0xEEFF210 }, - { 0xF9E08740, 0xEC835E0 }, - { 0xF97E01A8, 0xE9DE1D0 }, - { 0xF91CA060, 0xE70FD40 }, - { 0xF8BC7458, 0xE419000 }, - { 0xF85D8ED0, 0xE0FA290 }, - { 0x10000000, 0x0 }, - { 0xFFA62F0, 0xD65E3B }, - { 0xFE98FD0, 0x1AC260A }, - { 0xFCD9250, 0x280C170 }, - { 0xFA67E20, 0x3539B38 }, - { 0xF746EA0, 0x4241F70 }, - { 0xF378710, 0x4F1BBD0 }, - { 0xEEFF200, 0x5BBE008 }, - { 0xE9DE1D0, 0x681FE48 }, - { 0xE419010, 0x7438B90 }, - { 0xDDB3D70, 0x8000000 }, - { 0xD6B31D0, 0x8B6D770 }, - { 0xCF1BBD0, 0x9679180 }, - { 0xC6F3090, 0xA11B240 }, - { 0xBE3EBD0, 0xAB4C250 }, - { 0xB504F30, 0xB504F30 }, - { 0xAB4C240, 0xBE3EBE0 }, - { 0xA11B240, 0xC6F30A0 }, - { 0x9679180, 0xCF1BBD0 }, - { 0x8B6D760, 0xD6B31E0 }, - { 0x7FFFFF8, 0xDDB3D80 }, - { 0x7438B90, 0xE419010 }, - { 0x681FE40, 0xE9DE1E0 }, - { 0x5BBDFF0, 0xEEFF210 }, - { 0x4F1BBC8, 0xF378710 }, - { 0x4241F78, 0xF746EA0 }, - { 0x3539B2C, 0xFA67E20 }, - { 0x280C154, 0xFCD9250 }, - { 0x1AC25FE, 0xFE98FD0 }, - { 0xD65E3F, 0xFFA62F0 }, - { 0xFFFFFFF5, 0x10000000 }, - { 0xFF29A1AA, 0xFFA62F0 }, - { 0xFE53D9EA, 0xFE98FD0 }, - { 0xFD7F3E98, 0xFCD9250 }, - { 0xFCAC64BC, 0xFA67E10 }, - { 0xFBDBE070, 0xF746EA0 }, - { 0xFB0E4428, 0xF378700 }, - { 0xFA441FF8, 0xEEFF210 }, - { 0xF97E01A8, 0xE9DE1D0 }, - { 0xF8BC7458, 0xE419000 }, - { 0xF7FFFFF0, 0xDDB3D70 }, - { 0xF7492890, 0xD6B31D0 }, - { 0xF6986E90, 0xCF1BBD0 }, - { 0xF5EE4DA0, 0xC6F3080 }, - { 0xF54B3DA0, 0xBE3EBD0 }, - { 0xF4AFB0D0, 0xB504F30 }, - { 0xF41C1410, 0xAB4C220 }, - { 0xF390CF50, 0xA11B220 }, - { 0xF30E4420, 0x9679170 }, - { 0xF294CE30, 0x8B6D770 }, - { 0xF224C290, 0x8000010 }, - { 0xF1BE6FE0, 0x7438B68 }, - { 0xF1621E20, 0x681FE38 }, - { 0xF1100DF0, 0x5BBE000 }, - { 0xF0C878E0, 0x4F1BB98 }, - { 0xF08B9150, 0x4241F50 }, - { 0xF05981E0, 0x3539B20 }, - { 0xF0326DB0, 0x280C168 }, - { 0xF0167030, 0x1AC2612 }, - { 0xF0059D00, 0xD65E13 }, - { 0xF0000000, 0xFFFFFFE9 }, - { 0xF0059D10, 0xFF29A1BE }, - { 0xF0167040, 0xFE53D9BE }, - { 0xF0326DC0, 0xFD7F3E6C }, - { 0xF05981F0, 0xFCAC64B0 }, - { 0xF08B9160, 0xFBDBE088 }, - { 0xF0C878F0, 0xFB0E4438 }, - { 0xF1100E00, 0xFA441FD0 }, - { 0xF1621E30, 0xF97E01A0 }, - { 0xF1BE6FF0, 0xF8BC7468 }, - { 0xF224C2B0, 0xF7FFFFD0 }, - { 0xF294CE40, 0xF7492870 }, - { 0xF30E4440, 0xF6986E60 }, - { 0xF390CF70, 0xF5EE4DB0 }, - { 0xF41C1430, 0xF54B3DB0 }, - { 0xF4AFB0F0, 0xF4AFB0B0 }, - { 0xF54B3DD0, 0xF41C1420 }, - { 0xF5EE4DD0, 0xF390CF60 }, - { 0xF6986EB0, 0xF30E4410 }, - { 0xF7492880, 0xF294CE30 }, - { 0x10000000, 0x0 }, - { 0xFF35F90, 0x1415E54 }, - { 0xFCD9250, 0x280C170 }, - { 0xF8ED3C0, 0x3BC3138 }, - { 0xF378710, 0x4F1BBD0 }, - { 0xEC835E0, 0x61F78B0 }, - { 0xE419010, 0x7438B90 }, - { 0xDA46A00, 0x85C2770 }, - { 0xCF1BBD0, 0x9679180 }, - { 0xC2A9F70, 0xA6423B0 }, - { 0xB504F30, 0xB504F30 }, - { 0xA6423A0, 0xC2A9F70 }, - { 0x9679180, 0xCF1BBD0 }, - { 0x85C2760, 0xDA46A10 }, - { 0x7438B90, 0xE419010 }, - { 0x61F78A8, 0xEC835E0 }, - { 0x4F1BBC8, 0xF378710 }, - { 0x3BC3124, 0xF8ED3C0 }, - { 0x280C154, 0xFCD9250 }, - { 0x1415E50, 0xFF35F90 }, - { 0x10000000, 0x0 }, - { 0xFCD9250, 0x280C170 }, - { 0xF378710, 0x4F1BBD0 }, - { 0xE419010, 0x7438B90 }, - { 0xCF1BBD0, 0x9679180 }, - { 0xB504F30, 0xB504F30 }, - { 0x9679180, 0xCF1BBD0 }, - { 0x7438B90, 0xE419010 }, - { 0x4F1BBC8, 0xF378710 }, - { 0x280C154, 0xFCD9250 }, - { 0xFFFFFFF5, 0x10000000 }, - { 0xFD7F3E98, 0xFCD9250 }, - { 0xFB0E4428, 0xF378700 }, - { 0xF8BC7458, 0xE419000 }, - { 0xF6986E90, 0xCF1BBD0 }, - { 0xF4AFB0D0, 0xB504F30 }, - { 0xF30E4420, 0x9679170 }, - { 0xF1BE6FE0, 0x7438B68 }, - { 0xF0C878E0, 0x4F1BB98 }, - { 0xF0326DB0, 0x280C168 }, - { 0x10000000, 0x0 }, - { 0xF8ED3C0, 0x3BC3138 }, - { 0xE419010, 0x7438B90 }, - { 0xC2A9F70, 0xA6423B0 }, - { 0x9679180, 0xCF1BBD0 }, - { 0x61F78A8, 0xEC835E0 }, - { 0x280C154, 0xFCD9250 }, - { 0xFEBEA198, 0xFF35F90 }, - { 0xFB0E4428, 0xF378700 }, - { 0xF7A3D870, 0xDA469F0 }, - { 0xF4AFB0D0, 0xB504F30 }, - { 0xF25B95F0, 0x85C2760 }, - { 0xF0C878E0, 0x4F1BB98 }, - { 0xF00CA060, 0x1415E44 }, - { 0xF0326DC0, 0xFD7F3E6C }, - { 0xF137CA20, 0xF9E08758 }, - { 0xF30E4440, 0xF6986E60 }, - { 0xF59BDC80, 0xF3D56070 }, - { 0xF8BC74C0, 0xF1BE6FD0 }, - { 0xFC43CEB4, 0xF0712C40 }, - { 0x10000000, 0x0 }, - { 0xF378710, 0x4F1BBD0 }, - { 0xCF1BBD0, 0x9679180 }, - { 0x9679180, 0xCF1BBD0 }, - { 0x4F1BBC8, 0xF378710 }, - { 0x10000000, 0x0 }, - { 0xCF1BBD0, 0x9679180 }, - { 0x4F1BBC8, 0xF378710 }, - { 0xFB0E4428, 0xF378700 }, - { 0xF30E4420, 0x9679170 }, - { 0x10000000, 0x0 }, - { 0x9679180, 0xCF1BBD0 }, - { 0xFB0E4428, 0xF378700 }, - { 0xF0C878E0, 0x4F1BB98 }, - { 0xF30E4440, 0xF6986E60 }, - { 0x10000000, 0x0 }, - { 0x10000000, 0x0 }, - { 0x10000000, 0x0 }, - { 0x10000000, 0x0 }, - { 0x4F1BBF0, 0xF0C87900 } + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.999657332897186), FRAC_CONST(0.026176949962974) }, + { FRAC_CONST(0.998629510402679), FRAC_CONST(0.052335958927870) }, + { FRAC_CONST(0.996917307376862), FRAC_CONST(0.078459098935127) }, + { FRAC_CONST(0.994521915912628), FRAC_CONST(0.104528464376926) }, + { FRAC_CONST(0.991444885730743), FRAC_CONST(0.130526199936867) }, + { FRAC_CONST(0.987688362598419), FRAC_CONST(0.156434476375580) }, + { FRAC_CONST(0.983254909515381), FRAC_CONST(0.182235524058342) }, + { FRAC_CONST(0.978147625923157), FRAC_CONST(0.207911700010300) }, + { FRAC_CONST(0.972369909286499), FRAC_CONST(0.233445376157761) }, + { FRAC_CONST(0.965925812721252), FRAC_CONST(0.258819043636322) }, + { FRAC_CONST(0.958819746971130), FRAC_CONST(0.284015357494354) }, + { FRAC_CONST(0.951056540012360), FRAC_CONST(0.309017002582550) }, + { FRAC_CONST(0.942641496658325), FRAC_CONST(0.333806872367859) }, + { FRAC_CONST(0.933580398559570), FRAC_CONST(0.358367949724197) }, + { FRAC_CONST(0.923879504203796), FRAC_CONST(0.382683455944061) }, + { FRAC_CONST(0.913545429706573), FRAC_CONST(0.406736642122269) }, + { FRAC_CONST(0.902585268020630), FRAC_CONST(0.430511116981506) }, + { FRAC_CONST(0.891006529331207), FRAC_CONST(0.453990519046783) }, + { FRAC_CONST(0.878817081451416), FRAC_CONST(0.477158784866333) }, + { FRAC_CONST(0.866025388240814), FRAC_CONST(0.500000000000000) }, + { FRAC_CONST(0.852640151977539), FRAC_CONST(0.522498548030853) }, + { FRAC_CONST(0.838670551776886), FRAC_CONST(0.544639050960541) }, + { FRAC_CONST(0.824126183986664), FRAC_CONST(0.566406250000000) }, + { FRAC_CONST(0.809017002582550), FRAC_CONST(0.587785243988037) }, + { FRAC_CONST(0.793353319168091), FRAC_CONST(0.608761429786682) }, + { FRAC_CONST(0.777145922183990), FRAC_CONST(0.629320383071899) }, + { FRAC_CONST(0.760405957698822), FRAC_CONST(0.649448096752167) }, + { FRAC_CONST(0.743144810199738), FRAC_CONST(0.669130623340607) }, + { FRAC_CONST(0.725374400615692), FRAC_CONST(0.688354551792145) }, + { FRAC_CONST(0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(0.688354551792145), FRAC_CONST(0.725374400615692) }, + { FRAC_CONST(0.669130563735962), FRAC_CONST(0.743144869804382) }, + { FRAC_CONST(0.649448037147522), FRAC_CONST(0.760405957698822) }, + { FRAC_CONST(0.629320383071899), FRAC_CONST(0.777145981788635) }, + { FRAC_CONST(0.608761370182037), FRAC_CONST(0.793353378772736) }, + { FRAC_CONST(0.587785243988037), FRAC_CONST(0.809017002582550) }, + { FRAC_CONST(0.566406250000000), FRAC_CONST(0.824126183986664) }, + { FRAC_CONST(0.544638991355896), FRAC_CONST(0.838670611381531) }, + { FRAC_CONST(0.522498488426209), FRAC_CONST(0.852640211582184) }, + { FRAC_CONST(0.499999970197678), FRAC_CONST(0.866025447845459) }, + { FRAC_CONST(0.477158755064011), FRAC_CONST(0.878817141056061) }, + { FRAC_CONST(0.453990519046783), FRAC_CONST(0.891006529331207) }, + { FRAC_CONST(0.430511027574539), FRAC_CONST(0.902585327625275) }, + { FRAC_CONST(0.406736612319946), FRAC_CONST(0.913545489311218) }, + { FRAC_CONST(0.382683426141739), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(0.358367860317230), FRAC_CONST(0.933580458164215) }, + { FRAC_CONST(0.333806812763214), FRAC_CONST(0.942641496658325) }, + { FRAC_CONST(0.309016972780228), FRAC_CONST(0.951056540012360) }, + { FRAC_CONST(0.284015327692032), FRAC_CONST(0.958819746971130) }, + { FRAC_CONST(0.258819073438644), FRAC_CONST(0.965925812721252) }, + { FRAC_CONST(0.233445301651955), FRAC_CONST(0.972369909286499) }, + { FRAC_CONST(0.207911655306816), FRAC_CONST(0.978147625923157) }, + { FRAC_CONST(0.182235524058342), FRAC_CONST(0.983254909515381) }, + { FRAC_CONST(0.156434372067451), FRAC_CONST(0.987688362598419) }, + { FRAC_CONST(0.130526125431061), FRAC_CONST(0.991444885730743) }, + { FRAC_CONST(0.104528419673443), FRAC_CONST(0.994521915912628) }, + { FRAC_CONST(0.078459084033966), FRAC_CONST(0.996917307376862) }, + { FRAC_CONST(0.052335973829031), FRAC_CONST(0.998629510402679) }, + { FRAC_CONST(0.026176875457168), FRAC_CONST(0.999657332897186) }, + { FRAC_CONST(-0.000000043711388), FRAC_CONST(1.000000000000000) }, + { FRAC_CONST(-0.026176963001490), FRAC_CONST(0.999657332897186) }, + { FRAC_CONST(-0.052336059510708), FRAC_CONST(0.998629510402679) }, + { FRAC_CONST(-0.078459173440933), FRAC_CONST(0.996917307376862) }, + { FRAC_CONST(-0.104528509080410), FRAC_CONST(0.994521915912628) }, + { FRAC_CONST(-0.130526214838028), FRAC_CONST(0.991444885730743) }, + { FRAC_CONST(-0.156434446573257), FRAC_CONST(0.987688362598419) }, + { FRAC_CONST(-0.182235598564148), FRAC_CONST(0.983254909515381) }, + { FRAC_CONST(-0.207911744713783), FRAC_CONST(0.978147566318512) }, + { FRAC_CONST(-0.233445391058922), FRAC_CONST(0.972369909286499) }, + { FRAC_CONST(-0.258819162845612), FRAC_CONST(0.965925812721252) }, + { FRAC_CONST(-0.284015417098999), FRAC_CONST(0.958819687366486) }, + { FRAC_CONST(-0.309017032384872), FRAC_CONST(0.951056480407715) }, + { FRAC_CONST(-0.333806872367859), FRAC_CONST(0.942641496658325) }, + { FRAC_CONST(-0.358367949724197), FRAC_CONST(0.933580458164215) }, + { FRAC_CONST(-0.382683515548706), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(-0.406736701726913), FRAC_CONST(0.913545429706573) }, + { FRAC_CONST(-0.430511116981506), FRAC_CONST(0.902585268020630) }, + { FRAC_CONST(-0.453990608453751), FRAC_CONST(0.891006469726563) }, + { FRAC_CONST(-0.477158725261688), FRAC_CONST(0.878817141056061) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.998629510402679), FRAC_CONST(0.052335958927870) }, + { FRAC_CONST(0.994521915912628), FRAC_CONST(0.104528464376926) }, + { FRAC_CONST(0.987688362598419), FRAC_CONST(0.156434476375580) }, + { FRAC_CONST(0.978147625923157), FRAC_CONST(0.207911700010300) }, + { FRAC_CONST(0.965925812721252), FRAC_CONST(0.258819043636322) }, + { FRAC_CONST(0.951056540012360), FRAC_CONST(0.309017002582550) }, + { FRAC_CONST(0.933580398559570), FRAC_CONST(0.358367949724197) }, + { FRAC_CONST(0.913545429706573), FRAC_CONST(0.406736642122269) }, + { FRAC_CONST(0.891006529331207), FRAC_CONST(0.453990519046783) }, + { FRAC_CONST(0.866025388240814), FRAC_CONST(0.500000000000000) }, + { FRAC_CONST(0.838670551776886), FRAC_CONST(0.544639050960541) }, + { FRAC_CONST(0.809017002582550), FRAC_CONST(0.587785243988037) }, + { FRAC_CONST(0.777145922183990), FRAC_CONST(0.629320383071899) }, + { FRAC_CONST(0.743144810199738), FRAC_CONST(0.669130623340607) }, + { FRAC_CONST(0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(0.669130563735962), FRAC_CONST(0.743144869804382) }, + { FRAC_CONST(0.629320383071899), FRAC_CONST(0.777145981788635) }, + { FRAC_CONST(0.587785243988037), FRAC_CONST(0.809017002582550) }, + { FRAC_CONST(0.544638991355896), FRAC_CONST(0.838670611381531) }, + { FRAC_CONST(0.499999970197678), FRAC_CONST(0.866025447845459) }, + { FRAC_CONST(0.453990519046783), FRAC_CONST(0.891006529331207) }, + { FRAC_CONST(0.406736612319946), FRAC_CONST(0.913545489311218) }, + { FRAC_CONST(0.358367860317230), FRAC_CONST(0.933580458164215) }, + { FRAC_CONST(0.309016972780228), FRAC_CONST(0.951056540012360) }, + { FRAC_CONST(0.258819073438644), FRAC_CONST(0.965925812721252) }, + { FRAC_CONST(0.207911655306816), FRAC_CONST(0.978147625923157) }, + { FRAC_CONST(0.156434372067451), FRAC_CONST(0.987688362598419) }, + { FRAC_CONST(0.104528419673443), FRAC_CONST(0.994521915912628) }, + { FRAC_CONST(0.052335973829031), FRAC_CONST(0.998629510402679) }, + { FRAC_CONST(-0.000000043711388), FRAC_CONST(1.000000000000000) }, + { FRAC_CONST(-0.052336059510708), FRAC_CONST(0.998629510402679) }, + { FRAC_CONST(-0.104528509080410), FRAC_CONST(0.994521915912628) }, + { FRAC_CONST(-0.156434446573257), FRAC_CONST(0.987688362598419) }, + { FRAC_CONST(-0.207911744713783), FRAC_CONST(0.978147566318512) }, + { FRAC_CONST(-0.258819162845612), FRAC_CONST(0.965925812721252) }, + { FRAC_CONST(-0.309017032384872), FRAC_CONST(0.951056480407715) }, + { FRAC_CONST(-0.358367949724197), FRAC_CONST(0.933580458164215) }, + { FRAC_CONST(-0.406736701726913), FRAC_CONST(0.913545429706573) }, + { FRAC_CONST(-0.453990608453751), FRAC_CONST(0.891006469726563) }, + { FRAC_CONST(-0.500000059604645), FRAC_CONST(0.866025388240814) }, + { FRAC_CONST(-0.544639050960541), FRAC_CONST(0.838670551776886) }, + { FRAC_CONST(-0.587785184383392), FRAC_CONST(0.809017002582550) }, + { FRAC_CONST(-0.629320502281189), FRAC_CONST(0.777145862579346) }, + { FRAC_CONST(-0.669130682945251), FRAC_CONST(0.743144810199738) }, + { FRAC_CONST(-0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(-0.743144929409027), FRAC_CONST(0.669130444526672) }, + { FRAC_CONST(-0.777146041393280), FRAC_CONST(0.629320263862610) }, + { FRAC_CONST(-0.809017062187195), FRAC_CONST(0.587785184383392) }, + { FRAC_CONST(-0.838670551776886), FRAC_CONST(0.544639050960541) }, + { FRAC_CONST(-0.866025388240814), FRAC_CONST(0.500000059604645) }, + { FRAC_CONST(-0.891006588935852), FRAC_CONST(0.453990370035172) }, + { FRAC_CONST(-0.913545489311218), FRAC_CONST(0.406736582517624) }, + { FRAC_CONST(-0.933580458164215), FRAC_CONST(0.358367919921875) }, + { FRAC_CONST(-0.951056599617004), FRAC_CONST(0.309016793966293) }, + { FRAC_CONST(-0.965925872325897), FRAC_CONST(0.258818924427032) }, + { FRAC_CONST(-0.978147625923157), FRAC_CONST(0.207911610603333) }, + { FRAC_CONST(-0.987688362598419), FRAC_CONST(0.156434446573257) }, + { FRAC_CONST(-0.994521915912628), FRAC_CONST(0.104528494179249) }, + { FRAC_CONST(-0.998629570007324), FRAC_CONST(0.052335809916258) }, + { FRAC_CONST(-1.000000000000000), FRAC_CONST(-0.000000087422777) }, + { FRAC_CONST(-0.998629510402679), FRAC_CONST(-0.052335985004902) }, + { FRAC_CONST(-0.994521856307983), FRAC_CONST(-0.104528672993183) }, + { FRAC_CONST(-0.987688302993774), FRAC_CONST(-0.156434610486031) }, + { FRAC_CONST(-0.978147566318512), FRAC_CONST(-0.207911789417267) }, + { FRAC_CONST(-0.965925812721252), FRAC_CONST(-0.258819073438644) }, + { FRAC_CONST(-0.951056540012360), FRAC_CONST(-0.309016972780228) }, + { FRAC_CONST(-0.933580398559570), FRAC_CONST(-0.358368098735809) }, + { FRAC_CONST(-0.913545429706573), FRAC_CONST(-0.406736731529236) }, + { FRAC_CONST(-0.891006529331207), FRAC_CONST(-0.453990548849106) }, + { FRAC_CONST(-0.866025269031525), FRAC_CONST(-0.500000178813934) }, + { FRAC_CONST(-0.838670492172241), FRAC_CONST(-0.544639170169830) }, + { FRAC_CONST(-0.809016942977905), FRAC_CONST(-0.587785363197327) }, + { FRAC_CONST(-0.777145922183990), FRAC_CONST(-0.629320442676544) }, + { FRAC_CONST(-0.743144810199738), FRAC_CONST(-0.669130623340607) }, + { FRAC_CONST(-0.707106649875641), FRAC_CONST(-0.707106888294220) }, + { FRAC_CONST(-0.669130504131317), FRAC_CONST(-0.743144869804382) }, + { FRAC_CONST(-0.629320323467255), FRAC_CONST(-0.777145981788635) }, + { FRAC_CONST(-0.587785065174103), FRAC_CONST(-0.809017121791840) }, + { FRAC_CONST(-0.544639110565186), FRAC_CONST(-0.838670551776886) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.996917307376862), FRAC_CONST(0.078459098935127) }, + { FRAC_CONST(0.987688362598419), FRAC_CONST(0.156434476375580) }, + { FRAC_CONST(0.972369909286499), FRAC_CONST(0.233445376157761) }, + { FRAC_CONST(0.951056540012360), FRAC_CONST(0.309017002582550) }, + { FRAC_CONST(0.923879504203796), FRAC_CONST(0.382683455944061) }, + { FRAC_CONST(0.891006529331207), FRAC_CONST(0.453990519046783) }, + { FRAC_CONST(0.852640151977539), FRAC_CONST(0.522498548030853) }, + { FRAC_CONST(0.809017002582550), FRAC_CONST(0.587785243988037) }, + { FRAC_CONST(0.760405957698822), FRAC_CONST(0.649448096752167) }, + { FRAC_CONST(0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(0.649448037147522), FRAC_CONST(0.760405957698822) }, + { FRAC_CONST(0.587785243988037), FRAC_CONST(0.809017002582550) }, + { FRAC_CONST(0.522498488426209), FRAC_CONST(0.852640211582184) }, + { FRAC_CONST(0.453990519046783), FRAC_CONST(0.891006529331207) }, + { FRAC_CONST(0.382683426141739), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(0.309016972780228), FRAC_CONST(0.951056540012360) }, + { FRAC_CONST(0.233445301651955), FRAC_CONST(0.972369909286499) }, + { FRAC_CONST(0.156434372067451), FRAC_CONST(0.987688362598419) }, + { FRAC_CONST(0.078459084033966), FRAC_CONST(0.996917307376862) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.987688362598419), FRAC_CONST(0.156434476375580) }, + { FRAC_CONST(0.951056540012360), FRAC_CONST(0.309017002582550) }, + { FRAC_CONST(0.891006529331207), FRAC_CONST(0.453990519046783) }, + { FRAC_CONST(0.809017002582550), FRAC_CONST(0.587785243988037) }, + { FRAC_CONST(0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(0.587785243988037), FRAC_CONST(0.809017002582550) }, + { FRAC_CONST(0.453990519046783), FRAC_CONST(0.891006529331207) }, + { FRAC_CONST(0.309016972780228), FRAC_CONST(0.951056540012360) }, + { FRAC_CONST(0.156434372067451), FRAC_CONST(0.987688362598419) }, + { FRAC_CONST(-0.000000043711388), FRAC_CONST(1.000000000000000) }, + { FRAC_CONST(-0.156434446573257), FRAC_CONST(0.987688362598419) }, + { FRAC_CONST(-0.309017032384872), FRAC_CONST(0.951056480407715) }, + { FRAC_CONST(-0.453990608453751), FRAC_CONST(0.891006469726563) }, + { FRAC_CONST(-0.587785184383392), FRAC_CONST(0.809017002582550) }, + { FRAC_CONST(-0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(-0.809017062187195), FRAC_CONST(0.587785184383392) }, + { FRAC_CONST(-0.891006588935852), FRAC_CONST(0.453990370035172) }, + { FRAC_CONST(-0.951056599617004), FRAC_CONST(0.309016793966293) }, + { FRAC_CONST(-0.987688362598419), FRAC_CONST(0.156434446573257) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.972369909286499), FRAC_CONST(0.233445376157761) }, + { FRAC_CONST(0.891006529331207), FRAC_CONST(0.453990519046783) }, + { FRAC_CONST(0.760405957698822), FRAC_CONST(0.649448096752167) }, + { FRAC_CONST(0.587785243988037), FRAC_CONST(0.809017002582550) }, + { FRAC_CONST(0.382683426141739), FRAC_CONST(0.923879504203796) }, + { FRAC_CONST(0.156434372067451), FRAC_CONST(0.987688362598419) }, + { FRAC_CONST(-0.078459173440933), FRAC_CONST(0.996917307376862) }, + { FRAC_CONST(-0.309017032384872), FRAC_CONST(0.951056480407715) }, + { FRAC_CONST(-0.522498667240143), FRAC_CONST(0.852640092372894) }, + { FRAC_CONST(-0.707106769084930), FRAC_CONST(0.707106769084930) }, + { FRAC_CONST(-0.852640211582184), FRAC_CONST(0.522498488426209) }, + { FRAC_CONST(-0.951056599617004), FRAC_CONST(0.309016793966293) }, + { FRAC_CONST(-0.996917366981506), FRAC_CONST(0.078459039330482) }, + { FRAC_CONST(-0.987688302993774), FRAC_CONST(-0.156434610486031) }, + { FRAC_CONST(-0.923879504203796), FRAC_CONST(-0.382683426141739) }, + { FRAC_CONST(-0.809016942977905), FRAC_CONST(-0.587785363197327) }, + { FRAC_CONST(-0.649447917938232), FRAC_CONST(-0.760406076908112) }, + { FRAC_CONST(-0.453990221023560), FRAC_CONST(-0.891006648540497) }, + { FRAC_CONST(-0.233445450663567), FRAC_CONST(-0.972369909286499) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.951056540012360), FRAC_CONST(0.309017002582550) }, + { FRAC_CONST(0.809017002582550), FRAC_CONST(0.587785243988037) }, + { FRAC_CONST(0.587785243988037), FRAC_CONST(0.809017002582550) }, + { FRAC_CONST(0.309016972780228), FRAC_CONST(0.951056540012360) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.809017002582550), FRAC_CONST(0.587785243988037) }, + { FRAC_CONST(0.309016972780228), FRAC_CONST(0.951056540012360) }, + { FRAC_CONST(-0.309017032384872), FRAC_CONST(0.951056480407715) }, + { FRAC_CONST(-0.809017062187195), FRAC_CONST(0.587785184383392) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.587785243988037), FRAC_CONST(0.809017002582550) }, + { FRAC_CONST(-0.309017032384872), FRAC_CONST(0.951056480407715) }, + { FRAC_CONST(-0.951056599617004), FRAC_CONST(0.309016793966293) }, + { FRAC_CONST(-0.809016942977905), FRAC_CONST(-0.587785363197327) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(1.000000000000000), FRAC_CONST(0.000000000000000) }, + { FRAC_CONST(0.309017121791840), FRAC_CONST(-0.951056480407715) } }; +#endif #endif diff --git a/src/libfaad/codebook/Makefile.am b/src/libfaad/codebook/Makefile.am index bd2f22e5f..e4691f4b9 100644 --- a/src/libfaad/codebook/Makefile.am +++ b/src/libfaad/codebook/Makefile.am @@ -1,15 +1,15 @@ include $(top_srcdir)/misc/Makefile.common EXTRA_DIST = hcb.h \ - hcb_1.c \ - hcb_2.c \ - hcb_3.c \ - hcb_4.c \ - hcb_5.c \ - hcb_6.c \ - hcb_7.c \ - hcb_8.c \ - hcb_9.c \ - hcb_10.c \ - hcb_11.c \ - hcb_sf.c + hcb_1.h \ + hcb_2.h \ + hcb_3.h \ + hcb_4.h \ + hcb_5.h \ + hcb_6.h \ + hcb_7.h \ + hcb_8.h \ + hcb_9.h \ + hcb_10.h \ + hcb_11.h \ + hcb_sf.h diff --git a/src/libfaad/codebook/hcb.h b/src/libfaad/codebook/hcb.h index f798e58ed..66d937076 100644 --- a/src/libfaad/codebook/hcb.h +++ b/src/libfaad/codebook/hcb.h @@ -1,22 +1,28 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker -** +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. -** +** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. -** +** ** You should have received a copy of the GNU General Public License -** along with this program; if not, write to the Free Software +** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: hcb.h,v 1.2 2002/12/16 18:58:53 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: hcb.h,v 1.3 2003/12/30 02:00:12 miguelfreitas Exp $ **/ #ifndef __HCB_H__ @@ -65,7 +71,6 @@ extern "C" { #define ESC_HCB 11 #define QUAD_LEN 4 #define PAIR_LEN 2 -#define BOOKSCL 12 #define NOISE_HCB 13 #define INTENSITY_HCB2 14 #define INTENSITY_HCB 15 @@ -107,28 +112,29 @@ typedef struct int8_t data[2]; } hcb_bin_pair; -extern hcb hcb1_1[]; -extern hcb hcb2_1[]; -extern hcb hcb4_1[]; -extern hcb hcb6_1[]; -extern hcb hcb8_1[]; -extern hcb hcb10_1[]; -extern hcb hcb11_1[]; - -extern hcb_2_quad hcb1_2[]; -extern hcb_2_quad hcb2_2[]; -extern hcb_2_quad hcb4_2[]; -extern hcb_2_pair hcb6_2[]; -extern hcb_2_pair hcb8_2[]; -extern hcb_2_pair hcb10_2[]; -extern hcb_2_pair hcb11_2[]; +hcb *hcb_table[]; +hcb_2_quad *hcb_2_quad_table[]; +hcb_2_pair *hcb_2_pair_table[]; +hcb_bin_pair *hcb_bin_table[]; +uint8_t hcbN[]; +uint8_t unsigned_cb[]; +int hcb_2_quad_table_size[]; +int hcb_2_pair_table_size[]; +int hcb_bin_table_size[]; -extern hcb_bin_quad hcb3[]; -extern hcb_bin_pair hcb5[]; -extern hcb_bin_pair hcb7[]; -extern hcb_bin_pair hcb9[]; +#include "codebook/hcb_1.h" +#include "codebook/hcb_2.h" +#include "codebook/hcb_3.h" +#include "codebook/hcb_4.h" +#include "codebook/hcb_5.h" +#include "codebook/hcb_6.h" +#include "codebook/hcb_7.h" +#include "codebook/hcb_8.h" +#include "codebook/hcb_9.h" +#include "codebook/hcb_10.h" +#include "codebook/hcb_11.h" +#include "codebook/hcb_sf.h" -extern uint8_t hcb_sf[][2]; #ifdef __cplusplus } diff --git a/src/libfaad/codebook/hcb_1.c b/src/libfaad/codebook/hcb_1.h index 95bbd3f52..1c838558c 100644 --- a/src/libfaad/codebook/hcb_1.c +++ b/src/libfaad/codebook/hcb_1.h @@ -1,27 +1,30 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker -** +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. -** +** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. -** +** ** You should have received a copy of the GNU General Public License -** along with this program; if not, write to the Free Software +** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: hcb_1.c,v 1.2 2002/12/16 18:58:54 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: hcb_1.h,v 1.1 2003/12/30 02:00:12 miguelfreitas Exp $ **/ -#include "../common.h" -#include "hcb.h" - /* 2-step huffman table HCB_1 */ @@ -30,7 +33,7 @@ * * Used to find offset into 2nd step table and number of extra bits to get */ -extern hcb hcb1_1[] = { +static hcb hcb1_1[] = { { /* 00000 */ 0, 0 }, { /* */ 0, 0 }, { /* */ 0, 0 }, @@ -75,7 +78,7 @@ extern hcb hcb1_1[] = { * * Gives size of codeword and actual data (x,y,v,w) */ -extern hcb_2_quad hcb1_2[] = { +static hcb_2_quad hcb1_2[] = { /* 1 bit codeword */ { 1, 0, 0, 0, 0 }, diff --git a/src/libfaad/codebook/hcb_10.c b/src/libfaad/codebook/hcb_10.h index 7aea30985..1875fc090 100644 --- a/src/libfaad/codebook/hcb_10.c +++ b/src/libfaad/codebook/hcb_10.h @@ -1,27 +1,30 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker -** +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. -** +** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. -** +** ** You should have received a copy of the GNU General Public License -** along with this program; if not, write to the Free Software +** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: hcb_10.c,v 1.2 2002/12/16 18:58:55 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: hcb_10.h,v 1.1 2003/12/30 02:00:12 miguelfreitas Exp $ **/ -#include "../common.h" -#include "hcb.h" - /* 2-step huffman table HCB_10 */ @@ -30,7 +33,7 @@ * * Used to find offset into 2nd step table and number of extra bits to get */ -extern hcb hcb10_1[] = { +static hcb hcb10_1[] = { /* 4 bit codewords */ { /* 000000 */ 0, 0 }, { /* */ 0, 0 }, @@ -112,7 +115,7 @@ extern hcb hcb10_1[] = { * * Gives size of codeword and actual data (x,y,v,w) */ -extern hcb_2_pair hcb10_2[] = { +static hcb_2_pair hcb10_2[] = { /* 4 bit codewords */ { 4, 1, 1 }, { 4, 1, 2 }, diff --git a/src/libfaad/codebook/hcb_11.c b/src/libfaad/codebook/hcb_11.h index b6d202e80..352151cc2 100644 --- a/src/libfaad/codebook/hcb_11.c +++ b/src/libfaad/codebook/hcb_11.h @@ -1,27 +1,30 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker -** +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. -** +** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. -** +** ** You should have received a copy of the GNU General Public License -** along with this program; if not, write to the Free Software +** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: hcb_11.c,v 1.2 2002/12/16 18:58:56 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: hcb_11.h,v 1.1 2003/12/30 02:00:12 miguelfreitas Exp $ **/ -#include "../common.h" -#include "hcb.h" - /* 2-step huffman table HCB_11 */ @@ -30,7 +33,7 @@ * * Used to find offset into 2nd step table and number of extra bits to get */ -extern hcb hcb11_1[] = { +static hcb hcb11_1[] = { /* 4 bits */ { /* 00000 */ 0, 0 }, { /* */ 0, 0 }, @@ -92,7 +95,7 @@ extern hcb hcb11_1[] = { * * Gives size of codeword and actual data (x,y,v,w) */ -extern hcb_2_pair hcb11_2[] = { +static hcb_2_pair hcb11_2[] = { /* 4 */ { 4, 0, 0 }, { 4, 1, 1 }, diff --git a/src/libfaad/codebook/hcb_2.c b/src/libfaad/codebook/hcb_2.h index 6e2b9c1cf..16aa4308d 100644 --- a/src/libfaad/codebook/hcb_2.c +++ b/src/libfaad/codebook/hcb_2.h @@ -1,27 +1,30 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker -** +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. -** +** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. -** +** ** You should have received a copy of the GNU General Public License -** along with this program; if not, write to the Free Software +** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: hcb_2.c,v 1.2 2002/12/16 18:58:57 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: hcb_2.h,v 1.1 2003/12/30 02:00:12 miguelfreitas Exp $ **/ -#include "../common.h" -#include "hcb.h" - /* 2-step huffman table HCB_2 */ @@ -30,7 +33,7 @@ * * Used to find offset into 2nd step table and number of extra bits to get */ -extern hcb hcb2_1[] = { +static hcb hcb2_1[] = { { /* 00000 */ 0, 0 }, { /* */ 0, 0 }, { /* */ 0, 0 }, @@ -79,7 +82,7 @@ extern hcb hcb2_1[] = { * * Gives size of codeword and actual data (x,y,v,w) */ -extern hcb_2_quad hcb2_2[] = { +static hcb_2_quad hcb2_2[] = { /* 3 bit codeword */ { 3, 0, 0, 0, 0 }, diff --git a/src/libfaad/codebook/hcb_3.c b/src/libfaad/codebook/hcb_3.h index 09e013056..6b370f4ba 100644 --- a/src/libfaad/codebook/hcb_3.c +++ b/src/libfaad/codebook/hcb_3.h @@ -1,31 +1,34 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker -** +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. -** +** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. -** +** ** You should have received a copy of the GNU General Public License -** along with this program; if not, write to the Free Software +** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: hcb_3.c,v 1.2 2002/12/16 18:58:58 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: hcb_3.h,v 1.1 2003/12/30 02:00:12 miguelfreitas Exp $ **/ -#include "../common.h" -#include "hcb.h" - /* Binary search huffman table HCB_3 */ -extern hcb_bin_quad hcb3[] = { +static hcb_bin_quad hcb3[] = { { /* 0 */ 0, { 1, 2, 0, 0 } }, { /* 1 */ 1, { 0, 0, 0, 0 } }, /* 0 */ { /* 2 */ 0, { 1, 2, 0, 0 } }, diff --git a/src/libfaad/codebook/hcb_4.c b/src/libfaad/codebook/hcb_4.h index 1845936d4..46f373bd7 100644 --- a/src/libfaad/codebook/hcb_4.c +++ b/src/libfaad/codebook/hcb_4.h @@ -1,27 +1,30 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker -** +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. -** +** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. -** +** ** You should have received a copy of the GNU General Public License -** along with this program; if not, write to the Free Software +** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: hcb_4.c,v 1.2 2002/12/16 18:58:58 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: hcb_4.h,v 1.1 2003/12/30 02:00:12 miguelfreitas Exp $ **/ -#include "../common.h" -#include "hcb.h" - /* 2-step huffman table HCB_4 */ @@ -30,7 +33,7 @@ * * Used to find offset into 2nd step table and number of extra bits to get */ -extern hcb hcb4_1[] = { +static hcb hcb4_1[] = { /* 4 bit codewords */ { /* 00000 */ 0, 0 }, { /* */ 0, 0 }, @@ -82,7 +85,7 @@ extern hcb hcb4_1[] = { * * Gives size of codeword and actual data (x,y,v,w) */ -extern hcb_2_quad hcb4_2[] = { +static hcb_2_quad hcb4_2[] = { /* 4 bit codewords */ { 4, 1, 1, 1, 1 }, { 4, 0, 1, 1, 1 }, diff --git a/src/libfaad/codebook/hcb_5.c b/src/libfaad/codebook/hcb_5.h index 094a7ffd2..db309a4b6 100644 --- a/src/libfaad/codebook/hcb_5.c +++ b/src/libfaad/codebook/hcb_5.h @@ -1,31 +1,34 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker -** +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. -** +** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. -** +** ** You should have received a copy of the GNU General Public License -** along with this program; if not, write to the Free Software +** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: hcb_5.c,v 1.2 2002/12/16 18:58:58 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: hcb_5.h,v 1.1 2003/12/30 02:00:12 miguelfreitas Exp $ **/ -#include "../common.h" -#include "hcb.h" - /* Binary search huffman table HCB_5 */ -extern hcb_bin_pair hcb5[] = { +static hcb_bin_pair hcb5[] = { { /* 0 */ 0, { 1, 2 } }, { /* 1 */ 1, { 0, 0 } }, /* 0 */ { /* 2 */ 0, { 1, 2 } }, diff --git a/src/libfaad/codebook/hcb_6.c b/src/libfaad/codebook/hcb_6.h index 4136ebdfe..503d76ba9 100644 --- a/src/libfaad/codebook/hcb_6.c +++ b/src/libfaad/codebook/hcb_6.h @@ -1,27 +1,30 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker -** +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. -** +** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. -** +** ** You should have received a copy of the GNU General Public License -** along with this program; if not, write to the Free Software +** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: hcb_6.c,v 1.2 2002/12/16 18:58:59 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: hcb_6.h,v 1.1 2003/12/30 02:00:12 miguelfreitas Exp $ **/ -#include "../common.h" -#include "hcb.h" - /* 2-step huffman table HCB_6 */ @@ -30,7 +33,7 @@ * * Used to find offset into 2nd step table and number of extra bits to get */ -extern hcb hcb6_1[] = { +static hcb hcb6_1[] = { /* 4 bit codewords */ { /* 00000 */ 0, 0 }, { /* */ 0, 0 }, @@ -80,7 +83,7 @@ extern hcb hcb6_1[] = { * * Gives size of codeword and actual data (x,y,v,w) */ -extern hcb_2_pair hcb6_2[] = { +static hcb_2_pair hcb6_2[] = { /* 4 bit codewords */ { 4, 0, 0 }, { 4, 1, 0 }, diff --git a/src/libfaad/codebook/hcb_7.c b/src/libfaad/codebook/hcb_7.h index b0ba2fbfa..ea881776b 100644 --- a/src/libfaad/codebook/hcb_7.c +++ b/src/libfaad/codebook/hcb_7.h @@ -1,31 +1,34 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker -** +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. -** +** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. -** +** ** You should have received a copy of the GNU General Public License -** along with this program; if not, write to the Free Software +** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: hcb_7.c,v 1.2 2002/12/16 18:58:59 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: hcb_7.h,v 1.1 2003/12/30 02:00:12 miguelfreitas Exp $ **/ -#include "../common.h" -#include "hcb.h" - /* Binary search huffman table HCB_7 */ -extern hcb_bin_pair hcb7[] = { +static hcb_bin_pair hcb7[] = { { /* 0 */ 0, { 1, 2 } }, { /* 1 */ 1, { 0, 0 } }, { /* 2 */ 0, { 1, 2 } }, diff --git a/src/libfaad/codebook/hcb_8.c b/src/libfaad/codebook/hcb_8.h index 5aed46949..fc4c398b9 100644 --- a/src/libfaad/codebook/hcb_8.c +++ b/src/libfaad/codebook/hcb_8.h @@ -1,27 +1,30 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker -** +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. -** +** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. -** +** ** You should have received a copy of the GNU General Public License -** along with this program; if not, write to the Free Software +** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: hcb_8.c,v 1.2 2002/12/16 18:59:00 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: hcb_8.h,v 1.1 2003/12/30 02:00:12 miguelfreitas Exp $ **/ -#include "../common.h" -#include "hcb.h" - /* 2-step huffman table HCB_8 */ @@ -30,7 +33,7 @@ * * Used to find offset into 2nd step table and number of extra bits to get */ -extern hcb hcb8_1[] = { +static hcb hcb8_1[] = { /* 3 bit codeword */ { /* 00000 */ 0, 0 }, { /* */ 0, 0 }, @@ -84,7 +87,7 @@ extern hcb hcb8_1[] = { * * Gives size of codeword and actual data (x,y,v,w) */ -extern hcb_2_pair hcb8_2[] = { +static hcb_2_pair hcb8_2[] = { /* 3 bit codeword */ { 3, 1, 1 }, diff --git a/src/libfaad/codebook/hcb_9.c b/src/libfaad/codebook/hcb_9.h index 8a7638871..3121bcb53 100644 --- a/src/libfaad/codebook/hcb_9.c +++ b/src/libfaad/codebook/hcb_9.h @@ -1,31 +1,34 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker -** +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. -** +** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. -** +** ** You should have received a copy of the GNU General Public License -** along with this program; if not, write to the Free Software +** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: hcb_9.c,v 1.2 2002/12/16 18:59:00 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: hcb_9.h,v 1.1 2003/12/30 02:00:12 miguelfreitas Exp $ **/ -#include "../common.h" -#include "hcb.h" - /* Binary search huffman table HCB_9 */ -extern hcb_bin_pair hcb9[] = { +static hcb_bin_pair hcb9[] = { { /* 0 */ 0, { 1, 2 } }, { /* 1 */ 1, { 0, 0 } }, { /* 2 */ 0, { 1, 2 } }, diff --git a/src/libfaad/codebook/hcb_sf.c b/src/libfaad/codebook/hcb_sf.h index bdb9732f4..f7be8fd8e 100644 --- a/src/libfaad/codebook/hcb_sf.c +++ b/src/libfaad/codebook/hcb_sf.h @@ -1,31 +1,34 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker -** +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. -** +** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. -** +** ** You should have received a copy of the GNU General Public License -** along with this program; if not, write to the Free Software +** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: hcb_sf.c,v 1.2 2002/12/16 18:59:01 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: hcb_sf.h,v 1.1 2003/12/30 02:00:12 miguelfreitas Exp $ **/ -#include "../common.h" -#include "hcb.h" - /* Binary search huffman table HCB_SF */ -extern uint8_t hcb_sf[][2] = { +static uint8_t hcb_sf[][2] = { { /* 0 */ 1, 2 }, { /* 1 */ 60, 0 }, { /* 2 */ 1, 2 }, diff --git a/src/libfaad/common.c b/src/libfaad/common.c index 028886ba5..3df232482 100644 --- a/src/libfaad/common.c +++ b/src/libfaad/common.c @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: common.c,v 1.3 2003/08/25 21:51:40 f1rmb Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: common.c,v 1.4 2003/12/30 02:00:10 miguelfreitas Exp $ **/ /* just some common functions that could be used anywhere */ @@ -24,11 +30,73 @@ #include "common.h" #include "structs.h" +#include <stdlib.h> #include "syntax.h" -#include "dither.h" + +#ifdef USE_SSE +__declspec(naked) static int32_t __fastcall test_cpuid() +{ + __asm + { + pushf + pop eax + mov ecx,eax + xor eax,(1<<21) + push eax + popf + pushf + pop eax + push ecx + popf + cmp eax,ecx + mov eax,0 + setne al + ret + } +} + +__declspec(naked) static void __fastcall run_cpuid(int32_t param, int32_t out[4]) +{ + __asm + { + pushad + push edx + mov eax,ecx + cpuid + pop edi + mov [edi+0],eax + mov [edi+4],ebx + mov [edi+8],ecx + mov [edi+12],edx + popad + ret + } +} + +uint8_t cpu_has_sse() +{ + int32_t features[4]; + + if (test_cpuid()) + { + run_cpuid(1, features); + } + + /* check for SSE */ + if (features[3] & 0x02000000) + return 1; + + return 0; +} +#else +uint8_t cpu_has_sse() +{ + return 0; +} +#endif /* Returns the sample rate index based on the samplerate */ -uint8_t get_sr_index(uint32_t samplerate) +uint8_t get_sr_index(const uint32_t samplerate) { if (92017 <= samplerate) return 0; if (75132 <= samplerate) return 1; @@ -41,12 +109,78 @@ uint8_t get_sr_index(uint32_t samplerate) if (13856 <= samplerate) return 8; if (11502 <= samplerate) return 9; if (9391 <= samplerate) return 10; + if (16428320 <= samplerate) return 11; return 11; } +/* Returns the sample rate based on the sample rate index */ +uint32_t get_sample_rate(const uint8_t sr_index) +{ + static const uint32_t sample_rates[] = + { + 96000, 88200, 64000, 48000, 44100, 32000, + 24000, 22050, 16000, 12000, 11025, 8000 + }; + + if (sr_index < 12) + return sample_rates[sr_index]; + + return 0; +} + +uint8_t max_pred_sfb(const uint8_t sr_index) +{ + static const uint8_t pred_sfb_max[] = + { + 33, 33, 38, 40, 40, 40, 41, 41, 37, 37, 37, 34 + }; + + + if (sr_index < 12) + return pred_sfb_max[sr_index]; + + return 0; +} + +uint8_t max_tns_sfb(const uint8_t sr_index, const uint8_t object_type, + const uint8_t is_short) +{ + /* entry for each sampling rate + * 1 Main/LC long window + * 2 Main/LC short window + * 3 SSR long window + * 4 SSR short window + */ + static const uint8_t tns_sbf_max[][4] = + { + {31, 9, 28, 7}, /* 96000 */ + {31, 9, 28, 7}, /* 88200 */ + {34, 10, 27, 7}, /* 64000 */ + {40, 14, 26, 6}, /* 48000 */ + {42, 14, 26, 6}, /* 44100 */ + {51, 14, 26, 6}, /* 32000 */ + {46, 14, 29, 7}, /* 24000 */ + {46, 14, 29, 7}, /* 22050 */ + {42, 14, 23, 8}, /* 16000 */ + {42, 14, 23, 8}, /* 12000 */ + {42, 14, 23, 8}, /* 11025 */ + {39, 14, 19, 7}, /* 8000 */ + {39, 14, 19, 7}, /* 7350 */ + {0,0,0,0}, + {0,0,0,0}, + {0,0,0,0} + }; + uint8_t i = 0; + + if (is_short) i++; + if (object_type == SSR) i += 2; + + return tns_sbf_max[sr_index][i]; +} + /* Returns 0 if an object type is decodable, otherwise returns -1 */ -int8_t can_decode_ot(uint8_t object_type) +int8_t can_decode_ot(const uint8_t object_type) { switch (object_type) { @@ -96,6 +230,26 @@ int8_t can_decode_ot(uint8_t object_type) return -1; } +/* common malloc function */ +void *faad_malloc(int32_t size) +{ +#ifdef _WIN32 + return _aligned_malloc(size, 16); +#else + return malloc(size); +#endif +} + +/* common free function */ +void faad_free(void *b) +{ +#ifdef _WIN32 + _aligned_free(b); +#else + free(b); +#endif +} + static const uint8_t Parity [256] = { // parity 0,1,1,0,1,0,0,1,1,0,0,1,0,1,1,0,1,0,0,1,0,1,1,0,0,1,1,0,1,0,0,1, 1,0,0,1,0,1,1,0,0,1,1,0,1,0,0,1,0,1,1,0,1,0,0,1,1,0,0,1,0,1,1,0, @@ -139,6 +293,7 @@ static uint32_t __r2 = 1; */ uint32_t random_int(void) { + static const uint32_t rnd_seed = 16428320; uint32_t t1, t2, t3, t4; t3 = t1 = __r1; t4 = t2 = __r2; // Parity calculation is done via table lookup, this is also available @@ -148,14 +303,3 @@ uint32_t random_int(void) return (__r1 = (t3 >> 1) | t1 ) ^ (__r2 = (t4 + t4) | t2 ); } - -#if 0 - -#define LOG2 0.30102999566398 - -uint32_t int_log2(uint32_t val) -{ - return (uint32_t)(log((real_t)val)/LOG2 + 0.5); -} -#endif - diff --git a/src/libfaad/common.h b/src/libfaad/common.h index 143641529..aa40ebe0a 100644 --- a/src/libfaad/common.h +++ b/src/libfaad/common.h @@ -1,22 +1,28 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker -** +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. -** +** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. -** +** ** You should have received a copy of the GNU General Public License -** along with this program; if not, write to the Free Software +** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: common.h,v 1.8 2003/05/26 23:23:26 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: common.h,v 1.9 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #ifndef __COMMON_H__ @@ -26,12 +32,11 @@ extern "C" { #endif -#if __STDC_VERSION__+0 >= 199901L -#define INLINE inline -#elif defined(__GNUC__) #define INLINE __inline +#ifdef _WIN32 +#define ALIGN __declspec(align(16)) #else -#define INLINE +#define ALIGN #endif #ifndef max @@ -41,7 +46,6 @@ extern "C" { #define min(a, b) (((a) < (b)) ? (a) : (b)) #endif - /* COMPILE TIME DEFINITIONS */ /* use double precision */ @@ -49,6 +53,11 @@ extern "C" { /* use fixed point reals */ //#define FIXED_POINT +#ifdef _WIN32_WCE +#define FIXED_POINT +#endif + + #define ERROR_RESILIENCE @@ -60,6 +69,10 @@ extern "C" { #define LTP_DEC /* Allow decoding of LD profile AAC */ #define LD_DEC +/* Allow decoding of scalable profiles */ +//#define SCALABLE_DEC +/* Allow decoding of Digital Radio Mondiale (DRM) */ +//#define DRM /* LD can't do without LTP */ #ifdef LD_DEC @@ -71,14 +84,65 @@ extern "C" { #endif #endif +#define ALLOW_SMALL_FRAMELENGTH -/* END COMPILE TIME DEFINITIONS */ +// Define LC_ONLY_DECODER if you want a pure AAC LC decoder (independant of SBR_DEC) +//#define LC_ONLY_DECODER +#ifdef LC_ONLY_DECODER + #undef LTP_DEC + #undef MAIN_DEC + #undef SSR_DEC + #undef DRM + #undef ALLOW_SMALL_FRAMELENGTH + #undef ERROR_RESILIENCE +#endif + +#define SBR_DEC +//#define SBR_LOW_POWER + +/* FIXED POINT: No MAIN decoding, forced SBR Low Power decoder */ +#ifdef FIXED_POINT +# ifdef MAIN_DEC +# undef MAIN_DEC +# endif +# ifndef SBR_LOW_POWER +# define SBR_LOW_POWER +# endif +#endif // FIXED_POINT + +#ifdef DRM +# ifndef SCALABLE_DEC +# define SCALABLE_DEC +# endif +#endif + +#if ((defined(_WIN32) && !defined(_WIN32_WCE)) /* || ((__GNUC__ >= 3) && defined(__i386__)) */ ) #ifndef FIXED_POINT -#define POW_TABLE_SIZE 200 +/* includes <xmmintrin.h> to enable SSE intrinsics */ +#define USE_SSE +#endif +#endif + +#ifdef FIXED_POINT +#define SBR_DIV(A, B) (((int64_t)A << REAL_BITS)/B) +#else +#define SBR_DIV(A, B) ((A)/(B)) +#endif + +#ifndef SBR_LOW_POWER +#define qmf_t complex_t +#define QMF_RE(A) RE(A) +#define QMF_IM(A) IM(A) +#else +#define qmf_t real_t +#define QMF_RE(A) (A) +#define QMF_IM(A) #endif +/* END COMPILE TIME DEFINITIONS */ + #if defined(_WIN32) @@ -96,7 +160,7 @@ typedef float float32_t; #else #ifdef HAVE_CONFIG_H -# include "config.h" +# include "../config.h" #endif #include <stdio.h> @@ -129,9 +193,7 @@ typedef float float32_t; # if HAVE_STDINT_H # include <stdint.h> # else -# if !defined(__int8_t_defined) /* we need these... */ -#define __int8_t_defined typedef unsigned long long uint64_t; typedef unsigned long uint32_t; typedef unsigned short uint16_t; @@ -140,7 +202,6 @@ typedef long long int64_t; typedef long int32_t; typedef short int16_t; typedef char int8_t; -# endif # endif #endif #if HAVE_UNISTD_H @@ -180,12 +241,6 @@ char *strchr(), *strrchr(); #if defined(FIXED_POINT) - #ifdef HAS_MATHF_H - #include <mathf.h> - #else - #include <math.h> - #endif - #include "fixed.h" #elif defined(USE_DOUBLE_PRECISION) @@ -194,23 +249,74 @@ char *strchr(), *strrchr(); #include <math.h> - #define MUL(A,B) ((A)*(B)) - #define MUL_C_C(A,B) ((A)*(B)) - #define MUL_R_C(A,B) ((A)*(B)) + #define MUL_R(A,B) ((A)*(B)) + #define MUL_C(A,B) ((A)*(B)) + #define MUL_F(A,B) ((A)*(B)) + + /* Complex multiplication */ + static INLINE void ComplexMult(real_t *y1, real_t *y2, + real_t x1, real_t x2, real_t c1, real_t c2) + { + *y1 = MUL_F(x1, c1) + MUL_F(x2, c2); + *y2 = MUL_F(x2, c1) - MUL_F(x1, c2); + } - #define REAL_CONST(A) ((real_t)A) - #define COEF_CONST(A) ((real_t)A) + #define REAL_CONST(A) ((real_t)(A)) + #define COEF_CONST(A) ((real_t)(A)) + #define FRAC_CONST(A) ((real_t)(A)) /* pure fractional part */ #else /* Normal floating point operation */ typedef float real_t; - #define MUL(A,B) ((A)*(B)) - #define MUL_C_C(A,B) ((A)*(B)) - #define MUL_R_C(A,B) ((A)*(B)) - - #define REAL_CONST(A) ((real_t)A) - #define COEF_CONST(A) ((real_t)A) +#ifdef USE_SSE +# include <xmmintrin.h> +#endif + + #define MUL_R(A,B) ((A)*(B)) + #define MUL_C(A,B) ((A)*(B)) + #define MUL_F(A,B) ((A)*(B)) + + #define REAL_CONST(A) ((real_t)(A)) + #define COEF_CONST(A) ((real_t)(A)) + #define FRAC_CONST(A) ((real_t)(A)) /* pure fractional part */ + + /* Complex multiplication */ + static INLINE void ComplexMult(real_t *y1, real_t *y2, + real_t x1, real_t x2, real_t c1, real_t c2) + { + *y1 = MUL_F(x1, c1) + MUL_F(x2, c2); + *y2 = MUL_F(x2, c1) - MUL_F(x1, c2); + } + +#ifndef HAVE_LRINTF + #ifdef _WIN32 + #define HAS_LRINTF + static INLINE int lrintf(float f) + { + int i; + __asm + { + fld f + fistp i + } + return i; + } + #elif (defined(__i386__) && defined(__GNUC__)) + #define HAS_LRINTF + // from http://www.stereopsis.com/FPU.html + static INLINE int lrintf(float f) + { + int i; + __asm__ __volatile__ ( + "flds %1 \n\t" + "fistpl %0 \n\t" + : "=m" (i) + : "m" (f)); + return i; + } + #endif +#endif #ifdef __ICL /* only Intel C compiler has fmath ??? */ @@ -225,6 +331,14 @@ char *strchr(), *strrchr(); #else +#ifdef HAVE_LRINTF +# define HAS_LRINTF +# define _ISOC9X_SOURCE 1 +# define _ISOC99_SOURCE 1 +# define __USE_ISOC9X 1 +# define __USE_ISOC99 1 +#endif + #include <math.h> #ifdef HAVE_SINF @@ -254,19 +368,42 @@ char *strchr(), *strrchr(); #endif +#ifndef HAS_LRINTF +/* standard cast */ +#define lrintf(f) ((int32_t)(f)) +#endif + typedef real_t complex_t[2]; #define RE(A) A[0] #define IM(A) A[1] /* common functions */ -uint32_t int_log2(uint32_t val); - -uint8_t get_sr_index(uint32_t samplerate); -int8_t can_decode_ot(uint8_t object_type); +uint8_t cpu_has_sse(); +uint32_t random_int(void); +uint8_t get_sr_index(const uint32_t samplerate); +uint8_t max_pred_sfb(const uint8_t sr_index); +uint8_t max_tns_sfb(const uint8_t sr_index, const uint8_t object_type, + const uint8_t is_short); +uint32_t get_sample_rate(const uint8_t sr_index); +int8_t can_decode_ot(const uint8_t object_type); + +void *faad_malloc(int32_t size); +void faad_free(void *b); + +//#define PROFILE +#ifdef PROFILE +static int64_t faad_get_ts() +{ + __asm + { + rdtsc + } +} +#endif #ifndef M_PI -#define M_PI 3.14159265358979323846f +#define M_PI 3.14159265358979323846 #endif #ifndef M_PI_2 /* PI/2 */ #define M_PI_2 1.57079632679489661923 diff --git a/src/libfaad/data.c b/src/libfaad/data.c deleted file mode 100644 index 07ae4957f..000000000 --- a/src/libfaad/data.c +++ /dev/null @@ -1,268 +0,0 @@ -/* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker -** -** This program is free software; you can redistribute it and/or modify -** it under the terms of the GNU General Public License as published by -** the Free Software Foundation; either version 2 of the License, or -** (at your option) any later version. -** -** This program is distributed in the hope that it will be useful, -** but WITHOUT ANY WARRANTY; without even the implied warranty of -** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -** GNU General Public License for more details. -** -** You should have received a copy of the GNU General Public License -** along with this program; if not, write to the Free Software -** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. -** -** $Id: data.c,v 1.3 2003/04/12 14:58:47 miguelfreitas Exp $ -**/ - -#include "common.h" -#include "data.h" - -#ifdef LD_DEC -extern uint8_t num_swb_512_window[] = -{ - 0, 0, 0, 36, 36, 37, 31, 31, 0, 0, 0, 0 -}; -extern uint8_t num_swb_480_window[] = -{ - 0, 0, 0, 35, 35, 37, 30, 30, 0, 0, 0, 0 -}; -#endif - -extern uint8_t num_swb_960_window[] = -{ - 40, 40, 45, 49, 49, 49, 46, 46, 42, 42, 42, 40 -}; - -extern uint8_t num_swb_1024_window[] = -{ - 41, 41, 47, 49, 49, 51, 47, 47, 43, 43, 43, 40 -}; - -extern uint8_t num_swb_128_window[] = -{ - 12, 12, 12, 14, 14, 14, 15, 15, 15, 15, 15, 15 -}; - -static uint16_t swb_offset_1024_96[] = -{ - 0, 4, 8, 12, 16, 20, 24, 28, 32, 36, 40, 44, 48, 52, 56, - 64, 72, 80, 88, 96, 108, 120, 132, 144, 156, 172, 188, 212, 240, - 276, 320, 384, 448, 512, 576, 640, 704, 768, 832, 896, 960, 1024 -}; - -static uint16_t swb_offset_128_96[] = -{ - 0, 4, 8, 12, 16, 20, 24, 32, 40, 48, 64, 92, 128 -}; - -static uint16_t swb_offset_1024_64[] = -{ - 0, 4, 8, 12, 16, 20, 24, 28, 32, 36, 40, 44, 48, 52, 56, - 64, 72, 80, 88, 100, 112, 124, 140, 156, 172, 192, 216, 240, 268, - 304, 344, 384, 424, 464, 504, 544, 584, 624, 664, 704, 744, 784, 824, - 864, 904, 944, 984, 1024 -}; - -static uint16_t swb_offset_128_64[] = -{ - 0, 4, 8, 12, 16, 20, 24, 32, 40, 48, 64, 92, 128 -}; - - -static uint16_t swb_offset_1024_48[] = -{ - 0, 4, 8, 12, 16, 20, 24, 28, 32, 36, 40, 48, 56, 64, 72, - 80, 88, 96, 108, 120, 132, 144, 160, 176, 196, 216, 240, 264, 292, - 320, 352, 384, 416, 448, 480, 512, 544, 576, 608, 640, 672, 704, 736, - 768, 800, 832, 864, 896, 928, 1024 -}; - -#ifdef LD_DEC -static uint16_t swb_offset_512_48[] = -{ - 0, 4, 8, 12, 16, 20, 24, 28, 32, 36, 40, 44, 48, 52, 56, 60, 68, 76, 84, - 92, 100, 112, 124, 136, 148, 164, 184, 208, 236, 268, 300, 332, 364, 396, - 428, 460, 512 -}; - -static uint16_t swb_offset_480_48[] = -{ - 0, 4, 8, 12, 16, 20, 24, 28, 32, 36, 40, 44, 48, 52, 56, 64, 72 ,80 ,88, - 96, 108, 120, 132, 144, 156, 172, 188, 212, 240, 272, 304, 336, 368, 400, - 432, 480 -}; -#endif - -static uint16_t swb_offset_128_48[] = -{ - 0, 4, 8, 12, 16, 20, 28, 36, 44, 56, 68, 80, 96, 112, 128 -}; - -static uint16_t swb_offset_1024_32[] = -{ - 0, 4, 8, 12, 16, 20, 24, 28, 32, 36, 40, 48, 56, 64, 72, - 80, 88, 96, 108, 120, 132, 144, 160, 176, 196, 216, 240, 264, 292, - 320, 352, 384, 416, 448, 480, 512, 544, 576, 608, 640, 672, 704, 736, - 768, 800, 832, 864, 896, 928, 960, 992, 1024 -}; - -#ifdef LD_DEC -static uint16_t swb_offset_512_32[] = -{ - 0, 4, 8, 12, 16, 20, 24, 28, 32, 36, 40, 44, 48, 52, 56, 64, 72, 80, - 88, 96, 108, 120, 132, 144, 160, 176, 192, 212, 236, 260, 288, 320, 352, - 384, 416, 448, 480, 512 -}; - -static uint16_t swb_offset_480_32[] = -{ - 0, 4, 8, 12, 16, 20, 24, 28, 32, 36, 40, 44, 48, 52, 56, 60, 64, 72, 80, - 88, 96, 104, 112, 124, 136, 148, 164, 180, 200, 224, 256, 288, 320, 352, - 384, 416, 448, 480 -}; -#endif - -static uint16_t swb_offset_1024_24[] = -{ - 0, 4, 8, 12, 16, 20, 24, 28, 32, 36, 40, 44, 52, 60, 68, - 76, 84, 92, 100, 108, 116, 124, 136, 148, 160, 172, 188, 204, 220, - 240, 260, 284, 308, 336, 364, 396, 432, 468, 508, 552, 600, 652, 704, - 768, 832, 896, 960, 1024 -}; - -#ifdef LD_DEC -static uint16_t swb_offset_512_24[] = -{ - 0, 4, 8, 12, 16, 20, 24, 28, 32, 36, 40, 44, 52, 60, 68, - 80, 92, 104, 120, 140, 164, 192, 224, 256, 288, 320, 352, 384, 416, - 448, 480, 512 -}; - -static uint16_t swb_offset_480_24[] = -{ - 0, 4, 8, 12, 16, 20, 24, 28, 32, 36, 40, 44, 52, 60, 68, 80, 92, 104, 120, - 140, 164, 192, 224, 256, 288, 320, 352, 384, 416, 448, 480 -}; -#endif - -static uint16_t swb_offset_128_24[] = -{ - 0, 4, 8, 12, 16, 20, 24, 28, 36, 44, 52, 64, 76, 92, 108, 128 -}; - -static uint16_t swb_offset_1024_16[] = -{ - 0, 8, 16, 24, 32, 40, 48, 56, 64, 72, 80, 88, 100, 112, 124, - 136, 148, 160, 172, 184, 196, 212, 228, 244, 260, 280, 300, 320, 344, - 368, 396, 424, 456, 492, 532, 572, 616, 664, 716, 772, 832, 896, 960, 1024 -}; - -static uint16_t swb_offset_128_16[] = -{ - 0, 4, 8, 12, 16, 20, 24, 28, 32, 40, 48, 60, 72, 88, 108, 128 -}; - -static uint16_t swb_offset_1024_8[] = -{ - 0, 12, 24, 36, 48, 60, 72, 84, 96, 108, 120, 132, 144, 156, 172, - 188, 204, 220, 236, 252, 268, 288, 308, 328, 348, 372, 396, 420, 448, - 476, 508, 544, 580, 620, 664, 712, 764, 820, 880, 944, 1024 -}; - -static uint16_t swb_offset_128_8[] = -{ - 0, 4, 8, 12, 16, 20, 24, 28, 36, 44, 52, 60, 72, 88, 108, 128 -}; - -extern uint16_t *swb_offset_1024_window[] = -{ - swb_offset_1024_96, /* 96000 */ - swb_offset_1024_96, /* 88200 */ - swb_offset_1024_64, /* 64000 */ - swb_offset_1024_48, /* 48000 */ - swb_offset_1024_48, /* 44100 */ - swb_offset_1024_32, /* 32000 */ - swb_offset_1024_24, /* 24000 */ - swb_offset_1024_24, /* 22050 */ - swb_offset_1024_16, /* 16000 */ - swb_offset_1024_16, /* 12000 */ - swb_offset_1024_16, /* 11025 */ - swb_offset_1024_8 /* 8000 */ -}; - -#ifdef LD_DEC -extern uint16_t *swb_offset_512_window[] = -{ - 0, /* 96000 */ - 0, /* 88200 */ - 0, /* 64000 */ - swb_offset_512_48, /* 48000 */ - swb_offset_512_48, /* 44100 */ - swb_offset_512_32, /* 32000 */ - swb_offset_512_24, /* 24000 */ - swb_offset_512_24, /* 22050 */ - 0, /* 16000 */ - 0, /* 12000 */ - 0, /* 11025 */ - 0 /* 8000 */ -}; - -extern uint16_t *swb_offset_480_window[] = -{ - 0, /* 96000 */ - 0, /* 88200 */ - 0, /* 64000 */ - swb_offset_480_48, /* 48000 */ - swb_offset_480_48, /* 44100 */ - swb_offset_480_32, /* 32000 */ - swb_offset_480_24, /* 24000 */ - swb_offset_480_24, /* 22050 */ - 0, /* 16000 */ - 0, /* 12000 */ - 0, /* 11025 */ - 0 /* 8000 */ -}; -#endif - -extern uint16_t *swb_offset_128_window[] = -{ - swb_offset_128_96, /* 96000 */ - swb_offset_128_96, /* 88200 */ - swb_offset_128_64, /* 64000 */ - swb_offset_128_48, /* 48000 */ - swb_offset_128_48, /* 44100 */ - swb_offset_128_48, /* 32000 */ - swb_offset_128_24, /* 24000 */ - swb_offset_128_24, /* 22050 */ - swb_offset_128_16, /* 16000 */ - swb_offset_128_16, /* 12000 */ - swb_offset_128_16, /* 11025 */ - swb_offset_128_8 /* 8000 */ -}; - -extern uint8_t pred_sfb_max[] = -{ - 33, /* 96000 */ - 33, /* 88200 */ - 38, /* 64000 */ - 40, /* 48000 */ - 40, /* 44100 */ - 40, /* 32000 */ - 41, /* 24000 */ - 41, /* 22050 */ - 37, /* 16000 */ - 37, /* 12000 */ - 37, /* 11025 */ - 34 /* 8000 */ -}; - -extern uint32_t sample_rates[] = -{ - 96000, 88200, 64000, 48000, 44100, 32000, 24000, 22050, 16000, - 12000, 11025, 8000 -}; diff --git a/src/libfaad/decoder.c b/src/libfaad/decoder.c index dbe691f77..8c824ff3d 100644 --- a/src/libfaad/decoder.c +++ b/src/libfaad/decoder.c @@ -1,22 +1,28 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker -** +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. -** +** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. -** +** ** You should have received a copy of the GNU General Public License -** along with this program; if not, write to the Free Software +** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: decoder.c,v 1.5 2003/08/25 21:51:41 f1rmb Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: decoder.c,v 1.6 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #include "common.h" @@ -28,21 +34,13 @@ #include "decoder.h" #include "mp4.h" #include "syntax.h" -#include "specrec.h" -#include "data.h" -#include "tns.h" -#include "pns.h" -#include "is.h" -#include "ms.h" -#include "ic_predict.h" -#include "lt_predict.h" -#include "drc.h" #include "error.h" #include "output.h" -#include "dither.h" +#ifdef SBR_DEC +#include "sbr_dec.h" +#endif #ifdef SSR_DEC #include "ssr.h" -#include "ssr_fb.h" #endif #ifdef ANALYSIS @@ -51,10 +49,12 @@ uint16_t dbg_count; int8_t* FAADAPI faacDecGetErrorMessage(uint8_t errcode) { + if (errcode >= NUM_ERROR_MESSAGES) + return NULL; return err_msg[errcode]; } -uint32_t FAADAPI faacDecGetCapabilities(void) +uint32_t FAADAPI faacDecGetCapabilities() { uint32_t cap = 0; @@ -80,12 +80,12 @@ uint32_t FAADAPI faacDecGetCapabilities(void) return cap; } -faacDecHandle FAADAPI faacDecOpen(void) +faacDecHandle FAADAPI faacDecOpen() { uint8_t i; faacDecHandle hDecoder = NULL; - if ((hDecoder = (faacDecHandle)malloc(sizeof(faacDecStruct))) == NULL) + if ((hDecoder = (faacDecHandle)faad_malloc(sizeof(faacDecStruct))) == NULL) return NULL; memset(hDecoder, 0, sizeof(faacDecStruct)); @@ -93,6 +93,7 @@ faacDecHandle FAADAPI faacDecOpen(void) hDecoder->config.outputFormat = FAAD_FMT_16BIT; hDecoder->config.defObjectType = MAIN; hDecoder->config.defSampleRate = 44100; /* Default: 44.1kHz */ + hDecoder->config.downMatrix = 0; hDecoder->adts_header_present = 0; hDecoder->adif_header_present = 0; #ifdef ERROR_RESILIENCE @@ -109,6 +110,9 @@ faacDecHandle FAADAPI faacDecOpen(void) { hDecoder->window_shape_prev[i] = 0; hDecoder->time_out[i] = NULL; +#ifdef SBR_DEC + hDecoder->time_out2[i] = NULL; +#endif #ifdef SSR_DEC hDecoder->ssr_overlap[i] = NULL; hDecoder->prev_fmd[i] = NULL; @@ -122,11 +126,22 @@ faacDecHandle FAADAPI faacDecOpen(void) #endif } +#ifdef SBR_DEC + for (i = 0; i < 32; i++) + { + hDecoder->sbr[i] = NULL; + } +#endif + hDecoder->drc = drc_init(REAL_CONST(1.0), REAL_CONST(1.0)); -#if POW_TABLE_SIZE - hDecoder->pow2_table = (real_t*)malloc(POW_TABLE_SIZE*sizeof(real_t)); - build_tables(hDecoder->pow2_table); +#ifdef USE_SSE + if (cpu_has_sse()) + { + hDecoder->apply_sf_func = apply_scalefactors_sse; + } else { + hDecoder->apply_sf_func = apply_scalefactors; + } #endif return hDecoder; @@ -134,20 +149,44 @@ faacDecHandle FAADAPI faacDecOpen(void) faacDecConfigurationPtr FAADAPI faacDecGetCurrentConfiguration(faacDecHandle hDecoder) { - faacDecConfigurationPtr config = &(hDecoder->config); + if (hDecoder) + { + faacDecConfigurationPtr config = &(hDecoder->config); + + return config; + } - return config; + return NULL; } uint8_t FAADAPI faacDecSetConfiguration(faacDecHandle hDecoder, faacDecConfigurationPtr config) { - hDecoder->config.defObjectType = config->defObjectType; - hDecoder->config.defSampleRate = config->defSampleRate; - hDecoder->config.outputFormat = config->outputFormat; + if (hDecoder && config) + { + /* check if we can decode this object type */ + if (can_decode_ot(config->defObjectType) < 0) + return 0; + hDecoder->config.defObjectType = config->defObjectType; + + /* samplerate: anything but 0 should be possible */ + if (config->defSampleRate == 0) + return 0; + hDecoder->config.defSampleRate = config->defSampleRate; + + /* check output format */ + if ((config->outputFormat < 1) || (config->outputFormat > 9)) + return 0; + hDecoder->config.outputFormat = config->outputFormat; + + if (config->downMatrix > 1) + hDecoder->config.downMatrix = config->downMatrix; + + /* OK */ + return 1; + } - /* OK */ - return 1; + return 0; } int32_t FAADAPI faacDecInit(faacDecHandle hDecoder, uint8_t *buffer, @@ -159,9 +198,12 @@ int32_t FAADAPI faacDecInit(faacDecHandle hDecoder, uint8_t *buffer, adif_header adif; adts_header adts; + if ((hDecoder == NULL) || (samplerate == NULL) || (channels == NULL)) + return -1; + hDecoder->sf_index = get_sr_index(hDecoder->config.defSampleRate); hDecoder->object_type = hDecoder->config.defObjectType; - *samplerate = sample_rates[hDecoder->sf_index]; + *samplerate = get_sample_rate(hDecoder->sf_index); *channels = 1; if (buffer != NULL) @@ -177,11 +219,14 @@ int32_t FAADAPI faacDecInit(faacDecHandle hDecoder, uint8_t *buffer, get_adif_header(&adif, &ld); faad_byte_align(&ld); - hDecoder->sf_index = adif.pce.sf_index; - hDecoder->object_type = adif.pce.object_type; + hDecoder->sf_index = adif.pce[0].sf_index; + hDecoder->object_type = adif.pce[0].object_type + 1; + + *samplerate = get_sample_rate(hDecoder->sf_index); + *channels = adif.pce[0].channels; - *samplerate = sample_rates[hDecoder->sf_index]; - *channels = adif.pce.channels; + memcpy(&(hDecoder->pce), &(adif.pce[0]), sizeof(program_config)); + hDecoder->pce_set = 1; bits = bit2byte(faad_get_processed_bits(&ld)); @@ -189,12 +234,13 @@ int32_t FAADAPI faacDecInit(faacDecHandle hDecoder, uint8_t *buffer, } else if (faad_showbits(&ld, 12) == 0xfff) { hDecoder->adts_header_present = 1; + adts.old_format = hDecoder->config.useOldADTSFormat; adts_frame(&adts, &ld); hDecoder->sf_index = adts.sf_index; - hDecoder->object_type = adts.profile; + hDecoder->object_type = adts.profile + 1; - *samplerate = sample_rates[hDecoder->sf_index]; + *samplerate = get_sample_rate(hDecoder->sf_index); *channels = (adts.channel_configuration > 6) ? 2 : adts.channel_configuration; } @@ -208,6 +254,15 @@ int32_t FAADAPI faacDecInit(faacDecHandle hDecoder, uint8_t *buffer, } hDecoder->channelConfiguration = *channels; +#ifdef SBR_DEC + /* implicit signalling */ + if (*samplerate <= 24000) + { + *samplerate *= 2; + hDecoder->forceUpSampling = 1; + } +#endif + /* must be done before frameLength is divided by 2 for LD */ #ifdef SSR_DEC if (hDecoder->object_type == SSR) @@ -224,11 +279,6 @@ int32_t FAADAPI faacDecInit(faacDecHandle hDecoder, uint8_t *buffer, if (can_decode_ot(hDecoder->object_type) < 0) return -1; -#ifndef FIXED_POINT - if (hDecoder->config.outputFormat >= FAAD_FMT_DITHER_LOWEST) - Init_Dither(16, hDecoder->config.outputFormat - FAAD_FMT_DITHER_LOWEST); -#endif - return bits; } @@ -240,9 +290,6 @@ int8_t FAADAPI faacDecInit2(faacDecHandle hDecoder, uint8_t *pBuffer, int8_t rc; mp4AudioSpecificConfig mp4ASC; - hDecoder->adif_header_present = 0; - hDecoder->adts_header_present = 0; - if((hDecoder == NULL) || (pBuffer == NULL) || (SizeOfDecoderSpecificInfo < 2) @@ -252,27 +299,51 @@ int8_t FAADAPI faacDecInit2(faacDecHandle hDecoder, uint8_t *pBuffer, return -1; } + hDecoder->adif_header_present = 0; + hDecoder->adts_header_present = 0; + /* decode the audio specific config */ - rc = AudioSpecificConfig(pBuffer, SizeOfDecoderSpecificInfo, &mp4ASC); + rc = AudioSpecificConfig2(pBuffer, SizeOfDecoderSpecificInfo, &mp4ASC, + &(hDecoder->pce)); /* copy the relevant info to the decoder handle */ *samplerate = mp4ASC.samplingFrequency; - *channels = mp4ASC.channelsConfiguration; + if (mp4ASC.channelsConfiguration) + { + *channels = mp4ASC.channelsConfiguration; + } else { + *channels = hDecoder->pce.channels; + hDecoder->pce_set = 1; + } hDecoder->sf_index = mp4ASC.samplingFrequencyIndex; hDecoder->object_type = mp4ASC.objectTypeIndex; +#ifdef ERROR_RESILIENCE hDecoder->aacSectionDataResilienceFlag = mp4ASC.aacSectionDataResilienceFlag; hDecoder->aacScalefactorDataResilienceFlag = mp4ASC.aacScalefactorDataResilienceFlag; hDecoder->aacSpectralDataResilienceFlag = mp4ASC.aacSpectralDataResilienceFlag; +#endif +#ifdef SBR_DEC + hDecoder->sbr_present_flag = mp4ASC.sbr_present_flag; + hDecoder->forceUpSampling = mp4ASC.forceUpSampling; + + /* AAC core decoder samplerate is 2 times as low */ + if (hDecoder->sbr_present_flag == 1 || hDecoder->forceUpSampling == 1) + { + hDecoder->sf_index = get_sr_index(mp4ASC.samplingFrequency / 2); + } +#endif - if (hDecoder->object_type < 5) - hDecoder->object_type--; /* For AAC differs from MPEG-4 */ if (rc != 0) { return rc; } - hDecoder->channelConfiguration = *channels; + hDecoder->channelConfiguration = mp4ASC.channelsConfiguration; if (mp4ASC.frameLengthFlag) +#ifdef ALLOW_SMALL_FRAMELENGTH hDecoder->frameLength = 960; +#else + return -1; +#endif /* must be done before frameLength is divided by 2 for LD */ #ifdef SSR_DEC @@ -287,39 +358,86 @@ int8_t FAADAPI faacDecInit2(faacDecHandle hDecoder, uint8_t *pBuffer, hDecoder->frameLength >>= 1; #endif -#ifndef FIXED_POINT - if (hDecoder->config.outputFormat >= FAAD_FMT_DITHER_LOWEST) - Init_Dither(16, hDecoder->config.outputFormat - FAAD_FMT_DITHER_LOWEST); -#endif - return 0; } +#ifdef DRM int8_t FAADAPI faacDecInitDRM(faacDecHandle hDecoder, uint32_t samplerate, uint8_t channels) { + uint8_t i; + /* Special object type defined for DRM */ hDecoder->config.defObjectType = DRM_ER_LC; hDecoder->config.defSampleRate = samplerate; +#ifdef ERROR_RESILIENCE // This shoudl always be defined for DRM hDecoder->aacSectionDataResilienceFlag = 1; /* VCB11 */ hDecoder->aacScalefactorDataResilienceFlag = 0; /* no RVLC */ hDecoder->aacSpectralDataResilienceFlag = 1; /* HCR */ +#endif hDecoder->frameLength = 960; hDecoder->sf_index = get_sr_index(hDecoder->config.defSampleRate); hDecoder->object_type = hDecoder->config.defObjectType; - hDecoder->channelConfiguration = channels; + + if ((channels == DRMCH_STEREO) || (channels == DRMCH_SBR_STEREO)) + hDecoder->channelConfiguration = 2; + else + hDecoder->channelConfiguration = 1; + +#ifdef SBR_DEC + if (channels == DRMCH_SBR_LC_STEREO) + hDecoder->lcstereo_flag = 1; + else + hDecoder->lcstereo_flag = 0; + + if ((channels == DRMCH_MONO) || (channels == DRMCH_STEREO)) + hDecoder->sbr_present_flag = 0; + else + hDecoder->sbr_present_flag = 1; + + /* Reset sbr for new initialization */ + sbrDecodeEnd(hDecoder->sbr[0]); + hDecoder->sbr[0] = NULL; +#endif /* must be done before frameLength is divided by 2 for LD */ hDecoder->fb = filter_bank_init(hDecoder->frameLength); -#ifndef FIXED_POINT - if (hDecoder->config.outputFormat >= FAAD_FMT_DITHER_LOWEST) - Init_Dither(16, hDecoder->config.outputFormat - FAAD_FMT_DITHER_LOWEST); + /* Take care of buffers */ + if (hDecoder->sample_buffer) faad_free(hDecoder->sample_buffer); + hDecoder->sample_buffer = NULL; + + for (i = 0; i < MAX_CHANNELS; i++) + { + hDecoder->window_shape_prev[i] = 0; + + if (hDecoder->time_out[i]) faad_free(hDecoder->time_out[i]); + hDecoder->time_out[i] = NULL; +#ifdef SBR_DEC + if (hDecoder->time_out2[i]) faad_free(hDecoder->time_out2[i]); + hDecoder->time_out2[i] = NULL; +#endif +#ifdef SSR_DEC + if (hDecoder->ssr_overlap[i]) faad_free(hDecoder->ssr_overlap[i]); + hDecoder->ssr_overlap[i] = NULL; + if (hDecoder->prev_fmd[i]) faad_free(hDecoder->prev_fmd[i]); + hDecoder->prev_fmd[i] = NULL; +#endif +#ifdef MAIN_DEC + if (hDecoder->pred_stat[i]) faad_free(hDecoder->pred_stat[i]); + hDecoder->pred_stat[i] = NULL; #endif +#ifdef LTP_DEC + hDecoder->ltp_lag[i] = 0; + if (hDecoder->lt_pred_stat[i]) faad_free(hDecoder->lt_pred_stat[i]); + hDecoder->lt_pred_stat[i] = NULL; +#endif + } return 0; } +#endif void FAADAPI faacDecClose(faacDecHandle hDecoder) { @@ -328,18 +446,29 @@ void FAADAPI faacDecClose(faacDecHandle hDecoder) if (hDecoder == NULL) return; +#ifdef PROFILE + printf("AAC decoder total: %I64d cycles\n", hDecoder->cycles); + printf("requant: %I64d cycles\n", hDecoder->requant_cycles); + printf("spectral_data: %I64d cycles\n", hDecoder->spectral_cycles); + printf("scalefactors: %I64d cycles\n", hDecoder->scalefac_cycles); + printf("output: %I64d cycles\n", hDecoder->output_cycles); +#endif + for (i = 0; i < MAX_CHANNELS; i++) { - if (hDecoder->time_out[i]) free(hDecoder->time_out[i]); + if (hDecoder->time_out[i]) faad_free(hDecoder->time_out[i]); +#ifdef SBR_DEC + if (hDecoder->time_out2[i]) faad_free(hDecoder->time_out2[i]); +#endif #ifdef SSR_DEC - if (hDecoder->ssr_overlap[i]) free(hDecoder->ssr_overlap[i]); - if (hDecoder->prev_fmd[i]) free(hDecoder->prev_fmd[i]); + if (hDecoder->ssr_overlap[i]) faad_free(hDecoder->ssr_overlap[i]); + if (hDecoder->prev_fmd[i]) faad_free(hDecoder->prev_fmd[i]); #endif #ifdef MAIN_DEC - if (hDecoder->pred_stat[i]) free(hDecoder->pred_stat[i]); + if (hDecoder->pred_stat[i]) faad_free(hDecoder->pred_stat[i]); #endif #ifdef LTP_DEC - if (hDecoder->lt_pred_stat[i]) free(hDecoder->lt_pred_stat[i]); + if (hDecoder->lt_pred_stat[i]) faad_free(hDecoder->lt_pred_stat[i]); #endif } @@ -352,84 +481,327 @@ void FAADAPI faacDecClose(faacDecHandle hDecoder) drc_end(hDecoder->drc); -#ifndef FIXED_POINT -#if POW_TABLE_SIZE - if (hDecoder->pow2_table) free(hDecoder->pow2_table); -#endif + if (hDecoder->sample_buffer) faad_free(hDecoder->sample_buffer); + +#ifdef SBR_DEC + for (i = 0; i < 32; i++) + { + if (hDecoder->sbr[i]) + sbrDecodeEnd(hDecoder->sbr[i]); + } #endif - if (hDecoder->sample_buffer) free(hDecoder->sample_buffer); + if (hDecoder) faad_free(hDecoder); +} + +void FAADAPI faacDecPostSeekReset(faacDecHandle hDecoder, int32_t frame) +{ + if (hDecoder) + { + hDecoder->postSeekResetFlag = 1; + + if (frame != -1) + hDecoder->frame = frame; + } +} + +static void create_channel_config(faacDecHandle hDecoder, faacDecFrameInfo *hInfo) +{ + hInfo->num_front_channels = 0; + hInfo->num_side_channels = 0; + hInfo->num_back_channels = 0; + hInfo->num_lfe_channels = 0; + memset(hInfo->channel_position, 0, MAX_CHANNELS*sizeof(uint8_t)); + + if (hDecoder->downMatrix) + { + hInfo->num_front_channels = 2; + hInfo->channel_position[0] = FRONT_CHANNEL_LEFT; + hInfo->channel_position[1] = FRONT_CHANNEL_RIGHT; + return; + } + + /* check if there is a PCE */ + if (hDecoder->pce_set) + { + uint8_t i, chpos = 0; + uint8_t chdir, back_center = 0; + + hInfo->num_front_channels = hDecoder->pce.num_front_channels; + hInfo->num_side_channels = hDecoder->pce.num_side_channels; + hInfo->num_back_channels = hDecoder->pce.num_back_channels; + hInfo->num_lfe_channels = hDecoder->pce.num_lfe_channels; + + chdir = hInfo->num_front_channels; + if (chdir & 1) + { + hInfo->channel_position[chpos++] = FRONT_CHANNEL_CENTER; + chdir--; + } + for (i = 0; i < chdir; i += 2) + { + hInfo->channel_position[chpos++] = FRONT_CHANNEL_LEFT; + hInfo->channel_position[chpos++] = FRONT_CHANNEL_RIGHT; + } + + for (i = 0; i < hInfo->num_side_channels; i += 2) + { + hInfo->channel_position[chpos++] = SIDE_CHANNEL_LEFT; + hInfo->channel_position[chpos++] = SIDE_CHANNEL_RIGHT; + } + + chdir = hInfo->num_back_channels; + if (chdir & 1) + { + back_center = 1; + chdir--; + } + for (i = 0; i < chdir; i += 2) + { + hInfo->channel_position[chpos++] = BACK_CHANNEL_LEFT; + hInfo->channel_position[chpos++] = BACK_CHANNEL_RIGHT; + } + if (back_center) + { + hInfo->channel_position[chpos++] = BACK_CHANNEL_CENTER; + } + + for (i = 0; i < hInfo->num_lfe_channels; i++) + { + hInfo->channel_position[chpos++] = LFE_CHANNEL; + } - if (hDecoder) free(hDecoder); + } else { + switch (hDecoder->channelConfiguration) + { + case 1: + hInfo->num_front_channels = 1; + hInfo->channel_position[0] = FRONT_CHANNEL_CENTER; + break; + case 2: + hInfo->num_front_channels = 2; + hInfo->channel_position[0] = FRONT_CHANNEL_LEFT; + hInfo->channel_position[1] = FRONT_CHANNEL_RIGHT; + break; + case 3: + hInfo->num_front_channels = 3; + hInfo->channel_position[0] = FRONT_CHANNEL_CENTER; + hInfo->channel_position[1] = FRONT_CHANNEL_LEFT; + hInfo->channel_position[2] = FRONT_CHANNEL_RIGHT; + break; + case 4: + hInfo->num_front_channels = 3; + hInfo->num_back_channels = 1; + hInfo->channel_position[0] = FRONT_CHANNEL_CENTER; + hInfo->channel_position[1] = FRONT_CHANNEL_LEFT; + hInfo->channel_position[2] = FRONT_CHANNEL_RIGHT; + hInfo->channel_position[3] = BACK_CHANNEL_CENTER; + break; + case 5: + hInfo->num_front_channels = 3; + hInfo->num_back_channels = 2; + hInfo->channel_position[0] = FRONT_CHANNEL_CENTER; + hInfo->channel_position[1] = FRONT_CHANNEL_LEFT; + hInfo->channel_position[2] = FRONT_CHANNEL_RIGHT; + hInfo->channel_position[3] = BACK_CHANNEL_LEFT; + hInfo->channel_position[4] = BACK_CHANNEL_RIGHT; + break; + case 6: + hInfo->num_front_channels = 3; + hInfo->num_back_channels = 2; + hInfo->num_lfe_channels = 1; + hInfo->channel_position[0] = FRONT_CHANNEL_CENTER; + hInfo->channel_position[1] = FRONT_CHANNEL_LEFT; + hInfo->channel_position[2] = FRONT_CHANNEL_RIGHT; + hInfo->channel_position[3] = BACK_CHANNEL_LEFT; + hInfo->channel_position[4] = BACK_CHANNEL_RIGHT; + hInfo->channel_position[5] = LFE_CHANNEL; + break; + case 7: + hInfo->num_front_channels = 3; + hInfo->num_side_channels = 2; + hInfo->num_back_channels = 2; + hInfo->num_lfe_channels = 1; + hInfo->channel_position[0] = FRONT_CHANNEL_CENTER; + hInfo->channel_position[1] = FRONT_CHANNEL_LEFT; + hInfo->channel_position[2] = FRONT_CHANNEL_RIGHT; + hInfo->channel_position[3] = SIDE_CHANNEL_LEFT; + hInfo->channel_position[4] = SIDE_CHANNEL_RIGHT; + hInfo->channel_position[5] = BACK_CHANNEL_LEFT; + hInfo->channel_position[6] = BACK_CHANNEL_RIGHT; + hInfo->channel_position[7] = LFE_CHANNEL; + break; + default: /* channelConfiguration == 0 || channelConfiguration > 7 */ + { + uint8_t i; + uint8_t ch = hDecoder->fr_channels - hDecoder->has_lfe; + if (ch & 1) /* there's either a center front or a center back channel */ + { + uint8_t ch1 = (ch-1)/2; + if (hDecoder->first_syn_ele == ID_SCE) + { + hInfo->num_front_channels = ch1 + 1; + hInfo->num_back_channels = ch1; + hInfo->channel_position[0] = FRONT_CHANNEL_CENTER; + for (i = 1; i <= ch1; i+=2) + { + hInfo->channel_position[i] = FRONT_CHANNEL_LEFT; + hInfo->channel_position[i+1] = FRONT_CHANNEL_RIGHT; + } + for (i = ch1+1; i < ch; i+=2) + { + hInfo->channel_position[i] = BACK_CHANNEL_LEFT; + hInfo->channel_position[i+1] = BACK_CHANNEL_RIGHT; + } + } else { + hInfo->num_front_channels = ch1; + hInfo->num_back_channels = ch1 + 1; + for (i = 0; i < ch1; i+=2) + { + hInfo->channel_position[i] = FRONT_CHANNEL_LEFT; + hInfo->channel_position[i+1] = FRONT_CHANNEL_RIGHT; + } + for (i = ch1; i < ch-1; i+=2) + { + hInfo->channel_position[i] = BACK_CHANNEL_LEFT; + hInfo->channel_position[i+1] = BACK_CHANNEL_RIGHT; + } + hInfo->channel_position[ch-1] = BACK_CHANNEL_CENTER; + } + } else { + uint8_t ch1 = (ch)/2; + hInfo->num_front_channels = ch1; + hInfo->num_back_channels = ch1; + if (ch1 & 1) + { + hInfo->channel_position[0] = FRONT_CHANNEL_CENTER; + for (i = 1; i <= ch1; i+=2) + { + hInfo->channel_position[i] = FRONT_CHANNEL_LEFT; + hInfo->channel_position[i+1] = FRONT_CHANNEL_RIGHT; + } + for (i = ch1+1; i < ch-1; i+=2) + { + hInfo->channel_position[i] = BACK_CHANNEL_LEFT; + hInfo->channel_position[i+1] = BACK_CHANNEL_RIGHT; + } + hInfo->channel_position[ch-1] = BACK_CHANNEL_CENTER; + } else { + for (i = 0; i < ch1; i+=2) + { + hInfo->channel_position[i] = FRONT_CHANNEL_LEFT; + hInfo->channel_position[i+1] = FRONT_CHANNEL_RIGHT; + } + for (i = ch1; i < ch; i+=2) + { + hInfo->channel_position[i] = BACK_CHANNEL_LEFT; + hInfo->channel_position[i+1] = BACK_CHANNEL_RIGHT; + } + } + } + hInfo->num_lfe_channels = hDecoder->has_lfe; + for (i = ch; i < hDecoder->fr_channels; i++) + { + hInfo->channel_position[i] = LFE_CHANNEL; + } + } + break; + } + } } void* FAADAPI faacDecDecode(faacDecHandle hDecoder, faacDecFrameInfo *hInfo, uint8_t *buffer, uint32_t buffer_size) { - int32_t i; - uint8_t ch; adts_header adts; uint8_t channels = 0, ch_ele = 0; - bitfile *ld = (bitfile*)malloc(sizeof(bitfile)); + uint8_t output_channels = 0; + bitfile ld; + uint32_t bitsconsumed; +#ifdef DRM + uint8_t *revbuffer; + uint8_t *prevbufstart; + uint8_t *pbufend; +#endif - /* local copys of globals */ - uint8_t sf_index = hDecoder->sf_index; - uint8_t object_type = hDecoder->object_type; - uint8_t channelConfiguration = hDecoder->channelConfiguration; + /* local copy of globals */ + uint8_t sf_index, object_type, channelConfiguration, outputFormat; + uint8_t *window_shape_prev; + uint16_t frame_len; #ifdef MAIN_DEC - pred_state **pred_stat = hDecoder->pred_stat; -#endif -#ifdef LTP_DEC - real_t **lt_pred_stat = hDecoder->lt_pred_stat; -#endif -#ifndef FIXED_POINT -#if POW_TABLE_SIZE - real_t *pow2_table = hDecoder->pow2_table; -#else - real_t *pow2_table = NULL; + pred_state **pred_stat; #endif + real_t **time_out; +#ifdef SBR_DEC + real_t **time_out2; #endif - uint8_t *window_shape_prev = hDecoder->window_shape_prev; - real_t **time_out = hDecoder->time_out; #ifdef SSR_DEC - real_t **ssr_overlap = hDecoder->ssr_overlap; - real_t **prev_fmd = hDecoder->prev_fmd; -#endif - fb_info *fb = hDecoder->fb; - drc_info *drc = hDecoder->drc; - uint8_t outputFormat = hDecoder->config.outputFormat; -#ifdef LTP_DEC - uint16_t *ltp_lag = hDecoder->ltp_lag; + real_t **ssr_overlap, **prev_fmd; #endif + fb_info *fb; + drc_info *drc; + program_config *pce; - program_config pce; - element *syntax_elements[MAX_SYNTAX_ELEMENTS]; - element **elements; - int16_t *spec_data[MAX_CHANNELS]; - real_t *spec_coef[MAX_CHANNELS]; + void *sample_buffer; - uint16_t frame_len = hDecoder->frameLength; +#ifdef PROFILE + int64_t count = faad_get_ts(); +#endif - void *sample_buffer; + /* safety checks */ + if ((hDecoder == NULL) || (hInfo == NULL) || (buffer == NULL)) + { + return NULL; + } + + sf_index = hDecoder->sf_index; + object_type = hDecoder->object_type; + channelConfiguration = hDecoder->channelConfiguration; +#ifdef MAIN_DEC + pred_stat = hDecoder->pred_stat; +#endif + window_shape_prev = hDecoder->window_shape_prev; + time_out = hDecoder->time_out; +#ifdef SBR_DEC + time_out2 = hDecoder->time_out2; +#endif +#ifdef SSR_DEC + ssr_overlap = hDecoder->ssr_overlap; + prev_fmd = hDecoder->prev_fmd; +#endif + fb = hDecoder->fb; + drc = hDecoder->drc; + outputFormat = hDecoder->config.outputFormat; + pce = &hDecoder->pce; + frame_len = hDecoder->frameLength; memset(hInfo, 0, sizeof(faacDecFrameInfo)); + memset(hDecoder->internal_channel, 0, MAX_CHANNELS*sizeof(hDecoder->internal_channel[0])); /* initialize the bitstream */ - faad_initbits(ld, buffer, buffer_size); + faad_initbits(&ld, buffer, buffer_size); #ifdef DRM if (object_type == DRM_ER_LC) { - faad_getbits(ld, 8 + /* We do not support stereo right now */ + if (hDecoder->channelConfiguration == 2) + { + hInfo->error = 8; // Throw CRC error + goto error; + } + + faad_getbits(&ld, 8 DEBUGVAR(1,1,"faacDecDecode(): skip CRC")); } #endif if (hDecoder->adts_header_present) { - if ((hInfo->error = adts_frame(&adts, ld)) > 0) + adts.old_format = hDecoder->config.useOldADTSFormat; + if ((hInfo->error = adts_frame(&adts, &ld)) > 0) goto error; /* MPEG2 does byte_alignment() here, @@ -442,11 +814,17 @@ void* FAADAPI faacDecDecode(faacDecHandle hDecoder, dbg_count = 0; #endif - elements = syntax_elements; - /* decode the complete bitstream */ - elements = raw_data_block(hDecoder, hInfo, ld, syntax_elements, - spec_data, spec_coef, &pce, drc); +#ifdef SCALABLE_DEC + if ((hDecoder->object_type == 6) || (hDecoder->object_type == DRM_ER_LC)) + { + aac_scalable_main_element(hDecoder, hInfo, &ld, pce, drc); + } else { +#endif + raw_data_block(hDecoder, hInfo, &ld, pce, drc); +#ifdef SCALABLE_DEC + } +#endif ch_ele = hDecoder->fr_ch_ele; channels = hDecoder->fr_channels; @@ -456,22 +834,94 @@ void* FAADAPI faacDecDecode(faacDecHandle hDecoder, /* no more bit reading after this */ - hInfo->bytesconsumed = bit2byte(faad_get_processed_bits(ld)); - if (ld->error) + bitsconsumed = faad_get_processed_bits(&ld); + hInfo->bytesconsumed = bit2byte(bitsconsumed); + if (ld.error) { hInfo->error = 14; goto error; } - faad_endbits(ld); - if (ld) free(ld); - ld = NULL; + faad_endbits(&ld); + +#ifdef DRM +#ifdef SBR_DEC + if ((hDecoder->sbr_present_flag == 1) && (hDecoder->object_type == DRM_ER_LC)) + { + int32_t i; + + if (bitsconsumed + 8 > buffer_size*8) + { + hInfo->error = 14; + goto error; + } + + hDecoder->sbr_used[0] = 1; + + if (!hDecoder->sbr[0]) + hDecoder->sbr[0] = sbrDecodeInit(hDecoder->frameLength, 1); + + /* Reverse bit reading of SBR data in DRM audio frame */ + revbuffer = (uint8_t*)faad_malloc(buffer_size*sizeof(uint8_t)); + prevbufstart = revbuffer; + pbufend = &buffer[buffer_size - 1]; + for (i = 0; i < buffer_size; i++) + *prevbufstart++ = tabFlipbits[*pbufend--]; + + /* Set SBR data */ + hDecoder->sbr[0]->data = revbuffer; + /* consider 8 bits from AAC-CRC */ + hDecoder->sbr[0]->data_size_bits = buffer_size*8 - bitsconsumed - 8; + hDecoder->sbr[0]->data_size = + bit2byte(hDecoder->sbr[0]->data_size_bits + 8); + + hDecoder->sbr[0]->lcstereo_flag = hDecoder->lcstereo_flag; + + hDecoder->sbr[0]->sample_rate = get_sample_rate(hDecoder->sf_index); + hDecoder->sbr[0]->sample_rate *= 2; + + hDecoder->sbr[0]->id_aac = hDecoder->element_id[0]; + } +#endif +#endif + + if (!hDecoder->adts_header_present && !hDecoder->adif_header_present) + { + if (channels != hDecoder->channelConfiguration) + hDecoder->channelConfiguration = channels; + + if (channels == 8) /* 7.1 */ + hDecoder->channelConfiguration = 7; + if (channels == 7) /* not a standard channelConfiguration */ + hDecoder->channelConfiguration = 0; + } + + if ((channels == 5 || channels == 6) && hDecoder->config.downMatrix) + { + hDecoder->downMatrix = 1; + output_channels = 2; + } else { + output_channels = channels; + } + + /* Make a channel configuration based on either a PCE or a channelConfiguration */ + create_channel_config(hDecoder, hInfo); /* number of samples in this frame */ - hInfo->samples = frame_len*channels; + hInfo->samples = frame_len*output_channels; /* number of channels in this frame */ - hInfo->channels = channels; + hInfo->channels = output_channels; /* samplerate */ - hInfo->samplerate = sample_rates[hDecoder->sf_index]; + hInfo->samplerate = get_sample_rate(hDecoder->sf_index); + /* object type */ + hInfo->object_type = hDecoder->object_type; + /* sbr */ + hInfo->sbr = NO_SBR; + /* header type */ + hInfo->header_type = RAW; + if (hDecoder->adif_header_present) + hInfo->header_type = ADIF; + if (hDecoder->adts_header_present) + hInfo->header_type = ADTS; /* check if frame has channel elements */ if (channels == 0) @@ -480,213 +930,98 @@ void* FAADAPI faacDecDecode(faacDecHandle hDecoder, return NULL; } + /* allocate the buffer for the final samples */ if (hDecoder->sample_buffer == NULL) { - if (hDecoder->config.outputFormat == FAAD_FMT_DOUBLE) - hDecoder->sample_buffer = malloc(frame_len*channels*sizeof(double)); - else - hDecoder->sample_buffer = malloc(frame_len*channels*sizeof(real_t)); + static const uint8_t str[] = { sizeof(int16_t), sizeof(int32_t), sizeof(int32_t), + sizeof(float32_t), sizeof(double), sizeof(int16_t), sizeof(int16_t), + sizeof(int16_t), sizeof(int16_t), 0, 0, 0 + }; + uint8_t stride = str[outputFormat-1]; +#ifdef SBR_DEC + if ((hDecoder->sbr_present_flag == 1) || (hDecoder->forceUpSampling == 1)) + stride = 2 * stride; +#endif + hDecoder->sample_buffer = faad_malloc(frame_len*channels*stride); } sample_buffer = hDecoder->sample_buffer; - /* noiseless coding is done, the rest of the tools come now */ - for (ch = 0; ch < channels; ch++) +#ifdef SBR_DEC + if ((hDecoder->sbr_present_flag == 1) || (hDecoder->forceUpSampling == 1)) { - ic_stream *ics; - - /* find the syntax element to which this channel belongs */ + uint8_t i, ch = 0; for (i = 0; i < ch_ele; i++) { - if (syntax_elements[i]->channel == ch) - ics = &(syntax_elements[i]->ics1); - else if (syntax_elements[i]->paired_channel == ch) - ics = &(syntax_elements[i]->ics2); - } - - /* inverse quantization */ - inverse_quantization(spec_coef[ch], spec_data[ch], frame_len); - - /* apply scalefactors */ -#ifdef FIXED_POINT - apply_scalefactors(ics, spec_coef[ch], frame_len); -#else - apply_scalefactors(ics, spec_coef[ch], pow2_table, frame_len); -#endif - - /* deinterleave short block grouping */ - if (ics->window_sequence == EIGHT_SHORT_SEQUENCE) - quant_to_spec(ics, spec_coef[ch], frame_len); - } - - /* Because for ms, is and pns both channels spectral coefficients are needed - we have to restart running through all channels here. - */ - for (ch = 0; ch < channels; ch++) - { - int16_t pch = -1; - uint8_t right_channel; - ic_stream *ics, *icsr; - ltp_info *ltp; - - /* find the syntax element to which this channel belongs */ - for (i = 0; i < ch_ele; i++) - { - if (syntax_elements[i]->channel == ch) + /* following case can happen when forceUpSampling == 1 */ + if (hDecoder->sbr[i] == NULL) { - ics = &(syntax_elements[i]->ics1); - icsr = &(syntax_elements[i]->ics2); - ltp = &(ics->ltp); - pch = syntax_elements[i]->paired_channel; - right_channel = 0; - } else if (syntax_elements[i]->paired_channel == ch) { - ics = &(syntax_elements[i]->ics2); - if (syntax_elements[i]->common_window) - ltp = &(ics->ltp2); - else - ltp = &(ics->ltp); - right_channel = 1; + hDecoder->sbr[i] = sbrDecodeInit(hDecoder->frameLength +#ifdef DRM + , 0 +#endif + ); + hDecoder->sbr[i]->data = NULL; + hDecoder->sbr[i]->data_size = 0; + hDecoder->sbr[i]->id_aac = hDecoder->element_id[i]; } - } - /* pns decoding */ - if ((!right_channel) && (pch != -1) && (ics->ms_mask_present)) - pns_decode(ics, icsr, spec_coef[ch], spec_coef[pch], frame_len, 1); - else if ((pch == -1) || ((pch != -1) && (!ics->ms_mask_present))) - pns_decode(ics, NULL, spec_coef[ch], NULL, frame_len, 0); - - if (!right_channel && (pch != -1)) - { - /* mid/side decoding */ - ms_decode(ics, icsr, spec_coef[ch], spec_coef[pch], frame_len); - - /* intensity stereo decoding */ - is_decode(ics, icsr, spec_coef[ch], spec_coef[pch], frame_len); - } - -#ifdef MAIN_DEC - /* MAIN object type prediction */ - if (object_type == MAIN) - { - /* allocate the state only when needed */ - if (pred_stat[ch] == NULL) + /* Allocate space for SBR output */ + if (hDecoder->time_out2[ch] == NULL) { - pred_stat[ch] = (pred_state*)malloc(frame_len * sizeof(pred_state)); - reset_all_predictors(pred_stat[ch], frame_len); + hDecoder->time_out2[ch] = (real_t*)faad_malloc(hDecoder->frameLength*2*sizeof(real_t)); + memset(hDecoder->time_out2[ch], 0, hDecoder->frameLength*2*sizeof(real_t)); } - /* intra channel prediction */ - ic_prediction(ics, spec_coef[ch], pred_stat[ch], frame_len); - - /* In addition, for scalefactor bands coded by perceptual - noise substitution the predictors belonging to the - corresponding spectral coefficients are reset. - */ - pns_reset_pred_state(ics, pred_stat[ch]); - } -#endif -#ifdef LTP_DEC - if ((object_type == LTP) -#ifdef ERROR_RESILIENCE - || (object_type == ER_LTP) -#endif -#ifdef LD_DEC - || (object_type == LD) -#endif - ) - { -#ifdef LD_DEC - if (object_type == LD) + if (hDecoder->sbr[i]->id_aac == ID_CPE) { - if (ltp->data_present) + /* space for 2 channels needed */ + if (hDecoder->time_out2[ch+1] == NULL) { - if (ltp->lag_update) - ltp_lag[ch] = ltp->lag; + hDecoder->time_out2[ch+1] = (real_t*)faad_malloc(hDecoder->frameLength*2*sizeof(real_t)); + memset(hDecoder->time_out2[ch+1], 0, hDecoder->frameLength*2*sizeof(real_t)); } - ltp->lag = ltp_lag[ch]; - } -#endif - /* allocate the state only when needed */ - if (lt_pred_stat[ch] == NULL) - { - lt_pred_stat[ch] = (real_t*)malloc(frame_len*4 * sizeof(real_t)); - memset(lt_pred_stat[ch], 0, frame_len*4 * sizeof(real_t)); + memcpy(time_out2[ch], + time_out[ch], frame_len*sizeof(real_t)); + memcpy(time_out2[ch+1], + time_out[ch+1], frame_len*sizeof(real_t)); + sbrDecodeFrame(hDecoder->sbr[i], + time_out2[ch], time_out2[ch+1], + hDecoder->postSeekResetFlag, hDecoder->forceUpSampling); + ch += 2; + } else { + memcpy(time_out2[ch], + time_out[ch], frame_len*sizeof(real_t)); + sbrDecodeFrame(hDecoder->sbr[i], + time_out2[ch], NULL, + hDecoder->postSeekResetFlag, hDecoder->forceUpSampling); + ch++; } - - /* long term prediction */ - lt_prediction(ics, ltp, spec_coef[ch], lt_pred_stat[ch], fb, - ics->window_shape, window_shape_prev[ch], - sf_index, object_type, frame_len); - } -#endif - - /* tns decoding */ - tns_decode_frame(ics, &(ics->tns), sf_index, object_type, - spec_coef[ch], frame_len); - - /* drc decoding */ - if (drc->present) - { - if (!drc->exclude_mask[ch] || !drc->excluded_chns_present) - drc_decode(drc, spec_coef[ch]); - } - - if (time_out[ch] == NULL) - { - time_out[ch] = (real_t*)malloc(frame_len*2*sizeof(real_t)); - memset(time_out[ch], 0, frame_len*2*sizeof(real_t)); } - - /* filter bank */ -#ifdef SSR_DEC - if (object_type != SSR) + frame_len *= 2; + hInfo->samples *= 2; + hInfo->samplerate *= 2; + /* sbr */ + if (hDecoder->sbr_present_flag == 1) { -#endif - ifilter_bank(fb, ics->window_sequence, ics->window_shape, - window_shape_prev[ch], spec_coef[ch], - time_out[ch], object_type, frame_len); -#ifdef SSR_DEC + hInfo->object_type = HE_AAC; + hInfo->sbr = SBR_UPSAMPLED; } else { - if (ssr_overlap[ch] == NULL) - { - ssr_overlap[ch] = (real_t*)malloc(2*frame_len*sizeof(real_t)); - memset(ssr_overlap[ch], 0, 2*frame_len*sizeof(real_t)); - } - if (prev_fmd[ch] == NULL) - { - uint16_t k; - prev_fmd[ch] = (real_t*)malloc(2*frame_len*sizeof(real_t)); - for (k = 0; k < 2*frame_len; k++) - prev_fmd[ch][k] = REAL_CONST(-1); - } - - ssr_decode(&(ics->ssr), fb, ics->window_sequence, ics->window_shape, - window_shape_prev[ch], spec_coef[ch], time_out[ch], - ssr_overlap[ch], hDecoder->ipqf_buffer[ch], prev_fmd[ch], frame_len); + hInfo->sbr = NO_SBR_UPSAMPLED; } -#endif - /* save window shape for next frame */ - window_shape_prev[ch] = ics->window_shape; -#ifdef LTP_DEC - if ((object_type == LTP) -#ifdef ERROR_RESILIENCE - || (object_type == ER_LTP) -#endif -#ifdef LD_DEC - || (object_type == LD) -#endif - ) - { - lt_update_state(lt_pred_stat[ch], time_out[ch], time_out[ch]+frame_len, - frame_len, object_type); - } + sample_buffer = output_to_PCM(hDecoder, time_out2, sample_buffer, + output_channels, frame_len, outputFormat); + } else { #endif + sample_buffer = output_to_PCM(hDecoder, time_out, sample_buffer, + output_channels, frame_len, outputFormat); +#ifdef SBR_DEC } +#endif - sample_buffer = output_to_PCM(time_out, sample_buffer, channels, - frame_len, outputFormat); + hDecoder->postSeekResetFlag = 0; hDecoder->frame++; #ifdef LD_DEC @@ -704,40 +1039,19 @@ void* FAADAPI faacDecDecode(faacDecHandle hDecoder, #endif /* cleanup */ - for (ch = 0; ch < channels; ch++) - { - if (spec_coef[ch]) free(spec_coef[ch]); - if (spec_data[ch]) free(spec_data[ch]); - } - - for (i = 0; i < ch_ele; i++) - { - if (syntax_elements[i]) free(syntax_elements[i]); - } - #ifdef ANALYSIS fflush(stdout); #endif +#ifdef PROFILE + count = faad_get_ts() - count; + hDecoder->cycles += count; +#endif + return sample_buffer; error: - /* free all memory that could have been allocated */ - faad_endbits(ld); - if (ld) free(ld); - /* cleanup */ - for (ch = 0; ch < channels; ch++) - { - if (spec_coef[ch]) free(spec_coef[ch]); - if (spec_data[ch]) free(spec_data[ch]); - } - - for (i = 0; i < ch_ele; i++) - { - if (syntax_elements[i]) free(syntax_elements[i]); - } - #ifdef ANALYSIS fflush(stdout); #endif diff --git a/src/libfaad/decoder.h b/src/libfaad/decoder.h index 0257049ce..9973d69cb 100644 --- a/src/libfaad/decoder.h +++ b/src/libfaad/decoder.h @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: decoder.h,v 1.4 2003/08/25 21:51:41 f1rmb Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: decoder.h,v 1.5 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #ifndef __DECODER_H__ @@ -51,12 +57,6 @@ extern "C" { #define FAAD_FMT_32BIT 3 #define FAAD_FMT_FLOAT 4 #define FAAD_FMT_DOUBLE 5 -#define FAAD_FMT_16BIT_DITHER 6 -#define FAAD_FMT_16BIT_L_SHAPE 7 -#define FAAD_FMT_16BIT_M_SHAPE 8 -#define FAAD_FMT_16BIT_H_SHAPE 9 - -#define FAAD_FMT_DITHER_LOWEST FAAD_FMT_16BIT_DITHER #define LC_DEC_CAP (1<<0) #define MAIN_DEC_CAP (1<<1) @@ -65,11 +65,22 @@ extern "C" { #define ERROR_RESILIENCE_CAP (1<<4) #define FIXED_POINT_CAP (1<<5) +#define FRONT_CHANNEL_CENTER (1) +#define FRONT_CHANNEL_LEFT (2) +#define FRONT_CHANNEL_RIGHT (3) +#define SIDE_CHANNEL_LEFT (4) +#define SIDE_CHANNEL_RIGHT (5) +#define BACK_CHANNEL_LEFT (6) +#define BACK_CHANNEL_RIGHT (7) +#define BACK_CHANNEL_CENTER (8) +#define LFE_CHANNEL (9) +#define UNKNOWN_CHANNEL (0) + int8_t* FAADAPI faacDecGetErrorMessage(uint8_t errcode); -uint32_t FAADAPI faacDecGetCapabilities(void); +uint32_t FAADAPI faacDecGetCapabilities(); -faacDecHandle FAADAPI faacDecOpen(void); +faacDecHandle FAADAPI faacDecOpen(); faacDecConfigurationPtr FAADAPI faacDecGetCurrentConfiguration(faacDecHandle hDecoder); @@ -94,24 +105,13 @@ int8_t FAADAPI faacDecInitDRM(faacDecHandle hDecoder, uint32_t samplerate, void FAADAPI faacDecClose(faacDecHandle hDecoder); +void FAADAPI faacDecPostSeekReset(faacDecHandle hDecoder, int32_t frame); + void* FAADAPI faacDecDecode(faacDecHandle hDecoder, faacDecFrameInfo *hInfo, uint8_t *buffer, uint32_t buffer_size); -element *decode_sce_lfe(faacDecHandle hDecoder, - faacDecFrameInfo *hInfo, bitfile *ld, - int16_t **spec_data, real_t **spec_coef, - uint8_t id_syn_ele); -element *decode_cpe(faacDecHandle hDecoder, - faacDecFrameInfo *hInfo, bitfile *ld, - int16_t **spec_data, real_t **spec_coef, - uint8_t id_syn_ele); -element **raw_data_block(faacDecHandle hDecoder, faacDecFrameInfo *hInfo, - bitfile *ld, element **elements, - int16_t **spec_data, real_t **spec_coef, - program_config *pce, drc_info *drc); - #ifdef _WIN32 #pragma pack(pop) #endif diff --git a/src/libfaad/dither.c b/src/libfaad/dither.c deleted file mode 100644 index 9c29e189a..000000000 --- a/src/libfaad/dither.c +++ /dev/null @@ -1,132 +0,0 @@ -/* This program is licensed under the GNU Library General Public License, version 2, - * a copy of which is included with this program (with filename LICENSE.LGPL). - * - * (c) 2002 John Edwards - * mostly lifted from work by Frank Klemm - * random functions for dithering. - * - * last modified: - * $Id: dither.c,v 1.1 2002/12/16 18:59:59 miguelfreitas Exp $ - */ -#include "common.h" - -#ifndef FIXED_POINT - -#include <string.h> -#include "dither.h" -#include "common.h" - - -double -Random_Equi ( double mult ) // gives a equal distributed random number -{ // between -2^31*mult and +2^31*mult - return mult * (int) random_int (); -} - -double -Random_Triangular ( double mult ) // gives a triangular distributed random number -{ // between -2^32*mult and +2^32*mult - return mult * ( (double) (int) random_int () + (double) (int) random_int () ); -} - -/*********************************************************************************************************************/ - -static const float32_t F44_0 [16 + 32] = { - (float)0, (float)0, (float)0, (float)0, (float)0, (float)0, (float)0, (float)0, - (float)0, (float)0, (float)0, (float)0, (float)0, (float)0, (float)0, (float)0, - - (float)0, (float)0, (float)0, (float)0, (float)0, (float)0, (float)0, (float)0, - (float)0, (float)0, (float)0, (float)0, (float)0, (float)0, (float)0, (float)0, - - (float)0, (float)0, (float)0, (float)0, (float)0, (float)0, (float)0, (float)0, - (float)0, (float)0, (float)0, (float)0, (float)0, (float)0, (float)0, (float)0 -}; - - -static const float32_t F44_1 [16 + 32] = { /* SNR(w) = 4.843163 dB, SNR = -3.192134 dB */ - (float) 0.85018292704024355931, (float) 0.29089597350995344721, (float)-0.05021866022121039450, (float)-0.23545456294599161833, - (float)-0.58362726442227032096, (float)-0.67038978965193036429, (float)-0.38566861572833459221, (float)-0.15218663390367969967, - (float)-0.02577543084864530676, (float) 0.14119295297688728127, (float) 0.22398848581628781612, (float) 0.15401727203382084116, - (float) 0.05216161232906000929, (float)-0.00282237820999675451, (float)-0.03042794608323867363, (float)-0.03109780942998826024, - - (float) 0.85018292704024355931, (float) 0.29089597350995344721, (float)-0.05021866022121039450, (float)-0.23545456294599161833, - (float)-0.58362726442227032096, (float)-0.67038978965193036429, (float)-0.38566861572833459221, (float)-0.15218663390367969967, - (float)-0.02577543084864530676, (float) 0.14119295297688728127, (float) 0.22398848581628781612, (float) 0.15401727203382084116, - (float) 0.05216161232906000929, (float)-0.00282237820999675451, (float)-0.03042794608323867363, (float)-0.03109780942998826024, - - (float) 0.85018292704024355931, (float) 0.29089597350995344721, (float)-0.05021866022121039450, (float)-0.23545456294599161833, - (float)-0.58362726442227032096, (float)-0.67038978965193036429, (float)-0.38566861572833459221, (float)-0.15218663390367969967, - (float)-0.02577543084864530676, (float) 0.14119295297688728127, (float) 0.22398848581628781612, (float) 0.15401727203382084116, - (float) 0.05216161232906000929, (float)-0.00282237820999675451, (float)-0.03042794608323867363, (float)-0.03109780942998826024, -}; - - -static const float32_t F44_2 [16 + 32] = { /* SNR(w) = 10.060213 dB, SNR = -12.766730 dB */ - (float) 1.78827593892108555290, (float) 0.95508210637394326553, (float)-0.18447626783899924429, (float)-0.44198126506275016437, - (float)-0.88404052492547413497, (float)-1.42218907262407452967, (float)-1.02037566838362314995, (float)-0.34861755756425577264, - (float)-0.11490230170431934434, (float) 0.12498899339968611803, (float) 0.38065885268563131927, (float) 0.31883491321310506562, - (float) 0.10486838686563442765, (float)-0.03105361685110374845, (float)-0.06450524884075370758, (float)-0.02939198261121969816, - - (float) 1.78827593892108555290, (float) 0.95508210637394326553, (float)-0.18447626783899924429, (float)-0.44198126506275016437, - (float)-0.88404052492547413497, (float)-1.42218907262407452967, (float)-1.02037566838362314995, (float)-0.34861755756425577264, - (float)-0.11490230170431934434, (float) 0.12498899339968611803, (float) 0.38065885268563131927, (float) 0.31883491321310506562, - (float) 0.10486838686563442765, (float)-0.03105361685110374845, (float)-0.06450524884075370758, (float)-0.02939198261121969816, - - (float) 1.78827593892108555290, (float) 0.95508210637394326553, (float)-0.18447626783899924429, (float)-0.44198126506275016437, - (float)-0.88404052492547413497, (float)-1.42218907262407452967, (float)-1.02037566838362314995, (float)-0.34861755756425577264, - (float)-0.11490230170431934434, (float) 0.12498899339968611803, (float) 0.38065885268563131927, (float) 0.31883491321310506562, - (float) 0.10486838686563442765, (float)-0.03105361685110374845, (float)-0.06450524884075370758, (float)-0.02939198261121969816, -}; - - -static const float32_t F44_3 [16 + 32] = { /* SNR(w) = 15.382598 dB, SNR = -29.402334 dB */ - (float) 2.89072132015058161445, (float) 2.68932810943698754106, (float) 0.21083359339410251227, (float)-0.98385073324997617515, - (float)-1.11047823227097316719, (float)-2.18954076314139673147, (float)-2.36498032881953056225, (float)-0.95484132880101140785, - (float)-0.23924057925542965158, (float)-0.13865235703915925642, (float) 0.43587843191057992846, (float) 0.65903257226026665927, - (float) 0.24361815372443152787, (float)-0.00235974960154720097, (float) 0.01844166574603346289, (float) 0.01722945988740875099, - - (float) 2.89072132015058161445, (float) 2.68932810943698754106, (float) 0.21083359339410251227, (float)-0.98385073324997617515, - (float)-1.11047823227097316719, (float)-2.18954076314139673147, (float)-2.36498032881953056225, (float)-0.95484132880101140785, - (float)-0.23924057925542965158, (float)-0.13865235703915925642, (float) 0.43587843191057992846, (float) 0.65903257226026665927, - (float) 0.24361815372443152787, (float)-0.00235974960154720097, (float) 0.01844166574603346289, (float) 0.01722945988740875099, - - (float) 2.89072132015058161445, (float) 2.68932810943698754106, (float) 0.21083359339410251227, (float)-0.98385073324997617515, - (float)-1.11047823227097316719, (float)-2.18954076314139673147, (float)-2.36498032881953056225, (float)-0.95484132880101140785, - (float)-0.23924057925542965158, (float)-0.13865235703915925642, (float) 0.43587843191057992846, (float) 0.65903257226026665927, - (float) 0.24361815372443152787, (float)-0.00235974960154720097, (float) 0.01844166574603346289, (float) 0.01722945988740875099 -}; - - -double -scalar16 ( const float32_t* x, const float32_t* y ) -{ - return x[ 0]*y[ 0] + x[ 1]*y[ 1] + x[ 2]*y[ 2] + x[ 3]*y[ 3] - + x[ 4]*y[ 4] + x[ 5]*y[ 5] + x[ 6]*y[ 6] + x[ 7]*y[ 7] - + x[ 8]*y[ 8] + x[ 9]*y[ 9] + x[10]*y[10] + x[11]*y[11] - + x[12]*y[12] + x[13]*y[13] + x[14]*y[14] + x[15]*y[15]; -} - - -void -Init_Dither ( unsigned char bits, unsigned char shapingtype ) -{ - static uint8_t default_dither [] = { 92, 92, 88, 84, 81, 78, 74, 67, 0, 0 }; - static const float32_t* F [] = { F44_0, F44_1, F44_2, F44_3 }; - uint8_t index; - - if (shapingtype < 0) shapingtype = 0; - if (shapingtype > 3) shapingtype = 3; - index = bits - 11 - shapingtype; - if (index < 0) index = 0; - if (index > 9) index = 9; - - memset ( Dither.ErrorHistory , 0, sizeof (Dither.ErrorHistory ) ); - memset ( Dither.DitherHistory, 0, sizeof (Dither.DitherHistory) ); - - Dither.FilterCoeff = F [shapingtype]; - Dither.Mask = ((uint64_t)-1) << (32 - bits); - Dither.Add = 0.5 * ((1L << (32 - bits)) - 1); - Dither.Dither = 0.01*default_dither[index] / (((int64_t)1) << bits); -} - -#endif diff --git a/src/libfaad/dither.h b/src/libfaad/dither.h deleted file mode 100644 index 34fb31996..000000000 --- a/src/libfaad/dither.h +++ /dev/null @@ -1,47 +0,0 @@ -/* This program is licensed under the GNU Library General Public License, version 2, - * a copy of which is included with this program (with filename LICENSE.LGPL). - * - * (c) 2002 John Edwards - * - * rand_t header. - * - * last modified: $ID:$ - */ - -#include "common.h" - -#ifndef __RAND_T_H -#define __RAND_T_H - -#ifdef __cplusplus -extern "C" { -#endif - -#ifndef FIXED_POINT - -typedef struct { - const float32_t* FilterCoeff; - uint64_t Mask; - double Add; - float32_t Dither; - float32_t ErrorHistory [2] [16]; // max. 2 channels, 16th order Noise shaping - float32_t DitherHistory [2] [16]; - int32_t LastRandomNumber [2]; -} dither_t; - -extern dither_t Dither; -extern double doubletmp; -//static const uint8_t Parity [256]; -uint32_t random_int ( void ); -extern double scalar16 ( const float32_t* x, const float32_t* y ); -extern double Random_Equi ( double mult ); -extern double Random_Triangular ( double mult ); -void Init_Dither ( unsigned char bits, unsigned char shapingtype ); - -#endif - -#ifdef __cplusplus -} -#endif - -#endif diff --git a/src/libfaad/drc.c b/src/libfaad/drc.c index 14f3a2b1f..9482d984f 100644 --- a/src/libfaad/drc.c +++ b/src/libfaad/drc.c @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: drc.c,v 1.2 2002/12/16 19:00:00 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: drc.c,v 1.3 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #include "common.h" @@ -29,7 +35,7 @@ drc_info *drc_init(real_t cut, real_t boost) { - drc_info *drc = (drc_info*)malloc(sizeof(drc_info)); + drc_info *drc = (drc_info*)faad_malloc(sizeof(drc_info)); memset(drc, 0, sizeof(drc_info)); drc->ctrl1 = cut; @@ -45,7 +51,7 @@ drc_info *drc_init(real_t cut, real_t boost) void drc_end(drc_info *drc) { - if (drc) free(drc); + if (drc) faad_free(drc); } #ifdef FIXED_POINT @@ -121,9 +127,9 @@ void drc_decode(drc_info *drc, real_t *spec) #ifndef FIXED_POINT /* Decode DRC gain factor */ if (drc->dyn_rng_sgn[bd]) /* compress */ - exp = -drc->ctrl1 * (drc->dyn_rng_ctl[bd] - (DRC_REF_LEVEL - drc->prog_ref_level))/24.0; + exp = -drc->ctrl1 * (drc->dyn_rng_ctl[bd] - (DRC_REF_LEVEL - drc->prog_ref_level))/REAL_CONST(24.0); else /* boost */ - exp = drc->ctrl2 * (drc->dyn_rng_ctl[bd] - (DRC_REF_LEVEL - drc->prog_ref_level))/24.0; + exp = drc->ctrl2 * (drc->dyn_rng_ctl[bd] - (DRC_REF_LEVEL - drc->prog_ref_level))/REAL_CONST(24.0); factor = (real_t)pow(2.0, exp); /* Apply gain factor */ @@ -147,14 +153,14 @@ void drc_decode(drc_info *drc, real_t *spec) { spec[i] >>= -exp; if (frac) - spec[i] = MUL(spec[i],drc_pow2_table[frac+23]); + spec[i] = MUL_R(spec[i],drc_pow2_table[frac+23]); } } else { for (i = bottom; i < top; i++) { spec[i] <<= exp; if (frac) - spec[i] = MUL(spec[i],drc_pow2_table[frac+23]); + spec[i] = MUL_R(spec[i],drc_pow2_table[frac+23]); } } #endif diff --git a/src/libfaad/drc.h b/src/libfaad/drc.h index e831f7545..137566c54 100644 --- a/src/libfaad/drc.h +++ b/src/libfaad/drc.h @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: drc.h,v 1.2 2002/12/16 19:00:00 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: drc.h,v 1.3 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #ifndef __DRC_H__ diff --git a/src/libfaad/error.c b/src/libfaad/error.c index b716d4837..84943f100 100644 --- a/src/libfaad/error.c +++ b/src/libfaad/error.c @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: error.c,v 1.3 2003/04/12 14:58:47 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: error.c,v 1.4 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #include "common.h" @@ -37,5 +43,9 @@ extern int8_t *err_msg[] = { "Non existent huffman codebook number found", "Maximum number of channels exceeded", "Maximum number of bitstream elements exceeded", - "Input data buffer too small" -}; + "Input data buffer too small", + "Array index out of range", + "Maximum number of scalefactor bands exceeded", + "Quantised value out of range", + "LTP lag out of range" +};
\ No newline at end of file diff --git a/src/libfaad/error.h b/src/libfaad/error.h index 52a9609ee..fb6780361 100644 --- a/src/libfaad/error.h +++ b/src/libfaad/error.h @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: error.h,v 1.2 2002/12/16 19:00:01 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: error.h,v 1.3 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #ifndef __ERROR_H__ @@ -26,6 +32,7 @@ extern "C" { #endif +#define NUM_ERROR_MESSAGES 19 extern int8_t *err_msg[]; #ifdef __cplusplus diff --git a/src/libfaad/faad.h b/src/libfaad/faad.h index 11c69777c..31f8e13f1 100644 --- a/src/libfaad/faad.h +++ b/src/libfaad/faad.h @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: faad.h,v 1.4 2003/08/25 21:51:41 f1rmb Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: faad.h,v 1.5 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #ifndef __AACDEC_H__ @@ -37,13 +43,14 @@ extern "C" { #endif #endif -#define FAAD2_VERSION "1.2 beta" +#define FAAD2_VERSION "2.0 RC3 " /* object types for AAC */ -#define MAIN 0 -#define LC 1 -#define SSR 2 -#define LTP 3 +#define MAIN 1 +#define LC 2 +#define SSR 3 +#define LTP 4 +#define HE_AAC 5 #define ER_LC 17 #define ER_LTP 19 #define LD 23 @@ -54,27 +61,49 @@ extern "C" { #define ADIF 1 #define ADTS 2 +/* SBR signalling */ +#define NO_SBR 0 +#define SBR_UPSAMPLED 1 +#define SBR_DOWNSAMPLED 2 +#define NO_SBR_UPSAMPLED 3 + /* library output formats */ #define FAAD_FMT_16BIT 1 #define FAAD_FMT_24BIT 2 #define FAAD_FMT_32BIT 3 #define FAAD_FMT_FLOAT 4 #define FAAD_FMT_DOUBLE 5 -#define FAAD_FMT_16BIT_DITHER 6 -#define FAAD_FMT_16BIT_L_SHAPE 7 -#define FAAD_FMT_16BIT_M_SHAPE 8 -#define FAAD_FMT_16BIT_H_SHAPE 9 - + /* Capabilities */ -#define LC_DEC_CAP (1<<0) -#define MAIN_DEC_CAP (1<<1) -#define LTP_DEC_CAP (1<<2) -#define LD_DEC_CAP (1<<3) -#define ERROR_RESILIENCE_CAP (1<<4) -#define FIXED_POINT_CAP (1<<5) - -/* A decode call can eat up to FAAD_MIN_STREAMSIZE octets per decoded channel, - so at least so much octets per channel should be available in this stream */ +#define LC_DEC_CAP (1<<0) /* Can decode LC */ +#define MAIN_DEC_CAP (1<<1) /* Can decode MAIN */ +#define LTP_DEC_CAP (1<<2) /* Can decode LTP */ +#define LD_DEC_CAP (1<<3) /* Can decode LD */ +#define ERROR_RESILIENCE_CAP (1<<4) /* Can decode ER */ +#define FIXED_POINT_CAP (1<<5) /* Fixed point */ + +/* Channel definitions */ +#define FRONT_CHANNEL_CENTER (1) +#define FRONT_CHANNEL_LEFT (2) +#define FRONT_CHANNEL_RIGHT (3) +#define SIDE_CHANNEL_LEFT (4) +#define SIDE_CHANNEL_RIGHT (5) +#define BACK_CHANNEL_LEFT (6) +#define BACK_CHANNEL_RIGHT (7) +#define BACK_CHANNEL_CENTER (8) +#define LFE_CHANNEL (9) +#define UNKNOWN_CHANNEL (0) + +/* DRM channel definitions */ +#define DRMCH_MONO 1 +#define DRMCH_STEREO 2 +#define DRMCH_SBR_MONO 3 +#define DRMCH_SBR_LC_STEREO 4 +#define DRMCH_SBR_STEREO 5 + + +/* A decode call can eat up to FAAD_MIN_STREAMSIZE bytes per decoded channel, + so at least so much bytes per channel should be available in this stream */ #define FAAD_MIN_STREAMSIZE 768 /* 6144 bits/channel */ @@ -91,13 +120,15 @@ typedef struct mp4AudioSpecificConfig /* GA Specific Info */ unsigned char frameLengthFlag; unsigned char dependsOnCoreCoder; - unsigned long coreCoderDelay; + unsigned short coreCoderDelay; unsigned char extensionFlag; unsigned char aacSectionDataResilienceFlag; unsigned char aacScalefactorDataResilienceFlag; unsigned char aacSpectralDataResilienceFlag; unsigned char epConfig; + char sbr_present_flag; + char forceUpSampling; } mp4AudioSpecificConfig; typedef struct faacDecConfiguration @@ -105,6 +136,8 @@ typedef struct faacDecConfiguration unsigned char defObjectType; unsigned long defSampleRate; unsigned char outputFormat; + unsigned char downMatrix; + unsigned char useOldADTSFormat; } faacDecConfiguration, *faacDecConfigurationPtr; typedef struct faacDecFrameInfo @@ -114,13 +147,29 @@ typedef struct faacDecFrameInfo unsigned char channels; unsigned char error; unsigned long samplerate; + + /* SBR: 0: off, 1: on; upsample, 2: on; downsampled, 3: off; upsampled */ + unsigned char sbr; + + /* MPEG-4 ObjectType */ + unsigned char object_type; + + /* AAC header type; MP4 will be signalled as RAW also */ + unsigned char header_type; + + /* multichannel configuration */ + unsigned char num_front_channels; + unsigned char num_side_channels; + unsigned char num_back_channels; + unsigned char num_lfe_channels; + unsigned char channel_position[64]; } faacDecFrameInfo; char* FAADAPI faacDecGetErrorMessage(unsigned char errcode); -unsigned long FAADAPI faacDecGetCapabilities(void); +unsigned long FAADAPI faacDecGetCapabilities(); -faacDecHandle FAADAPI faacDecOpen(void); +faacDecHandle FAADAPI faacDecOpen(); faacDecConfigurationPtr FAADAPI faacDecGetCurrentConfiguration(faacDecHandle hDecoder); @@ -143,6 +192,8 @@ char FAADAPI faacDecInit2(faacDecHandle hDecoder, unsigned char *pBuffer, char FAADAPI faacDecInitDRM(faacDecHandle hDecoder, unsigned long samplerate, unsigned char channels); +void FAADAPI faacDecPostSeekReset(faacDecHandle hDecoder, long frame); + void FAADAPI faacDecClose(faacDecHandle hDecoder); void* FAADAPI faacDecDecode(faacDecHandle hDecoder, diff --git a/src/libfaad/filtbank.c b/src/libfaad/filtbank.c index 27480a16d..28187172f 100644 --- a/src/libfaad/filtbank.c +++ b/src/libfaad/filtbank.c @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: filtbank.c,v 1.5 2003/04/12 14:58:47 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: filtbank.c,v 1.6 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #include "common.h" @@ -45,7 +51,7 @@ fb_info *filter_bank_init(uint16_t frame_len) uint16_t frame_len_ld = frame_len/2; #endif - fb_info *fb = (fb_info*)malloc(sizeof(fb_info)); + fb_info *fb = (fb_info*)faad_malloc(sizeof(fb_info)); memset(fb, 0, sizeof(fb_info)); /* normal */ @@ -56,8 +62,10 @@ fb_info *filter_bank_init(uint16_t frame_len) fb->mdct1024 = faad_mdct_init(2*frame_len_ld); #endif +#ifdef ALLOW_SMALL_FRAMELENGTH if (frame_len == 1024) { +#endif fb->long_window[0] = sine_long_1024; fb->short_window[0] = sine_short_128; fb->long_window[1] = kbd_long_1024; @@ -66,6 +74,7 @@ fb_info *filter_bank_init(uint16_t frame_len) fb->ld_window[0] = sine_mid_512; fb->ld_window[1] = ld_mid_512; #endif +#ifdef ALLOW_SMALL_FRAMELENGTH } else /* (frame_len == 960) */ { fb->long_window[0] = sine_long_960; fb->short_window[0] = sine_short_120; @@ -76,6 +85,16 @@ fb_info *filter_bank_init(uint16_t frame_len) fb->ld_window[1] = ld_mid_480; #endif } +#endif + +#ifdef USE_SSE + if (cpu_has_sse()) + { + fb->if_func = ifilter_bank_sse; + } else { + fb->if_func = ifilter_bank; + } +#endif return fb; } @@ -84,18 +103,23 @@ void filter_bank_end(fb_info *fb) { if (fb != NULL) { +#ifdef PROFILE + printf("FB: %I64d cycles\n", fb->cycles); +#endif + faad_mdct_end(fb->mdct256); faad_mdct_end(fb->mdct2048); #ifdef LD_DEC faad_mdct_end(fb->mdct1024); #endif - free(fb); + faad_free(fb); } } -static INLINE void imdct(fb_info *fb, real_t *in_data, real_t *out_data, uint16_t len) +static INLINE void imdct_long(fb_info *fb, real_t *in_data, real_t *out_data, uint16_t len) { +#ifdef LD_DEC mdct_info *mdct; switch (len) @@ -104,20 +128,42 @@ static INLINE void imdct(fb_info *fb, real_t *in_data, real_t *out_data, uint16_ case 1920: mdct = fb->mdct2048; break; - case 256: - case 240: - mdct = fb->mdct256; + case 1024: + case 960: + mdct = fb->mdct1024; break; + } + + faad_imdct(mdct, in_data, out_data); +#else + faad_imdct(fb->mdct2048, in_data, out_data); +#endif +} + +#ifdef USE_SSE +static INLINE void imdct_long_sse(fb_info *fb, real_t *in_data, real_t *out_data, uint16_t len) +{ #ifdef LD_DEC + mdct_info *mdct; + + switch (len) + { + case 2048: + case 1920: + mdct = fb->mdct2048; + break; case 1024: case 960: mdct = fb->mdct1024; break; -#endif } - faad_imdct(mdct, in_data, out_data); + faad_imdct_sse(mdct, in_data, out_data); +#else + faad_imdct_sse(fb->mdct2048, in_data, out_data); +#endif } +#endif #ifdef LTP_DEC static INLINE void mdct(fb_info *fb, real_t *in_data, real_t *out_data, uint16_t len) @@ -151,12 +197,12 @@ void ifilter_bank(fb_info *fb, uint8_t window_sequence, uint8_t window_shape, real_t *time_out, uint8_t object_type, uint16_t frame_len) { int16_t i; - real_t *transf_buf; + ALIGN real_t transf_buf[2*1024] = {0}; - real_t *window_long; - real_t *window_long_prev; - real_t *window_short; - real_t *window_short_prev; + const real_t *window_long; + const real_t *window_long_prev; + const real_t *window_short; + const real_t *window_short_prev; uint16_t nlong = frame_len; uint16_t nshort = frame_len/8; @@ -164,7 +210,9 @@ void ifilter_bank(fb_info *fb, uint8_t window_sequence, uint8_t window_shape, uint16_t nflat_ls = (nlong-nshort)/2; - transf_buf = (real_t*)malloc(2*nlong*sizeof(real_t)); +#ifdef PROFILE + int64_t count = faad_get_ts(); +#endif #ifdef LD_DEC if (object_type == LD) @@ -184,72 +232,422 @@ void ifilter_bank(fb_info *fb, uint8_t window_sequence, uint8_t window_shape, switch (window_sequence) { case ONLY_LONG_SEQUENCE: - imdct(fb, freq_in, transf_buf, 2*nlong); - for (i = nlong-1; i >= 0; i--) + imdct_long(fb, freq_in, transf_buf, 2*nlong); + for (i = 0; i < nlong; i+=4) { - time_out[i] = time_out[nlong+i] + MUL_R_C(transf_buf[i],window_long_prev[i]); - time_out[nlong+i] = MUL_R_C(transf_buf[nlong+i],window_long[nlong-1-i]); + time_out[i] = time_out[nlong+i] + MUL_F(transf_buf[i],window_long_prev[i]); + time_out[i+1] = time_out[nlong+i+1] + MUL_F(transf_buf[i+1],window_long_prev[i+1]); + time_out[i+2] = time_out[nlong+i+2] + MUL_F(transf_buf[i+2],window_long_prev[i+2]); + time_out[i+3] = time_out[nlong+i+3] + MUL_F(transf_buf[i+3],window_long_prev[i+3]); + } + for (i = 0; i < nlong; i+=4) + { + time_out[nlong+i] = MUL_F(transf_buf[nlong+i],window_long[nlong-1-i]); + time_out[nlong+i+1] = MUL_F(transf_buf[nlong+i+1],window_long[nlong-2-i]); + time_out[nlong+i+2] = MUL_F(transf_buf[nlong+i+2],window_long[nlong-3-i]); + time_out[nlong+i+3] = MUL_F(transf_buf[nlong+i+3],window_long[nlong-4-i]); } break; case LONG_START_SEQUENCE: - imdct(fb, freq_in, transf_buf, 2*nlong); - for (i = 0; i < nlong; i++) - time_out[i] = time_out[nlong+i] + MUL_R_C(transf_buf[i],window_long_prev[i]); + imdct_long(fb, freq_in, transf_buf, 2*nlong); + for (i = 0; i < nlong; i+=4) + { + time_out[i] = time_out[nlong+i] + MUL_F(transf_buf[i],window_long_prev[i]); + time_out[i+1] = time_out[nlong+i+1] + MUL_F(transf_buf[i+1],window_long_prev[i+1]); + time_out[i+2] = time_out[nlong+i+2] + MUL_F(transf_buf[i+2],window_long_prev[i+2]); + time_out[i+3] = time_out[nlong+i+3] + MUL_F(transf_buf[i+3],window_long_prev[i+3]); + } for (i = 0; i < nflat_ls; i++) time_out[nlong+i] = transf_buf[nlong+i]; for (i = 0; i < nshort; i++) - time_out[nlong+nflat_ls+i] = MUL_R_C(transf_buf[nlong+nflat_ls+i],window_short[nshort-i-1]); + time_out[nlong+nflat_ls+i] = MUL_F(transf_buf[nlong+nflat_ls+i],window_short[nshort-i-1]); for (i = 0; i < nflat_ls; i++) time_out[nlong+nflat_ls+nshort+i] = 0; break; case EIGHT_SHORT_SEQUENCE: - imdct(fb, freq_in+0*nshort, transf_buf+2*nshort*0, 2*nshort); - imdct(fb, freq_in+1*nshort, transf_buf+2*nshort*1, 2*nshort); - imdct(fb, freq_in+2*nshort, transf_buf+2*nshort*2, 2*nshort); - imdct(fb, freq_in+3*nshort, transf_buf+2*nshort*3, 2*nshort); - imdct(fb, freq_in+4*nshort, transf_buf+2*nshort*4, 2*nshort); - imdct(fb, freq_in+5*nshort, transf_buf+2*nshort*5, 2*nshort); - imdct(fb, freq_in+6*nshort, transf_buf+2*nshort*6, 2*nshort); - imdct(fb, freq_in+7*nshort, transf_buf+2*nshort*7, 2*nshort); + faad_imdct(fb->mdct256, freq_in+0*nshort, transf_buf+2*nshort*0); + faad_imdct(fb->mdct256, freq_in+1*nshort, transf_buf+2*nshort*1); + faad_imdct(fb->mdct256, freq_in+2*nshort, transf_buf+2*nshort*2); + faad_imdct(fb->mdct256, freq_in+3*nshort, transf_buf+2*nshort*3); + faad_imdct(fb->mdct256, freq_in+4*nshort, transf_buf+2*nshort*4); + faad_imdct(fb->mdct256, freq_in+5*nshort, transf_buf+2*nshort*5); + faad_imdct(fb->mdct256, freq_in+6*nshort, transf_buf+2*nshort*6); + faad_imdct(fb->mdct256, freq_in+7*nshort, transf_buf+2*nshort*7); for (i = 0; i < nflat_ls; i++) time_out[i] = time_out[nlong+i]; - for(i = nshort-1; i >= 0; i--) + for(i = 0; i < nshort; i++) { - time_out[nflat_ls+ i] = time_out[nlong+nflat_ls+ i] + MUL_R_C(transf_buf[nshort*0+i],window_short_prev[i]); - time_out[nflat_ls+1*nshort+i] = time_out[nlong+nflat_ls+nshort*1+i] + MUL_R_C(transf_buf[nshort*1+i],window_short[nshort-1-i]) + MUL_R_C(transf_buf[nshort*2+i],window_short[i]); - time_out[nflat_ls+2*nshort+i] = time_out[nlong+nflat_ls+nshort*2+i] + MUL_R_C(transf_buf[nshort*3+i],window_short[nshort-1-i]) + MUL_R_C(transf_buf[nshort*4+i],window_short[i]); - time_out[nflat_ls+3*nshort+i] = time_out[nlong+nflat_ls+nshort*3+i] + MUL_R_C(transf_buf[nshort*5+i],window_short[nshort-1-i]) + MUL_R_C(transf_buf[nshort*6+i],window_short[i]); + time_out[nflat_ls+ i] = time_out[nlong+nflat_ls+ i] + MUL_F(transf_buf[nshort*0+i],window_short_prev[i]); + time_out[nflat_ls+1*nshort+i] = time_out[nlong+nflat_ls+nshort*1+i] + MUL_F(transf_buf[nshort*1+i],window_short[nshort-1-i]) + MUL_F(transf_buf[nshort*2+i],window_short[i]); + time_out[nflat_ls+2*nshort+i] = time_out[nlong+nflat_ls+nshort*2+i] + MUL_F(transf_buf[nshort*3+i],window_short[nshort-1-i]) + MUL_F(transf_buf[nshort*4+i],window_short[i]); + time_out[nflat_ls+3*nshort+i] = time_out[nlong+nflat_ls+nshort*3+i] + MUL_F(transf_buf[nshort*5+i],window_short[nshort-1-i]) + MUL_F(transf_buf[nshort*6+i],window_short[i]); if (i < trans) - time_out[nflat_ls+4*nshort+i] = time_out[nlong+nflat_ls+nshort*4+i] + MUL_R_C(transf_buf[nshort*7+i],window_short[nshort-1-i]) + MUL_R_C(transf_buf[nshort*8+i],window_short[i]); + time_out[nflat_ls+4*nshort+i] = time_out[nlong+nflat_ls+nshort*4+i] + MUL_F(transf_buf[nshort*7+i],window_short[nshort-1-i]) + MUL_F(transf_buf[nshort*8+i],window_short[i]); else - time_out[nflat_ls+4*nshort+i] = MUL_R_C(transf_buf[nshort*7+i],window_short[nshort-1-i]) + MUL_R_C(transf_buf[nshort*8+i],window_short[i]); - time_out[nflat_ls+5*nshort+i] = MUL_R_C(transf_buf[nshort*9+i],window_short[nshort-1-i]) + MUL_R_C(transf_buf[nshort*10+i],window_short[i]); - time_out[nflat_ls+6*nshort+i] = MUL_R_C(transf_buf[nshort*11+i],window_short[nshort-1-i]) + MUL_R_C(transf_buf[nshort*12+i],window_short[i]); - time_out[nflat_ls+7*nshort+i] = MUL_R_C(transf_buf[nshort*13+i],window_short[nshort-1-i]) + MUL_R_C(transf_buf[nshort*14+i],window_short[i]); - time_out[nflat_ls+8*nshort+i] = MUL_R_C(transf_buf[nshort*15+i],window_short[nshort-1-i]); + time_out[nflat_ls+4*nshort+i] = MUL_F(transf_buf[nshort*7+i],window_short[nshort-1-i]) + MUL_F(transf_buf[nshort*8+i],window_short[i]); + time_out[nflat_ls+5*nshort+i] = MUL_F(transf_buf[nshort*9+i],window_short[nshort-1-i]) + MUL_F(transf_buf[nshort*10+i],window_short[i]); + time_out[nflat_ls+6*nshort+i] = MUL_F(transf_buf[nshort*11+i],window_short[nshort-1-i]) + MUL_F(transf_buf[nshort*12+i],window_short[i]); + time_out[nflat_ls+7*nshort+i] = MUL_F(transf_buf[nshort*13+i],window_short[nshort-1-i]) + MUL_F(transf_buf[nshort*14+i],window_short[i]); + time_out[nflat_ls+8*nshort+i] = MUL_F(transf_buf[nshort*15+i],window_short[nshort-1-i]); } for (i = 0; i < nflat_ls; i++) time_out[nlong+nflat_ls+nshort+i] = 0; break; case LONG_STOP_SEQUENCE: - imdct(fb, freq_in, transf_buf, 2*nlong); + imdct_long(fb, freq_in, transf_buf, 2*nlong); for (i = 0; i < nflat_ls; i++) time_out[i] = time_out[nlong+i]; for (i = 0; i < nshort; i++) - time_out[nflat_ls+i] = time_out[nlong+nflat_ls+i] + MUL_R_C(transf_buf[nflat_ls+i],window_short_prev[i]); + time_out[nflat_ls+i] = time_out[nlong+nflat_ls+i] + MUL_F(transf_buf[nflat_ls+i],window_short_prev[i]); for (i = 0; i < nflat_ls; i++) time_out[nflat_ls+nshort+i] = time_out[nlong+nflat_ls+nshort+i] + transf_buf[nflat_ls+nshort+i]; for (i = 0; i < nlong; i++) - time_out[nlong+i] = MUL_R_C(transf_buf[nlong+i],window_long[nlong-1-i]); + time_out[nlong+i] = MUL_F(transf_buf[nlong+i],window_long[nlong-1-i]); break; } - free(transf_buf); +#ifdef PROFILE + count = faad_get_ts() - count; + fb->cycles += count; +#endif } +#ifdef USE_SSE +void ifilter_bank_sse(fb_info *fb, uint8_t window_sequence, uint8_t window_shape, + uint8_t window_shape_prev, real_t *freq_in, + real_t *time_out, uint8_t object_type, uint16_t frame_len) +{ + int16_t i; + ALIGN real_t transf_buf[2*1024] = {0}; + + const real_t *window_long; + const real_t *window_long_prev; + const real_t *window_short; + const real_t *window_short_prev; + + uint16_t nlong = frame_len; + uint16_t nshort = frame_len/8; + uint16_t trans = nshort/2; + + uint16_t nflat_ls = (nlong-nshort)/2; + +#ifdef PROFILE + int64_t count = faad_get_ts(); +#endif + +#ifdef LD_DEC + if (object_type == LD) + { + window_long = fb->ld_window[window_shape]; + window_long_prev = fb->ld_window[window_shape_prev]; + } else { +#endif + window_long = fb->long_window[window_shape]; + window_long_prev = fb->long_window[window_shape_prev]; + window_short = fb->short_window[window_shape]; + window_short_prev = fb->short_window[window_shape_prev]; +#ifdef LD_DEC + } +#endif + + switch (window_sequence) + { + case ONLY_LONG_SEQUENCE: + imdct_long_sse(fb, freq_in, transf_buf, 2*nlong); + for (i = 0; i < nlong; i+=4) + { + __m128 m1 = _mm_load_ps(&transf_buf[i]); + __m128 m2 = _mm_load_ps(&window_long_prev[i]); + __m128 m3 = _mm_load_ps(&time_out[nlong+i]); + + __m128 m4 = _mm_mul_ps(m1, m2); + m4 = _mm_add_ps(m4, m3); + + _mm_store_ps(&time_out[i], m4); + } + for (i = 0; i < nlong; i+=4) + { + __m128 m1 = _mm_load_ps(&transf_buf[nlong+i]); + __m128 m2 = _mm_load_ps(&window_long[nlong-4-i]); + __m128 m3, m4; + + m3 = _mm_shuffle_ps(m2, m2, _MM_SHUFFLE(0, 1, 2, 3)); + + m4 = _mm_mul_ps(m1, m3); + + _mm_store_ps(&time_out[nlong+i], m4); + } + break; + + case LONG_START_SEQUENCE: + imdct_long_sse(fb, freq_in, transf_buf, 2*nlong); + for (i = 0; i < nlong; i+=4) + { + __m128 m1 = _mm_load_ps(&transf_buf[i]); + __m128 m2 = _mm_load_ps(&window_long_prev[i]); + __m128 m3 = _mm_load_ps(&time_out[nlong+i]); + + __m128 m4 = _mm_mul_ps(m1, m2); + m4 = _mm_add_ps(m4, m3); + + _mm_store_ps(&time_out[i], m4); + } + for (i = 0; i < nflat_ls; i+=4) + { + __m128 m1 = _mm_load_ps(&transf_buf[nlong+i]); + _mm_store_ps(&time_out[nlong+i], m1); + } + for (i = 0; i < nshort; i+=4) + { + __m128 m1 = _mm_load_ps(&transf_buf[nlong+nflat_ls+i]); + __m128 m2 = _mm_load_ps(&window_short[nshort-4-i]); + __m128 m3, m4; + + m3 = _mm_shuffle_ps(m2, m2, _MM_SHUFFLE(0, 1, 2, 3)); + + m4 = _mm_mul_ps(m1, m3); + + _mm_store_ps(&time_out[nlong+nflat_ls+i], m4); + } + for (i = 0; i < nflat_ls; i+=4) + { + __m128 m1 = _mm_setzero_ps(); + _mm_store_ps(&time_out[nlong+nflat_ls+nshort+i], m1); + } + break; + + case EIGHT_SHORT_SEQUENCE: + faad_imdct_sse(fb->mdct256, freq_in+0*nshort, transf_buf+2*nshort*0); + faad_imdct_sse(fb->mdct256, freq_in+1*nshort, transf_buf+2*nshort*1); + faad_imdct_sse(fb->mdct256, freq_in+2*nshort, transf_buf+2*nshort*2); + faad_imdct_sse(fb->mdct256, freq_in+3*nshort, transf_buf+2*nshort*3); + faad_imdct_sse(fb->mdct256, freq_in+4*nshort, transf_buf+2*nshort*4); + faad_imdct_sse(fb->mdct256, freq_in+5*nshort, transf_buf+2*nshort*5); + faad_imdct_sse(fb->mdct256, freq_in+6*nshort, transf_buf+2*nshort*6); + faad_imdct_sse(fb->mdct256, freq_in+7*nshort, transf_buf+2*nshort*7); + for (i = 0; i < nflat_ls; i+=4) + { + __m128 m1 = _mm_load_ps(&time_out[nlong+i]); + _mm_store_ps(&time_out[i], m1); + } + for (i = 0; i < nshort; i+=4) + { + __m128 m1 = _mm_load_ps(&transf_buf[nshort*0+i]); + __m128 m2 = _mm_load_ps(&window_short_prev[i]); + __m128 m3 = _mm_load_ps(&time_out[nlong+nflat_ls+i]); + + __m128 m4 = _mm_mul_ps(m1, m2); + m4 = _mm_add_ps(m4, m3); + + _mm_store_ps(&time_out[nflat_ls+i], m4); + } + for (i = 0; i < nshort; i+=4) + { + __m128 m1, m2, m3, m4, m5, m6, m7, m8; + m1 = _mm_load_ps(&transf_buf[nshort*1+i]); + m2 = _mm_load_ps(&window_short[nshort-4-i]); + m3 = _mm_load_ps(&time_out[nlong+nflat_ls+nshort*1+i]); + m6 = _mm_load_ps(&transf_buf[nshort*2+i]); + m7 = _mm_load_ps(&window_short[i]); + + m5 = _mm_shuffle_ps(m2, m2, _MM_SHUFFLE(0, 1, 2, 3)); + + m4 = _mm_mul_ps(m1, m5); + m8 = _mm_mul_ps(m6, m7); + m4 = _mm_add_ps(m4, m3); + m4 = _mm_add_ps(m4, m8); + + _mm_store_ps(&time_out[nflat_ls+1*nshort+i], m4); + } + for (i = 0; i < nshort; i+=4) + { + __m128 m1, m2, m3, m4, m5, m6, m7, m8; + m1 = _mm_load_ps(&transf_buf[nshort*3+i]); + m2 = _mm_load_ps(&window_short[nshort-4-i]); + m3 = _mm_load_ps(&time_out[nlong+nflat_ls+nshort*2+i]); + m6 = _mm_load_ps(&transf_buf[nshort*4+i]); + m7 = _mm_load_ps(&window_short[i]); + + m5 = _mm_shuffle_ps(m2, m2, _MM_SHUFFLE(0, 1, 2, 3)); + + m4 = _mm_mul_ps(m1, m5); + m8 = _mm_mul_ps(m6, m7); + m4 = _mm_add_ps(m4, m3); + m4 = _mm_add_ps(m4, m8); + + _mm_store_ps(&time_out[nflat_ls+2*nshort+i], m4); + } + for (i = 0; i < nshort; i+=4) + { + __m128 m1, m2, m3, m4, m5, m6, m7, m8; + m1 = _mm_load_ps(&transf_buf[nshort*5+i]); + m2 = _mm_load_ps(&window_short[nshort-4-i]); + m3 = _mm_load_ps(&time_out[nlong+nflat_ls+nshort*3+i]); + m6 = _mm_load_ps(&transf_buf[nshort*6+i]); + m7 = _mm_load_ps(&window_short[i]); + + m5 = _mm_shuffle_ps(m2, m2, _MM_SHUFFLE(0, 1, 2, 3)); + + m4 = _mm_mul_ps(m1, m5); + m8 = _mm_mul_ps(m6, m7); + m4 = _mm_add_ps(m4, m3); + m4 = _mm_add_ps(m4, m8); + + _mm_store_ps(&time_out[nflat_ls+3*nshort+i], m4); + } + for(i = 0; i < trans; i+=4) + { + __m128 m1, m2, m3, m4, m5, m6, m7, m8; + m1 = _mm_load_ps(&transf_buf[nshort*7+i]); + m2 = _mm_load_ps(&window_short[nshort-4-i]); + m3 = _mm_load_ps(&time_out[nlong+nflat_ls+nshort*4+i]); + m6 = _mm_load_ps(&transf_buf[nshort*8+i]); + m7 = _mm_load_ps(&window_short[i]); + + m5 = _mm_shuffle_ps(m2, m2, _MM_SHUFFLE(0, 1, 2, 3)); + + m4 = _mm_mul_ps(m1, m5); + m8 = _mm_mul_ps(m6, m7); + m4 = _mm_add_ps(m4, m3); + m4 = _mm_add_ps(m4, m8); + + _mm_store_ps(&time_out[nflat_ls+4*nshort+i], m4); + } + for (i = trans; i < nshort; i+=4) + { + __m128 m1, m2, m3, m4, m5, m6, m7, m8; + m1 = _mm_load_ps(&transf_buf[nshort*7+i]); + m2 = _mm_load_ps(&window_short[nshort-4-i]); + m6 = _mm_load_ps(&transf_buf[nshort*8+i]); + m7 = _mm_load_ps(&window_short[i]); + + m5 = _mm_shuffle_ps(m2, m2, _MM_SHUFFLE(0, 1, 2, 3)); + + m4 = _mm_mul_ps(m1, m5); + m8 = _mm_mul_ps(m6, m7); + m3 = _mm_add_ps(m4, m8); + + _mm_store_ps(&time_out[nflat_ls+4*nshort+i], m3); + } + for (i = 0; i < nshort; i+=4) + { + __m128 m1, m2, m3, m4, m5, m6, m7, m8; + m1 = _mm_load_ps(&transf_buf[nshort*9+i]); + m2 = _mm_load_ps(&window_short[nshort-4-i]); + m6 = _mm_load_ps(&transf_buf[nshort*10+i]); + m7 = _mm_load_ps(&window_short[i]); + + m5 = _mm_shuffle_ps(m2, m2, _MM_SHUFFLE(0, 1, 2, 3)); + + m4 = _mm_mul_ps(m1, m5); + m8 = _mm_mul_ps(m6, m7); + m3 = _mm_add_ps(m4, m8); + + _mm_store_ps(&time_out[nflat_ls+5*nshort+i], m3); + } + for (i = 0; i < nshort; i+=4) + { + __m128 m1, m2, m3, m4, m5, m6, m7, m8; + m1 = _mm_load_ps(&transf_buf[nshort*11+i]); + m2 = _mm_load_ps(&window_short[nshort-4-i]); + m6 = _mm_load_ps(&transf_buf[nshort*12+i]); + m7 = _mm_load_ps(&window_short[i]); + + m5 = _mm_shuffle_ps(m2, m2, _MM_SHUFFLE(0, 1, 2, 3)); + + m4 = _mm_mul_ps(m1, m5); + m8 = _mm_mul_ps(m6, m7); + m3 = _mm_add_ps(m4, m8); + + _mm_store_ps(&time_out[nflat_ls+6*nshort+i], m3); + } + for (i = 0; i < nshort; i+=4) + { + __m128 m1, m2, m3, m4, m5, m6, m7, m8; + m1 = _mm_load_ps(&transf_buf[nshort*13+i]); + m2 = _mm_load_ps(&window_short[nshort-4-i]); + m6 = _mm_load_ps(&transf_buf[nshort*14+i]); + m7 = _mm_load_ps(&window_short[i]); + + m5 = _mm_shuffle_ps(m2, m2, _MM_SHUFFLE(0, 1, 2, 3)); + + m4 = _mm_mul_ps(m1, m5); + m8 = _mm_mul_ps(m6, m7); + m3 = _mm_add_ps(m4, m8); + + _mm_store_ps(&time_out[nflat_ls+7*nshort+i], m3); + } + for (i = 0; i < nshort; i+=4) + { + __m128 m1, m2, m3, m5; + m1 = _mm_load_ps(&transf_buf[nshort*15+i]); + m2 = _mm_load_ps(&window_short[nshort-4-i]); + + m5 = _mm_shuffle_ps(m2, m2, _MM_SHUFFLE(0, 1, 2, 3)); + + m3 = _mm_mul_ps(m1, m5); + + _mm_store_ps(&time_out[nflat_ls+8*nshort+i], m3); + } + for (i = 0; i < nflat_ls; i+=4) + { + __m128 m1 = _mm_setzero_ps(); + _mm_store_ps(&time_out[nlong+nflat_ls+nshort+i], m1); + } + break; + + case LONG_STOP_SEQUENCE: + imdct_long_sse(fb, freq_in, transf_buf, 2*nlong); + for (i = 0; i < nflat_ls; i+=4) + { + __m128 m1 = _mm_load_ps(&time_out[nlong+i]); + _mm_store_ps(&time_out[i], m1); + } + for (i = 0; i < nshort; i+=4) + { + __m128 m1 = _mm_load_ps(&transf_buf[nflat_ls+i]); + __m128 m2 = _mm_load_ps(&window_short_prev[i]); + __m128 m3 = _mm_load_ps(&time_out[nlong+nflat_ls+i]); + + __m128 m4 = _mm_mul_ps(m1, m2); + m4 = _mm_add_ps(m4, m3); + + _mm_store_ps(&time_out[nflat_ls+i], m4); + } + for (i = 0; i < nflat_ls; i+=4) + { + __m128 m1 = _mm_load_ps(&transf_buf[nflat_ls+nshort+i]); + __m128 m2 = _mm_load_ps(&time_out[nlong+nflat_ls+nshort+i]); + + __m128 m3 = _mm_add_ps(m1, m2); + + _mm_store_ps(&time_out[nflat_ls+nshort+i], m3); + } + for (i = 0; i < nlong; i+=4) + { + __m128 m1 = _mm_load_ps(&transf_buf[nlong+i]); + __m128 m2 = _mm_load_ps(&window_long[nlong-4-i]); + __m128 m3, m4; + + m3 = _mm_shuffle_ps(m2, m2, _MM_SHUFFLE(0, 1, 2, 3)); + + m4 = _mm_mul_ps(m1, m3); + + _mm_store_ps(&time_out[nlong+i], m4); + } + break; + } + +#ifdef PROFILE + count = faad_get_ts() - count; + fb->cycles += count; +#endif +} +#endif + #ifdef LTP_DEC /* only works for LTP -> no overlapping, no short blocks */ void filter_bank_ltp(fb_info *fb, uint8_t window_sequence, uint8_t window_shape, @@ -257,12 +655,12 @@ void filter_bank_ltp(fb_info *fb, uint8_t window_sequence, uint8_t window_shape, uint8_t object_type, uint16_t frame_len) { int16_t i; - real_t *windowed_buf; + ALIGN real_t windowed_buf[2*1024] = {0}; - real_t *window_long; - real_t *window_long_prev; - real_t *window_short; - real_t *window_short_prev; + const real_t *window_long; + const real_t *window_long_prev; + const real_t *window_short; + const real_t *window_short_prev; uint16_t nlong = frame_len; uint16_t nshort = frame_len/8; @@ -270,8 +668,6 @@ void filter_bank_ltp(fb_info *fb, uint8_t window_sequence, uint8_t window_shape, assert(window_sequence != EIGHT_SHORT_SEQUENCE); - windowed_buf = (real_t*)malloc(nlong*2*sizeof(real_t)); - #ifdef LD_DEC if (object_type == LD) { @@ -292,19 +688,19 @@ void filter_bank_ltp(fb_info *fb, uint8_t window_sequence, uint8_t window_shape, case ONLY_LONG_SEQUENCE: for (i = nlong-1; i >= 0; i--) { - windowed_buf[i] = MUL_R_C(in_data[i], window_long_prev[i]); - windowed_buf[i+nlong] = MUL_R_C(in_data[i+nlong], window_long[nlong-1-i]); + windowed_buf[i] = MUL_F(in_data[i], window_long_prev[i]); + windowed_buf[i+nlong] = MUL_F(in_data[i+nlong], window_long[nlong-1-i]); } mdct(fb, windowed_buf, out_mdct, 2*nlong); break; case LONG_START_SEQUENCE: for (i = 0; i < nlong; i++) - windowed_buf[i] = MUL_R_C(in_data[i], window_long_prev[i]); + windowed_buf[i] = MUL_F(in_data[i], window_long_prev[i]); for (i = 0; i < nflat_ls; i++) windowed_buf[i+nlong] = in_data[i+nlong]; for (i = 0; i < nshort; i++) - windowed_buf[i+nlong+nflat_ls] = MUL_R_C(in_data[i+nlong+nflat_ls], window_short[nshort-1-i]); + windowed_buf[i+nlong+nflat_ls] = MUL_F(in_data[i+nlong+nflat_ls], window_short[nshort-1-i]); for (i = 0; i < nflat_ls; i++) windowed_buf[i+nlong+nflat_ls+nshort] = 0; mdct(fb, windowed_buf, out_mdct, 2*nlong); @@ -314,15 +710,13 @@ void filter_bank_ltp(fb_info *fb, uint8_t window_sequence, uint8_t window_shape, for (i = 0; i < nflat_ls; i++) windowed_buf[i] = 0; for (i = 0; i < nshort; i++) - windowed_buf[i+nflat_ls] = MUL_R_C(in_data[i+nflat_ls], window_short_prev[i]); + windowed_buf[i+nflat_ls] = MUL_F(in_data[i+nflat_ls], window_short_prev[i]); for (i = 0; i < nflat_ls; i++) windowed_buf[i+nflat_ls+nshort] = in_data[i+nflat_ls+nshort]; for (i = 0; i < nlong; i++) - windowed_buf[i+nlong] = MUL_R_C(in_data[i+nlong], window_long[nlong-1-i]); + windowed_buf[i+nlong] = MUL_F(in_data[i+nlong], window_long[nlong-1-i]); mdct(fb, windowed_buf, out_mdct, 2*nlong); break; } - - free(windowed_buf); } #endif diff --git a/src/libfaad/filtbank.h b/src/libfaad/filtbank.h index 96025d55b..60e25e840 100644 --- a/src/libfaad/filtbank.h +++ b/src/libfaad/filtbank.h @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: filtbank.h,v 1.2 2002/12/16 19:00:04 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: filtbank.h,v 1.3 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #ifndef __FILTBANK_H__ @@ -26,7 +32,6 @@ extern "C" { #endif -#include "mdct.h" fb_info *filter_bank_init(uint16_t frame_len); void filter_bank_end(fb_info *fb); @@ -50,6 +55,11 @@ void ifilter_bank(fb_info *fb, real_t *time_out, uint8_t object_type, uint16_t frame_len); +#ifdef USE_SSE +void ifilter_bank_sse(fb_info *fb, uint8_t window_sequence, uint8_t window_shape, + uint8_t window_shape_prev, real_t *freq_in, + real_t *time_out, uint8_t object_type, uint16_t frame_len); +#endif #ifdef __cplusplus } diff --git a/src/libfaad/fixed.h b/src/libfaad/fixed.h index 5fae855ab..65897d166 100644 --- a/src/libfaad/fixed.h +++ b/src/libfaad/fixed.h @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: fixed.h,v 1.2 2003/04/12 14:58:47 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: fixed.h,v 1.3 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #ifndef __FIXED_H__ @@ -26,23 +32,32 @@ extern "C" { #endif +#ifdef _WIN32_WCE +#include <cmnintrin.h> +#endif #define COEF_BITS 28 #define COEF_PRECISION (1 << COEF_BITS) -#define REAL_BITS 7 +#define REAL_BITS 14 // MAXIMUM OF 14 FOR FIXED POINT SBR #define REAL_PRECISION (1 << REAL_BITS) +/* FRAC is the fractional only part of the fixed point number [0.0..1.0) */ +#define FRAC_SIZE 32 /* frac is a 32 bit integer */ +#define FRAC_BITS 31 +#define FRAC_PRECISION ((uint32_t)(1 << FRAC_BITS)) +#define FRAC_MAX 0x7FFFFFFF typedef int32_t real_t; -#define REAL_CONST(A) ((real_t)(A*(REAL_PRECISION))) -#define COEF_CONST(A) ((real_t)(A*(COEF_PRECISION))) +#define REAL_CONST(A) (((A) >= 0) ? ((real_t)((A)*(REAL_PRECISION)+0.5)) : ((real_t)((A)*(REAL_PRECISION)-0.5))) +#define COEF_CONST(A) (((A) >= 0) ? ((real_t)((A)*(COEF_PRECISION)+0.5)) : ((real_t)((A)*(COEF_PRECISION)-0.5))) +#define FRAC_CONST(A) (((A) == 1.00) ? ((real_t)FRAC_MAX) : (((A) >= 0) ? ((real_t)((A)*(FRAC_PRECISION)+0.5)) : ((real_t)((A)*(FRAC_PRECISION)-0.5)))) #if defined(_WIN32) && !defined(_WIN32_WCE) -/* multiply real with real */ -static INLINE MUL(real_t A, real_t B) +/* multiply with real shift */ +static INLINE real_t MUL_R(real_t A, real_t B) { _asm { mov eax,A @@ -51,8 +66,8 @@ static INLINE MUL(real_t A, real_t B) } } -/* multiply coef with coef */ -static INLINE MUL_C_C(real_t A, real_t B) +/* multiply with coef shift */ +static INLINE real_t MUL_C(real_t A, real_t B) { _asm { mov eax,A @@ -61,60 +76,120 @@ static INLINE MUL_C_C(real_t A, real_t B) } } -/* multiply real with coef */ -static INLINE MUL_R_C(real_t A, real_t B) +static INLINE real_t _MulHigh(real_t A, real_t B) { _asm { mov eax,A imul B - shrd eax,edx,COEF_BITS + mov eax,edx } } +/* multiply with fractional shift */ +static INLINE real_t MUL_F(real_t A, real_t B) +{ + return _MulHigh(A,B) << (FRAC_SIZE-FRAC_BITS); +} + +/* Complex multiplication */ +static INLINE void ComplexMult(real_t *y1, real_t *y2, + real_t x1, real_t x2, real_t c1, real_t c2) +{ + *y1 = (_MulHigh(x1, c1) + _MulHigh(x2, c2))<<(FRAC_SIZE-FRAC_BITS); + *y2 = (_MulHigh(x2, c1) - _MulHigh(x1, c2))<<(FRAC_SIZE-FRAC_BITS); +} + #elif defined(__GNUC__) && defined (__arm__) /* taken from MAD */ #define arm_mul(x, y, SCALEBITS) \ - ({ uint32_t __hi; \ - uint32_t __lo; \ - uint32_t __result; \ - asm ("smull %0, %1, %3, %4\n\t" \ - "movs %0, %0, lsr %5\n\t" \ - "adc %2, %0, %1, lsl %6" \ - : "=&r" (__lo), "=&r" (__hi), "=r" (__result) \ - : "%r" (x), "r" (y), \ - "M" (SCALEBITS), "M" (32 - (SCALEBITS)) \ - : "cc"); \ - __result; \ - }) - -static INLINE real_t MUL(real_t A, real_t B) +({ \ + uint32_t __hi; \ + uint32_t __lo; \ + uint32_t __result; \ + asm("smull %0, %1, %3, %4\n\t" \ + "movs %0, %0, lsr %5\n\t" \ + "adc %2, %0, %1, lsl %6" \ + : "=&r" (__lo), "=&r" (__hi), "=r" (__result) \ + : "%r" (x), "r" (y), \ + "M" (SCALEBITS), "M" (32 - (SCALEBITS)) \ + : "cc"); \ + __result; \ +}) + +static INLINE real_t MUL_R(real_t A, real_t B) +{ + return arm_mul(A, B, REAL_BITS); +} + +static INLINE real_t MUL_C(real_t A, real_t B) +{ + return arm_mul(A, B, COEF_BITS); +} + +static INLINE real_t _MulHigh(real_t x, real_t y) { - return arm_mul( A, B, REAL_BITS); + uint32_t __lo; + uint32_t __hi; + asm("smull\t%0, %1, %2, %3" + : "=&r"(__lo),"=&r"(__hi) + : "%r"(x),"r"(y) + : "cc"); + return __hi; } -static INLINE real_t MUL_C_C(real_t A, real_t B) +static INLINE real_t MUL_F(real_t A, real_t B) { - return arm_mul( A, B, COEF_BITS); + return _MulHigh(A, B) << (FRAC_SIZE-FRAC_BITS); } -static INLINE real_t MUL_R_C(real_t A, real_t B) +/* Complex multiplication */ +static INLINE void ComplexMult(real_t *y1, real_t *y2, + real_t x1, real_t x2, real_t c1, real_t c2) { - return arm_mul( A, B, COEF_BITS); + int32_t tmp, yt1, yt2; + asm("smull %0, %1, %4, %6\n\t" + "smlal %0, %1, %5, %7\n\t" + "rsb %3, %4, #0\n\t" + "smull %0, %2, %5, %6\n\t" + "smlal %0, %2, %3, %7" + : "=&r" (tmp), "=&r" (yt1), "=&r" (yt2), "=r" (x1) + : "3" (x1), "r" (x2), "r" (c1), "r" (c2) + : "cc" ); + *y1 = yt1 << (FRAC_SIZE-FRAC_BITS); + *y2 = yt2 << (FRAC_SIZE-FRAC_BITS); } #else - /* multiply real with real */ - #define MUL(A,B) (real_t)(((int64_t)(A)*(int64_t)(B)+(1 << (REAL_BITS-1))) >> REAL_BITS) - /* multiply coef with coef */ - #define MUL_C_C(A,B) (real_t)(((int64_t)(A)*(int64_t)(B)+(1 << (COEF_BITS-1))) >> COEF_BITS) - /* multiply real with coef */ - #define MUL_R_C(A,B) (real_t)(((int64_t)(A)*(int64_t)(B)+(1 << (COEF_BITS-1))) >> COEF_BITS) + /* multiply with real shift */ + #define MUL_R(A,B) (real_t)(((int64_t)(A)*(int64_t)(B)+(1 << (REAL_BITS-1))) >> REAL_BITS) + /* multiply with coef shift */ + #define MUL_C(A,B) (real_t)(((int64_t)(A)*(int64_t)(B)+(1 << (COEF_BITS-1))) >> COEF_BITS) + /* multiply with fractional shift */ +#ifndef _WIN32_WCE + #define _MulHigh(A,B) (real_t)(((int64_t)(A)*(int64_t)(B)+(1 << (FRAC_SIZE-1))) >> FRAC_SIZE) + #define MUL_F(A,B) (real_t)(((int64_t)(A)*(int64_t)(B)+(1 << (FRAC_BITS-1))) >> FRAC_BITS) +#else + /* eVC for PocketPC has an intrinsic function that returns only the high 32 bits of a 32x32 bit multiply */ + static INLINE real_t MUL_F(real_t A, real_t B) + { + return _MulHigh(A,B) << (32-FRAC_BITS); + } +#endif + +/* Complex multiplication */ +static INLINE void ComplexMult(real_t *y1, real_t *y2, + real_t x1, real_t x2, real_t c1, real_t c2) +{ + *y1 = (_MulHigh(x1, c1) + _MulHigh(x2, c2))<<(FRAC_SIZE-FRAC_BITS); + *y2 = (_MulHigh(x2, c1) - _MulHigh(x1, c2))<<(FRAC_SIZE-FRAC_BITS); +} #endif + #ifdef __cplusplus } #endif diff --git a/src/libfaad/hcr.c b/src/libfaad/hcr.c index aa282f32d..4b59e205b 100644 --- a/src/libfaad/hcr.c +++ b/src/libfaad/hcr.c @@ -1,5 +1,5 @@ /* -** FAAD - Freeware Advanced Audio Decoder +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding ** Copyright (C) 2002 A. Kurpiers ** ** This program is free software; you can redistribute it and/or modify @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: hcr.c,v 1.2 2003/04/12 14:58:47 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: hcr.c,v 1.3 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #include "common.h" @@ -28,256 +34,15 @@ #include "syntax.h" #include "specrec.h" #include "bits.h" -#include "data.h" #include "pulse.h" #include "analysis.h" #include "bits.h" -#include "codebook/hcb.h" +#include "huffman.h" /* Implements the HCR11 tool as described in ISO/IEC 14496-3/Amd.1, 8.5.3.3 */ #ifdef ERROR_RESILIENCE -//FIXME these tables are not needed twice actually - -static hcb *hcb_table[] = { - 0, hcb1_1, hcb2_1, 0, hcb4_1, 0, hcb6_1, 0, hcb8_1, 0, hcb10_1, hcb11_1 -}; - -static hcb_2_quad *hcb_2_quad_table[] = { - 0, hcb1_2, hcb2_2, 0, hcb4_2, 0, 0, 0, 0, 0, 0, 0 -}; - -static hcb_2_pair *hcb_2_pair_table[] = { - 0, 0, 0, 0, 0, 0, hcb6_2, 0, hcb8_2, 0, hcb10_2, hcb11_2 -}; - -static hcb_bin_pair *hcb_bin_table[] = { - 0, 0, 0, 0, 0, hcb5, 0, hcb7, 0, hcb9, 0, 0 -}; - -static uint8_t hcbN[] = { 0, 5, 5, 0, 5, 0, 5, 0, 5, 0, 6, 5 }; - - -/* defines whether a huffman codebook is unsigned or not */ -/* Table 4.6.2 */ -static uint8_t unsigned_cb[] = { 0, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, - /* codebook 16 to 31 */ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 -}; -typedef struct -{ - /* bit input */ - uint32_t bufa; - uint32_t bufb; - int8_t len; -} bits_t; - - -static INLINE uint32_t showbits(bits_t *ld, uint8_t bits) -{ - if (bits == 0) return 0; - if (ld->len <= 32){ - /* huffman_spectral_data_2 needs to read more than may be available, bits maybe - > ld->len, deliver 0 than */ - if (ld->len >= bits) - return ((ld->bufa >> (ld->len - bits)) & (0xFFFFFFFF >> (32 - bits))); - else - return ((ld->bufa << (bits - ld->len)) & (0xFFFFFFFF >> (32 - bits))); - } else { - if ((ld->len - bits) < 32) - { - return ( (ld->bufb & (0xFFFFFFFF >> (64 - ld->len))) << (bits - ld->len + 32)) | - (ld->bufa >> (ld->len - bits)); - } else { - return ((ld->bufb >> (ld->len - bits - 32)) & (0xFFFFFFFF >> (32 - bits))); - } - } -} - -/* return 1 if position is outside of buffer, 0 otherwise */ -static INLINE int8_t flushbits( bits_t *ld, uint8_t bits) -{ - ld->len -= bits; - - if (ld->len <0) - { - ld->len = 0; - return 1; - } else { - return 0; - } -} - - -static INLINE int8_t getbits(bits_t *ld, uint8_t n, uint32_t *result) -{ - *result = showbits(ld, n); - return flushbits(ld, n); -} - -static INLINE int8_t get1bit(bits_t *ld, uint8_t *result) -{ - uint32_t res; - int8_t ret; - - ret = getbits(ld, 1, &res); - *result = res & 1; - return ret; -} - -/* Special version of huffman_spectral_data adapted from huffman.h -Will not read from a bitfile but a bits_t structure. -Will keep track of the bits decoded and return the number of bits remaining. -Do not read more than ld->len, return -1 if codeword would be longer */ - -static int8_t huffman_spectral_data_2(uint8_t cb, bits_t *ld, int16_t *sp ) -{ - uint32_t cw; - uint16_t offset = 0; - uint8_t extra_bits; - uint8_t i; - uint8_t save_cb = cb; - - - switch (cb) - { - case 1: /* 2-step method for data quadruples */ - case 2: - case 4: - - cw = showbits(ld, hcbN[cb]); - offset = hcb_table[cb][cw].offset; - extra_bits = hcb_table[cb][cw].extra_bits; - - if (extra_bits) - { - /* we know for sure it's more than hcbN[cb] bits long */ - if ( flushbits(ld, hcbN[cb]) ) return -1; - offset += (uint16_t)showbits(ld, extra_bits); - if ( flushbits(ld, hcb_2_quad_table[cb][offset].bits - hcbN[cb]) ) return -1; - } else { - if ( flushbits(ld, hcb_2_quad_table[cb][offset].bits) ) return -1; - } - - sp[0] = hcb_2_quad_table[cb][offset].x; - sp[1] = hcb_2_quad_table[cb][offset].y; - sp[2] = hcb_2_quad_table[cb][offset].v; - sp[3] = hcb_2_quad_table[cb][offset].w; - break; - - case 6: /* 2-step method for data pairs */ - case 8: - case 10: - case 11: - /* VCB11 uses codebook 11 */ - case 16: case 17: case 18: case 19: case 20: case 21: case 22: case 23: - case 24: case 25: case 26: case 27: case 28: case 29: case 30: case 31: - - /* TODO: If ER is used, some extra error checking should be done */ - if (cb >= 16) - cb = 11; - - cw = showbits(ld, hcbN[cb]); - offset = hcb_table[cb][cw].offset; - extra_bits = hcb_table[cb][cw].extra_bits; - - if (extra_bits) - { - /* we know for sure it's more than hcbN[cb] bits long */ - if ( flushbits(ld, hcbN[cb]) ) return -1; - offset += (uint16_t)showbits(ld, extra_bits); - if ( flushbits(ld, hcb_2_pair_table[cb][offset].bits - hcbN[cb]) ) return -1; - } else { - if ( flushbits(ld, hcb_2_pair_table[cb][offset].bits) ) return -1; - } - sp[0] = hcb_2_pair_table[cb][offset].x; - sp[1] = hcb_2_pair_table[cb][offset].y; - break; - - case 3: /* binary search for data quadruples */ - - while (!hcb3[offset].is_leaf) - { - uint8_t b; - - if ( get1bit(ld, &b) ) return -1; - offset += hcb3[offset].data[b]; - } - - sp[0] = hcb3[offset].data[0]; - sp[1] = hcb3[offset].data[1]; - sp[2] = hcb3[offset].data[2]; - sp[3] = hcb3[offset].data[3]; - - break; - - case 5: /* binary search for data pairs */ - case 7: - case 9: - - while (!hcb_bin_table[cb][offset].is_leaf) - { - uint8_t b; - - if (get1bit(ld, &b) ) return -1; - offset += hcb_bin_table[cb][offset].data[b]; - } - - sp[0] = hcb_bin_table[cb][offset].data[0]; - sp[1] = hcb_bin_table[cb][offset].data[1]; - - break; - } - - /* decode sign bits */ - if (unsigned_cb[cb]) { - - for(i = 0; i < ((cb < FIRST_PAIR_HCB) ? QUAD_LEN : PAIR_LEN); i++) - { - if(sp[i]) - { - uint8_t b; - if ( get1bit(ld, &b) ) return -1; - if (b != 0) { - sp[i] = -sp[i]; - } - } - } - } - - /* decode huffman escape bits */ - if ((cb == ESC_HCB) || (cb >= 16)) - { - uint8_t k; - for (k = 0; k < 2; k++) - { - if ((sp[k] == 16) || (sp[k] == -16)) - { - uint8_t neg, i; - int32_t j; - uint32_t off; - - neg = (sp[k] < 0) ? 1 : 0; - - for (i = 4; ; i++) - { - uint8_t b; - if (get1bit(ld, &b)) - return -1; - if (b == 0) - break; - } -// TODO: here we would need to test "off" if VCB11 is used! - if (getbits(ld, i, &off)) - return -1; - j = off + (1<<i); - sp[k] = neg ? -j : j; - } - } - } - return ld->len; -} - /* rewind len (max. 32) bits so that the MSB becomes LSB */ static uint32_t rewind_word( uint32_t W, uint8_t len) @@ -324,7 +89,7 @@ static void rewind_bits(bits_t * r) r->bufb = hw; } else { - lw = showbits(r, r->len ); + lw = showbits_hcr(r, r->len ); r->bufa = rewind_word( lw, r->len); r->bufb = 0; } @@ -342,14 +107,14 @@ static void concat_bits( bits_t * a, bits_t * b) lwa = a->bufa; hwa = a->bufb & (0xFFFFFFFF >> (64 - a->len)); } else { - lwa = showbits(a, a->len ); + lwa = showbits_hcr(a, a->len ); hwa = 0; } if (b->len >=32) { lwb = b->bufa; hwb = (b->bufb & (0xFFFFFFFF >> (64 - b->len)) ) | ( lwa << (b->len - 32)); } else { - lwb = showbits(b, b->len ) | (lwa << (b->len)); + lwb = showbits_hcr(b, b->len ) | (lwa << (b->len)); hwb = (lwa >> (32 - b->len)) | (hwa << (b->len)); } @@ -392,7 +157,7 @@ uint8_t reordered_spectral_data(faacDecHandle hDecoder, ic_stream *ics, bitfile uint16_t nshort = hDecoder->frameLength/8; - memset (spectral_data, 0, hDecoder->frameLength*sizeof(uint16_t)); + /*memset (spectral_data, 0, hDecoder->frameLength*sizeof(uint16_t));*/ if (ics->length_of_reordered_spectral_data == 0) return 0; /* nothing to do */ @@ -513,12 +278,12 @@ uint8_t reordered_spectral_data(faacDecHandle hDecoder, ic_stream *ics, bitfile if (Segment[ numberOfSegments-1 ].len > 32) { Segment[ numberOfSegments-1 ].bufb = hw + - showbits(&Segment[ numberOfSegments-1 ], Segment[ numberOfSegments-1 ].len - 32); + showbits_hcr(&Segment[ numberOfSegments-1 ], Segment[ numberOfSegments-1 ].len - 32); Segment[ numberOfSegments-1 ].bufa = lw + - showbits(&Segment[ numberOfSegments-1 ], 32); + showbits_hcr(&Segment[ numberOfSegments-1 ], 32); } else { Segment[ numberOfSegments-1 ].bufa = lw + - showbits(&Segment[ numberOfSegments-1 ], Segment[ numberOfSegments-1 ].len); + showbits_hcr(&Segment[ numberOfSegments-1 ], Segment[ numberOfSegments-1 ].len); Segment[ numberOfSegments-1 ].bufb = hw; } Segment[ numberOfSegments-1 ].len += additional_bits; diff --git a/src/libfaad/huffman.c b/src/libfaad/huffman.c new file mode 100644 index 000000000..5ec920976 --- /dev/null +++ b/src/libfaad/huffman.c @@ -0,0 +1,503 @@ +/* +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** +** This program is free software; you can redistribute it and/or modify +** it under the terms of the GNU General Public License as published by +** the Free Software Foundation; either version 2 of the License, or +** (at your option) any later version. +** +** This program is distributed in the hope that it will be useful, +** but WITHOUT ANY WARRANTY; without even the implied warranty of +** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +** GNU General Public License for more details. +** +** You should have received a copy of the GNU General Public License +** along with this program; if not, write to the Free Software +** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +** +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: huffman.c,v 1.1 2003/12/30 02:00:10 miguelfreitas Exp $ +**/ + +#include "common.h" +#include "structs.h" + +#include <stdlib.h> +#ifdef ANALYSIS +#include <stdio.h> +#endif + +#include "bits.h" +#include "huffman.h" +#include "codebook/hcb.h" + + +int8_t huffman_scale_factor(bitfile *ld) +{ + uint16_t offset = 0; + + while (hcb_sf[offset][1]) + { + uint8_t b = faad_get1bit(ld + DEBUGVAR(1,255,"huffman_scale_factor()")); + offset += hcb_sf[offset][b]; + + if (offset > 240) + { + /* printf("ERROR: offset into hcb_sf = %d >240!\n", offset); */ + return -1; + } + } + + return hcb_sf[offset][0]; +} + + +hcb *hcb_table[] = { + 0, hcb1_1, hcb2_1, 0, hcb4_1, 0, hcb6_1, 0, hcb8_1, 0, hcb10_1, hcb11_1 +}; + +hcb_2_quad *hcb_2_quad_table[] = { + 0, hcb1_2, hcb2_2, 0, hcb4_2, 0, 0, 0, 0, 0, 0, 0 +}; + +hcb_2_pair *hcb_2_pair_table[] = { + 0, 0, 0, 0, 0, 0, hcb6_2, 0, hcb8_2, 0, hcb10_2, hcb11_2 +}; + +hcb_bin_pair *hcb_bin_table[] = { + 0, 0, 0, 0, 0, hcb5, 0, hcb7, 0, hcb9, 0, 0 +}; + +uint8_t hcbN[] = { 0, 5, 5, 0, 5, 0, 5, 0, 5, 0, 6, 5 }; + +/* defines whether a huffman codebook is unsigned or not */ +/* Table 4.6.2 */ +uint8_t unsigned_cb[] = { 0, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, + /* codebook 16 to 31 */ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 +}; + +int hcb_2_quad_table_size[] = { 0, 114, 86, 0, 185, 0, 0, 0, 0, 0, 0, 0 }; +int hcb_2_pair_table_size[] = { 0, 0, 0, 0, 0, 0, 126, 0, 83, 0, 210, 373 }; +int hcb_bin_table_size[] = { 0, 0, 0, 161, 0, 161, 0, 127, 0, 337, 0, 0 }; + +static INLINE void huffman_sign_bits(bitfile *ld, int16_t *sp, uint8_t len) +{ + uint8_t i; + + for (i = 0; i < len; i++) + { + if(sp[i]) + { + if(faad_get1bit(ld + DEBUGVAR(1,5,"huffman_sign_bits(): sign bit")) & 1) + { + sp[i] = -sp[i]; + } + } + } +} + +static INLINE int16_t huffman_getescape(bitfile *ld, int16_t sp) +{ + uint8_t neg, i; + int16_t j; + int32_t off; + + if (sp < 0) + { + if (sp != -16) + return sp; + neg = 1; + } else { + if(sp != 16) + return sp; + neg = 0; + } + + for (i = 4; ; i++) + { + if (faad_get1bit(ld + DEBUGVAR(1,6,"huffman_getescape(): escape size")) == 0) + { + break; + } + } + + off = faad_getbits(ld, i + DEBUGVAR(1,9,"huffman_getescape(): escape")); + + j = off + (1<<i); + if (neg) + j = -j; + + return j; +} + +static uint8_t huffman_2step_quad(uint8_t cb, bitfile *ld, int16_t *sp) +{ + uint32_t cw; + uint16_t offset = 0; + uint8_t extra_bits; + + cw = faad_showbits(ld, hcbN[cb]); + offset = hcb_table[cb][cw].offset; + extra_bits = hcb_table[cb][cw].extra_bits; + + if (extra_bits) + { + /* we know for sure it's more than hcbN[cb] bits long */ + faad_flushbits(ld, hcbN[cb]); + offset += (uint16_t)faad_showbits(ld, extra_bits); + faad_flushbits(ld, hcb_2_quad_table[cb][offset].bits - hcbN[cb]); + } else { + faad_flushbits(ld, hcb_2_quad_table[cb][offset].bits); + } + + if (offset > hcb_2_quad_table_size[cb]) + { + /* printf("ERROR: offset into hcb_2_quad_table = %d >%d!\n", offset, + hcb_2_quad_table_size[cb]); */ + return 10; + } + + sp[0] = hcb_2_quad_table[cb][offset].x; + sp[1] = hcb_2_quad_table[cb][offset].y; + sp[2] = hcb_2_quad_table[cb][offset].v; + sp[3] = hcb_2_quad_table[cb][offset].w; + + return 0; +} + +static uint8_t huffman_2step_quad_sign(uint8_t cb, bitfile *ld, int16_t *sp) +{ + uint8_t err = huffman_2step_quad(cb, ld, sp); + huffman_sign_bits(ld, sp, QUAD_LEN); + + return err; +} + +static uint8_t huffman_2step_pair(uint8_t cb, bitfile *ld, int16_t *sp) +{ + uint32_t cw; + uint16_t offset = 0; + uint8_t extra_bits; + + cw = faad_showbits(ld, hcbN[cb]); + offset = hcb_table[cb][cw].offset; + extra_bits = hcb_table[cb][cw].extra_bits; + + if (extra_bits) + { + /* we know for sure it's more than hcbN[cb] bits long */ + faad_flushbits(ld, hcbN[cb]); + offset += (uint16_t)faad_showbits(ld, extra_bits); + faad_flushbits(ld, hcb_2_pair_table[cb][offset].bits - hcbN[cb]); + } else { + faad_flushbits(ld, hcb_2_pair_table[cb][offset].bits); + } + + if (offset > hcb_2_pair_table_size[cb]) + { + /* printf("ERROR: offset into hcb_2_pair_table = %d >%d!\n", offset, + hcb_2_pair_table_size[cb]); */ + return 10; + } + + sp[0] = hcb_2_pair_table[cb][offset].x; + sp[1] = hcb_2_pair_table[cb][offset].y; + + return 0; +} + +static huffman_2step_pair_sign(uint8_t cb, bitfile *ld, int16_t *sp) +{ + uint8_t err = huffman_2step_pair(cb, ld, sp); + huffman_sign_bits(ld, sp, PAIR_LEN); + + return err; +} + +static uint8_t huffman_binary_quad(uint8_t cb, bitfile *ld, int16_t *sp) +{ + uint16_t offset = 0; + + while (!hcb3[offset].is_leaf) + { + uint8_t b = faad_get1bit(ld + DEBUGVAR(1,255,"huffman_spectral_data():3")); + offset += hcb3[offset].data[b]; + } + + if (offset > hcb_bin_table_size[cb]) + { + /* printf("ERROR: offset into hcb_bin_table = %d >%d!\n", offset, + hcb_bin_table_size[cb]); */ + return 10; + } + + sp[0] = hcb3[offset].data[0]; + sp[1] = hcb3[offset].data[1]; + sp[2] = hcb3[offset].data[2]; + sp[3] = hcb3[offset].data[3]; + + return 0; +} + +static uint8_t huffman_binary_quad_sign(uint8_t cb, bitfile *ld, int16_t *sp) +{ + uint8_t err = huffman_binary_quad(cb, ld, sp); + huffman_sign_bits(ld, sp, QUAD_LEN); + + return err; +} + +static uint8_t huffman_binary_pair(uint8_t cb, bitfile *ld, int16_t *sp) +{ + uint16_t offset = 0; + + while (!hcb_bin_table[cb][offset].is_leaf) + { + uint8_t b = faad_get1bit(ld + DEBUGVAR(1,255,"huffman_spectral_data():9")); + offset += hcb_bin_table[cb][offset].data[b]; + } + + if (offset > hcb_bin_table_size[cb]) + { + /* printf("ERROR: offset into hcb_bin_table = %d >%d!\n", offset, + hcb_bin_table_size[cb]); */ + return 10; + } + + sp[0] = hcb_bin_table[cb][offset].data[0]; + sp[1] = hcb_bin_table[cb][offset].data[1]; + + return 0; +} + +static uint8_t huffman_binary_pair_sign(uint8_t cb, bitfile *ld, int16_t *sp) +{ + uint8_t err = huffman_binary_pair(cb, ld, sp); + huffman_sign_bits(ld, sp, PAIR_LEN); + + return err; +} + +static int16_t huffman_codebook(uint8_t i) +{ + static const uint32_t data = 16428320; + if (i == 0) return (int16_t)(data >> 16) & 0xFFFF; + else return (int16_t)data & 0xFFFF; +} + +uint8_t huffman_spectral_data(uint8_t cb, bitfile *ld, int16_t *sp) +{ + switch (cb) + { + case 1: /* 2-step method for data quadruples */ + case 2: + return huffman_2step_quad(cb, ld, sp); + case 3: /* binary search for data quadruples */ + return huffman_binary_quad_sign(cb, ld, sp); + case 4: /* 2-step method for data quadruples */ + return huffman_2step_quad_sign(cb, ld, sp); + case 5: /* binary search for data pairs */ + return huffman_binary_pair(cb, ld, sp); + case 6: /* 2-step method for data pairs */ + return huffman_2step_pair(cb, ld, sp); + case 7: /* binary search for data pairs */ + case 9: + return huffman_binary_pair_sign(cb, ld, sp); + case 8: /* 2-step method for data pairs */ + case 10: + return huffman_2step_pair_sign(cb, ld, sp); + case 12: { + uint8_t err = huffman_2step_quad(1, ld, sp); + sp[0] = huffman_codebook(0); sp[1] = huffman_codebook(1); + return err; } + case 11: +#ifdef ERROR_RESILIENCE + /* VCB11 uses codebook 11 */ + case 16: case 17: case 18: case 19: case 20: case 21: case 22: case 23: + case 24: case 25: case 26: case 27: case 28: case 29: case 30: case 31: + /* TODO: If ER is used, some extra error checking should be done */ +#endif + { + uint8_t err = huffman_2step_pair_sign(11, ld, sp); + sp[0] = huffman_getescape(ld, sp[0]); + sp[1] = huffman_getescape(ld, sp[1]); + return err; + } + default: + /* Non existent codebook number, something went wrong */ + return 11; + } + + return 0; +} + + +#ifdef ERROR_RESILIENCE + +/* Special version of huffman_spectral_data +Will not read from a bitfile but a bits_t structure. +Will keep track of the bits decoded and return the number of bits remaining. +Do not read more than ld->len, return -1 if codeword would be longer */ + +int8_t huffman_spectral_data_2(uint8_t cb, bits_t *ld, int16_t *sp) +{ + uint32_t cw; + uint16_t offset = 0; + uint8_t extra_bits; + uint8_t i; + uint8_t save_cb = cb; + + + switch (cb) + { + case 1: /* 2-step method for data quadruples */ + case 2: + case 4: + + cw = showbits_hcr(ld, hcbN[cb]); + offset = hcb_table[cb][cw].offset; + extra_bits = hcb_table[cb][cw].extra_bits; + + if (extra_bits) + { + /* we know for sure it's more than hcbN[cb] bits long */ + if ( flushbits_hcr(ld, hcbN[cb]) ) return -1; + offset += (uint16_t)showbits_hcr(ld, extra_bits); + if ( flushbits_hcr(ld, hcb_2_quad_table[cb][offset].bits - hcbN[cb]) ) return -1; + } else { + if ( flushbits_hcr(ld, hcb_2_quad_table[cb][offset].bits) ) return -1; + } + + sp[0] = hcb_2_quad_table[cb][offset].x; + sp[1] = hcb_2_quad_table[cb][offset].y; + sp[2] = hcb_2_quad_table[cb][offset].v; + sp[3] = hcb_2_quad_table[cb][offset].w; + break; + + case 6: /* 2-step method for data pairs */ + case 8: + case 10: + case 11: + /* VCB11 uses codebook 11 */ + case 16: case 17: case 18: case 19: case 20: case 21: case 22: case 23: + case 24: case 25: case 26: case 27: case 28: case 29: case 30: case 31: + + /* TODO: If ER is used, some extra error checking should be done */ + if (cb >= 16) + cb = 11; + + cw = showbits_hcr(ld, hcbN[cb]); + offset = hcb_table[cb][cw].offset; + extra_bits = hcb_table[cb][cw].extra_bits; + + if (extra_bits) + { + /* we know for sure it's more than hcbN[cb] bits long */ + if ( flushbits_hcr(ld, hcbN[cb]) ) return -1; + offset += (uint16_t)showbits_hcr(ld, extra_bits); + if ( flushbits_hcr(ld, hcb_2_pair_table[cb][offset].bits - hcbN[cb]) ) return -1; + } else { + if ( flushbits_hcr(ld, hcb_2_pair_table[cb][offset].bits) ) return -1; + } + sp[0] = hcb_2_pair_table[cb][offset].x; + sp[1] = hcb_2_pair_table[cb][offset].y; + break; + + case 3: /* binary search for data quadruples */ + + while (!hcb3[offset].is_leaf) + { + uint8_t b; + + if ( get1bit_hcr(ld, &b) ) return -1; + offset += hcb3[offset].data[b]; + } + + sp[0] = hcb3[offset].data[0]; + sp[1] = hcb3[offset].data[1]; + sp[2] = hcb3[offset].data[2]; + sp[3] = hcb3[offset].data[3]; + + break; + + case 5: /* binary search for data pairs */ + case 7: + case 9: + + while (!hcb_bin_table[cb][offset].is_leaf) + { + uint8_t b; + + if (get1bit_hcr(ld, &b) ) return -1; + offset += hcb_bin_table[cb][offset].data[b]; + } + + sp[0] = hcb_bin_table[cb][offset].data[0]; + sp[1] = hcb_bin_table[cb][offset].data[1]; + + break; + } + + /* decode sign bits */ + if (unsigned_cb[cb]) { + + for(i = 0; i < ((cb < FIRST_PAIR_HCB) ? QUAD_LEN : PAIR_LEN); i++) + { + if(sp[i]) + { + uint8_t b; + if ( get1bit_hcr(ld, &b) ) return -1; + if (b != 0) { + sp[i] = -sp[i]; + } + } + } + } + + /* decode huffman escape bits */ + if ((cb == ESC_HCB) || (cb >= 16)) + { + uint8_t k; + for (k = 0; k < 2; k++) + { + if ((sp[k] == 16) || (sp[k] == -16)) + { + uint8_t neg, i; + int32_t j; + uint32_t off; + + neg = (sp[k] < 0) ? 1 : 0; + + for (i = 4; ; i++) + { + uint8_t b; + if (get1bit_hcr(ld, &b)) + return -1; + if (b == 0) + break; + } +// TODO: here we would need to test "off" if VCB11 is used! + if (getbits_hcr(ld, i, &off)) + return -1; + j = off + (1<<i); + sp[k] = (int16_t)((neg) ? -j : j); + } + } + } + return ld->len; +} + +#endif + diff --git a/src/libfaad/huffman.h b/src/libfaad/huffman.h index 3d56eae62..35b8b72f2 100644 --- a/src/libfaad/huffman.h +++ b/src/libfaad/huffman.h @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: huffman.h,v 1.2 2002/12/16 19:00:12 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: huffman.h,v 1.3 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #ifndef __HUFFMAN_H__ @@ -26,306 +32,24 @@ extern "C" { #endif -#include <stdlib.h> -#ifdef ANALYSIS -#include <stdio.h> -#endif -#include "bits.h" -#include "codebook/hcb.h" - - -static INLINE int8_t huffman_scale_factor(bitfile *ld) -{ - uint16_t offset = 0; - - while (hcb_sf[offset][1]) - { - uint8_t b = faad_get1bit(ld - DEBUGVAR(1,255,"huffman_scale_factor()")); - offset += hcb_sf[offset][b]; - - if (offset > 240) - { - /* printf("ERROR: offset into hcb_sf = %d >240!\n", offset); */ - return -1; - } - } - - return hcb_sf[offset][0]; -} - - -static hcb *hcb_table[] = { - 0, hcb1_1, hcb2_1, 0, hcb4_1, 0, hcb6_1, 0, hcb8_1, 0, hcb10_1, hcb11_1 -}; - -static hcb_2_quad *hcb_2_quad_table[] = { - 0, hcb1_2, hcb2_2, 0, hcb4_2, 0, 0, 0, 0, 0, 0, 0 -}; - -static hcb_2_pair *hcb_2_pair_table[] = { - 0, 0, 0, 0, 0, 0, hcb6_2, 0, hcb8_2, 0, hcb10_2, hcb11_2 -}; - -static hcb_bin_pair *hcb_bin_table[] = { - 0, 0, 0, 0, 0, hcb5, 0, hcb7, 0, hcb9, 0, 0 -}; - -static uint8_t hcbN[] = { 0, 5, 5, 0, 5, 0, 5, 0, 5, 0, 6, 5 }; - -/* defines whether a huffman codebook is unsigned or not */ -/* Table 4.6.2 */ -static uint8_t unsigned_cb[] = { 0, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, - /* codebook 16 to 31 */ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 -}; - -static int hcb_2_quad_table_size[] = { 0, 114, 86, 0, 185, 0, 0, 0, 0, 0, 0, 0 }; -static int hcb_2_pair_table_size[] = { 0, 0, 0, 0, 0, 0, 126, 0, 83, 0, 210, 373 }; -static int hcb_bin_table_size[] = { 0, 0, 0, 161, 0, 161, 0, 127, 0, 337, 0, 0 }; - -static INLINE void huffman_sign_bits(bitfile *ld, int16_t *sp, uint8_t len) -{ - uint8_t i; - - for(i = 0; i < len; i++) - { - if(sp[i]) - { - if(faad_get1bit(ld - DEBUGVAR(1,5,"huffman_sign_bits(): sign bit")) & 1) - { - sp[i] = -sp[i]; - } - } - } -} - -static INLINE int16_t huffman_getescape(bitfile *ld, int16_t sp) -{ - uint8_t neg, i; - int16_t j; - int32_t off; - - if (sp < 0) { - if(sp != -16) - return sp; - neg = 1; - } else { - if(sp != 16) - return sp; - neg = 0; - } - - for (i = 4; ; i++) - { - if (faad_get1bit(ld - DEBUGVAR(1,6,"huffman_getescape(): escape size")) == 0) - { - break; - } - } - - off = faad_getbits(ld, i - DEBUGVAR(1,9,"huffman_getescape(): escape")); - - j = off + (1<<i); - if (neg) - j = -j; - - return j; -} - -static uint8_t huffman_2step_quad(uint8_t cb, bitfile *ld, int16_t *sp) -{ - uint32_t cw; - uint16_t offset = 0; - uint8_t extra_bits; - - cw = faad_showbits(ld, hcbN[cb]); - offset = hcb_table[cb][cw].offset; - extra_bits = hcb_table[cb][cw].extra_bits; - - if (extra_bits) - { - /* we know for sure it's more than hcbN[cb] bits long */ - faad_flushbits(ld, hcbN[cb]); - offset += (uint16_t)faad_showbits(ld, extra_bits); - faad_flushbits(ld, hcb_2_quad_table[cb][offset].bits - hcbN[cb]); - } else { - faad_flushbits(ld, hcb_2_quad_table[cb][offset].bits); - } - - if (offset > hcb_2_quad_table_size[cb]) - { - /* printf("ERROR: offset into hcb_2_quad_table = %d >%d!\n", offset, - hcb_2_quad_table_size[cb]); */ - return 10; - } - - sp[0] = hcb_2_quad_table[cb][offset].x; - sp[1] = hcb_2_quad_table[cb][offset].y; - sp[2] = hcb_2_quad_table[cb][offset].v; - sp[3] = hcb_2_quad_table[cb][offset].w; - - return 0; -} -static uint8_t huffman_2step_quad_sign(uint8_t cb, bitfile *ld, int16_t *sp) -{ - uint8_t err = huffman_2step_quad(cb, ld, sp); - huffman_sign_bits(ld, sp, QUAD_LEN); - - return err; -} - -static uint8_t huffman_2step_pair(uint8_t cb, bitfile *ld, int16_t *sp) -{ - uint32_t cw; - uint16_t offset = 0; - uint8_t extra_bits; - - cw = faad_showbits(ld, hcbN[cb]); - offset = hcb_table[cb][cw].offset; - extra_bits = hcb_table[cb][cw].extra_bits; - - if (extra_bits) - { - /* we know for sure it's more than hcbN[cb] bits long */ - faad_flushbits(ld, hcbN[cb]); - offset += (uint16_t)faad_showbits(ld, extra_bits); - faad_flushbits(ld, hcb_2_pair_table[cb][offset].bits - hcbN[cb]); - } else { - faad_flushbits(ld, hcb_2_pair_table[cb][offset].bits); - } - - if (offset > hcb_2_pair_table_size[cb]) - { - /* printf("ERROR: offset into hcb_2_pair_table = %d >%d!\n", offset, - hcb_2_pair_table_size[cb]); */ - return 10; - } - - sp[0] = hcb_2_pair_table[cb][offset].x; - sp[1] = hcb_2_pair_table[cb][offset].y; - - return 0; -} - -static huffman_2step_pair_sign(uint8_t cb, bitfile *ld, int16_t *sp) -{ - uint8_t err = huffman_2step_pair(cb, ld, sp); - huffman_sign_bits(ld, sp, PAIR_LEN); - - return err; -} - -static uint8_t huffman_binary_quad(uint8_t cb, bitfile *ld, int16_t *sp) -{ - uint16_t offset = 0; - - while (!hcb3[offset].is_leaf) - { - uint8_t b = faad_get1bit(ld - DEBUGVAR(1,255,"huffman_spectral_data():3")); - offset += hcb3[offset].data[b]; - } - - if (offset > hcb_bin_table_size[cb]) - { - /* printf("ERROR: offset into hcb_bin_table = %d >%d!\n", offset, - hcb_bin_table_size[cb]); */ - return 10; - } - - sp[0] = hcb3[offset].data[0]; - sp[1] = hcb3[offset].data[1]; - sp[2] = hcb3[offset].data[2]; - sp[3] = hcb3[offset].data[3]; - - return 0; -} - -static uint8_t huffman_binary_quad_sign(uint8_t cb, bitfile *ld, int16_t *sp) -{ - uint8_t err = huffman_binary_quad(cb, ld, sp); - huffman_sign_bits(ld, sp, QUAD_LEN); - - return err; -} - -static uint8_t huffman_binary_pair(uint8_t cb, bitfile *ld, int16_t *sp) -{ - uint16_t offset = 0; - - while (!hcb_bin_table[cb][offset].is_leaf) - { - uint8_t b = faad_get1bit(ld - DEBUGVAR(1,255,"huffman_spectral_data():9")); - offset += hcb_bin_table[cb][offset].data[b]; - } - - if (offset > hcb_bin_table_size[cb]) - { - /* printf("ERROR: offset into hcb_bin_table = %d >%d!\n", offset, - hcb_bin_table_size[cb]); */ - return 10; - } - - sp[0] = hcb_bin_table[cb][offset].data[0]; - sp[1] = hcb_bin_table[cb][offset].data[1]; - - return 0; -} - -static uint8_t huffman_binary_pair_sign(uint8_t cb, bitfile *ld, int16_t *sp) -{ - uint8_t err = huffman_binary_pair(cb, ld, sp); - huffman_sign_bits(ld, sp, PAIR_LEN); - - return err; -} - -static INLINE uint8_t huffman_spectral_data(uint8_t cb, bitfile *ld, int16_t *sp) -{ - switch (cb) - { - case 1: /* 2-step method for data quadruples */ - case 2: - return huffman_2step_quad(cb, ld, sp); - case 3: /* binary search for data quadruples */ - return huffman_binary_quad_sign(cb, ld, sp); - case 4: /* 2-step method for data quadruples */ - return huffman_2step_quad_sign(cb, ld, sp); - case 5: /* binary search for data pairs */ - return huffman_binary_pair(cb, ld, sp); - case 6: /* 2-step method for data pairs */ - return huffman_2step_pair(cb, ld, sp); - case 7: /* binary search for data pairs */ - case 9: - return huffman_binary_pair_sign(cb, ld, sp); - case 8: /* 2-step method for data pairs */ - case 10: - return huffman_2step_pair_sign(cb, ld, sp); - case 11: +static INLINE void huffman_sign_bits(bitfile *ld, int16_t *sp, uint8_t len); +static INLINE int16_t huffman_getescape(bitfile *ld, int16_t sp); +static uint8_t huffman_2step_quad(uint8_t cb, bitfile *ld, int16_t *sp); +static uint8_t huffman_2step_quad_sign(uint8_t cb, bitfile *ld, int16_t *sp); +static uint8_t huffman_2step_pair(uint8_t cb, bitfile *ld, int16_t *sp); +static huffman_2step_pair_sign(uint8_t cb, bitfile *ld, int16_t *sp); +static uint8_t huffman_binary_quad(uint8_t cb, bitfile *ld, int16_t *sp); +static uint8_t huffman_binary_quad_sign(uint8_t cb, bitfile *ld, int16_t *sp); +static uint8_t huffman_binary_pair(uint8_t cb, bitfile *ld, int16_t *sp); +static uint8_t huffman_binary_pair_sign(uint8_t cb, bitfile *ld, int16_t *sp); +static int16_t huffman_codebook(uint8_t i); + +int8_t huffman_scale_factor(bitfile *ld); +uint8_t huffman_spectral_data(uint8_t cb, bitfile *ld, int16_t *sp); #ifdef ERROR_RESILIENCE - /* VCB11 uses codebook 11 */ - case 16: case 17: case 18: case 19: case 20: case 21: case 22: case 23: - case 24: case 25: case 26: case 27: case 28: case 29: case 30: case 31: - /* TODO: If ER is used, some extra error checking should be done */ +int8_t huffman_spectral_data_2(uint8_t cb, bits_t *ld, int16_t *sp); #endif - { - uint8_t err = huffman_2step_pair_sign(11, ld, sp); - sp[0] = huffman_getescape(ld, sp[0]); - sp[1] = huffman_getescape(ld, sp[1]); - return err; - } - default: - /* Non existent codebook number, something went wrong */ - return 11; - } - - return 0; -} #ifdef __cplusplus } diff --git a/src/libfaad/ic_predict.c b/src/libfaad/ic_predict.c index 997b2c654..31ae5d668 100644 --- a/src/libfaad/ic_predict.c +++ b/src/libfaad/ic_predict.c @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: ic_predict.c,v 1.2 2002/12/16 19:00:14 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: ic_predict.c,v 1.3 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #include "common.h" @@ -28,63 +34,161 @@ #include "ic_predict.h" #include "pns.h" + +static void flt_round(float32_t *pf) +{ + int32_t flg; + uint32_t tmp, tmp1, tmp2; + + tmp = *(uint32_t*)pf; + flg = tmp & (uint32_t)0x00008000; + tmp &= (uint32_t)0xffff0000; + tmp1 = tmp; + /* round 1/2 lsb toward infinity */ + if (flg) + { + tmp &= (uint32_t)0xff800000; /* extract exponent and sign */ + tmp |= (uint32_t)0x00010000; /* insert 1 lsb */ + tmp2 = tmp; /* add 1 lsb and elided one */ + tmp &= (uint32_t)0xff800000; /* extract exponent and sign */ + + *pf = *(float32_t*)&tmp1 + *(float32_t*)&tmp2 - *(float32_t*)&tmp; + } else { + *pf = *(float32_t*)&tmp; + } +} + +static int16_t quant_pred(float32_t x) +{ + int16_t q; + uint32_t *tmp = (uint32_t*)&x; + + q = (int16_t)(*tmp>>16); + + return q; +} + +static float32_t inv_quant_pred(int16_t q) +{ + float32_t x; + uint32_t *tmp = (uint32_t*)&x; + *tmp = ((uint32_t)q)<<16; + + return x; +} + static void ic_predict(pred_state *state, real_t input, real_t *output, uint8_t pred) { + uint16_t tmp; + int16_t i, j; real_t dr1, predictedvalue; real_t e0, e1; real_t k1, k2; - real_t *r; - real_t *KOR; - real_t *VAR; + real_t r[2]; + real_t COR[2]; + real_t VAR[2]; - r = state->r; /* delay elements */ - KOR = state->KOR; /* correlations */ - VAR = state->VAR; /* variances */ + r[0] = inv_quant_pred(state->r[0]); + r[1] = inv_quant_pred(state->r[1]); + COR[0] = inv_quant_pred(state->COR[0]); + COR[1] = inv_quant_pred(state->COR[1]); + VAR[0] = inv_quant_pred(state->VAR[0]); + VAR[1] = inv_quant_pred(state->VAR[1]); - if (VAR[0] == 0) - k1 = 0; - else - k1 = KOR[0]/VAR[0]*B; + +#if 1 + tmp = state->VAR[0]; + j = (tmp >> 7); + i = tmp & 0x7f; + if (j >= 128) + { + j -= 128; + k1 = COR[0] * exp_table[j] * mnt_table[i]; + } else { + k1 = REAL_CONST(0); + } +#else + + { +#define B 0.953125 + real_t c = COR[0]; + real_t v = VAR[0]; + real_t tmp; + if (c == 0 || v <= 1) + { + k1 = 0; + } else { + tmp = B / v; + flt_round(&tmp); + k1 = c * tmp; + } + } +#endif if (pred) { - /* only needed for the actual predicted value, k1 is always needed */ - if (VAR[1] == 0) - k2 = 0; - else - k2 = KOR[1]/VAR[1]*B; +#if 1 + tmp = state->VAR[1]; + j = (tmp >> 7); + i = tmp & 0x7f; + if (j >= 128) + { + j -= 128; + k2 = COR[1] * exp_table[j] * mnt_table[i]; + } else { + k2 = REAL_CONST(0); + } +#else - predictedvalue = MUL(k1, r[0]) + MUL(k2, r[1]); +#define B 0.953125 + real_t c = COR[1]; + real_t v = VAR[1]; + real_t tmp; + if (c == 0 || v <= 1) + { + k2 = 0; + } else { + tmp = B / v; + flt_round(&tmp); + k2 = c * tmp; + } +#endif + predictedvalue = k1*r[0] + k2*r[1]; + flt_round(&predictedvalue); *output = input + predictedvalue; - } else { - *output = input; } /* calculate new state data */ e0 = *output; - e1 = e0 - MUL(k1, r[0]); + e1 = e0 - k1*r[0]; + dr1 = k1*e0; - dr1 = MUL(k1, e0); + VAR[0] = ALPHA*VAR[0] + 0.5f * (r[0]*r[0] + e0*e0); + COR[0] = ALPHA*COR[0] + r[0]*e0; + VAR[1] = ALPHA*VAR[1] + 0.5f * (r[1]*r[1] + e1*e1); + COR[1] = ALPHA*COR[1] + r[1]*e1; - VAR[0] = MUL(ALPHA, VAR[0]) + MUL(REAL_CONST(0.5), (MUL(r[0], r[0]) + MUL(e0, e0))); - KOR[0] = MUL(ALPHA, KOR[0]) + MUL(r[0], e0); - VAR[1] = MUL(ALPHA, VAR[1]) + MUL(REAL_CONST(0.5), (MUL(r[1], r[1]) + MUL(e1, e1))); - KOR[1] = MUL(ALPHA, KOR[1]) + MUL(r[1], e1); + r[1] = A * (r[0]-dr1); + r[0] = A * e0; - r[1] = MUL(A, (r[0]-dr1)); - r[0] = MUL(A, e0); + state->r[0] = quant_pred(r[0]); + state->r[1] = quant_pred(r[1]); + state->COR[0] = quant_pred(COR[0]); + state->COR[1] = quant_pred(COR[1]); + state->VAR[0] = quant_pred(VAR[0]); + state->VAR[1] = quant_pred(VAR[1]); } static void reset_pred_state(pred_state *state) { state->r[0] = 0; state->r[1] = 0; - state->KOR[0] = 0; - state->KOR[1] = 0; - state->VAR[0] = REAL_CONST(1.0); - state->VAR[1] = REAL_CONST(1.0); + state->COR[0] = 0; + state->COR[1] = 0; + state->VAR[0] = 0x3F80; + state->VAR[1] = 0x3F80; } void pns_reset_pred_state(ic_stream *ics, pred_state *state) @@ -125,7 +229,7 @@ void reset_all_predictors(pred_state *state, uint16_t frame_len) /* intra channel prediction */ void ic_prediction(ic_stream *ics, real_t *spec, pred_state *state, - uint16_t frame_len) + uint16_t frame_len, uint8_t sf_index) { uint8_t sfb; uint16_t bin; @@ -134,7 +238,7 @@ void ic_prediction(ic_stream *ics, real_t *spec, pred_state *state, { reset_all_predictors(state, frame_len); } else { - for (sfb = 0; sfb < ics->pred.limit; sfb++) + for (sfb = 0; sfb < max_pred_sfb(sf_index); sfb++) { uint16_t low = ics->swb_offset[sfb]; uint16_t high = ics->swb_offset[sfb+1]; @@ -142,8 +246,7 @@ void ic_prediction(ic_stream *ics, real_t *spec, pred_state *state, for (bin = low; bin < high; bin++) { ic_predict(&state[bin], spec[bin], &spec[bin], - (ics->predictor_data_present && - ics->pred.prediction_used[sfb])); + (ics->predictor_data_present && ics->pred.prediction_used[sfb])); } } diff --git a/src/libfaad/ic_predict.h b/src/libfaad/ic_predict.h index 881e9fd98..9d7a9d8e2 100644 --- a/src/libfaad/ic_predict.h +++ b/src/libfaad/ic_predict.h @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: ic_predict.h,v 1.2 2002/12/16 19:00:20 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: ic_predict.h,v 1.3 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #ifdef MAIN_DEC @@ -30,14 +36,210 @@ extern "C" { #define ALPHA REAL_CONST(0.90625) #define A REAL_CONST(0.953125) -#define B REAL_CONST(0.953125) void pns_reset_pred_state(ic_stream *ics, pred_state *state); void reset_all_predictors(pred_state *state, uint16_t frame_len); void ic_prediction(ic_stream *ics, real_t *spec, pred_state *state, - uint16_t frame_len); + uint16_t frame_len, uint8_t sf_index); + +ALIGN static const real_t mnt_table[128] = { + COEF_CONST(0.9531250000), COEF_CONST(0.9453125000), + COEF_CONST(0.9375000000), COEF_CONST(0.9296875000), + COEF_CONST(0.9257812500), COEF_CONST(0.9179687500), + COEF_CONST(0.9101562500), COEF_CONST(0.9023437500), + COEF_CONST(0.8984375000), COEF_CONST(0.8906250000), + COEF_CONST(0.8828125000), COEF_CONST(0.8789062500), + COEF_CONST(0.8710937500), COEF_CONST(0.8671875000), + COEF_CONST(0.8593750000), COEF_CONST(0.8515625000), + COEF_CONST(0.8476562500), COEF_CONST(0.8398437500), + COEF_CONST(0.8359375000), COEF_CONST(0.8281250000), + COEF_CONST(0.8242187500), COEF_CONST(0.8203125000), + COEF_CONST(0.8125000000), COEF_CONST(0.8085937500), + COEF_CONST(0.8007812500), COEF_CONST(0.7968750000), + COEF_CONST(0.7929687500), COEF_CONST(0.7851562500), + COEF_CONST(0.7812500000), COEF_CONST(0.7773437500), + COEF_CONST(0.7734375000), COEF_CONST(0.7656250000), + COEF_CONST(0.7617187500), COEF_CONST(0.7578125000), + COEF_CONST(0.7539062500), COEF_CONST(0.7500000000), + COEF_CONST(0.7421875000), COEF_CONST(0.7382812500), + COEF_CONST(0.7343750000), COEF_CONST(0.7304687500), + COEF_CONST(0.7265625000), COEF_CONST(0.7226562500), + COEF_CONST(0.7187500000), COEF_CONST(0.7148437500), + COEF_CONST(0.7109375000), COEF_CONST(0.7070312500), + COEF_CONST(0.6992187500), COEF_CONST(0.6953125000), + COEF_CONST(0.6914062500), COEF_CONST(0.6875000000), + COEF_CONST(0.6835937500), COEF_CONST(0.6796875000), + COEF_CONST(0.6796875000), COEF_CONST(0.6757812500), + COEF_CONST(0.6718750000), COEF_CONST(0.6679687500), + COEF_CONST(0.6640625000), COEF_CONST(0.6601562500), + COEF_CONST(0.6562500000), COEF_CONST(0.6523437500), + COEF_CONST(0.6484375000), COEF_CONST(0.6445312500), + COEF_CONST(0.6406250000), COEF_CONST(0.6406250000), + COEF_CONST(0.6367187500), COEF_CONST(0.6328125000), + COEF_CONST(0.6289062500), COEF_CONST(0.6250000000), + COEF_CONST(0.6210937500), COEF_CONST(0.6210937500), + COEF_CONST(0.6171875000), COEF_CONST(0.6132812500), + COEF_CONST(0.6093750000), COEF_CONST(0.6054687500), + COEF_CONST(0.6054687500), COEF_CONST(0.6015625000), + COEF_CONST(0.5976562500), COEF_CONST(0.5937500000), + COEF_CONST(0.5937500000), COEF_CONST(0.5898437500), + COEF_CONST(0.5859375000), COEF_CONST(0.5820312500), + COEF_CONST(0.5820312500), COEF_CONST(0.5781250000), + COEF_CONST(0.5742187500), COEF_CONST(0.5742187500), + COEF_CONST(0.5703125000), COEF_CONST(0.5664062500), + COEF_CONST(0.5664062500), COEF_CONST(0.5625000000), + COEF_CONST(0.5585937500), COEF_CONST(0.5585937500), + COEF_CONST(0.5546875000), COEF_CONST(0.5507812500), + COEF_CONST(0.5507812500), COEF_CONST(0.5468750000), + COEF_CONST(0.5429687500), COEF_CONST(0.5429687500), + COEF_CONST(0.5390625000), COEF_CONST(0.5390625000), + COEF_CONST(0.5351562500), COEF_CONST(0.5312500000), + COEF_CONST(0.5312500000), COEF_CONST(0.5273437500), + COEF_CONST(0.5273437500), COEF_CONST(0.5234375000), + COEF_CONST(0.5195312500), COEF_CONST(0.5195312500), + COEF_CONST(0.5156250000), COEF_CONST(0.5156250000), + COEF_CONST(0.5117187500), COEF_CONST(0.5117187500), + COEF_CONST(0.5078125000), COEF_CONST(0.5078125000), + COEF_CONST(0.5039062500), COEF_CONST(0.5039062500), + COEF_CONST(0.5000000000), COEF_CONST(0.4980468750), + COEF_CONST(0.4960937500), COEF_CONST(0.4941406250), + COEF_CONST(0.4921875000), COEF_CONST(0.4902343750), + COEF_CONST(0.4882812500), COEF_CONST(0.4863281250), + COEF_CONST(0.4843750000), COEF_CONST(0.4824218750), + COEF_CONST(0.4804687500), COEF_CONST(0.4785156250) +}; +ALIGN static const real_t exp_table[128] = { + COEF_CONST(0.50000000000000000000000000000000000000000000000000), + COEF_CONST(0.25000000000000000000000000000000000000000000000000), + COEF_CONST(0.12500000000000000000000000000000000000000000000000), + COEF_CONST(0.06250000000000000000000000000000000000000000000000), + COEF_CONST(0.03125000000000000000000000000000000000000000000000), + COEF_CONST(0.01562500000000000000000000000000000000000000000000), + COEF_CONST(0.00781250000000000000000000000000000000000000000000), + COEF_CONST(0.00390625000000000000000000000000000000000000000000), + COEF_CONST(0.00195312500000000000000000000000000000000000000000), + COEF_CONST(0.00097656250000000000000000000000000000000000000000), + COEF_CONST(0.00048828125000000000000000000000000000000000000000), + COEF_CONST(0.00024414062500000000000000000000000000000000000000), + COEF_CONST(0.00012207031250000000000000000000000000000000000000), + COEF_CONST(0.00006103515625000000000000000000000000000000000000), + COEF_CONST(0.00003051757812500000000000000000000000000000000000), + COEF_CONST(0.00001525878906250000000000000000000000000000000000), + COEF_CONST(0.00000762939453125000000000000000000000000000000000), + COEF_CONST(0.00000381469726562500000000000000000000000000000000), + COEF_CONST(0.00000190734863281250000000000000000000000000000000), + COEF_CONST(0.00000095367431640625000000000000000000000000000000), + COEF_CONST(0.00000047683715820312500000000000000000000000000000), + COEF_CONST(0.00000023841857910156250000000000000000000000000000), + COEF_CONST(0.00000011920928955078125000000000000000000000000000), + COEF_CONST(0.00000005960464477539062500000000000000000000000000), + COEF_CONST(0.00000002980232238769531300000000000000000000000000), + COEF_CONST(0.00000001490116119384765600000000000000000000000000), + COEF_CONST(0.00000000745058059692382810000000000000000000000000), + COEF_CONST(0.00000000372529029846191410000000000000000000000000), + COEF_CONST(0.00000000186264514923095700000000000000000000000000), + COEF_CONST(0.00000000093132257461547852000000000000000000000000), + COEF_CONST(0.00000000046566128730773926000000000000000000000000), + COEF_CONST(0.00000000023283064365386963000000000000000000000000), + COEF_CONST(0.00000000011641532182693481000000000000000000000000), + COEF_CONST(0.00000000005820766091346740700000000000000000000000), + COEF_CONST(0.00000000002910383045673370400000000000000000000000), + COEF_CONST(0.00000000001455191522836685200000000000000000000000), + COEF_CONST(0.00000000000727595761418342590000000000000000000000), + COEF_CONST(0.00000000000363797880709171300000000000000000000000), + COEF_CONST(0.00000000000181898940354585650000000000000000000000), + COEF_CONST(0.00000000000090949470177292824000000000000000000000), + COEF_CONST(0.00000000000045474735088646412000000000000000000000), + COEF_CONST(0.00000000000022737367544323206000000000000000000000), + COEF_CONST(0.00000000000011368683772161603000000000000000000000), + COEF_CONST(0.00000000000005684341886080801500000000000000000000), + COEF_CONST(0.00000000000002842170943040400700000000000000000000), + COEF_CONST(0.00000000000001421085471520200400000000000000000000), + COEF_CONST(0.00000000000000710542735760100190000000000000000000), + COEF_CONST(0.00000000000000355271367880050090000000000000000000), + COEF_CONST(0.00000000000000177635683940025050000000000000000000), + COEF_CONST(0.00000000000000088817841970012523000000000000000000), + COEF_CONST(0.00000000000000044408920985006262000000000000000000), + COEF_CONST(0.00000000000000022204460492503131000000000000000000), + COEF_CONST(0.00000000000000011102230246251565000000000000000000), + COEF_CONST(0.00000000000000005551115123125782700000000000000000), + COEF_CONST(0.00000000000000002775557561562891400000000000000000), + COEF_CONST(0.00000000000000001387778780781445700000000000000000), + COEF_CONST(0.00000000000000000693889390390722840000000000000000), + COEF_CONST(0.00000000000000000346944695195361420000000000000000), + COEF_CONST(0.00000000000000000173472347597680710000000000000000), + COEF_CONST(0.00000000000000000086736173798840355000000000000000), + COEF_CONST(0.00000000000000000043368086899420177000000000000000), + COEF_CONST(0.00000000000000000021684043449710089000000000000000), + COEF_CONST(0.00000000000000000010842021724855044000000000000000), + COEF_CONST(0.00000000000000000005421010862427522200000000000000), + COEF_CONST(0.00000000000000000002710505431213761100000000000000), + COEF_CONST(0.00000000000000000001355252715606880500000000000000), + COEF_CONST(0.00000000000000000000677626357803440270000000000000), + COEF_CONST(0.00000000000000000000338813178901720140000000000000), + COEF_CONST(0.00000000000000000000169406589450860070000000000000), + COEF_CONST(0.00000000000000000000084703294725430034000000000000), + COEF_CONST(0.00000000000000000000042351647362715017000000000000), + COEF_CONST(0.00000000000000000000021175823681357508000000000000), + COEF_CONST(0.00000000000000000000010587911840678754000000000000), + COEF_CONST(0.00000000000000000000005293955920339377100000000000), + COEF_CONST(0.00000000000000000000002646977960169688600000000000), + COEF_CONST(0.00000000000000000000001323488980084844300000000000), + COEF_CONST(0.00000000000000000000000661744490042422140000000000), + COEF_CONST(0.00000000000000000000000330872245021211070000000000), + COEF_CONST(0.00000000000000000000000165436122510605530000000000), + COEF_CONST(0.00000000000000000000000082718061255302767000000000), + COEF_CONST(0.00000000000000000000000041359030627651384000000000), + COEF_CONST(0.00000000000000000000000020679515313825692000000000), + COEF_CONST(0.00000000000000000000000010339757656912846000000000), + COEF_CONST(0.00000000000000000000000005169878828456423000000000), + COEF_CONST(0.00000000000000000000000002584939414228211500000000), + COEF_CONST(0.00000000000000000000000001292469707114105700000000), + COEF_CONST(0.00000000000000000000000000646234853557052870000000), + COEF_CONST(0.00000000000000000000000000323117426778526440000000), + COEF_CONST(0.00000000000000000000000000161558713389263220000000), + COEF_CONST(0.00000000000000000000000000080779356694631609000000), + COEF_CONST(0.00000000000000000000000000040389678347315804000000), + COEF_CONST(0.00000000000000000000000000020194839173657902000000), + COEF_CONST(0.00000000000000000000000000010097419586828951000000), + COEF_CONST(0.00000000000000000000000000005048709793414475600000), + COEF_CONST(0.00000000000000000000000000002524354896707237800000), + COEF_CONST(0.00000000000000000000000000001262177448353618900000), + COEF_CONST(0.00000000000000000000000000000631088724176809440000), + COEF_CONST(0.00000000000000000000000000000315544362088404720000), + COEF_CONST(0.00000000000000000000000000000157772181044202360000), + COEF_CONST(0.00000000000000000000000000000078886090522101181000), + COEF_CONST(0.00000000000000000000000000000039443045261050590000), + COEF_CONST(0.00000000000000000000000000000019721522630525295000), + COEF_CONST(0.00000000000000000000000000000009860761315262647600), + COEF_CONST(0.00000000000000000000000000000004930380657631323800), + COEF_CONST(0.00000000000000000000000000000002465190328815661900), + COEF_CONST(0.00000000000000000000000000000001232595164407830900), + COEF_CONST(0.00000000000000000000000000000000616297582203915470), + COEF_CONST(0.00000000000000000000000000000000308148791101957740), + COEF_CONST(0.00000000000000000000000000000000154074395550978870), + COEF_CONST(0.00000000000000000000000000000000077037197775489434), + COEF_CONST(0.00000000000000000000000000000000038518598887744717), + COEF_CONST(0.00000000000000000000000000000000019259299443872359), + COEF_CONST(0.00000000000000000000000000000000009629649721936179), + COEF_CONST(0.00000000000000000000000000000000004814824860968090), + COEF_CONST(0.00000000000000000000000000000000002407412430484045), + COEF_CONST(0.00000000000000000000000000000000001203706215242022), + COEF_CONST(0.00000000000000000000000000000000000601853107621011), + COEF_CONST(0.00000000000000000000000000000000000300926553810506), + COEF_CONST(0.00000000000000000000000000000000000150463276905253), + COEF_CONST(0.00000000000000000000000000000000000075231638452626), + COEF_CONST(0.00000000000000000000000000000000000037615819226313), + COEF_CONST(0.00000000000000000000000000000000000018807909613157), + COEF_CONST(0.00000000000000000000000000000000000009403954806578), + COEF_CONST(0.00000000000000000000000000000000000004701977403289), + COEF_CONST(0.00000000000000000000000000000000000002350988701645), + COEF_CONST(0.00000000000000000000000000000000000001175494350822), + COEF_CONST(0.0 /* 0000000000000000000000000000000000000587747175411 "floating point underflow" */), + COEF_CONST(0.0) +}; #ifdef __cplusplus } diff --git a/src/libfaad/iq_table.h b/src/libfaad/iq_table.h index de78da88d..33b2dd75a 100644 --- a/src/libfaad/iq_table.h +++ b/src/libfaad/iq_table.h @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: iq_table.h,v 1.1 2002/12/16 19:00:21 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: iq_table.h,v 1.2 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #ifndef IQ_TABLE_H__ @@ -26,2076 +32,9247 @@ extern "C" { #endif + /* !!!DON'T CHANGE IQ_TABLE_SIZE!!! */ -#define IQ_TABLE_SIZE 1026 + #ifndef FIXED_POINT +#define IQ_TABLE_SIZE 8192 + #ifdef _MSC_VER #pragma warning(disable:4305) #pragma warning(disable:4244) #endif -static real_t iq_table[] = +ALIGN static const real_t iq_table[IQ_TABLE_SIZE] = { - 0.0000000000, - 1.0000000000, - 2.5198420998, - 4.3267487109, - 6.3496042079, - 8.5498797334, - 10.9027235570, - 13.3905182794, - 16.0000000000, - 18.7207544075, - 21.5443469003, - 24.4637809963, - 27.4731418213, - 30.5673509404, - 33.7419916985, - 36.9931811150, - 40.3174735966, - 43.7117870412, - 47.1733450958, - 50.6996313257, - 54.2883523319, - 57.9374077040, - 61.6448652744, - 65.4089405366, - 69.2279793748, - 73.1004434553, - 77.0248977786, - 81.0000000000, - 85.0244912125, - 89.0971879449, - 93.2169751786, - 97.3828002241, - 101.5936673260, - 105.8486328899, - 110.1468012434, - 114.4873208566, - 118.8693809602, - 123.2922085109, - 127.7550654584, - 132.2572462776, - 136.7980757341, - 141.3769068557, - 145.9931190852, - 150.6461165966, - 155.3353267543, - 160.0601987021, - 164.8202020667, - 169.6148257665, - 174.4435769119, - 179.3059797911, - 184.2015749320, - 189.1299182326, - 194.0905801545, - 199.0831449737, - 204.1072100830, - 209.1623853419, - 214.2482924705, - 219.3645644828, - 224.5108451564, - 229.6867885365, - 234.8920584701, - 240.1263281692, - 245.3892798002, - 250.6806040975, - 256.0000000000, - 261.3471743083, - 266.7218413611, - 272.1237227299, - 277.5525469304, - 283.0080491495, - 288.4899709866, - 293.9980602090, - 299.5320705195, - 305.0917613358, - 310.6768975818, - 316.2872494882, - 321.9225924034, - 327.5827066139, - 333.2673771724, - 338.9763937351, - 344.7095504051, - 350.4666455847, - 356.2474818330, - 362.0518657308, - 367.8796077506, - 373.7305221334, - 379.6044267700, - 385.5011430873, - 391.4204959402, - 397.3623135070, - 403.3264271901, - 409.3126715201, - 415.3208840636, - 421.3509053358, - 427.4025787150, - 433.4757503618, - 439.5702691405, - 445.6859865441, - 451.8227566217, - 457.9804359091, - 464.1588833613, - 470.3579602882, - 476.5775302922, - 482.8174592083, - 489.0776150459, - 495.3578679332, - 501.6580900633, - 507.9781556420, - 514.3179408377, - 520.6773237328, - 527.0561842769, - 533.4544042413, - 539.8718671753, - 546.3084583636, - 552.7640647857, - 559.2385750758, - 565.7318794845, - 572.2438698415, - 578.7744395198, - 585.3234834006, - 591.8908978393, - 598.4765806331, - 605.0804309888, - 611.7023494920, - 618.3422380776, - 625.0000000000, - 631.6755398055, - 638.3687633048, - 645.0795775462, - 651.8078907899, - 658.5536124831, - 665.3166532354, - 672.0969247951, - 678.8943400262, - 685.7088128862, - 692.5402584041, - 699.3885926590, - 706.2537327602, - 713.1355968262, - 720.0341039659, - 726.9491742592, - 733.8807287386, - 740.8286893712, - 747.7929790411, - 754.7735215322, - 761.7702415115, - 768.7830645130, - 775.8119169219, - 782.8567259587, - 789.9174196648, - 796.9939268870, - 804.0861772639, - 811.1941012115, - 818.3176299096, - 825.4566952887, - 832.6112300164, - 839.7811674856, - 846.9664418012, - 854.1669877685, - 861.3827408814, - 868.6136373104, - 875.8596138918, - 883.1206081164, - 890.3965581189, - 897.6874026669, - 904.9930811514, - 912.3135335758, - 919.6487005467, - 926.9985232641, - 934.3629435117, - 941.7419036483, - 949.1353465979, - 956.5432158417, - 963.9654554089, - 971.4020098686, - 978.8528243212, - 986.3178443907, - 993.7970162163, - 1001.2902864449, - 1008.7976022234, - 1016.3189111915, - 1023.8541614739, - 1031.4033016737, - 1038.9662808647, - 1046.5430485854, - 1054.1335548314, - 1061.7377500496, - 1069.3555851309, - 1076.9870114047, - 1084.6319806319, - 1092.2904449995, - 1099.9623571140, - 1107.6476699961, - 1115.3463370744, - 1123.0583121801, - 1130.7835495416, - 1138.5220037785, - 1146.2736298969, - 1154.0383832838, - 1161.8162197020, - 1169.6070952851, - 1177.4109665328, - 1185.2277903054, - 1193.0575238198, - 1200.9001246442, - 1208.7555506939, - 1216.6237602266, - 1224.5047118380, - 1232.3983644575, - 1240.3046773436, - 1248.2236100803, - 1256.1551225723, - 1264.0991750417, - 1272.0557280230, - 1280.0247423603, - 1288.0061792024, - 1296.0000000000, - 1304.0061665011, - 1312.0246407478, - 1320.0553850728, - 1328.0983620955, - 1336.1535347188, - 1344.2208661255, - 1352.3003197751, - 1360.3918594003, - 1368.4954490040, - 1376.6110528559, - 1384.7386354892, - 1392.8781616980, - 1401.0295965338, - 1409.1929053025, - 1417.3680535619, - 1425.5550071182, - 1433.7537320236, - 1441.9641945733, - 1450.1863613025, - 1458.4201989843, - 1466.6656746263, - 1474.9227554684, - 1483.1914089801, - 1491.4716028579, - 1499.7633050227, - 1508.0664836175, - 1516.3811070048, - 1524.7071437644, - 1533.0445626906, - 1541.3933327903, - 1549.7534232806, - 1558.1248035861, - 1566.5074433375, - 1574.9013123686, - 1583.3063807145, - 1591.7226186094, - 1600.1499964846, - 1608.5884849662, - 1617.0380548732, - 1625.4986772154, - 1633.9703231917, - 1642.4529641876, - 1650.9465717736, - 1659.4511177036, - 1667.9665739122, - 1676.4929125137, - 1685.0301057998, - 1693.5781262378, - 1702.1369464690, - 1710.7065393070, - 1719.2868777356, - 1727.8779349075, - 1736.4796841426, - 1745.0920989258, - 1753.7151529063, - 1762.3488198950, - 1770.9930738636, - 1779.6478889428, - 1788.3132394207, - 1796.9890997413, - 1805.6754445031, - 1814.3722484576, - 1823.0794865074, - 1831.7971337056, - 1840.5251652535, - 1849.2635564999, - 1858.0122829390, - 1866.7713202096, - 1875.5406440938, - 1884.3202305150, - 1893.1100555371, - 1901.9100953633, - 1910.7203263343, - 1919.5407249276, - 1928.3712677557, - 1937.2119315653, - 1946.0626932359, - 1954.9235297784, - 1963.7944183344, - 1972.6753361744, - 1981.5662606973, - 1990.4671694285, - 1999.3780400196, - 2008.2988502465, - 2017.2295780088, - 2026.1702013285, - 2035.1206983489, - 2044.0810473338, - 2053.0512266659, - 2062.0312148464, - 2071.0209904936, - 2080.0205323417, - 2089.0298192403, - 2098.0488301532, - 2107.0775441570, - 2116.1159404408, - 2125.1639983049, - 2134.2216971598, - 2143.2890165253, - 2152.3659360297, - 2161.4524354089, - 2170.5484945052, - 2179.6540932666, - 2188.7692117462, - 2197.8938301007, - 2207.0279285901, - 2216.1714875766, - 2225.3244875237, - 2234.4869089955, - 2243.6587326558, - 2252.8399392674, - 2262.0305096911, - 2271.2304248850, - 2280.4396659037, - 2289.6582138977, - 2298.8860501122, - 2308.1231558868, - 2317.3695126545, - 2326.6251019409, - 2335.8899053637, - 2345.1639046317, - 2354.4470815443, - 2363.7394179907, - 2373.0408959490, - 2382.3514974860, - 2391.6712047559, - 2401.0000000000, - 2410.3378655461, - 2419.6847838074, - 2429.0407372823, - 2438.4057085534, - 2447.7796802872, - 2457.1626352330, - 2466.5545562227, - 2475.9554261700, - 2485.3652280695, - 2494.7839449968, - 2504.2115601072, - 2513.6480566352, - 2523.0934178943, - 2532.5476272760, - 2542.0106682495, - 2551.4825243609, - 2560.9631792328, - 2570.4526165636, - 2579.9508201270, - 2589.4577737714, - 2598.9734614194, - 2608.4978670675, - 2618.0309747849, - 2627.5727687136, - 2637.1232330677, - 2646.6823521328, - 2656.2501102653, - 2665.8264918923, - 2675.4114815110, - 2685.0050636878, - 2694.6072230582, - 2704.2179443264, - 2713.8372122643, - 2723.4650117115, - 2733.1013275747, - 2742.7461448270, - 2752.3994485079, - 2762.0612237221, - 2771.7314556399, - 2781.4101294962, - 2791.0972305902, - 2800.7927442847, - 2810.4966560063, - 2820.2089512442, - 2829.9296155502, - 2839.6586345385, - 2849.3959938845, - 2859.1416793251, - 2868.8956766580, - 2878.6579717413, - 2888.4285504930, - 2898.2073988909, - 2907.9945029718, - 2917.7898488313, - 2927.5934226236, - 2937.4052105607, - 2947.2251989123, - 2957.0533740053, - 2966.8897222234, - 2976.7342300070, - 2986.5868838523, - 2996.4476703115, - 3006.3165759920, - 3016.1935875562, - 3026.0786917212, - 3035.9718752584, - 3045.8731249931, - 3055.7824278041, - 3065.6997706236, - 3075.6251404365, - 3085.5585242804, - 3095.4999092450, - 3105.4492824719, - 3115.4066311543, - 3125.3719425365, - 3135.3452039137, - 3145.3264026318, - 3155.3155260867, - 3165.3125617243, - 3175.3174970403, - 3185.3303195795, - 3195.3510169356, - 3205.3795767511, - 3215.4159867169, - 3225.4602345719, - 3235.5123081028, - 3245.5721951437, - 3255.6398835758, - 3265.7153613275, - 3275.7986163735, - 3285.8896367348, - 3295.9884104787, - 3306.0949257178, - 3316.2091706107, - 3326.3311333606, - 3336.4608022160, - 3346.5981654700, - 3356.7432114599, - 3366.8959285672, - 3377.0563052172, - 3387.2243298788, - 3397.3999910641, - 3407.5832773283, - 3417.7741772695, - 3427.9726795281, - 3438.1787727870, - 3448.3924457710, - 3458.6136872466, - 3468.8424860221, - 3479.0788309468, - 3489.3227109112, - 3499.5741148464, - 3509.8330317244, - 3520.0994505573, - 3530.3733603973, - 3540.6547503364, - 3550.9436095064, - 3561.2399270783, - 3571.5436922624, - 3581.8548943078, - 3592.1735225026, - 3602.4995661730, - 3612.8330146838, - 3623.1738574377, - 3633.5220838752, - 3643.8776834744, - 3654.2406457510, - 3664.6109602577, - 3674.9886165844, - 3685.3736043574, - 3695.7659132398, - 3706.1655329312, - 3716.5724531671, - 3726.9866637191, - 3737.4081543945, - 3747.8369150361, - 3758.2729355221, - 3768.7162057659, - 3779.1667157159, - 3789.6244553551, - 3800.0894147012, - 3810.5615838063, - 3821.0409527566, - 3831.5275116724, - 3842.0212507077, - 3852.5221600504, - 3863.0302299216, - 3873.5454505757, - 3884.0678123003, - 3894.5973054159, - 3905.1339202756, - 3915.6776472653, - 3926.2284768030, - 3936.7863993390, - 3947.3514053559, - 3957.9234853677, - 3968.5026299205, - 3979.0888295917, - 3989.6820749901, - 4000.2823567557, - 4010.8896655596, - 4021.5039921036, - 4032.1253271203, - 4042.7536613729, - 4053.3889856548, - 4064.0312907898, - 4074.6805676315, - 4085.3368070638, - 4096.0000000000, - 4106.6701373831, - 4117.3472101855, - 4128.0312094089, - 4138.7221260843, - 4149.4199512713, - 4160.1246760588, - 4170.8362915639, - 4181.5547889326, - 4192.2801593392, - 4203.0123939861, - 4213.7514841039, - 4224.4974209512, - 4235.2501958144, - 4246.0098000075, - 4256.7762248721, - 4267.5494617770, - 4278.3295021186, - 4289.1163373202, - 4299.9099588321, - 4310.7103581313, - 4321.5175267219, - 4332.3314561342, - 4343.1521379251, - 4353.9795636778, - 4364.8137250016, - 4375.6546135320, - 4386.5022209304, - 4397.3565388837, - 4408.2175591050, - 4419.0852733324, - 4429.9596733298, - 4440.8407508861, - 4451.7284978156, - 4462.6229059575, - 4473.5239671759, - 4484.4316733599, - 4495.3460164231, - 4506.2669883035, - 4517.1945809640, - 4528.1287863914, - 4539.0695965968, - 4550.0170036156, - 4560.9709995068, - 4571.9315763535, - 4582.8987262626, - 4593.8724413645, - 4604.8527138130, - 4615.8395357856, - 4626.8328994828, - 4637.8327971284, - 4648.8392209693, - 4659.8521632753, - 4670.8716163390, - 4681.8975724760, - 4692.9300240243, - 4703.9689633444, - 4715.0143828193, - 4726.0662748543, - 4737.1246318771, - 4748.1894463371, - 4759.2607107062, - 4770.3384174777, - 4781.4225591672, - 4792.5131283116, - 4803.6101174696, - 4814.7135192213, - 4825.8233261683, - 4836.9395309335, - 4848.0621261609, - 4859.1911045158, - 4870.3264586842, - 4881.4681813733, - 4892.6162653110, - 4903.7707032459, - 4914.9314879474, - 4926.0986122052, - 4937.2720688295, - 4948.4518506510, - 4959.6379505206, - 4970.8303613092, - 4982.0290759079, - 4993.2340872279, - 5004.4453882001, - 5015.6629717753, - 5026.8868309241, - 5038.1169586365, - 5049.3533479223, - 5060.5959918105, - 5071.8448833497, - 5083.1000156077, - 5094.3613816714, - 5105.6289746470, - 5116.9027876595, - 5128.1828138531, - 5139.4690463907, - 5150.7614784539, - 5162.0601032433, - 5173.3649139777, - 5184.6759038949, - 5195.9930662506, - 5207.3163943194, - 5218.6458813939, - 5229.9815207850, - 5241.3233058217, - 5252.6712298510, - 5264.0252862380, - 5275.3854683656, - 5286.7517696346, - 5298.1241834635, - 5309.5027032884, - 5320.8873225631, - 5332.2780347590, - 5343.6748333647, - 5355.0777118863, - 5366.4866638472, - 5377.9016827880, - 5389.3227622665, - 5400.7498958574, - 5412.1830771527, - 5423.6222997611, - 5435.0675573082, - 5446.5188434364, - 5457.9761518049, - 5469.4394760894, - 5480.9088099822, - 5492.3841471923, - 5503.8654814448, - 5515.3528064816, - 5526.8461160606, - 5538.3454039558, - 5549.8506639579, - 5561.3618898731, - 5572.8790755240, - 5584.4022147491, - 5595.9313014028, - 5607.4663293552, - 5619.0072924923, - 5630.5541847159, - 5642.1069999431, - 5653.6657321070, - 5665.2303751559, - 5676.8009230538, - 5688.3773697797, - 5699.9597093284, - 5711.5479357096, - 5723.1420429485, - 5734.7420250850, - 5746.3478761746, - 5757.9595902874, - 5769.5771615087, - 5781.2005839386, - 5792.8298516920, - 5804.4649588987, - 5816.1058997031, - 5827.7526682643, - 5839.4052587560, - 5851.0636653664, - 5862.7278822983, - 5874.3979037688, - 5886.0737240093, - 5897.7553372658, - 5909.4427377983, - 5921.1359198811, - 5932.8348778025, - 5944.5396058651, - 5956.2500983854, - 5967.9663496940, - 5979.6883541351, - 5991.4161060672, - 6003.1495998623, - 6014.8888299063, - 6026.6337905987, - 6038.3844763527, - 6050.1408815952, - 6061.9030007664, - 6073.6708283203, - 6085.4443587241, - 6097.2235864585, - 6109.0085060174, - 6120.7991119082, - 6132.5953986513, - 6144.3973607806, - 6156.2049928426, - 6168.0182893975, - 6179.8372450182, - 6191.6618542904, - 6203.4921118132, - 6215.3280121982, - 6227.1695500700, - 6239.0167200659, - 6250.8695168361, - 6262.7279350432, - 6274.5919693627, - 6286.4616144826, - 6298.3368651034, - 6310.2177159382, - 6322.1041617124, - 6333.9961971640, - 6345.8938170431, - 6357.7970161124, - 6369.7057891466, - 6381.6201309327, - 6393.5400362700, - 6405.4654999698, - 6417.3965168555, - 6429.3330817625, - 6441.2751895383, - 6453.2228350423, - 6465.1760131457, - 6477.1347187317, - 6489.0989466952, - 6501.0686919430, - 6513.0439493936, - 6525.0247139769, - 6537.0109806350, - 6549.0027443210, - 6561.0000000000, - 6573.0027426484, - 6585.0109672541, - 6597.0246688165, - 6609.0438423464, - 6621.0684828657, - 6633.0985854079, - 6645.1341450177, - 6657.1751567510, - 6669.2216156747, - 6681.2735168671, - 6693.3308554176, - 6705.3936264265, - 6717.4618250051, - 6729.5354462759, - 6741.6144853722, - 6753.6989374383, - 6765.7887976291, - 6777.8840611107, - 6789.9847230597, - 6802.0907786636, - 6814.2022231205, - 6826.3190516394, - 6838.4412594396, - 6850.5688417513, - 6862.7017938151, - 6874.8401108821, - 6886.9837882140, - 6899.1328210829, - 6911.2872047712, - 6923.4469345719, - 6935.6120057882, - 6947.7824137335, - 6959.9581537318, - 6972.1392211169, - 6984.3256112330, - 6996.5173194347, - 7008.7143410863, - 7020.9166715624, - 7033.1243062477, - 7045.3372405367, - 7057.5554698343, - 7069.7789895548, - 7082.0077951229, - 7094.2418819728, - 7106.4812455489, - 7118.7258813051, - 7130.9757847053, - 7143.2309512230, - 7155.4913763416, - 7167.7570555538, - 7180.0279843624, - 7192.3041582795, - 7204.5855728270, - 7216.8722235361, - 7229.1641059476, - 7241.4612156120, - 7253.7635480891, - 7266.0710989478, - 7278.3838637670, - 7290.7018381344, - 7303.0250176474, - 7315.3533979125, - 7327.6869745455, - 7340.0257431713, - 7352.3696994244, - 7364.7188389480, - 7377.0731573946, - 7389.4326504259, - 7401.7973137127, - 7414.1671429346, - 7426.5421337804, - 7438.9222819480, - 7451.3075831438, - 7463.6980330837, - 7476.0936274921, - 7488.4943621024, - 7500.9002326569, - 7513.3112349065, - 7525.7273646110, - 7538.1486175390, - 7550.5749894679, - 7563.0064761834, - 7575.4430734804, - 7587.8847771619, - 7600.3315830400, - 7612.7834869349, - 7625.2404846758, - 7637.7025721001, - 7650.1697450538, - 7662.6419993914, - 7675.1193309757, - 7687.6017356782, - 7700.0892093785, - 7712.5817479647, - 7725.0793473331, - 7737.5820033885, - 7750.0897120437, - 7762.6024692201, - 7775.1202708469, - 7787.6431128620, - 7800.1709912110, - 7812.7039018478, - 7825.2418407347, - 7837.7848038416, - 7850.3327871468, - 7862.8857866366, - 7875.4437983052, - 7888.0068181548, - 7900.5748421957, - 7913.1478664460, - 7925.7258869318, - 7938.3088996870, - 7950.8969007534, - 7963.4898861807, - 7976.0878520263, - 7988.6907943555, - 8001.2987092412, - 8013.9115927643, - 8026.5294410131, - 8039.1522500838, - 8051.7800160802, - 8064.4127351138, - 8077.0504033037, - 8089.6930167764, - 8102.3405716663, - 8114.9930641151, - 8127.6504902721, - 8140.3128462940, - 8152.9801283453, - 8165.6523325976, - 8178.3294552300, - 8191.0114924292, - 8203.6984403890, - 8216.3902953107, - 8229.0870534031, - 8241.7887108821, - 8254.4952639709, - 8267.2067089000, - 8279.9230419073, - 8292.6442592376, - 8305.3703571432, - 8318.1013318835, - 8330.8371797251, - 8343.5778969415, - 8356.3234798136, - 8369.0739246292, - 8381.8292276834, - 8394.5893852780, - 8407.3543937222, - 8420.1242493321, - 8432.8989484305, - 8445.6784873475, - 8458.4628624202, - 8471.2520699922, - 8484.0461064144, - 8496.8449680444, - 8509.6486512468, - 8522.4571523928, - 8535.2704678607, - 8548.0885940353, - 8560.9115273086, - 8573.7392640788, - 8586.5718007514, - 8599.4091337382, - 8612.2512594579, - 8625.0981743359, - 8637.9498748040, - 8650.8063573010, - 8663.6676182722, - 8676.5336541692, - 8689.4044614507, - 8702.2800365815, - 8715.1603760331, - 8728.0454762838, - 8740.9353338178, - 8753.8299451264, - 8766.7293067070, - 8779.6334150636, - 8792.5422667064, - 8805.4558581523, - 8818.3741859245, - 8831.2972465524, - 8844.2250365719, - 8857.1575525253, - 8870.0947909611, - 8883.0367484340, - 8895.9834215053, - 8908.9348067421, - 8921.8909007182, - 8934.8517000133, - 8947.8172012135, + 0, + 1, + 2.5198420997897464, + 4.3267487109222245, + 6.3496042078727974, + 8.5498797333834844, + 10.902723556992836, + 13.390518279406722, + 15.999999999999998, + 18.720754407467133, + 21.544346900318832, + 24.463780996262464, + 27.47314182127996, + 30.567350940369842, + 33.741991698453212, + 36.993181114957046, + 40.317473596635935, + 43.711787041189993, + 47.173345095760126, + 50.699631325716943, + 54.288352331898118, + 57.937407704003519, + 61.6448652744185, + 65.408940536585988, + 69.227979374755591, + 73.100443455321638, + 77.024897778591622, + 80.999999999999986, + 85.024491212518527, + 89.097187944889555, + 93.216975178615741, + 97.382800224133163, + 101.59366732596474, + 105.84863288986224, + 110.14680124343441, + 114.4873208566006, + 118.86938096020653, + 123.29220851090024, + 127.75506545836058, + 132.25724627755247, + 136.79807573413572, + 141.37690685569191, + 145.99311908523086, + 150.6461165966291, + 155.33532675434674, + 160.06019870205279, + 164.82020206673349, + 169.61482576651861, + 174.44357691188537, + 179.30597979112557, + 184.20157493201927, + 189.12991823257562, + 194.09058015449685, + 199.08314497371677, + 204.1072100829694, + 209.16238534187647, + 214.24829247050752, + 219.36456448277784, + 224.51084515641216, + 229.6867885365223, + 234.89205847013176, + 240.12632816923249, + 245.38927980018505, + 250.68060409747261, + 255.99999999999991, + 261.34717430828869, + 266.72184136106449, + 272.12372272986045, + 277.55254693037961, + 283.0080491494619, + 288.48997098659891, + 293.99806020902247, + 299.53207051947408, + 305.0917613358298, + 310.67689758182206, + 316.28724948815585, + 321.92259240337177, + 327.58270661385535, + 333.26737717243742, + 338.97639373507025, + 344.70955040510125, + 350.46664558470013, + 356.24748183302603, + 362.05186573075139, + 367.87960775058258, + 373.73052213344511, + 379.60442677002078, + 385.50114308734607, + 391.42049594019937, + 397.36231350702371, + 403.32642719014467, + 409.31267152006262, + 415.32088406360799, + 421.35090533576471, + 427.40257871497619, + 433.4757503617617, + 439.5702691404793, + 445.68598654408271, + 451.82275662172759, + 457.98043590909128, + 464.15888336127773, + 470.35796028818726, + 476.5775302922363, + 482.81745920832043, + 489.07761504591741, + 495.35786793323581, + 501.65809006331688, + 507.97815564200368, + 514.31794083769648, + 520.67732373281672, + 527.05618427690604, + 533.45440424129174, + 539.87186717525128, + 546.30845836361505, + 552.76406478574609, + 559.23857507584194, + 565.73187948450413, + 572.24386984152341, + 578.77443951983378, + 585.32348340058843, + 591.89089783931263, + 598.47658063309257, + 605.08043098876044, + 611.70234949203643, + 618.3422380775919, + 624.99999999999977, + 631.67553980553748, + 638.36876330481164, + 645.07957754617485, + 651.80789078990415, + 658.55361248311499, + 665.31665323538357, + 672.09692479505225, + 678.8943400261943, + 685.70881288621433, + 692.540258404062, + 699.38859265903977, + 706.25373276018058, + 713.13559682617972, + 720.03410396586037, + 726.94917425915435, + 733.88072873858209, + 740.82868937121543, + 747.79297904110535, + 754.77352153216191, + 761.77024151147043, + 768.78306451302956, + 775.81191692189896, + 782.85672595874246, + 789.91741966475445, + 796.99392688695798, + 804.08617726386274, + 811.19410121147098, + 818.31762990962227, + 825.45669528866563, + 832.61123001644864, + 839.78116748561604, + 846.96644180120552, + 854.16698776853514, + 861.38274088137143, + 868.61363731036977, + 875.85961389178203, + 883.12060811641959, + 890.39655811886757, + 897.68740266694181, + 904.99308115138172, + 912.31353357577188, + 919.64870054668756, + 926.99852326405619, + 934.36294351172899, + 941.74190364825859, + 949.13534659787422, + 956.54321584165211, + 963.96545540887348, + 971.40200986856541, + 978.85282432122176, + 986.31784439069588, + 993.7970162162635, + 1001.29028644485, + 1008.797602223418, + 1016.3189111915103, + 1023.8541614739464, + 1031.4033016736653, + 1038.9662808647138, + 1046.5430485853758, + 1054.1335548314366, + 1061.7377500495838, + 1069.3555851309357, + 1076.9870114046978, + 1084.6319806319441, + 1092.2904449995174, + 1099.9623571140482, + 1107.6476699960892, + 1115.3463370743607, + 1123.058312180106, + 1130.7835495415541, + 1138.5220037784854, + 1146.273629896901, + 1154.0383832837879, + 1161.816219701986, + 1169.607095285146, + 1177.4109665327808, + 1185.2277903054078, + 1193.0575238197798, + 1200.9001246442001, + 1208.7555506939248, + 1216.6237602266442, + 1224.5047118380478, + 1232.3983644574657, + 1240.3046773435874, + 1248.2236100802568, + 1256.1551225723395, + 1264.099175041662, + 1272.0557280230228, + 1280.0247423602691, + 1288.0061792024444, + 1295.9999999999995, + 1304.006166501068, + 1312.0246407478062, + 1320.0553850727929, + 1328.0983620954903, + 1336.1535347187651, + 1344.2208661254647, + 1352.3003197750522, + 1360.3918594002962, + 1368.4954490040145, + 1376.6110528558709, + 1384.7386354892244, + 1392.8781616980295, + 1401.0295965337855, + 1409.1929053025353, + 1417.3680535619119, + 1425.5550071182327, + 1433.7537320236374, + 1441.9641945732744, + 1450.1863613025282, + 1458.4201989842913, + 1466.6656746262797, + 1474.9227554683875, + 1483.1914089800841, + 1491.4716028578516, + 1499.7633050226596, + 1508.0664836174794, + 1516.3811070048375, + 1524.7071437644029, + 1533.0445626906128, + 1541.3933327903342, + 1549.7534232805581, + 1558.1248035861302, + 1566.507443337515, + 1574.9013123685909, + 1583.3063807144795, + 1591.7226186094069, + 1600.1499964845941, + 1608.58848496618, + 1617.0380548731737, + 1625.4986772154357, + 1633.9703231916887, + 1642.4529641875577, + 1650.9465717736346, + 1659.4511177035752, + 1667.9665739122186, + 1676.4929125137353, + 1685.030105799801, + 1693.5781262377957, + 1702.136946469027, + 1710.7065393069795, + 1719.2868777355877, + 1727.8779349075323, + 1736.4796841425596, + 1745.092098925825, + 1753.7151529062583, + 1762.3488198949503, + 1770.9930738635628, + 1779.6478889427597, + 1788.3132394206564, + 1796.9890997412947, + 1805.6754445031333, + 1814.3722484575621, + 1823.0794865074322, + 1831.7971337056094, + 1840.5251652535437, + 1849.2635564998579, + 1858.0122829389563, + 1866.7713202096493, + 1875.5406440937966, + 1884.3202305149687, + 1893.110055537124, + 1901.9100953633042, + 1910.7203263343454, + 1919.5407249276057, + 1928.3712677557098, + 1937.2119315653083, + 1946.0626932358525, + 1954.923529778386, + 1963.79441833435, + 1972.6753361744036, + 1981.5662606972594, + 1990.467169428533, + 1999.3780400196069, + 2008.2988502465078, + 2017.2295780087982, + 2026.1702013284819, + 2035.1206983489212, + 2044.0810473337688, + 2053.0512266659125, + 2062.0312148464309, + 2071.0209904935646, + 2080.0205323416958, + 2089.0298192403443, + 2098.0488301531714, + 2107.0775441569995, + 2116.115940440839, + 2125.1639983049317, + 2134.2216971597995, + 2143.2890165253098, + 2152.3659360297484, + 2161.4524354089031, + 2170.5484945051617, + 2179.6540932666144, + 2188.7692117461711, + 2197.8938301006888, + 2207.0279285901042, + 2216.1714875765838, + 2225.324487523676, + 2234.4869089954782, + 2243.6587326558101, + 2252.8399392673982, + 2262.0305096910702, + 2271.2304248849537, + 2280.4396659036897, + 2289.6582138976523, + 2298.8860501121762, + 2308.1231558867926, + 2317.3695126544767, + 2326.6251019409005, + 2335.8899053636933, + 2345.1639046317132, + 2354.4470815443233, + 2363.7394179906792, + 2373.0408959490205, + 2382.3514974859731, + 2391.6712047558558, + 2400.9999999999991, + 2410.3378655460651, + 2419.6847838073813, + 2429.0407372822747, + 2438.4057085534191, + 2447.7796802871858, + 2457.1626352330004, + 2466.5545562227112, + 2475.9554261699564, + 2485.3652280695474, + 2494.7839449968492, + 2504.2115601071737, + 2513.6480566351788, + 2523.0934178942675, + 2532.5476272760025, + 2542.0106682495189, + 2551.482524360948, + 2560.9631792328441, + 2570.4526165636184, + 2579.9508201269791, + 2589.4577737713744, + 2598.9734614194458, + 2608.4978670674823, + 2618.0309747848837, + 2627.5727687136259, + 2637.1232330677353, + 2646.6823521327647, + 2656.2501102652768, + 2665.8264918923328, + 2675.4114815109842, + 2685.0050636877722, + 2694.6072230582295, + 2704.2179443263894, + 2713.8372122642972, + 2723.4650117115279, + 2733.1013275747096, + 2742.7461448270483, + 2752.3994485078601, + 2762.0612237221085, + 2771.7314556399419, + 2781.4101294962406, + 2791.0972305901655, + 2800.7927442847094, + 2810.4966560062589, + 2820.2089512441521, + 2829.9296155502466, + 2839.6586345384894, + 2849.3959938844923, + 2859.1416793251065, + 2868.8956766580086, + 2878.6579717412847, + 2888.4285504930212, + 2898.2073988908974, + 2907.9945029717837, + 2917.789848831344, + 2927.5934226236377, + 2937.4052105607311, + 2947.2251989123079, + 2957.0533740052865, + 2966.8897222234368, + 2976.734230007005, + 2986.5868838523397, + 2996.4476703115197, + 3006.3165759919889, + 3016.1935875561908, + 3026.0786917212095, + 3035.9718752584108, + 3045.8731249930906, + 3055.7824278041207, + 3065.6997706236039, + 3075.625140436528, + 3085.5585242804245, + 3095.4999092450298, + 3105.4492824719491, + 3115.4066311543256, + 3125.3719425365089, + 3135.3452039137287, + 3145.3264026317715, + 3155.3155260866592, + 3165.3125617243295, + 3175.3174970403229, + 3185.3303195794679, + 3195.35101693557, + 3205.3795767511078, + 3215.4159867169251, + 3225.460234571929, + 3235.5123081027928, + 3245.5721951436558, + 3255.63988357583, + 3265.7153613275095, + 3275.7986163734795, + 3285.8896367348289, + 3295.9884104786665, + 3306.0949257178395, + 3316.2091706106517, + 3326.331133360588, + 3336.4608022160378, + 3346.5981654700231, + 3356.7432114599264, + 3366.8959285672249, + 3377.0563052172211, + 3387.2243298787821, + 3397.3999910640764, + 3407.5832773283128, + 3417.7741772694862, + 3427.9726795281199, + 3438.1787727870123, + 3448.3924457709873, + 3458.6136872466445, + 3468.8424860221107, + 3479.0788309467976, + 3489.3227109111554, + 3499.5741148464344, + 3509.8330317244445, + 3520.0994505573185, + 3530.3733603972751, + 3540.6547503363886, + 3550.9436095063534, + 3561.239927078258, + 3571.5436922623535, + 3581.8548943078308, + 3592.1735225025936, + 3602.4995661730372, + 3612.8330146838275, + 3623.1738574376814, + 3633.5220838751502, + 3643.8776834744031, + 3654.2406457510142, + 3664.6109602577494, + 3674.9886165843564, + 3685.3736043573545, + 3695.7659132398294, + 3706.1655329312248, + 3716.5724531671399, + 3726.9866637191262, + 3737.4081543944876, + 3747.8369150360782, + 3758.2729355221072, + 3768.7162057659411, + 3779.1667157159077, + 3789.6244553551055, + 3800.0894147012082, + 3810.5615838062768, + 3821.0409527565694, + 3831.5275116723533, + 3842.0212507077194, + 3852.522160050396, + 3863.0302299215673, + 3873.5454505756893, + 3884.0678123003108, + 3894.5973054158922, + 3905.1339202756285, + 3915.6776472652732, + 3926.2284768029604, + 3936.7863993390338, + 3947.3514053558706, + 3957.9234853677135, + 3968.5026299204969, + 3979.0888295916798, + 3989.6820749900776, + 4000.2823567556948, + 4010.8896655595613, + 4021.5039921035655, + 4032.1253271202945, + 4042.7536613728694, + 4053.3889856547858, + 4064.0312907897551, + 4074.6805676315448, + 4085.3368070638221, + 4095.9999999999982, + 4106.6701373830711, + 4117.347210185475, + 4128.0312094089259, + 4138.722126084268, + 4149.4199512713267, + 4160.1246760587583, + 4170.8362915638982, + 4181.5547889326181, + 4192.2801593391769, + 4203.0123939860741, + 4213.7514841039101, + 4224.4974209512384, + 4235.2501958144258, + 4246.0098000075095, + 4256.7762248720574, + 4267.549461777031, + 4278.3295021186423, + 4289.1163373202198, + 4299.9099588320714, + 4310.7103581313495, + 4321.5175267219138, + 4332.3314561342004, + 4343.152137925088, + 4353.9795636777671, + 4364.8137250016052, + 4375.6546135320223, + 4386.5022209303588, + 4397.3565388837469, + 4408.2175591049827, + 4419.0852733324018, + 4429.9596733297531, + 4440.8407508860728, + 4451.7284978155603, + 4462.6229059574571, + 4473.5239671759227, + 4484.4316733599126, + 4495.3460164230582, + 4506.2669883035496, + 4517.1945809640119, + 4528.1287863913894, + 4539.069596596828, + 4550.0170036155587, + 4560.9709995067806, + 4571.931576353546, + 4582.898726262647, + 4593.8724413645004, + 4604.8527138130348, + 4615.8395357855816, + 4626.8328994827571, + 4637.8327971283588, + 4648.8392209692511, + 4659.8521632752563, + 4670.8716163390473, + 4681.8975724760394, + 4692.9300240242837, + 4703.9689633443595, + 4715.0143828192668, + 4726.0662748543255, + 4737.1246318770682, + 4748.1894463371373, + 4759.2607107061804, + 4770.3384174777493, + 4781.4225591671993, + 4792.5131283115852, + 4803.6101174695614, + 4814.7135192212854, + 4825.8233261683154, + 4836.9395309335096, + 4848.0621261609349, + 4859.1911045157631, + 4870.3264586841779, + 4881.4681813732768, + 4892.6162653109768, + 4903.7707032459193, + 4914.931487947375, + 4926.0986122051509, + 4937.2720688294967, + 4948.4518506510112, + 4959.637950520555, + 4970.8303613091521, + 4982.0290759079044, + 4993.2340872278974, + 5004.4453882001153, + 5015.6629717753467, + 5026.8868309241007, + 5038.1169586365131, + 5049.353347922266, + 5060.5959918104927, + 5071.8448833496996, + 5083.1000156076734, + 5094.3613816713996, + 5105.6289746469747, + 5116.9027876595246, + 5128.18281385312, + 5139.4690463906918, + 5150.7614784539473, + 5162.0601032432933, + 5173.3649139777472, + 5184.6759038948594, + 5195.9930662506322, + 5207.3163943194386, + 5218.6458813939435, + 5229.9815207850224, + 5241.3233058216847, + 5252.6712298509919, + 5264.025286237983, + 5275.3854683655954, + 5286.7517696345885, + 5298.1241834634639, + 5309.5027032883945, + 5320.887322563146, + 5332.2780347589978, + 5343.6748333646756, + 5355.0777118862716, + 5366.4866638471722, + 5377.901682787985, + 5389.3227622664635, + 5400.749895857437, + 5412.1830771527357, + 5423.622299761123, + 5435.067557308219, + 5446.5188434364318, + 5457.9761518048872, + 5469.4394760893592, + 5480.9088099821975, + 5492.3841471922606, + 5503.8654814448455, + 5515.3528064816201, + 5526.846116060552, + 5538.3454039558474, + 5549.8506639578736, + 5561.3618898731029, + 5572.8790755240361, + 5584.4022147491451, + 5595.9313014027975, + 5607.4663293552012, + 5619.0072924923297, + 5630.5541847158656, + 5642.1069999431284, + 5653.665732107017, + 5665.230375155943, + 5676.8009230537655, + 5688.3773697797333, + 5699.9597093284156, + 5711.5479357096474, + 5723.1420429484588, + 5734.7420250850209, + 5746.347876174581, + 5757.9595902874016, + 5769.5771615087006, + 5781.2005839385911, + 5792.8298516920213, + 5804.4649588987149, + 5816.1058997031105, + 5827.7526682643065, + 5839.4052587559972, + 5851.0636653664196, + 5862.7278822982908, + 5874.3979037687541, + 5886.0737240093204, + 5897.7553372658094, + 5909.4427377982956, + 5921.1359198810505, + 5932.8348778024874, + 5944.5396058651031, + 5956.2500983854261, + 5967.9663496939575, + 5979.6883541351208, + 5991.4161060672022, + 6003.1495998623004, + 6014.8888299062692, + 6026.6337905986684, + 6038.3844763527022, + 6050.1408815951781, + 6061.9030007664414, + 6073.6708283203316, + 6085.4443587241267, + 6097.2235864584891, + 6109.0085060174197, + 6120.7991119081998, + 6132.595398651345, + 6144.3973607805519, + 6156.2049928426459, + 6168.0182893975361, + 6179.8372450181578, + 6191.6618542904307, + 6203.4921118132024, + 6215.3280121982016, + 6227.1695500699925, + 6239.0167200659189, + 6250.8695168360628, + 6262.7279350431891, + 6274.5919693627056, + 6286.4616144826068, + 6298.3368651034316, + 6310.2177159382172, + 6322.1041617124456, + 6333.9961971640032, + 6345.8938170431311, + 6357.7970161123785, + 6369.7057891465583, + 6381.6201309327007, + 6393.5400362700075, + 6405.4654999698032, + 6417.3965168554978, + 6429.3330817625329, + 6441.2751895383453, + 6453.2228350423138, + 6465.176013145724, + 6477.134718731716, + 6489.0989466952469, + 6501.0686919430445, + 6513.0439493935628, + 6525.0247139769417, + 6537.010980634961, + 6549.002744321001, + 6560.9999999999973, + 6573.0027426483985, + 6585.0109672541284, + 6597.0246688165371, + 6609.0438423463656, + 6621.0684828657004, + 6633.0985854079354, + 6645.134145017727, + 6657.1751567509573, + 6669.2216156746908, + 6681.2735168671343, + 6693.3308554176001, + 6705.3936264264594, + 6717.461825005108, + 6729.535446275926, + 6741.6144853722335, + 6753.6989374382601, + 6765.7887976290967, + 6777.8840611106634, + 6789.9847230596661, + 6802.0907786635626, + 6814.2022231205201, + 6826.3190516393797, + 6838.4412594396181, + 6850.5688417513074, + 6862.701793815083, + 6874.840110882099, + 6886.9837882139991, + 6899.1328210828724, + 6911.2872047712199, + 6923.4469345719199, + 6935.6120057881863, + 6947.7824137335365, + 6959.9581537317536, + 6972.1392211168532, + 6984.3256112330409, + 6996.5173194346862, + 7008.7143410862773, + 7020.9166715623942, + 7033.1243062476678, + 7045.3372405367481, + 7057.5554698342685, + 7069.7789895548103, + 7082.0077951228714, + 7094.2418819728273, + 7106.4812455489018, + 7118.7258813051285, + 7130.9757847053224, + 7143.2309512230404, + 7155.4913763415516, + 7167.7570555538041, + 7180.0279843623894, + 7192.3041582795131, + 7204.5855728269571, + 7216.8722235360519, + 7229.1641059476406, + 7241.4612156120484, + 7253.7635480890503, + 7266.0710989478375, + 7278.3838637669869, + 7290.7018381344296, + 7303.0250176474174, + 7315.3533979124932, + 7327.6869745454596, + 7340.0257431713462, + 7352.3696994243801, + 7364.7188389479543, + 7377.0731573945968, + 7389.4326504259407, + 7401.7973137126937, + 7414.1671429346061, + 7426.5421337804428, + 7438.922281947951, + 7451.3075831438346, + 7463.6980330837177, + 7476.0936274921214, + 7488.4943621024304, + 7500.9002326568652, + 7513.3112349064522, + 7525.7273646109943, + 7538.1486175390446, + 7550.5749894678729, + 7563.0064761834419, + 7575.4430734803736, + 7587.8847771619248, + 7600.3315830399597, + 7612.7834869349153, + 7625.24048467578, + 7637.7025721000637, + 7650.1697450537677, + 7662.6419993913596, + 7675.1193309757446, + 7687.6017356782404, + 7700.0892093785433, + 7712.5817479647112, + 7725.079347333125, + 7737.5820033884729, + 7750.0897120437139, + 7762.6024692200581, + 7775.1202708469355, + 7787.6431128619733, + 7800.1709912109645, + 7812.7039018478481, + 7825.2418407346768, + 7837.7848038415968, + 7850.3327871468155, + 7862.8857866365806, + 7875.4437983051539, + 7888.006818154784, + 7900.5748421956796, + 7913.1478664459901, + 7925.725886931772, + 7938.3088996869719, + 7950.8969007533951, + 7963.4898861806851, + 7976.0878520262959, + 7988.6907943554688, + 8001.2987092412086, + 8013.911592764257, + 8026.5294410130691, + 8039.1522500837891, + 8051.7800160802271, + 8064.412735113835, + 8077.0504033036796, + 8089.6930167764222, + 8102.3405716662946, + 8114.9930641150731, + 8127.6504902720571, + 8140.3128462940449, + 8152.9801283453098, + 8165.6523325975786, + 8178.3294552300049, + 8191.0114924291529, + 8203.6984403889655, + 8216.3902953107463, + 8229.0870534031419, + 8241.7887108821069, + 8254.4952639708936, + 8267.2067089000211, + 8279.9230419072574, + 8292.6442592375952, + 8305.3703571432306, + 8318.101331883543, + 8330.8371797250657, + 8343.577896941475, + 8356.3234798135582, + 8369.0739246291978, + 8381.8292276833508, + 8394.5893852780209, + 8407.3543937222421, + 8420.1242493320569, + 8432.8989484304948, + 8445.6784873475499, + 8458.4628624201578, + 8471.2520699921806, + 8484.0461064143838, + 8496.8449680444082, + 8509.6486512467636, + 8522.4571523927953, + 8535.270467860666, + 8548.0885940353437, + 8560.9115273085663, + 8573.7392640788403, + 8586.5718007514006, + 8599.4091337382069, + 8612.2512594579148, + 8625.0981743358552, + 8637.9498748040205, + 8650.8063573010386, + 8663.6676182721567, + 8676.533654169225, + 8689.4044614506638, + 8702.2800365814601, + 8715.1603760331418, + 8728.0454762837508, + 8740.9353338178389, + 8753.8299451264356, + 8766.7293067070332, + 8779.6334150635721, + 8792.5422667064158, + 8805.4558581523324, + 8818.3741859244819, + 8831.2972465523908, + 8844.2250365719356, + 8857.1575525253265, + 8870.0947909610859, + 8883.0367484340295, + 8895.9834215052524, + 8908.934806742107, + 8921.8909007181846, + 8934.8517000132997, + 8947.817201213471, 8960.7874009109, - 8973.7622957040, - 8986.7418821972, - 8999.7261570012, - 9012.7151167328, - 9025.7087580148, - 9038.7070774762, - 9051.7100717521, - 9064.7177374833, - 9077.7300713171, - 9090.7470699065, - 9103.7687299106, - 9116.7950479945, - 9129.8260208291, - 9142.8616450914, - 9155.9019174644, - 9168.9468346367, - 9181.9963933031, - 9195.0505901642, - 9208.1094219263, - 9221.1728853017, - 9234.2409770084, - 9247.3136937704, - 9260.3910323173, - 9273.4729893846, - 9286.5595617135, - 9299.6507460510, - 9312.7465391496, - 9325.8469377679, - 9338.9519386698, - 9352.0615386252, - 9365.1757344094, - 9378.2945228036, - 9391.4179005944, - 9404.5458645741, - 9417.6784115407, - 9430.8155382977, - 9443.9572416540, - 9457.1035184244, - 9470.2543654290, - 9483.4097794934, - 9496.5697574489, - 9509.7342961321, - 9522.9033923851, - 9536.0770430556, - 9549.2552449966, - 9562.4379950666, - 9575.6252901295, - 9588.8171270546, - 9602.0135027165, - 9615.2144139955, - 9628.4198577767, - 9641.6298309511, - 9654.8443304146, - 9668.0633530688, - 9681.2868958202, - 9694.5149555808, - 9707.7475292679, - 9720.9846138040, - 9734.2262061168, - 9747.4723031393, - 9760.7229018097, - 9773.9779990712, - 9787.2375918726, - 9800.5016771674, - 9813.7702519147, - 9827.0433130783, - 9840.3208576275, - 9853.6028825365, - 9866.8893847847, - 9880.1803613565, - 9893.4758092415, - 9906.7757254342, - 9920.0801069342, - 9933.3889507462, - 9946.7022538799, - 9960.0200133500, - 9973.3422261761, - 9986.6688893829, - 10000.0000000000, - 10013.3355550619, - 10026.6755516082, - 10040.0199866833, - 10053.3688573365, - 10066.7221606221, - 10080.0798935991, - 10093.4420533317, - 10106.8086368886, - 10120.1796413436, - 10133.5550637751, - 10146.9349012666, - 10160.3191509062, - 10173.7078097869, - 10187.1008750065, - 10200.4983436674, - 10213.9002128770, - 10227.3064797472, - 10240.7171413949, - 10254.1321949415, - 10267.5516375131, - 10280.9754662408, - 10294.4036782600, - 10307.8362707111, - 10321.2732407388, - 10334.7145854928 + 8973.7622957039603, + 8986.7418821971733, + 8999.7261570011924, + 9012.7151167327884, + 9025.7087580148236, + 9038.7070774762469, + 9051.7100717520643, + 9064.7177374833282, + 9077.7300713171153, + 9090.7470699065179, + 9103.7687299106146, + 9116.7950479944648, + 9129.8260208290812, + 9142.8616450914233, + 9155.9019174643727, + 9168.9468346367157, + 9181.9963933031358, + 9195.0505901641845, + 9208.1094219262741, + 9221.1728853016557, + 9234.240977008405, + 9247.3136937704076, + 9260.3910323173386, + 9273.472989384647, + 9286.5595617135423, + 9299.6507460509747, + 9312.7465391496207, + 9325.8469377678684, + 9338.9519386698012, + 9352.0615386251757, + 9365.1757344094131, + 9378.2945228035842, + 9391.4179005943843, + 9404.5458645741273, + 9417.6784115407263, + 9430.8155382976747, + 9443.9572416540359, + 9457.1035184244265, + 9470.2543654290002, + 9483.4097794934296, + 9496.5697574488931, + 9509.7342961320664, + 9522.9033923850911, + 9536.0770430555804, + 9549.2552449965824, + 9562.4379950665825, + 9575.6252901294793, + 9588.8171270545736, + 9602.0135027165488, + 9615.2144139954635, + 9628.4198577767274, + 9641.629830951093, + 9654.844330414644, + 9668.0633530687719, + 9681.286895820167, + 9694.5149555808002, + 9707.7475292679192, + 9720.9846138040157, + 9734.2262061168276, + 9747.4723031393187, + 9760.7229018096641, + 9773.9779990712323, + 9787.2375918725811, + 9800.5016771674327, + 9813.7702519146696, + 9827.0433130783094, + 9840.3208576275028, + 9853.602882536512, + 9866.8893847846994, + 9880.1803613565116, + 9893.4758092414686, + 9906.7757254341523, + 9920.0801069341851, + 9933.3889507462245, + 9946.7022538799429, + 9960.0200133500221, + 9973.3422261761298, + 9986.6688893829159, + 9999.9999999999945, + 10013.335555061929, + 10026.675551608221, + 10040.019986683301, + 10053.368857336509, + 10066.722160622081, + 10080.079893599144, + 10093.442053331697, + 10106.808636888598, + 10120.179641343551, + 10133.555063775095, + 10146.934901266595, + 10160.31915090622, + 10173.707809786936, + 10187.100875006496, + 10200.498343667417, + 10213.900212876984, + 10227.306479747222, + 10240.717141394889, + 10254.132194941467, + 10267.551637513146, + 10280.975466240814, + 10294.40367826004, + 10307.836270711066, + 10321.273240738796, + 10334.71458549278, + 10348.160302127204, + 10361.610387800878, + 10375.064839677221, + 10388.523654924258, + 10401.986830714593, + 10415.454364225412, + 10428.926252638465, + 10442.402493140049, + 10455.883082921007, + 10469.368019176709, + 10482.85729910704, + 10496.350919916393, + 10509.848878813653, + 10523.351173012188, + 10536.857799729838, + 10550.3687561889, + 10563.884039616123, + 10577.403647242685, + 10590.927576304197, + 10604.455824040679, + 10617.988387696556, + 10631.525264520642, + 10645.066451766135, + 10658.611946690598, + 10672.161746555956, + 10685.715848628475, + 10699.274250178762, + 10712.836948481747, + 10726.403940816675, + 10739.975224467091, + 10753.550796720834, + 10767.130654870027, + 10780.714796211059, + 10794.303218044579, + 10807.895917675487, + 10821.492892412922, + 10835.094139570248, + 10848.699656465047, + 10862.309440419107, + 10875.923488758415, + 10889.541798813138, + 10903.16436791762, + 10916.791193410372, + 10930.422272634056, + 10944.05760293548, + 10957.697181665582, + 10971.341006179427, + 10984.98907383619, + 10998.641381999149, + 11012.297928035676, + 11025.958709317223, + 11039.623723219316, + 11053.292967121541, + 11066.966438407539, + 11080.64413446499, + 11094.326052685608, + 11108.012190465128, + 11121.702545203296, + 11135.397114303863, + 11149.095895174571, + 11162.798885227143, + 11176.506081877278, + 11190.217482544635, + 11203.933084652828, + 11217.652885629415, + 11231.376882905886, + 11245.105073917659, + 11258.837456104062, + 11272.574026908333, + 11286.314783777601, + 11300.059724162888, + 11313.808845519083, + 11327.562145304952, + 11341.319620983111, + 11355.081270020033, + 11368.847089886023, + 11382.617078055218, + 11396.391232005579, + 11410.169549218874, + 11423.952027180676, + 11437.738663380349, + 11451.529455311042, + 11465.324400469679, + 11479.123496356951, + 11492.926740477304, + 11506.734130338931, + 11520.545663453764, + 11534.361337337466, + 11548.181149509423, + 11562.005097492724, + 11575.83317881417, + 11589.665391004253, + 11603.501731597149, + 11617.342198130715, + 11631.186788146468, + 11645.035499189589, + 11658.888328808911, + 11672.745274556904, + 11686.606333989675, + 11700.471504666955, + 11714.340784152086, + 11728.214170012021, + 11742.091659817312, + 11755.973251142101, + 11769.858941564111, + 11783.748728664636, + 11797.642610028539, + 11811.540583244237, + 11825.442645903697, + 11839.34879560242, + 11853.259029939445, + 11867.173346517333, + 11881.091742942155, + 11895.014216823492, + 11908.940765774427, + 11922.871387411526, + 11936.806079354839, + 11950.744839227897, + 11964.687664657684, + 11978.634553274653, + 11992.585502712702, + 12006.540510609168, + 12020.499574604828, + 12034.462692343877, + 12048.429861473938, + 12062.401079646032, + 12076.376344514589, + 12090.355653737433, + 12104.339004975769, + 12118.326395894188, + 12132.317824160644, + 12146.313287446457, + 12160.312783426305, + 12174.316309778205, + 12188.323864183525, + 12202.335444326955, + 12216.351047896511, + 12230.370672583531, + 12244.394316082657, + 12258.421976091831, + 12272.453650312296, + 12286.489336448574, + 12300.529032208471, + 12314.572735303058, + 12328.620443446678, + 12342.672154356922, + 12356.727865754638, + 12370.787575363909, + 12384.851280912055, + 12398.918980129623, + 12412.990670750381, + 12427.066350511306, + 12441.146017152583, + 12455.229668417589, + 12469.317302052901, + 12483.40891580827, + 12497.50450743663, + 12511.604074694078, + 12525.707615339878, + 12539.815127136444, + 12553.926607849342, + 12568.042055247275, + 12582.161467102082, + 12596.284841188726, + 12610.41217528529, + 12624.543467172971, + 12638.678714636069, + 12652.817915461985, + 12666.961067441209, + 12681.108168367316, + 12695.259216036962, + 12709.414208249869, + 12723.573142808827, + 12737.736017519681, + 12751.902830191326, + 12766.073578635704, + 12780.248260667788, + 12794.426874105588, + 12808.609416770132, + 12822.795886485468, + 12836.986281078653, + 12851.180598379744, + 12865.378836221802, + 12879.580992440871, + 12893.787064875984, + 12907.997051369144, + 12922.210949765335, + 12936.428757912496, + 12950.650473661524, + 12964.876094866273, + 12979.105619383534, + 12993.339045073039, + 13007.576369797454, + 13021.817591422368, + 13036.062707816285, + 13050.311716850629, + 13064.564616399723, + 13078.821404340792, + 13093.082078553954, + 13107.346636922217, + 13121.615077331464, + 13135.887397670458, + 13150.163595830827, + 13164.44366970706, + 13178.727617196502, + 13193.015436199352, + 13207.307124618648, + 13221.602680360265, + 13235.902101332911, + 13250.205385448118, + 13264.512530620239, + 13278.823534766434, + 13293.138395806676, + 13307.457111663734, + 13321.779680263176, + 13336.106099533356, + 13350.436367405409, + 13364.77048181325, + 13379.108440693562, + 13393.450241985796, + 13407.795883632158, + 13422.145363577607, + 13436.498679769853, + 13450.855830159346, + 13465.216812699266, + 13479.581625345529, + 13493.950266056772, + 13508.32273279435, + 13522.699023522329, + 13537.079136207483, + 13551.463068819286, + 13565.850819329906, + 13580.2423857142, + 13594.63776594971, + 13609.036958016657, + 13623.439959897927, + 13637.846769579081, + 13652.257385048335, + 13666.67180429656, + 13681.090025317284, + 13695.512046106669, + 13709.937864663521, + 13724.367478989278, + 13738.800887088004, + 13753.238086966385, + 13767.679076633727, + 13782.123854101939, + 13796.572417385545, + 13811.024764501659, + 13825.480893469998, + 13839.94080231286, + 13854.404489055134, + 13868.871951724283, + 13883.34318835034, + 13897.818196965914, + 13912.296975606168, + 13926.779522308825, + 13941.26583511416, + 13955.755912064991, + 13970.249751206682, + 13984.747350587126, + 13999.248708256751, + 14013.753822268511, + 14028.262690677873, + 14042.775311542828, + 14057.291682923867, + 14071.811802883994, + 14086.335669488704, + 14100.863280805994, + 14115.394634906341, + 14129.92972986271, + 14144.468563750548, + 14159.01113464777, + 14173.55744063476, + 14188.107479794369, + 14202.661250211901, + 14217.218749975118, + 14231.779977174227, + 14246.344929901879, + 14260.913606253163, + 14275.486004325601, + 14290.062122219146, + 14304.641958036171, + 14319.225509881464, + 14333.812775862236, + 14348.403754088098, + 14362.998442671067, + 14377.59683972556, + 14392.198943368388, + 14406.804751718748, + 14421.414262898223, + 14436.027475030774, + 14450.64438624274, + 14465.264994662828, + 14479.889298422106, + 14494.517295654005, + 14509.148984494313, + 14523.784363081166, + 14538.423429555049, + 14553.066182058781, + 14567.712618737527, + 14582.362737738777, + 14597.016537212348, + 14611.674015310382, + 14626.33517018734, + 14640.999999999993, + 14655.668502907418, + 14670.340677071003, + 14685.016520654426, + 14699.696031823671, + 14714.379208746999, + 14729.066049594967, + 14743.756552540408, + 14758.45071575843, + 14773.148537426418, + 14787.850015724018, + 14802.555148833142, + 14817.263934937961, + 14831.976372224897, + 14846.692458882624, + 14861.41219310206, + 14876.135573076363, + 14890.862597000923, + 14905.593263073371, + 14920.327569493558, + 14935.065514463557, + 14949.807096187662, + 14964.552312872382, + 14979.301162726431, + 14994.053643960735, + 15008.809754788414, + 15023.569493424788, + 15038.332858087369, + 15053.099846995858, + 15067.870458372134, + 15082.644690440264, + 15097.422541426484, + 15112.204009559202, + 15126.989093068994, + 15141.777790188597, + 15156.570099152905, + 15171.366018198967, + 15186.165545565986, + 15200.968679495301, + 15215.775418230402, + 15230.585760016909, + 15245.399703102579, + 15260.217245737298, + 15275.038386173073, + 15289.863122664035, + 15304.691453466432, + 15319.523376838621, + 15334.358891041069, + 15349.197994336346, + 15364.040684989128, + 15378.886961266177, + 15393.736821436356, + 15408.590263770609, + 15423.447286541972, + 15438.307888025554, + 15453.172066498542, + 15468.039820240196, + 15482.91114753184, + 15497.786046656869, + 15512.664515900733, + 15527.546553550939, + 15542.432157897045, + 15557.32132723066, + 15572.214059845435, + 15587.110354037064, + 15602.010208103273, + 15616.913620343823, + 15631.820589060506, + 15646.731112557136, + 15661.645189139546, + 15676.562817115593, + 15691.483994795139, + 15706.408720490062, + 15721.336992514242, + 15736.268809183561, + 15751.204168815901, + 15766.143069731135, + 15781.085510251132, + 15796.03148869974, + 15810.981003402798, + 15825.934052688119, + 15840.890634885489, + 15855.850748326673, + 15870.814391345401, + 15885.781562277361, + 15900.752259460214, + 15915.726481233565, + 15930.704225938984, + 15945.685491919978, + 15960.670277522009, + 15975.658581092481, + 15990.65040098073, + 16005.645735538035, + 16020.644583117599, + 16035.646942074556, + 16050.652810765967, + 16065.662187550806, + 16080.675070789974, + 16095.691458846273, + 16110.711350084424, + 16125.734742871053, + 16140.761635574685, + 16155.792026565747, + 16170.825914216561, + 16185.863296901338, + 16200.904172996183, + 16215.948540879079, + 16230.996398929899, + 16246.047745530386, + 16261.102579064163, + 16276.160897916721, + 16291.22270047542, + 16306.287985129484, + 16321.356750269995, + 16336.428994289896, + 16351.504715583982, + 16366.5839125489, + 16381.666583583141, + 16396.752727087041, + 16411.842341462776, + 16426.935425114363, + 16442.031976447644, + 16457.131993870298, + 16472.235475791829, + 16487.342420623561, + 16502.452826778641, + 16517.566692672033, + 16532.684016720516, + 16547.804797342676, + 16562.929032958902, + 16578.056721991394, + 16593.18786286415, + 16608.322454002962, + 16623.460493835417, + 16638.601980790896, + 16653.746913300558, + 16668.895289797354, + 16684.047108716015, + 16699.202368493046, + 16714.361067566726, + 16729.523204377107, + 16744.688777366009, + 16759.857784977012, + 16775.030225655464, + 16790.206097848466, + 16805.385400004874, + 16820.568130575302, + 16835.754288012104, + 16850.943870769381, + 16866.136877302983, + 16881.333306070494, + 16896.53315553123, + 16911.736424146249, + 16926.943110378332, + 16942.153212691992, + 16957.366729553454, + 16972.583659430682, + 16987.804000793338, + 17003.027752112816, + 17018.254911862205, + 17033.485478516312, + 17048.719450551645, + 17063.956826446421, + 17079.197604680547, + 17094.44178373563, + 17109.689362094967, + 17124.940338243552, + 17140.194710668064, + 17155.452477856852, + 17170.713638299967, + 17185.978190489128, + 17201.246132917724, + 17216.517464080825, + 17231.792182475165, + 17247.070286599141, + 17262.351774952826, + 17277.636646037936, + 17292.924898357855, + 17308.216530417623, + 17323.511540723921, + 17338.809927785089, + 17354.111690111105, + 17369.416826213594, + 17384.725334605821, + 17400.037213802683, + 17415.352462320716, + 17430.67107867809, + 17445.993061394587, + 17461.318408991636, + 17476.647119992274, + 17491.979192921168, + 17507.314626304586, + 17522.653418670423, + 17537.995568548187, + 17553.341074468986, + 17568.689934965536, + 17584.042148572156, + 17599.397713824768, + 17614.75662926089, + 17630.118893419625, + 17645.484504841683, + 17660.853462069354, + 17676.225763646511, + 17691.601408118619, + 17706.980394032718, + 17722.362719937424, + 17737.748384382936, + 17753.137385921014, + 17768.529723104999, + 17783.92539448979, + 17799.324398631856, + 17814.726734089225, + 17830.13239942148, + 17845.541393189767, + 17860.95371395678, + 17876.369360286772, + 17891.788330745527, + 17907.210623900395, + 17922.636238320254, + 17938.065172575527, + 17953.497425238176, + 17968.932994881692, + 17984.371880081104, + 17999.814079412972, + 18015.259591455371, + 18030.708414787914, + 18046.160547991731, + 18061.615989649465, + 18077.074738345284, + 18092.536792664861, + 18108.002151195393, + 18123.470812525571, + 18138.942775245599, + 18154.418037947191, + 18169.896599223546, + 18185.37845766938, + 18200.863611880886, + 18216.352060455767, + 18231.843801993204, + 18247.338835093873, + 18262.837158359936, + 18278.338770395032, + 18293.84366980429, + 18309.351855194309, + 18324.863325173166, + 18340.378078350412, + 18355.896113337069, + 18371.417428745623, + 18386.942023190033, + 18402.469895285718, + 18418.00104364955, + 18433.53546689987, + 18449.073163656474, + 18464.614132540602, + 18480.158372174956, + 18495.705881183676, + 18511.256658192357, + 18526.810701828035, + 18542.368010719183, + 18557.928583495715, + 18573.492418788985, + 18589.059515231773, + 18604.629871458303, + 18620.203486104212, + 18635.78035780658, + 18651.360485203899, + 18666.943866936086, + 18682.53050164448, + 18698.120387971841, + 18713.713524562332, + 18729.30991006154, + 18744.909543116457, + 18760.512422375479, + 18776.118546488418, + 18791.727914106479, + 18807.340523882274, + 18822.95637446981, + 18838.575464524489, + 18854.197792703111, + 18869.823357663863, + 18885.452158066328, + 18901.08419257147, + 18916.719459841639, + 18932.357958540564, + 18947.999687333362, + 18963.644644886521, + 18979.292829867907, + 18994.944240946759, + 19010.598876793687, + 19026.256736080668, + 19041.917817481048, + 19057.582119669532, + 19073.2496413222, + 19088.920381116473, + 19104.594337731145, + 19120.271509846356, + 19135.951896143604, + 19151.635495305738, + 19167.322306016948, + 19183.012326962784, + 19198.705556830122, + 19214.401994307198, + 19230.101638083579, + 19245.804486850167, + 19261.510539299208, + 19277.219794124274, + 19292.932250020265, + 19308.647905683421, + 19324.366759811302, + 19340.088811102793, + 19355.8140582581, + 19371.542499978754, + 19387.2741349676, + 19403.008961928797, + 19418.746979567823, + 19434.488186591469, + 19450.232581707827, + 19465.980163626304, + 19481.730931057613, + 19497.484882713761, + 19513.242017308068, + 19529.002333555141, + 19544.765830170898, + 19560.532505872539, + 19576.302359378566, + 19592.075389408761, + 19607.851594684209, + 19623.630973927269, + 19639.41352586159, + 19655.199249212103, + 19670.988142705017, + 19686.780205067826, + 19702.575435029288, + 19718.373831319448, + 19734.175392669615, + 19749.980117812371, + 19765.788005481569, + 19781.599054412323, + 19797.413263341008, + 19813.230631005274, + 19829.051156144014, + 19844.874837497395, + 19860.701673806827, + 19876.531663814985, + 19892.364806265789, + 19908.201099904403, + 19924.040543477258, + 19939.883135732012, + 19955.728875417579, + 19971.577761284105, + 19987.429792082985, + 20003.284966566847, + 20019.14328348956, + 20035.004741606219, + 20050.869339673161, + 20066.737076447946, + 20082.607950689362, + 20098.481961157428, + 20114.359106613385, + 20130.239385819699, + 20146.122797540058, + 20162.009340539353, + 20177.899013583716, + 20193.791815440476, + 20209.687744878182, + 20225.586800666591, + 20241.488981576669, + 20257.394286380597, + 20273.302713851754, + 20289.214262764715, + 20305.128931895277, + 20321.046720020415, + 20336.967625918318, + 20352.891648368361, + 20368.818786151114, + 20384.749038048347, + 20400.682402843009, + 20416.618879319249, + 20432.558466262391, + 20448.501162458953, + 20464.446966696629, + 20480.395877764302, + 20496.347894452025, + 20512.303015551031, + 20528.261239853735, + 20544.22256615372, + 20560.186993245738, + 20576.15451992572, + 20592.125144990758, + 20608.098867239107, + 20624.075685470198, + 20640.055598484618, + 20656.038605084115, + 20672.024704071595, + 20688.013894251126, + 20704.006174427926, + 20720.001543408373, + 20735.999999999989, + 20752.001543011454, + 20768.006171252597, + 20784.013883534382, + 20800.024678668931, + 20816.038555469506, + 20832.055512750507, + 20848.075549327474, + 20864.098664017085, + 20880.124855637161, + 20896.154123006647, + 20912.186464945626, + 20928.221880275312, + 20944.260367818049, + 20960.301926397311, + 20976.346554837684, + 20992.394251964895, + 21008.445016605787, + 21024.498847588318, + 21040.555743741574, + 21056.615703895754, + 21072.678726882168, + 21088.744811533252, + 21104.813956682538, + 21120.886161164683, + 21136.961423815443, + 21153.039743471683, + 21169.121118971379, + 21185.205549153605, + 21201.293032858535, + 21217.383568927453, + 21233.477156202731, + 21249.573793527841, + 21265.673479747358, + 21281.776213706937, + 21297.881994253334, + 21313.990820234398, + 21330.102690499054, + 21346.21760389733, + 21362.335559280327, + 21378.456555500241, + 21394.580591410333, + 21410.707665864964, + 21426.83777771956, + 21442.970925830628, + 21459.107109055756, + 21475.246326253604, + 21491.388576283895, + 21507.533858007431, + 21523.682170286087, + 21539.833511982797, + 21555.987881961566, + 21572.145279087465, + 21588.305702226615, + 21604.469150246216, + 21620.635622014521, + 21636.805116400832, + 21652.977632275521, + 21669.153168510009, + 21685.331723976764, + 21701.513297549318, + 21717.697888102244, + 21733.885494511167, + 21750.076115652759, + 21766.269750404736, + 21782.466397645861, + 21798.666056255934, + 21814.868725115801, + 21831.074403107345, + 21847.283089113484, + 21863.494782018177, + 21879.709480706417, + 21895.927184064229, + 21912.147890978667, + 21928.371600337818, + 21944.598311030797, + 21960.828021947746, + 21977.060731979829, + 21993.296440019243, + 22009.535144959198, + 22025.77684569393, + 22042.021541118691, + 22058.269230129757, + 22074.519911624411, + 22090.773584500959, + 22107.030247658717, + 22123.289899998013, + 22139.552540420187, + 22155.818167827587, + 22172.086781123569, + 22188.358379212495, + 22204.632960999726, + 22220.910525391639, + 22237.191071295601, + 22253.474597619981, + 22269.761103274148, + 22286.050587168469, + 22302.343048214312, + 22318.638485324027, + 22334.936897410968, + 22351.23828338947, + 22367.542642174871, + 22383.849972683485, + 22400.160273832618, + 22416.473544540564, + 22432.789783726603, + 22449.108990310986, + 22465.431163214958, + 22481.75630136074, + 22498.084403671528, + 22514.415469071497, + 22530.749496485802, + 22547.086484840562, + 22563.426433062879, + 22579.769340080824, + 22596.115204823436, + 22612.464026220721, + 22628.815803203655, + 22645.170534704179, + 22661.5282196552, + 22677.888856990587, + 22694.252445645168, + 22710.618984554734, + 22726.988472656034, + 22743.360908886778, + 22759.736292185622, + 22776.114621492186, + 22792.495895747044, + 22808.880113891719, + 22825.267274868678, + 22841.657377621348, + 22858.050421094096, + 22874.446404232243, + 22890.845325982053, + 22907.247185290722, + 22923.651981106406, + 22940.059712378195, + 22956.470378056114, + 22972.883977091129, + 22989.300508435153, + 23005.719971041017, + 23022.142363862498, + 23038.567685854305, + 23054.995935972078, + 23071.427113172387, + 23087.86121641273, + 23104.298244651531, + 23120.738196848146, + 23137.181071962848, + 23153.626868956846, + 23170.075586792263, + 23186.527224432142, + 23202.981780840448, + 23219.439254982066, + 23235.899645822796, + 23252.362952329357, + 23268.829173469378, + 23285.298308211408, + 23301.770355524899, + 23318.245314380223, + 23334.723183748658, + 23351.203962602387, + 23367.687649914504, + 23384.174244659007, + 23400.663745810798, + 23417.15615234568, + 23433.651463240367, + 23450.149677472462, + 23466.650794020472, + 23483.154811863806, + 23499.661729982763, + 23516.171547358543, + 23532.684262973235, + 23549.199875809823, + 23565.718384852185, + 23582.239789085092, + 23598.764087494197, + 23615.291279066041, + 23631.821362788058, + 23648.354337648565, + 23664.890202636761, + 23681.428956742733, + 23697.970598957443, + 23714.515128272738, + 23731.062543681343, + 23747.612844176863, + 23764.166028753778, + 23780.72209640744, + 23797.281046134085, + 23813.842876930816, + 23830.407587795606, + 23846.975177727301, + 23863.545645725622, + 23880.11899079115, + 23896.695211925336, + 23913.274308130498, + 23929.856278409821, + 23946.441121767348, + 23963.028837207989, + 23979.619423737513, + 23996.212880362549, + 24012.809206090584, + 24029.408399929966, + 24046.010460889898, + 24062.615387980433, + 24079.223180212492, + 24095.833836597827, + 24112.447356149063, + 24129.063737879667, + 24145.682980803951, + 24162.305083937081, + 24178.930046295067, + 24195.557866894767, + 24212.188544753884, + 24228.822078890964, + 24245.458468325389, + 24262.097712077397, + 24278.739809168052, + 24295.384758619261, + 24312.032559453768, + 24328.683210695162, + 24345.336711367858, + 24361.993060497109, + 24378.652257108995, + 24395.314300230442, + 24411.979188889192, + 24428.646922113825, + 24445.317498933746, + 24461.990918379193, + 24478.667179481225, + 24495.346281271726, + 24512.028222783407, + 24528.713003049801, + 24545.400621105266, + 24562.091075984976, + 24578.784366724925, + 24595.480492361927, + 24612.179451933614, + 24628.881244478438, + 24645.585869035654, + 24662.293324645343, + 24679.003610348394, + 24695.716725186514, + 24712.432668202211, + 24729.151438438807, + 24745.873034940436, + 24762.597456752032, + 24779.324702919344, + 24796.054772488926, + 24812.787664508123, + 24829.5233780251, + 24846.261912088819, + 24863.003265749034, + 24879.747438056307, + 24896.494428062004, + 24913.244234818278, + 24929.996857378079, + 24946.752294795166, + 24963.510546124078, + 24980.271610420157, + 24997.035486739525, + 25013.802174139113, + 25030.571671676629, + 25047.343978410572, + 25064.119093400237, + 25080.897015705697, + 25097.677744387816, + 25114.461278508239, + 25131.2476171294, + 25148.036759314517, + 25164.828704127583, + 25181.623450633375, + 25198.42099789745, + 25215.221344986145, + 25232.024490966574, + 25248.830434906627, + 25265.639175874974, + 25282.450712941049, + 25299.265045175071, + 25316.082171648024, + 25332.902091431668, + 25349.724803598532, + 25366.550307221914, + 25383.378601375884, + 25400.209685135269, + 25417.043557575678, + 25433.880217773472, + 25450.719664805783, + 25467.561897750507, + 25484.406915686297, + 25501.254717692573, + 25518.105302849512, + 25534.958670238051, + 25551.814818939893, + 25568.67374803748, + 25585.535456614027, + 25602.399943753502, + 25619.267208540619, + 25636.137250060852, + 25653.010067400432, + 25669.885659646327, + 25686.76402588627, + 25703.645165208734, + 25720.529076702944, + 25737.415759458876, + 25754.305212567244, + 25771.197435119517, + 25788.092426207899, + 25804.990184925344, + 25821.890710365547, + 25838.794001622944, + 25855.700057792714, + 25872.608877970775, + 25889.520461253778, + 25906.434806739118, + 25923.351913524923, + 25940.271780710063, + 25957.194407394138, + 25974.11979267748, + 25991.047935661154, + 26007.978835446964, + 26024.912491137442, + 26041.848901835841, + 26058.788066646157, + 26075.729984673108, + 26092.674655022136, + 26109.622076799409, + 26126.572249111829, + 26143.525171067016, + 26160.480841773315, + 26177.43926033979, + 26194.400425876229, + 26211.364337493149, + 26228.330994301767, + 26245.30039541404, + 26262.272539942627, + 26279.247427000919, + 26296.225055703002, + 26313.205425163702, + 26330.188534498539, + 26347.174382823756, + 26364.162969256304, + 26381.154292913852, + 26398.148352914774, + 26415.145148378149, + 26432.144678423778, + 26449.146942172156, + 26466.151938744493, + 26483.159667262702, + 26500.170126849403, + 26517.183316627921, + 26534.199235722277, + 26551.217883257199, + 26568.239258358124, + 26585.263360151173, + 26602.290187763181, + 26619.319740321676, + 26636.352016954883, + 26653.387016791727, + 26670.424738961825, + 26687.465182595493, + 26704.508346823739, + 26721.554230778267, + 26738.602833591467, + 26755.65415439643, + 26772.708192326929, + 26789.764946517433, + 26806.824416103096, + 26823.886600219761, + 26840.95149800396, + 26858.019108592915, + 26875.089431124517, + 26892.162464737365, + 26909.238208570721, + 26926.316661764544, + 26943.397823459472, + 26960.481692796813, + 26977.568268918571, + 26994.657550967422, + 27011.749538086722, + 27028.844229420498, + 27045.941624113464, + 27063.041721311005, + 27080.144520159181, + 27097.250019804727, + 27114.35821939505, + 27131.469118078236, + 27148.582715003027, + 27165.699009318858, + 27182.818000175819, + 27199.939686724665, + 27217.064068116837, + 27234.191143504428, + 27251.320912040203, + 27268.453372877593, + 27285.588525170693, + 27302.726368074269, + 27319.866900743735, + 27337.010122335181, + 27354.156032005358, + 27371.304628911668, + 27388.455912212183, + 27405.609881065626, + 27422.766534631384, + 27439.925872069507, + 27457.087892540683, + 27474.252595206275, + 27491.419979228293, + 27508.5900437694, + 27525.762787992917, + 27542.93821106281, + 27560.116312143706, + 27577.297090400876, + 27594.480545000242, + 27611.666675108383, + 27628.855479892518, + 27646.046958520514, + 27663.241110160889, + 27680.437933982801, + 27697.637429156068, + 27714.839594851132, + 27732.04443023909, + 27749.251934491687, + 27766.462106781299, + 27783.674946280949, + 27800.890452164302, + 27818.108623605654, + 27835.329459779954, + 27852.55295986278, + 27869.779123030345, + 27887.007948459504, + 27904.239435327745, + 27921.473582813196, + 27938.710390094613, + 27955.949856351392, + 27973.19198076355, + 27990.436762511745, + 28007.684200777272, + 28024.934294742041, + 28042.187043588601, + 28059.442446500128, + 28076.700502660427, + 28093.961211253929, + 28111.224571465693, + 28128.490582481401, + 28145.759243487362, + 28163.030553670509, + 28180.304512218394, + 28197.581118319198, + 28214.860371161725, + 28232.14226993539, + 28249.42681383024, + 28266.71400203693, + 28284.003833746745, + 28301.296308151585, + 28318.591424443959, + 28335.889181817001, + 28353.189579464462, + 28370.492616580705, + 28387.798292360701, + 28405.106606000048, + 28422.417556694945, + 28439.731143642206, + 28457.047366039264, + 28474.366223084147, + 28491.687713975512, + 28509.011837912611, + 28526.338594095305, + 28543.667981724069, + 28560.999999999982, + 28578.334648124732, + 28595.671925300605, + 28613.011830730498, + 28630.354363617909, + 28647.699523166943, + 28665.0473085823, + 28682.397719069289, + 28699.750753833818, + 28717.10641208239, + 28734.464693022121, + 28751.825595860708, + 28769.189119806462, + 28786.55526406828, + 28803.924027855664, + 28821.295410378701, + 28838.669410848088, + 28856.046028475103, + 28873.425262471628, + 28890.80711205013, + 28908.191576423673, + 28925.578654805915, + 28942.968346411097, + 28960.360650454055, + 28977.755566150216, + 28995.153092715591, + 29012.553229366786, + 29029.955975320987, + 29047.361329795975, + 29064.769292010107, + 29082.179861182336, + 29099.593036532187, + 29117.00881727978, + 29134.427202645813, + 29151.848191851568, + 29169.271784118911, + 29186.697978670283, + 29204.126774728706, + 29221.55817151779, + 29238.992168261717, + 29256.42876418525, + 29273.867958513725, + 29291.309750473058, + 29308.754139289747, + 29326.201124190855, + 29343.65070440403, + 29361.102879157483, + 29378.557647680012, + 29396.015009200975, + 29413.474962950309, + 29430.937508158524, + 29448.402644056692, + 29465.870369876469, + 29483.340684850071, + 29500.81358821028, + 29518.289079190454, + 29535.767157024511, + 29553.247820946945, + 29570.731070192807, + 29588.216903997723, + 29605.70532159787, + 29623.19632223, + 29640.689905131429, + 29658.186069540028, + 29675.684814694236, + 29693.186139833047, + 29710.690044196028, + 29728.196527023298, + 29745.705587555527, + 29763.217225033964, + 29780.731438700397, + 29798.248227797183, + 29815.76759156723, + 29833.289529254005, + 29850.81404010153, + 29868.341123354381, + 29885.870778257693, + 29903.403004057145, + 29920.937799998974, + 29938.475165329975, + 29956.015099297485, + 29973.557601149394, + 29991.102670134147, + 30008.650305500738, + 30026.200506498706, + 30043.753272378144, + 30061.308602389683, + 30078.866495784507, + 30096.426951814352, + 30113.989969731494, + 30131.55554878875, + 30149.123688239491, + 30166.694387337629, + 30184.267645337608, + 30201.843461494434, + 30219.42183506364, + 30237.002765301309, + 30254.586251464058, + 30272.172292809046, + 30289.760888593977, + 30307.35203807709, + 30324.94574051716, + 30342.541995173502, + 30360.140801305966, + 30377.742158174944, + 30395.346065041358, + 30412.952521166666, + 30430.561525812864, + 30448.173078242475, + 30465.787177718561, + 30483.403823504719, + 30501.02301486507, + 30518.644751064272, + 30536.269031367516, + 30553.895855040515, + 30571.525221349519, + 30589.157129561307, + 30606.791578943175, + 30624.428568762964, + 30642.06809828903, + 30659.710166790261, + 30677.35477353607, + 30695.001917796391, + 30712.651598841687, + 30730.303815942945, + 30747.958568371676, + 30765.615855399912, + 30783.275676300211, + 30800.938030345646, + 30818.602916809814, + 30836.270334966837, + 30853.940284091354, + 30871.612763458521, + 30889.287772344011, + 30906.965310024025, + 30924.645375775272, + 30942.327968874983, + 30960.013088600903, + 30977.700734231294, + 30995.390905044929, + 31013.083600321101, + 31030.778819339619, + 31048.476561380798, + 31066.17682572547, + 31083.879611654978, + 31101.584918451179, + 31119.29274539644, + 31137.003091773637, + 31154.715956866155, + 31172.431339957893, + 31190.14924033326, + 31207.869657277162, + 31225.592590075023, + 31243.318038012771, + 31261.046000376838, + 31278.776476454172, + 31296.50946553221, + 31314.24496689891, + 31331.98297984272, + 31349.7235036526, + 31367.466537618013, + 31385.212081028923, + 31402.960133175795, + 31420.710693349596, + 31438.463760841791, + 31456.219334944351, + 31473.977414949743, + 31491.738000150934, + 31509.501089841389, + 31527.266683315069, + 31545.034779866437, + 31562.80537879045, + 31580.578479382562, + 31598.35408093872, + 31616.132182755369, + 31633.91278412945, + 31651.695884358396, + 31669.481482740131, + 31687.269578573076, + 31705.060171156143, + 31722.853259788735, + 31740.648843770748, + 31758.446922402567, + 31776.247494985066, + 31794.050560819614, + 31811.85611920806, + 31829.664169452753, + 31847.474710856521, + 31865.287742722685, + 31883.103264355046, + 31900.921275057899, + 31918.741774136019, + 31936.564760894671, + 31954.390234639599, + 31972.21819467704, + 31990.048640313704, + 32007.881570856793, + 32025.716985613984, + 32043.554883893445, + 32061.395265003815, + 32079.238128254223, + 32097.083472954269, + 32114.931298414049, + 32132.781603944117, + 32150.634388855524, + 32168.48965245979, + 32186.347394068915, + 32204.207612995371, + 32222.07030855212, + 32239.935480052583, + 32257.803126810672, + 32275.673248140767, + 32293.545843357719, + 32311.420911776862, + 32329.298452713996, + 32347.178465485395, + 32365.060949407813, + 32382.945903798463, + 32400.83332797504, + 32418.723221255706, + 32436.615582959093, + 32454.510412404306, + 32472.407708910916, + 32490.307471798966, + 32508.209700388961, + 32526.114394001877, + 32544.021551959166, + 32561.931173582732, + 32579.843258194956, + 32597.757805118679, + 32615.674813677211, + 32633.594283194328, + 32651.516212994258, + 32669.440602401712, + 32687.367450741847, + 32705.296757340297, + 32723.228521523146, + 32741.162742616943, + 32759.099419948703, + 32777.038552845901, + 32794.980140636464, + 32812.924182648792, + 32830.87067821173, + 32848.819626654593, + 32866.77102730715, + 32884.724879499619, + 32902.681182562686, + 32920.639935827494, + 32938.601138625643, + 32956.56479028918, + 32974.530890150607, + 32992.499437542894, + 33010.470431799447, + 33028.443872254145, + 33046.419758241311, + 33064.39808909571, + 33082.378864152583, + 33100.36208274759, + 33118.347744216881, + 33136.335847897026, + 33154.326393125062, + 33172.31937923847, + 33190.314805575174, + 33208.312671473555, + 33226.312976272442, + 33244.315719311111, + 33262.320899929284, + 33280.328517467125, + 33298.33857126526, + 33316.351060664747, + 33334.365985007091, + 33352.383343634239, + 33370.403135888591, + 33388.42536111299, + 33406.450018650721, + 33424.477107845501, + 33442.506628041512, + 33460.53857858335, + 33478.572958816083, + 33496.609768085189, + 33514.649005736617, + 33532.690671116739, + 33550.734763572356, + 33568.781282450735, + 33586.830227099563, + 33604.881596866973, + 33622.935391101528, + 33640.991609152239, + 33659.050250368542, + 33677.111314100322, + 33695.174799697881, + 33713.240706511984, + 33731.309033893805, + 33749.37978119497, + 33767.452947767531, + 33785.528532963974, + 33803.606536137209, + 33821.686956640602, + 33839.769793827938, + 33857.855047053425, + 33875.942715671707, + 33894.032799037872, + 33912.125296507431, + 33930.220207436316, + 33948.317531180888, + 33966.417267097961, + 33984.519414544746, + 34002.623972878901, + 34020.730941458511, + 34038.840319642077, + 34056.952106788536, + 34075.066302257255, + 34093.182905408015, + 34111.301915601027, + 34129.42333219693, + 34147.547154556785, + 34165.673382042078, + 34183.80201401472, + 34201.933049837033, + 34220.06648887178, + 34238.202330482141, + 34256.340574031703, + 34274.481218884495, + 34292.624264404949, + 34310.769709957938, + 34328.91755490873, + 34347.067798623029, + 34365.220440466954, + 34383.375479807051, + 34401.532916010263, + 34419.692748443973, + 34437.854976475966, + 34456.01959947445, + 34474.18661680806, + 34492.356027845817, + 34510.527831957188, + 34528.702028512052, + 34546.878616880676, + 34565.05759643377, + 34583.238966542449, + 34601.422726578232, + 34619.608875913065, + 34637.797413919296, + 34655.988339969692, + 34674.181653437423, + 34692.37735369608, + 34710.575440119668, + 34728.775912082579, + 34746.978768959649, + 34765.184010126082, + 34783.391634957537, + 34801.60164283005, + 34819.814033120063, + 34838.028805204456, + 34856.24595846048, + 34874.465492265823, + 34892.687405998557, + 34910.911699037177, + 34929.138370760564, + 34947.367420548027, + 34965.598847779271, + 34983.832651834389, + 35002.068832093908, + 35020.307387938738, + 35038.548318750189, + 35056.79162390998, + 35075.03730280025, + 35093.285354803513, + 35111.535779302685, + 35129.788575681116, + 35148.043743322516, + 35166.301281611013, + 35184.561189931141, + 35202.823467667826, + 35221.088114206388, + 35239.355128932555, + 35257.624511232447, + 35275.896260492584, + 35294.170376099886, + 35312.446857441668, + 35330.725703905628, + 35349.006914879887, + 35367.290489752944, + 35385.576427913686, + 35403.864728751418, + 35422.155391655811, + 35440.448416016967, + 35458.743801225341, + 35477.041546671804, + 35495.341651747622, + 35513.644115844436, + 35531.948938354304, + 35550.256118669655, + 35568.565656183309, + 35586.877550288496, + 35605.191800378816, + 35623.508405848268, + 35641.827366091238, + 35660.148680502505, + 35678.472348477233, + 35696.798369410979, + 35715.126742699678, + 35733.457467739659, + 35751.790543927644, + 35770.125970660738, + 35788.46374733642, + 35806.803873352568, + 35825.146348107453, + 35843.49117099971, + 35861.838341428367, + 35880.187858792851, + 35898.539722492955, + 35916.893931928862, + 35935.250486501129, + 35953.609385610718, + 35971.970628658957, + 35990.334215047558, + 36008.700144178612, + 36027.068415454596, + 36045.439028278372, + 36063.811982053165, + 36082.187276182609, + 36100.564910070694, + 36118.944883121789, + 36137.327194740654, + 36155.711844332429, + 36174.098831302617, + 36192.488155057115, + 36210.87981500219, + 36229.273810544473, + 36247.670141091003, + 36266.068806049167, + 36284.469804826738, + 36302.873136831862, + 36321.278801473069, + 36339.686798159251, + 36358.097126299683, + 36376.509785304013, + 36394.924774582258, + 36413.342093544816, + 36431.761741602444, + 36450.183718166292, + 36468.608022647859, + 36487.034654459028, + 36505.463613012063, + 36523.894897719583, + 36542.328507994578, + 36560.764443250409, + 36579.202702900831, + 36597.643286359926, + 36616.086193042182, + 36634.531422362437, + 36652.978973735895, + 36671.428846578143, + 36689.881040305125, + 36708.335554333149, + 36726.792388078902, + 36745.251540959427, + 36763.713012392138, + 36782.176801794812, + 36800.642908585593, + 36819.111332182983, + 36837.582072005869, + 36856.055127473483, + 36874.530498005421, + 36893.008183021651, + 36911.488181942506, + 36929.970494188674, + 36948.455119181206, + 36966.942056341519, + 36985.431305091392, + 37003.922864852961, + 37022.416735048733, + 37040.912915101559, + 37059.411404434657, + 37077.91220247162, + 37096.415308636388, + 37114.920722353243, + 37133.428443046862, + 37151.938470142253, + 37170.450803064785, + 37188.965441240209, + 37207.482384094597, + 37226.001631054402, + 37244.523181546429, + 37263.047034997842, + 37281.573190836149, + 37300.101648489224, + 37318.632407385296, + 37337.165466952945, + 37355.700826621112, + 37374.238485819085, + 37392.778443976509, + 37411.320700523385, + 37429.865254890057, + 37448.412106507232, + 37466.961254805974, + 37485.512699217681, + 37504.066439174116, + 37522.622474107404, + 37541.180803449992, + 37559.741426634704, + 37578.304343094693, + 37596.869552263488, + 37615.43705357494, + 37634.006846463279, + 37652.578930363044, + 37671.153304709165, + 37689.729968936896, + 37708.308922481847, + 37726.890164779965, + 37745.473695267559, + 37764.059513381275, + 37782.647618558112, + 37801.238010235415, + 37819.830687850859, + 37838.425650842495, + 37857.022898648691, + 37875.622430708172, + 37894.224246460013, + 37912.828345343616, + 37931.434726798747, + 37950.043390265506, + 37968.654335184328, + 37987.267560995999, + 38005.883067141665, + 38024.500853062775, + 38043.120918201159, + 38061.743261998963, + 38080.367883898682, + 38098.994783343158, + 38117.623959775563, + 38136.255412639417, + 38154.889141378575, + 38173.525145437234, + 38192.163424259939, + 38210.803977291551, + 38229.446803977284, + 38248.091903762703, + 38266.739276093685, + 38285.388920416466, + 38304.040836177606, + 38322.695022824002, + 38341.351479802899, + 38360.010206561863, + 38378.671202548816, + 38397.334467211993, + 38415.999999999978, + 38434.667800361683, + 38453.33786774637, + 38472.010201603611, + 38490.684801383337, + 38509.361666535784, + 38528.040796511552, + 38546.722190761553, + 38565.405848737035, + 38584.091769889594, + 38602.779953671132, + 38621.470399533908, + 38640.163106930493, + 38658.858075313794, + 38677.555304137059, + 38696.254792853862, + 38714.956540918094, + 38733.660547783991, + 38752.366812906112, + 38771.075335739348, + 38789.78611573892, + 38808.499152360368, + 38827.214445059573, + 38845.931993292739, + 38864.651796516388, + 38883.373854187383, + 38902.098165762916, + 38920.824730700486, + 38939.553548457938, + 38958.284618493431, + 38977.017940265461, + 38995.753513232834, + 39014.491336854699, + 39033.231410590517, + 39051.973733900079, + 39070.718306243485, + 39089.465127081188, + 39108.214195873945, + 39126.965512082832, + 39145.719075169261, + 39164.474884594965, + 39183.232939821988, + 39201.99324031271, + 39220.755785529815, + 39239.52057493633, + 39258.287607995589, + 39277.056884171245, + 39295.828402927284, + 39314.602163728006, + 39333.378166038019, + 39352.15640932227, + 39370.936893046004, + 39389.719616674811, + 39408.504579674584, + 39427.291781511522, + 39446.081221652174, + 39464.872899563372, + 39483.666814712291, + 39502.462966566411, + 39521.261354593538, + 39540.06197826178, + 39558.864837039568, + 39577.669930395656, + 39596.47725779911, + 39615.286818719302, + 39634.098612625923, + 39652.912638988993, + 39671.728897278823, + 39690.547386966064, + 39709.368107521652, + 39728.191058416858, + 39747.016239123259, + 39765.84364911275, + 39784.673287857528, + 39803.505154830105, + 39822.339249503319, + 39841.175571350293, + 39860.014119844491, + 39878.854894459677, + 39897.697894669909, + 39916.54311994958, + 39935.390569773372, + 39954.240243616303, + 39973.092140953675, + 39991.946261261117, + 40010.802604014549, + 40029.661168690225, + 40048.521954764678, + 40067.384961714779, + 40086.250189017679, + 40105.117636150855, + 40123.98730259209, + 40142.859187819471, + 40161.733291311379, + 40180.609612546526, + 40199.488151003912, + 40218.368906162854, + 40237.25187750296, + 40256.137064504153, + 40275.024466646668, + 40293.914083411029, + 40312.805914278084, + 40331.699958728961, + 40350.596216245103, + 40369.494686308273, + 40388.39536840051, + 40407.298262004173, + 40426.20336660192, + 40445.110681676706, + 40464.020206711793, + 40482.931941190756, + 40501.845884597446, + 40520.762036416032, + 40539.680396130985, + 40558.600963227072, + 40577.523737189367, + 40596.448717503234, + 40615.375903654342, + 40634.305295128659, + 40653.236891412453, + 40672.170691992294, + 40691.106696355047, + 40710.044903987873, + 40728.985314378238, + 40747.927927013901, + 40766.872741382918, + 40785.819756973651, + 40804.768973274746, + 40823.720389775161, + 40842.674005964131, + 40861.629821331211, + 40880.587835366234, + 40899.548047559321, + 40918.510457400931, + 40937.475064381761, + 40956.441867992849, + 40975.410867725499, + 40994.382063071331, + 41013.355453522236, + 41032.331038570417, + 41051.308817708363, + 41070.288790428858, + 41089.270956224987, + 41108.255314590111, + 41127.241865017888, + 41146.23060700229, + 41165.221540037543, + 41184.214663618193, + 41203.209977239079, + 41222.207480395307, + 41241.207172582297, + 41260.209053295752, + 41279.213122031659, + 41298.219378286303, + 41317.227821556255, + 41336.23845133838, + 41355.251267129832, + 41374.266268428037, + 41393.283454730743, + 41412.302825535953, + 41431.324380341983, + 41450.348118647416, + 41469.374039951144, + 41488.402143752326, + 41507.432429550427, + 41526.464896845187, + 41545.499545136627, + 41564.536373925075, + 41583.575382711126, + 41602.616570995662, + 41621.659938279874, + 41640.705484065205, + 41659.753207853406, + 41678.803109146495, + 41697.855187446803, + 41716.909442256911, + 41735.965873079709, + 41755.02447941836, + 41774.085260776315, + 41793.148216657297, + 41812.213346565331, + 41831.280650004708, + 41850.350126480014, + 41869.421775496106, + 41888.495596558132, + 41907.571589171515, + 41926.649752841957, + 41945.730087075463, + 41964.812591378286, + 41983.897265256979, + 42002.984108218378, + 42022.073119769593, + 42041.164299418015, + 42060.257646671307, + 42079.353161037419, + 42098.450842024591, + 42117.550689141324, + 42136.652701896404, + 42155.756879798893, + 42174.863222358137, + 42193.971729083758, + 42213.082399485655, + 42232.195233074002, + 42251.310229359246, + 42270.427387852127, + 42289.546708063644, + 42308.668189505079, + 42327.791831687995, + 42346.917634124227, + 42366.045596325886, + 42385.175717805352, + 42404.307998075295, + 42423.442436648642, + 42442.579033038608, + 42461.717786758672, + 42480.858697322597, + 42500.001764244422, + 42519.146987038446, + 42538.294365219248, + 42557.443898301688, + 42576.595585800882, + 42595.749427232236, + 42614.90542211142, + 42634.063569954378, + 42653.223870277317, + 42672.386322596729, + 42691.55092642938, + 42710.717681292292, + 42729.886586702756, + 42749.057642178363, + 42768.23084723694, + 42787.406201396603, + 42806.58370417574, + 42825.76335509299, + 42844.945153667286, + 42864.129099417805, + 42883.315191864014, + 42902.503430525649, + 42921.693814922692, + 42940.88634457541, + 42960.081019004348, + 42979.277837730297, + 42998.476800274322, + 43017.677906157769, + 43036.881154902228, + 43056.086546029583, + 43075.294079061961, + 43094.503753521763, + 43113.715568931671, + 43132.929524814601, + 43152.145620693766, + 43171.363856092619, + 43190.584230534907, + 43209.806743544621, + 43229.031394646016, + 43248.258183363621, + 43267.487109222224, + 43286.718171746885, + 43305.951370462906, + 43325.186704895881, + 43344.42417457165, + 43363.663779016322, + 43382.905517756262, + 43402.149390318104, + 43421.395396228749, + 43440.643535015348, + 43459.89380620532, + 43479.146209326354, + 43498.400743906379, + 43517.657409473606, + 43536.916205556496, + 43556.177131683784, + 43575.44018738444, + 43594.705372187724, + 43613.972685623135, + 43633.242127220445, + 43652.513696509668, + 43671.787393021099, + 43691.063216285271, + 43710.341165833001, + 43729.621241195346, + 43748.903441903625, + 43768.187767489413, + 43787.474217484552, + 43806.762791421126, + 43826.053488831501, + 43845.346309248278, + 43864.641252204325, + 43883.938317232765, + 43903.237503866971, + 43922.538811640596, + 43941.842240087513, + 43961.147788741881, + 43980.455457138101, + 43999.765244810835, + 44019.077151295001, + 44038.391176125755, + 44057.70731883854, + 44077.02557896902, + 44096.345956053141, + 44115.668449627083, + 44134.993059227287, + 44154.319784390456, + 44173.648624653535, + 44192.979579553728, + 44212.312648628489, + 44231.647831415532, + 44250.985127452805, + 44270.324536278538, + 44289.666057431183, + 44309.009690449464, + 44328.355434872348, + 44347.703290239064, + 44367.053256089079, + 44386.405331962109, + 44405.759517398139, + 44425.115811937387, + 44444.474215120332, + 44463.834726487694, + 44483.197345580462, + 44502.562071939843, + 44521.928905107328, + 44541.297844624634, + 44560.668890033732, + 44580.042040876848, + 44599.417296696454, + 44618.794657035272, + 44638.174121436256, + 44657.555689442641, + 44676.939360597877, + 44696.325134445673, + 44715.713010530002, + 44735.102988395054, + 44754.495067585296, + 44773.88924764542, + 44793.285528120374, + 44812.683908555344, + 44832.084388495779, + 44851.486967487363, + 44870.891645076015, + 44890.298420807922, + 44909.707294229491, + 44929.118264887409, + 44948.531332328566, + 44967.946496100136, + 44987.363755749502, + 45006.783110824319, + 45026.204560872473, + 45045.628105442098, + 45065.053744081561, + 45084.48147633949, + 45103.911301764747, + 45123.343219906426, + 45142.777230313885, + 45162.21333253671, + 45181.651526124733, + 45201.091810628037, + 45220.534185596924, + 45239.978650581965, + 45259.425205133957, + 45278.873848803938, + 45298.324581143192, + 45317.777401703235, + 45337.232310035848, + 45356.68930569302, + 45376.148388226997, + 45395.60955719027, + 45415.072812135557, + 45434.538152615823, + 45454.005578184282, + 45473.475088394356, + 45492.946682799746, + 45512.420360954362, + 45531.896122412363, + 45551.373966728155, + 45570.853893456362, + 45590.33590215187, + 45609.819992369776, + 45629.306163665438, + 45648.794415594442, + 45668.284747712612, + 45687.777159576006, + 45707.27165074092, + 45726.768220763894, + 45746.266869201696, + 45765.767595611323, + 45785.270399550034, + 45804.775280575297, + 45824.282238244828, + 45843.79127211657, + 45863.302381748719, + 45882.815566699683, + 45902.33082652813, + 45921.848160792935, + 45941.367569053225, + 45960.889050868354, + 45980.41260579793, + 45999.938233401757, + 46019.465933239902, + 46038.995704872657, + 46058.527547860547, + 46078.06146176433, + 46097.597446144995, + 46117.135500563774, + 46136.675624582109, + 46156.217817761702, + 46175.762079664462, + 46195.308409852543, + 46214.856807888333, + 46234.407273334444, + 46253.959805753715, + 46273.51440470924, + 46293.071069764315, + 46312.629800482478, + 46332.190596427499, + 46351.753457163381, + 46371.318382254351, + 46390.885371264863, + 46410.45442375962, + 46430.025539303526, + 46449.598717461733, + 46469.17395779962, + 46488.751259882782, + 46508.33062327707, + 46527.912047548532, + 46547.495532263471, + 46567.081076988397, + 46586.668681290059, + 46606.258344735434, + 46625.850066891719, + 46645.443847326351, + 46665.039685606986, + 46684.637581301497, + 46704.237533978005, + 46723.839543204842, + 46743.443608550573, + 46763.049729583989, + 46782.657905874104, + 46802.268136990162, + 46821.880422501628, + 46841.494761978196, + 46861.111154989776, + 46880.729601106526, + 46900.350099898795, + 46919.97265093719, + 46939.597253792526, + 46959.223908035841, + 46978.852613238392, + 46998.483368971691, + 47018.11617480743, + 47037.751030317551, + 47057.387935074221, + 47077.026888649809, + 47096.66789061694, + 47116.310940548428, + 47135.956038017328, + 47155.603182596918, + 47175.252373860698, + 47194.903611382375, + 47214.556894735892, + 47234.212223495422, + 47253.869597235338, + 47273.52901553025, + 47293.19047795498, + 47312.853984084577, + 47332.519533494306, + 47352.187125759658, + 47371.856760456343, + 47391.528437160297, + 47411.202155447652, + 47430.877914894787, + 47450.555715078299, + 47470.235555574982, + 47489.917435961863, + 47509.601355816201, + 47529.287314715453, + 47548.975312237308, + 47568.665347959672, + 47588.357421460656, + 47608.051532318605, + 47627.747680112072, + 47647.445864419846, + 47667.14608482091, + 47686.848340894474, + 47706.552632219973, + 47726.258958377046, + 47745.967318945557, + 47765.677713505589, + 47785.390141637428, + 47805.104602921601, + 47824.821096938824, + 47844.539623270044, + 47864.260181496429, + 47883.982771199349, + 47903.707391960394, + 47923.434043361369, + 47943.162724984308, + 47962.893436411439, + 47982.626177225218, + 48002.36094700831, + 48022.097745343599, + 48041.836571814172, + 48061.57742600335, + 48081.32030749465, + 48101.065215871815, + 48120.81215071879, + 48140.56111161974, + 48160.312098159047, + 48180.065109921306, + 48199.820146491307, + 48219.577207454073, + 48239.336292394844, + 48259.097400899045, + 48278.860532552339, + 48298.625686940592, + 48318.392863649875, + 48338.162062266485, + 48357.933282376915, + 48377.706523567889, + 48397.481785426316, + 48417.259067539344, + 48437.038369494308, + 48456.819690878765, + 48476.603031280487, + 48496.388390287451, + 48516.175767487839, + 48535.965162470042, + 48555.756574822684, + 48575.550004134566, + 48595.345449994718, + 48615.142911992378, + 48634.942389716991, + 48654.743882758201, + 48674.547390705877, + 48694.352913150084, + 48714.160449681112, + 48733.969999889443, + 48753.781563365759, + 48773.595139700978, + 48793.410728486211, + 48813.228329312769, + 48833.047941772187, + 48852.869565456189, + 48872.693199956717, + 48892.518844865925, + 48912.346499776155, + 48932.176164279976, + 48952.007837970152, + 48971.841520439666, + 48991.677211281676, + 49011.514910089587, + 49031.354616456978, + 49051.196329977654, + 49071.04005024561, + 49090.885776855059, + 49110.733509400408, + 49130.583247476279, + 49150.434990677488, + 49170.288738599062, + 49190.144490836232, + 49210.002246984441, + 49229.86200663932, + 49249.723769396718, + 49269.587534852675, + 49289.453302603448, + 49309.32107224549, + 49329.190843375451, + 49349.062615590192, + 49368.936388486785, + 49388.812161662492, + 49408.689934714785, + 49428.569707241324, + 49448.45147883999, + 49468.335249108866, + 49488.22101764621, + 49508.108784050521, + 49527.99854792047, + 49547.890308854934, + 49567.784066453009, + 49587.679820313977, + 49607.57757003732, + 49627.477315222721, + 49647.379055470075, + 49667.28279037946, + 49687.188519551179, + 49707.096242585707, + 49727.005959083741, + 49746.917668646165, + 49766.831370874068, + 49786.747065368734, + 49806.66475173166, + 49826.584429564515, + 49846.506098469203, + 49866.429758047794, + 49886.355407902578, + 49906.283047636032, + 49926.212676850846, + 49946.144295149883, + 49966.077902136225, + 49986.013497413151, + 50005.951080584135, + 50025.890651252834, + 50045.832209023123, + 50065.775753499074, + 50085.721284284933, + 50105.668800985164, + 50125.618303204428, + 50145.569790547575, + 50165.523262619652, + 50185.478719025901, + 50205.436159371769, + 50225.395583262893, + 50245.356990305103, + 50265.320380104429, + 50285.285752267104, + 50305.253106399534, + 50325.222442108337, + 50345.193759000336, + 50365.16705668252, + 50385.142334762102, + 50405.119592846473, + 50425.098830543218, + 50445.080047460127, + 50465.063243205179, + 50485.048417386541, + 50505.035569612577, + 50525.024699491856, + 50545.015806633128, + 50565.008890645338, + 50585.003951137631, + 50605.00098771933, + 50624.999999999971, + 50645.000987589265, + 50665.003950097132, + 50685.008887133677, + 50705.015798309192, + 50725.024683234165, + 50745.035541519283, + 50765.048372775411, + 50785.063176613621, + 50805.079952645159, + 50825.098700481489, + 50845.119419734241, + 50865.142110015244, + 50885.166770936521, + 50905.193402110279, + 50925.222003148934, + 50945.252573665071, + 50965.285113271471, + 50985.319621581119, + 51005.356098207172, + 51025.394542762981, + 51045.434954862096, + 51065.477334118244, + 51085.521680145357, + 51105.567992557546, + 51125.616270969113, + 51145.66651499454, + 51165.718724248516, + 51185.772898345916, + 51205.829036901778, + 51225.887139531362, + 51245.947205850105, + 51266.009235473619, + 51286.073228017718, + 51306.139183098399, + 51326.207100331856, + 51346.276979334456, + 51366.348819722756, + 51386.42262111351, + 51406.498383123653, + 51426.57610537031, + 51446.655787470787, + 51466.737429042587, + 51486.82102970338, + 51506.906589071048, + 51526.994106763632, + 51547.083582399391, + 51567.175015596738, + 51587.268405974297, + 51607.363753150858, + 51627.461056745415, + 51647.56031637713, + 51667.661531665362, + 51687.764702229651, + 51707.869827689727, + 51727.976907665499, + 51748.085941777055, + 51768.196929644677, + 51788.309870888836, + 51808.42476513017, + 51828.541611989524, + 51848.660411087905, + 51868.781162046515, + 51888.90386448674, + 51909.028518030143, + 51929.155122298485, + 51949.283676913685, + 51969.414181497872, + 51989.546635673345, + 52009.681039062583, + 52029.817391288263, + 52049.955691973213, + 52070.095940740481, + 52090.238137213273, + 52110.382281014987, + 52130.5283717692, + 52150.676409099666, + 52170.826392630333, + 52190.97832198532, + 52211.132196788931, + 52231.288016665654, + 52251.445781240145, + 52271.60549013727, + 52291.76714298204, + 52311.930739399664, + 52332.096279015546, + 52352.263761455244, + 52372.433186344519, + 52392.604553309284, + 52412.777861975665, + 52432.953111969946, + 52453.130302918595, + 52473.309434448267, + 52493.490506185793, + 52513.67351775818, + 52533.858468792605, + 52554.045358916446, + 52574.234187757254, + 52594.42495494274, + 52614.617660100812, + 52634.812302859558, + 52655.008882847229, + 52675.20739969227, + 52695.407853023295, + 52715.610242469098, + 52735.814567658657, + 52756.02082822111, + 52776.229023785803, + 52796.439153982225, + 52816.651218440056, + 52836.865216789171, + 52857.081148659599, + 52877.29901368155, + 52897.518811485425, + 52917.740541701773, + 52937.964203961354, + 52958.18979789508, + 52978.417323134046, + 52998.646779309529, + 53018.878166052978, + 53039.111482996006, + 53059.346729770419, + 53079.583906008193, + 53099.823011341483, + 53120.0640454026, + 53140.307007824063, + 53160.551898238533, + 53180.79871627887, + 53201.047461578091, + 53221.2981337694, + 53241.550732486176, + 53261.805257361964, + 53282.061708030487, + 53302.32008412564, + 53322.580385281493, + 53342.842611132299, + 53363.106761312469, + 53383.372835456597, + 53403.640833199453, + 53423.910754175973, + 53444.18259802126, + 53464.456364370613, + 53484.732052859479, + 53505.009663123499, + 53525.289194798468, + 53545.570647520362, + 53565.854020925333, + 53586.139314649699, + 53606.426528329954, + 53626.715661602764, + 53647.006714104959, + 53667.299685473547, + 53687.59457534572, + 53707.891383358816, + 53728.190109150361, + 53748.490752358055, + 53768.793312619753, + 53789.09778957349, + 53809.404182857485, + 53829.712492110106, + 53850.022716969899, + 53870.334857075584, + 53890.648912066055, + 53910.964881580367, + 53931.28276525774, + 53951.602562737586, + 53971.924273659461, + 53992.24789766311, + 54012.57343438844, + 54032.90088347553, + 54053.23024456462, + 54073.561517296133, + 54093.894701310644, + 54114.22979624891, + 54134.566801751855, + 54154.90571746057, + 54175.246543016314, + 54195.589278060506, + 54215.933922234755, + 54236.280475180814, + 54256.628936540626, + 54276.97930595628, + 54297.331583070045, + 54317.685767524359, + 54338.041858961828, + 54358.399857025215, + 54378.759761357462, + 54399.121571601667, + 54419.485287401105, + 54439.850908399218, + 54460.218434239614, + 54480.587864566056, + 54500.95919902248, + 54521.332437252997, + 54541.707578901878, + 54562.084623613555, + 54582.46357103264, + 54602.844420803893, + 54623.227172572246, + 54643.611825982807, + 54663.998380680838, + 54684.386836311773, + 54704.777192521207, + 54725.169448954897, + 54745.563605258772, + 54765.959661078923, + 54786.357616061614, + 54806.757469853255, + 54827.159222100439, + 54847.562872449904, + 54867.968420548583, + 54888.375866043534, + 54908.785208582012, + 54929.196447811417, + 54949.609583379322, + 54970.024614933463, + 54990.441542121727, + 55010.86036459219, + 55031.28108199306, + 55051.703693972733, + 55072.128200179759, + 55092.554600262847, + 55112.982893870874, + 55133.413080652877, + 55153.845160258061, + 55174.279132335789, + 55194.714996535586, + 55215.152752507143, + 55235.592399900306, + 55256.033938365079, + 55276.477367551655, + 55296.92268711036, + 55317.369896691685, + 55337.818995946305, + 55358.269984525024, + 55378.72286207883, + 55399.177628258869, + 55419.634282716441, + 55440.092825103013, + 55460.553255070205, + 55481.015572269804, + 55501.479776353764, + 55521.945866974187, + 55542.413843783339, + 55562.883706433655, + 55583.355454577715, + 55603.82908786826, + 55624.304605958219, + 55644.782008500639, + 55665.261295148754, + 55685.742465555952, + 55706.225519375774, + 55726.710456261928, + 55747.197275868275, + 55767.685977848843, + 55788.176561857814, + 55808.669027549528, + 55829.163374578478, + 55849.659602599328, + 55870.157711266889, + 55890.657700236145, + 55911.159569162221, + 55931.663317700411, + 55952.168945506164, + 55972.676452235086, + 55993.185837542944, + 56013.697101085651, + 56034.210242519301, + 56054.72526150012, + 56075.242157684508, + 56095.760930729011, + 56116.281580290342, + 56136.804106025367, + 56157.328507591104, + 56177.85478464474, + 56198.382936843598, + 56218.912963845185, + 56239.444865307138, + 56259.978640887268, + 56280.514290243525, + 56301.051813034042, + 56321.591208917082, + 56342.13247755108, + 56362.675618594607, + 56383.220631706419, + 56403.767516545398, + 56424.316272770608, + 56444.866900041241, + 56465.419398016667, + 56485.973766356394, + 56506.530004720102, + 56527.088112767611, + 56547.648090158902, + 56568.209936554107, + 56588.773651613519, + 56609.339234997584, + 56629.9066863669, + 56650.47600538221, + 56671.04719170442, + 56691.620244994599, + 56712.195164913959, + 56732.771951123868, + 56753.350603285835, + 56773.931121061541, + 56794.513504112823, + 56815.097752101647, + 56835.683864690152, + 56856.271841540627, + 56876.86168231551, + 56897.453386677393, + 56918.046954289028, + 56938.642384813298, + 56959.239677913261, + 56979.838833252121, + 57000.439850493225, + 57021.04272930009, + 57041.647469336371, + 57062.254070265873, + 57082.862531752558, + 57103.472853460553, + 57124.085035054108, + 57144.699076197649, + 57165.314976555739, + 57185.932735793103, + 57206.552353574611, + 57227.173829565276, + 57247.797163430281, + 57268.42235483494, + 57289.049403444733, + 57309.678308925286, + 57330.30907094237, + 57350.941689161911, + 57371.576163249985, + 57392.212492872815, + 57412.850677696784, + 57433.490717388406, + 57454.132611614368, + 57474.776360041491, + 57495.421962336746, + 57516.069418167266, + 57536.718727200314, + 57557.36988910332, + 57578.022903543861, + 57598.677770189643, + 57619.334488708548, + 57639.993058768589, + 57660.653480037938, + 57681.315752184906, + 57701.979874877965, + 57722.64584778573, + 57743.31367057695, + 57763.983342920546, + 57784.654864485572, + 57805.328234941233, + 57826.003453956881, + 57846.680521202026, + 57867.359436346305, + 57888.040199059527, + 57908.722809011633, + 57929.407265872709, + 57950.093569313001, + 57970.781719002895, + 57991.471714612911, + 58012.16355581375, + 58032.857242276223, + 58053.552773671312, + 58074.25014967013, + 58094.949369943948, + 58115.650434164185, + 58136.353342002389, + 58157.058093130276, + 58177.764687219693, + 58198.47312394264, + 58219.183402971255, + 58239.895523977837, + 58260.609486634821, + 58281.325290614775, + 58302.042935590434, + 58322.762421234678, + 58343.483747220511, + 58364.206913221096, + 58384.931918909751, + 58405.658763959924, + 58426.3874480452, + 58447.117970839339, + 58467.85033201622, + 58488.584531249864, + 58509.320568214462, + 58530.058442584334, + 58550.798154033931, + 58571.539702237875, + 58592.283086870906, + 58613.028307607929, + 58633.775364123983, + 58654.52425609425, + 58675.274983194053, + 58696.027545098877, + 58716.781941484325, + 58737.538172026158, + 58758.296236400274, + 58779.056134282728, + 58799.817865349694, + 58820.581429277503, + 58841.346825742643, + 58862.114054421712, + 58882.883114991484, + 58903.654007128847, + 58924.426730510851, + 58945.201284814684, + 58965.977669717664, + 58986.755884897269, + 59007.535930031117, + 59028.317804796949, + 59049.101508872664, + 59069.887041936301, + 59090.674403666046, + 59111.463593740213, + 59132.254611837263, + 59153.047457635803, + 59173.84213081457, + 59194.638631052461, + 59215.436958028506, + 59236.237111421855, + 59257.039090911829, + 59277.842896177877, + 59298.648526899589, + 59319.455982756685, + 59340.26526342905, + 59361.076368596696, + 59381.889297939757, + 59402.704051138542, + 59423.520627873484, + 59444.339027825139, + 59465.159250674224, + 59485.9812961016, + 59506.805163788253, + 59527.630853415307, + 59548.458364664046, + 59569.287697215863, + 59590.118850752311, + 59610.951824955089, + 59631.786619506012, + 59652.623234087048, + 59673.461668380311, + 59694.301922068029, + 59715.143994832593, + 59735.987886356525, + 59756.833596322482, + 59777.681124413255, + 59798.530470311794, + 59819.381633701159, + 59840.234614264569, + 59861.089411685381, + 59881.94602564707, + 59902.804455833269, + 59923.664701927737, + 59944.526763614384, + 59965.390640577243, + 59986.256332500488, + 60007.123839068438, + 60027.993159965539, + 60048.864294876381, + 60069.737243485688, + 60090.612005478324, + 60111.488580539284, + 60132.366968353708, + 60153.247168606867, + 60174.129180984164, + 60195.013005171153, + 60215.898640853513, + 60236.786087717061, + 60257.675345447751, + 60278.566413731671, + 60299.459292255044, + 60320.353980704247, + 60341.25047876576, + 60362.148786126229, + 60383.048902472423, + 60403.950827491237, + 60424.854560869717, + 60445.76010229504, + 60466.667451454516, + 60487.57660803559, + 60508.487571725847, + 60529.400342212997, + 60550.314919184893, + 60571.231302329521, + 60592.149491335003, + 60613.069485889588, + 60633.991285681674, + 60654.914890399785, + 60675.840299732568, + 60696.767513368832, + 60717.696530997484, + 60738.627352307602, + 60759.55997698837, + 60780.494404729128, + 60801.430635219323, + 60822.368668148556, + 60843.308503206565, + 60864.250140083204, + 60885.193578468468, + 60906.138818052495, + 60927.085858525541, + 60948.034699578006, + 60968.985340900421, + 60989.937782183442, + 61010.892023117864, + 61031.848063394616, + 61052.805902704764, + 61073.765540739492, + 61094.726977190134, + 61115.690211748137, + 61136.655244105103, + 61157.622073952742, + 61178.590700982917, + 61199.561124887616, + 61220.533345358948, + 61241.507362089171, + 61262.483174770663, + 61283.460783095943, + 61304.440186757645, + 61325.421385448557, + 61346.404378861582, + 61367.389166689762, + 61388.375748626262, + 61409.364124364387, + 61430.354293597571, + 61451.346256019373, + 61472.340011323497, + 61493.335559203762, + 61514.332899354122, + 61535.332031468672, + 61556.332955241618, + 61577.335670367313, + 61598.340176540238, + 61619.346473454993, + 61640.354560806329, + 61661.3644382891, + 61682.376105598312, + 61703.389562429089, + 61724.404808476691, + 61745.42184343651, + 61766.440667004063, + 61787.461278874987, + 61808.483678745069, + 61829.507866310203, + 61850.533841266435, + 61871.561603309929, + 61892.591152136971, + 61913.622487443987, + 61934.655608927525, + 61955.690516284267, + 61976.727209211022, + 61997.765687404724, + 62018.805950562448, + 62039.847998381381, + 62060.891830558845, + 62081.93744679229, + 62102.984846779298, + 62124.034030217575, + 62145.084996804966, + 62166.137746239416, + 62187.19227821903, + 62208.248592442025, + 62229.306688606739, + 62250.366566411656, + 62271.428225555377, + 62292.491665736627, + 62313.556886654267, + 62334.623888007271, + 62355.692669494762, + 62376.763230815974, + 62397.835571670272, + 62418.909691757144, + 62439.98559077621, + 62461.063268427228, + 62482.142724410049, + 62503.223958424685, + 62524.306970171267, + 62545.39175935003, + 62566.478325661366, + 62587.566668805768, + 62608.656788483881, + 62629.748684396451, + 62650.842356244357, + 62671.937803728622, + 62693.035026550366, + 62714.134024410858, + 62735.234797011479, + 62756.337344053733, + 62777.441665239276, + 62798.547760269852, + 62819.655628847358, + 62840.765270673801, + 62861.876685451323, + 62882.989872882186, + 62904.104832668774, + 62925.221564513602, + 62946.340068119309, + 62967.460343188657, + 62988.582389424526, + 63009.70620652994, + 63030.831794208025, + 63051.959152162039, + 63073.08828009537, + 63094.219177711529, + 63115.351844714154, + 63136.486280806988, + 63157.622485693922, + 63178.760459078956, + 63199.900200666219, + 63221.041710159967, + 63242.184987264569, + 63263.330031684534, + 63284.476843124474, + 63305.625421289144, + 63326.775765883409, + 63347.927876612259, + 63369.081753180813, + 63390.237395294316, + 63411.39480265812, + 63432.553974977716, + 63453.714911958712, + 63474.877613306839, + 63496.042078727944, + 63517.208307927998, + 63538.376300613119, + 63559.546056489504, + 63580.717575263516, + 63601.890856641607, + 63623.065900330374, + 63644.242706036515, + 63665.421273466869, + 63686.601602328381, + 63707.783692328136, + 63728.967543173334, + 63750.153154571279, + 63771.340526229418, + 63792.529657855317, + 63813.720549156649, + 63834.913199841227, + 63856.107609616978, + 63877.303778191941, + 63898.501705274284, + 63919.7013905723, + 63940.902833794404, + 63962.106034649114, + 63983.310992845094, + 64004.517708091109, + 64025.726180096048, + 64046.936408568938, + 64068.1483932189, + 64089.362133755196, + 64110.577629887193, + 64131.794881324393, + 64153.013887776404, + 64174.234648952966, + 64195.457164563937, + 64216.681434319289, + 64237.907457929112, + 64259.135235103626, + 64280.36476555316, + 64301.596048988169, + 64322.829085119236, + 64344.06387365704, + 64365.300414312398, + 64386.538706796251, + 64407.778750819634, + 64429.020546093721, + 64450.26409232981, + 64471.509389239291, + 64492.756436533709, + 64514.005233924705, + 64535.255781124033, + 64556.50807784358, + 64577.762123795357, + 64599.017918691468, + 64620.275462244172, + 64641.534754165805, + 64662.795794168844, + 64684.058581965895, + 64705.323117269661, + 64726.589399792974, + 64747.857429248776, + 64769.127205350138, + 64790.398727810236, + 64811.671996342375, + 64832.947010659969, + 64854.223770476558, + 64875.502275505794, + 64896.782525461451, + 64918.064520057414, + 64939.348259007682, + 64960.633742026388, + 64981.920968827762, + 65003.209939126165, + 65024.500652636067, + 65045.793109072067, + 65067.087308148861, + 65088.383249581282, + 65109.680933084259, + 65130.980358372864, + 65152.28152516226, + 65173.584433167736, + 65194.889082104703, + 65216.195471688683, + 65237.503601635319, + 65258.813471660353, + 65280.125081479666, + 65301.438430809241, + 65322.753519365178, + 65344.070346863708, + 65365.388913021146, + 65386.709217553958, + 65408.031260178701, + 65429.355040612056, + 65450.680558570821, + 65472.00781377191, + 65493.336805932355, + 65514.66753476928, + 65535.999999999956, + 65557.334201341757, + 65578.670138512171, + 65600.007811228788, + 65621.347219209332, + 65642.688362171626, + 65664.031239833639, + 65685.375851913413, + 65706.722198129137, + 65728.070278199084, + 65749.420091841661, + 65770.771638775404, + 65792.124918718939, + 65813.479931391004, + 65834.836676510458, + 65856.195153796303, + 65877.5553629676, + 65898.917303743554, + 65920.280975843489, + 65941.646378986843, + 65963.013512893158, + 65984.382377282076, + 66005.752971873386, + 66027.125296386963, + 66048.499350542799, + 66069.875134061018, + 66091.252646661844, + 66112.631888065618, + 66134.01285799277, + 66155.395556163887, + 66176.779982299631, + 66198.166136120795, + 66219.554017348273, + 66240.943625703105, + 66262.334960906388, + 66283.728022679396, + 66305.122810743444, + 66326.519324820023, + 66347.917564630698, + 66369.317529897162, + 66390.719220341227, + 66412.122635684791, + 66433.527775649884, + 66454.934639958636, + 66476.343228333324, + 66497.753540496284, + 66519.165576169995, + 66540.57933507704, + 66561.994816940118, + 66583.412021482043, + 66604.830948425733, + 66626.251597494222, + 66647.673968410629, + 66669.098060898235, + 66690.523874680381, + 66711.951409480564, + 66733.380665022371, + 66754.811641029475, + 66776.244337225711, + 66797.678753334985, + 66819.11488908132, + 66840.552744188884, + 66861.992318381905, + 66883.433611384738, + 66904.876622921889, + 66926.321352717903, + 66947.767800497502, + 66969.215965985466, + 66990.665848906734, + 67012.117448986304, + 67033.570765949335, + 67055.025799521056, + 67076.482549426815, + 67097.941015392076, + 67119.401197142433, + 67140.863094403554, + 67162.326706901222, + 67183.792034361351, + 67205.259076509959, + 67226.72783307315, + 67248.198303777172, + 67269.670488348347, + 67291.144386513144, + 67312.619997998088, + 67334.09732252988, + 67355.576359835293, + 67377.057109641188, + 67398.53957167457, + 67420.023745662547, + 67441.50963133233, + 67462.99722841123, + 67484.486536626689, + 67505.977555706224, + 67527.470285377494, + 67548.964725368263, + 67570.460875406367, + 67591.9587352198, + 67613.458304536631, + 67634.95958308503, + 67656.462570593329, + 67677.967266789899, + 67699.473671403248, + 67720.981784162024, + 67742.491604794923, + 67764.003133030797, + 67785.516368598575, + 67807.031311227314, + 67828.547960646174, + 67850.066316584402, + 67871.58637877139, + 67893.108146936589, + 67914.63162080961, + 67936.156800120138, + 67957.683684597971, + 67979.212273973011, + 68000.742567975263, + 68022.274566334876, + 68043.808268782057, + 68065.343675047145, + 68086.880784860579, + 68108.419597952918, + 68129.960114054789, + 68151.502332896969, + 68173.04625421032, + 68194.591877725834, + 68216.139203174564, + 68237.688230287706, + 68259.238958796544, + 68280.791388432481, + 68302.345518927032, + 68323.901350011787, + 68345.458881418483, + 68367.018112878912, + 68388.579044125028, + 68410.141674888844, + 68431.706004902502, + 68453.272033898262, + 68474.839761608455, + 68496.409187765545, + 68517.980312102081, + 68539.553134350732, + 68561.127654244279, + 68582.70387151558, + 68604.281785897634, + 68625.861397123503, + 68647.44270492639, + 68669.025709039604, + 68690.610409196524, + 68712.196805130661, + 68733.784896575627, + 68755.374683265123, + 68776.966164932994, + 68798.559341313128, + 68820.154212139591, + 68841.750777146473, + 68863.349036068044, + 68884.948988638629, + 68906.550634592684, + 68928.153973664739, + 68949.75900558944, + 68971.365730101577, + 68992.974146935987, + 69014.584255827634, + 69036.196056511588, + 69057.809548723017, + 69079.424732197207, + 69101.041606669532, + 69122.660171875468, + 69144.280427550606, + 69165.902373430625, + 69187.526009251334, + 69209.151334748618, + 69230.778349658474, + 69252.40705371699, + 69274.037446660412, + 69295.669528225, + 69317.303298147192, + 69338.938756163494, + 69360.575902010532, + 69382.214735425005, + 69403.855256143754, + 69425.497463903681, + 69447.141358441833, + 69468.78693949533, + 69490.434206801394, + 69512.083160097391, + 69533.733799120717, + 69555.386123608929, + 69577.04013329967, + 69598.695827930685, + 69620.353207239794, + 69642.012270964973, + 69663.67301884426, + 69685.335450615792, + 69706.999566017839, + 69728.665364788743, + 69750.332846666963, + 69772.002011391058, + 69793.672858699691, + 69815.345388331611, + 69837.019600025669, + 69858.695493520849, + 69880.373068556204, + 69902.052324870907, + 69923.733262204216, + 69945.415880295492, + 69967.100178884211, + 69988.786157709939, + 70010.473816512356, + 70032.163155031216, + 70053.854173006403, + 70075.546870177874, + 70097.241246285717, + 70118.937301070109, + 70140.635034271298, + 70162.334445629691, + 70184.035534885741, + 70205.738301780017, + 70227.442746053217, + 70249.1488674461, + 70270.856665699539, + 70292.566140554511, + 70314.277291752107, + 70335.990119033493, + 70357.704622139936, + 70379.420800812819, + 70401.138654793613, + 70422.85818382389, + 70444.579387645339, + 70466.302265999722, + 70488.026818628918, + 70509.753045274876, + 70531.480945679708, + 70553.210519585555, + 70574.941766734701, + 70596.674686869505, + 70618.409279732456, + 70640.145545066101, + 70661.883482613106, + 70683.623092116264, + 70705.364373318414, + 70727.107325962526, + 70748.851949791671, + 70770.598244549008, + 70792.346209977783, + 70814.095845821372, + 70835.847151823225, + 70857.600127726895, + 70879.354773276034, + 70901.111088214413, + 70922.869072285859, + 70944.628725234332, + 70966.390046803877, + 70988.153036738629, + 71009.917694782853, + 71031.684020680885, + 71053.45201417715, + 71075.221675016204, + 71096.993002942661, + 71118.765997701266, + 71140.540659036851, + 71162.316986694335, + 71184.09498041874, + 71205.874639955218, + 71227.655965048951, + 71249.438955445294, + 71271.223610889632, + 71293.009931127483, + 71314.797915904477, + 71336.587564966307, + 71358.378878058764, + 71380.171854927772, + 71401.966495319313, + 71423.762798979486, + 71445.560765654489, + 71467.360395090596, + 71489.161687034211, + 71510.964641231811, + 71532.769257429973, + 71554.575535375348, + 71576.383474814749, + 71598.19307549503, + 71620.004337163133, + 71641.817259566145, + 71663.631842451214, + 71685.4480855656, + 71707.26598865664, + 71729.085551471784, + 71750.906773758586, + 71772.729655264673, + 71794.554195737772, + 71816.380394925713, + 71838.208252576442, + 71860.037768437964, + 71881.868942258385, + 71903.701773785942, + 71925.536262768932, + 71947.372408955751, + 71969.210212094898, + 71991.049671934976, + 72012.890788224686, + 72034.73356071279, + 72056.577989148165, + 72078.424073279821, + 72100.271812856794, + 72122.121207628254, + 72143.97225734347, + 72165.824961751801, + 72187.679320602692, + 72209.53533364569, + 72231.393000630429, + 72253.252321306645, + 72275.113295424177, + 72296.975922732949, + 72318.840202982959, + 72340.706135924338, + 72362.573721307272, + 72384.442958882093, + 72406.313848399179, + 72428.186389609036, + 72450.060582262216, + 72471.936426109431, + 72493.813920901433, + 72515.693066389096, + 72537.573862323392, + 72559.456308455352, + 72581.340404536139, + 72603.226150316987, + 72625.113545549248, + 72647.002589984331, + 72668.893283373764, + 72690.785625469172, + 72712.679616022273, + 72734.575254784853, + 72756.472541508803, + 72778.371475946144, + 72800.272057848939, + 72822.174286969355, + 72844.07816305969, + 72865.983685872285, + 72887.890855159596, + 72909.799670674183, + 72931.710132168693, + 72953.622239395845, + 72975.535992108475, + 72997.451390059519, + 73019.368433001961, + 73041.287120688925, + 73063.207452873612, + 73085.129429309294, + 73107.053049749389, + 73128.978313947344, + 73150.905221656736, + 73172.833772631217, + 73194.763966624567, + 73216.695803390612, + 73238.62928268328, + 73260.564404256627, + 73282.501167864757, + 73304.439573261901, + 73326.379620202337, + 73348.321308440485, + 73370.264637730841, + 73392.209607827957, + 73414.156218486532, + 73436.104469461323, + 73458.054360507173, + 73480.005891379056, + 73501.959061831993, + 73523.913871621116, + 73545.870320501665, + 73567.828408228932, + 73589.78813455833, + 73611.749499245358, + 73633.712502045615, + 73655.677142714747, + 73677.643421008557, + 73699.611336682879, + 73721.580889493693, + 73743.552079197019, + 73765.524905548999, + 73787.499368305856, + 73809.475467223907, + 73831.453202059551, + 73853.432572569291, + 73875.413578509717, + 73897.396219637507, + 73919.380495709411, + 73941.36640648231, + 73963.353951713143, + 73985.343131158952, + 74007.333944576865, + 74029.326391724098, + 74051.320472357969, + 74073.316186235883, + 74095.313533115303, + 74117.312512753837, + 74139.313124909138, + 74161.315369338976, + 74183.319245801191, + 74205.324754053727, + 74227.331893854629, + 74249.340664961986, + 74271.351067134034, + 74293.363100129049, + 74315.376763705441, + 74337.392057621662, + 74359.408981636298, + 74381.427535508003, + 74403.447718995507, + 74425.469531857671, + 74447.492973853383, + 74469.518044741693, + 74491.54474428168, + 74513.573072232539, + 74535.603028353551, + 74557.634612404087, + 74579.667824143602, + 74601.702663331642, + 74623.739129727837, + 74645.777223091936, + 74667.816943183716, + 74689.858289763113, + 74711.901262590094, + 74733.945861424741, + 74755.992086027225, + 74778.039936157802, + 74800.089411576817, + 74822.140512044702, + 74844.193237321961, + 74866.24758716923, + 74888.303561347187, + 74910.36115961663, + 74932.420381738411, + 74954.481227473516, + 74976.543696582972, + 74998.607788827925, + 75020.673503969607, + 75042.740841769322, + 75064.809801988464, + 75086.88038438854, + 75108.952588731103, + 75131.026414777836, + 75153.101862290467, + 75175.178931030852, + 75197.257620760924, + 75219.33793124267, + 75241.419862238225, + 75263.503413509738, + 75285.588584819503, + 75307.675375929874, + 75329.763786603318, + 75351.853816602365, + 75373.945465689612, + 75396.038733627807, + 75418.133620179724, + 75440.230125108254, + 75462.32824817636, + 75484.427989147109, + 75506.529347783653, + 75528.63232384919, + 75550.736917107075, + 75572.843127320695, + 75594.950954253538, + 75617.060397669193, + 75639.171457331307, + 75661.284133003646, + 75683.398424450032, + 75705.514331434402, + 75727.631853720741, + 75749.750991073175, + 75771.871743255862, + 75793.994110033076, + 75816.118091169177, + 75838.243686428585, + 75860.370895575848, + 75882.499718375562, + 75904.630154592422, + 75926.762203991224, + 75948.895866336825, + 75971.031141394182, + 75993.168028928325, + 76015.306528704401, + 76037.4466404876, + 76059.588364043215, + 76081.731699136653, + 76103.876645533353, + 76126.023202998884, + 76148.171371298871, + 76170.321150199044, + 76192.472539465205, + 76214.625538863256, + 76236.780148159174, + 76258.936367119008, + 76281.094195508922, + 76303.253633095141, + 76325.414679643975, + 76347.577334921851, + 76369.741598695226, + 76391.907470730686, + 76414.074950794879, + 76436.244038654564, + 76458.414734076548, + 76480.587036827754, + 76502.760946675175, + 76524.936463385893, + 76547.11358672705, + 76569.292316465915, + 76591.472652369819, + 76613.654594206164, + 76635.838141742468, + 76658.023294746308, + 76680.210052985349, + 76702.398416227341, + 76724.588384240138, + 76746.779956791637, + 76768.973133649866, + 76791.167914582897, + 76813.364299358902, + 76835.562287746157, + 76857.761879512967, + 76879.963074427797, + 76902.165872259109, + 76924.37027277553, + 76946.576275745727, + 76968.783880938441, + 76990.993088122515, + 77013.203897066895, + 77035.416307540567, + 77057.630319312622, + 77079.845932152239, + 77102.063145828695, + 77124.281960111301, + 77146.50237476948, + 77168.724389572759, + 77190.948004290723, + 77213.173218693031, + 77235.400032549442, + 77257.628445629802, + 77279.858457704031, + 77302.090068542122, + 77324.323277914169, + 77346.558085590339, + 77368.794491340886, + 77391.032494936138, + 77413.272096146524, + 77435.51329474253, + 77457.756090494731, + 77480.000483173804, + 77502.246472550498, + 77524.494058395634, + 77546.743240480107, + 77568.994018574944, + 77591.246392451198, + 77613.500361880026, + 77635.755926632657, + 77658.013086480438, + 77680.271841194757, + 77702.532190547092, + 77724.794134309021, + 77747.057672252195, + 77769.322804148323, + 77791.589529769248, + 77813.857848886837, + 77836.127761273063, + 77858.399266699998, + 77880.67236493979, + 77902.947055764627, + 77925.223338946831, + 77947.50121425878, + 77969.780681472927, + 77992.061740361838, + 78014.344390698127, + 78036.628632254491, + 78058.914464803747, + 78081.201888118725, + 78103.490901972415, + 78125.781506137821, + 78148.073700388064, + 78170.367484496339, + 78192.662858235926, + 78214.959821380166, + 78237.258373702498, + 78259.558514976452, + 78281.860244975614, + 78304.163563473659, + 78326.468470244363, + 78348.77496506153, + 78371.083047699125, + 78393.392717931114, + 78415.703975531578, + 78438.016820274701, + 78460.331251934695, + 78482.647270285903, + 78504.964875102727, + 78527.284066159627, + 78549.604843231195, + 78571.927206092048, + 78594.251154516911, + 78616.576688280606, + 78638.903807157985, + 78661.232510924034, + 78683.562799353778, + 78705.894672222363, + 78728.228129304945, + 78750.563170376859, + 78772.899795213423, + 78795.238003590101, + 78817.577795282399, + 78839.919170065928, + 78862.262127716356, + 78884.606668009452, + 78906.952790721043, + 78929.300495627045, + 78951.64978250346, + 78974.000651126378, + 78996.353101271932, + 79018.707132716358, + 79041.062745235977, + 79063.41993860717, + 79085.778712606436, + 79108.139067010285, + 79130.501001595389, + 79152.864516138419, + 79175.22961041618, + 79197.596284205531, + 79219.96453728342, + 79242.33436942687, + 79264.705780412987, + 79287.078770018954, + 79309.453338022009, + 79331.829484199508, + 79354.207208328866, + 79376.586510187582, + 79398.967389553218, + 79421.349846203433, + 79443.733879915948, + 79466.119490468584, + 79488.50667763922, + 79510.895441205823, + 79533.285780946433, + 79555.677696639163, + 79578.071188062226, + 79600.466254993895, + 79622.862897212515, + 79645.261114496549, + 79667.660906624471, + 79690.062273374875, + 79712.465214526455, + 79734.869729857935, + 79757.275819148126, + 79779.683482175955, + 79802.092718720378, + 79824.503528560454, + 79846.915911475327, + 79869.329867244203, + 79891.745395646343, + 79914.162496461155, + 79936.581169468045, + 79959.001414446553, + 79981.423231176261, + 80003.846619436852, + 80026.271579008084, + 80048.698109669771, + 80071.12621120183, + 80093.555883384237, + 80115.987125997053, + 80138.419938820414, + 80160.854321634528, + 80183.290274219689, + 80205.727796356281, + 80228.166887824715, + 80250.607548405547, + 80273.049777879336, + 80295.493576026798, + 80317.938942628651, + 80340.385877465727, + 80362.834380318949, + 80385.28445096928, + 80407.736089197788, + 80430.189294785596, + 80452.644067513917, + 80475.100407164035, + 80497.558313517322, + 80520.017786355209, + 80542.478825459213, + 80564.941430610925, + 80587.405601592007, + 80609.871338184195, + 80632.338640169342, + 80654.8075073293, + 80677.277939446067, + 80699.749936301683, + 80722.223497678278, + 80744.698623358039, + 80767.17531312324, + 80789.653566756242, + 80812.133384039465, + 80834.614764755403, + 80857.097708686648, + 80879.582215615854, + 80902.068285325731, + 80924.555917599093, + 80947.045112218824, + 80969.535868967869, + 80992.028187629272, + 81014.522067986123, + 81037.017509821613, + 81059.514512919006, + 81082.013077061609, + 81104.513202032831, + 81127.014887616184, + 81149.518133595193, + 81172.022939753486, + 81194.529305874807, + 81217.037231742899, + 81239.546717141639, + 81262.057761854958, + 81284.570365666848, + 81307.084528361403, + 81329.600249722775, + 81352.117529535186, + 81374.636367582949, + 81397.156763650448, + 81419.678717522125, + 81442.202228982511, + 81464.727297816222, + 81487.253923807933, + 81509.782106742379, + 81532.311846404409, + 81554.843142578902, + 81577.375995050839, + 81599.910403605274, + 81622.446368027333, + 81644.983888102215, + 81667.522963615178, + 81690.063594351581, + 81712.605780096841, + 81735.149520636449, + 81757.694815755967, + 81780.241665241047, + 81802.79006887741, + 81825.340026450824, + 81847.891537747171, + 81870.444602552379, + 81892.999220652477, + 81915.555391833506, + 81938.113115881672, + 81960.672392583176, + 81983.233221724338, + 82005.795603091537, + 82028.359536471224, + 82050.925021649906, + 82073.492058414209, + 82096.060646550788, + 82118.630785846399, + 82141.202476087841, + 82163.775717062032, + 82186.35050855593, + 82208.926850356569, + 82231.504742251054, + 82254.084184026578, + 82276.665175470393, + 82299.24771636985, + 82321.831806512317, + 82344.417445685307, + 82367.004633676348, + 82389.593370273054, + 82412.183655263143, + 82434.775488434374, + 82457.368869574595, + 82479.963798471697, + 82502.560274913689, + 82525.158298688606, + 82547.757869584602, + 82570.35898738986, + 82592.961651892678, + 82615.565862881398, + 82638.171620144421, + 82660.778923470265, + 82683.387772647475, + 82705.998167464713, + 82728.610107710658, + 82751.223593174116, + 82773.83862364394, + 82796.45519890904, + 82819.073318758441, + 82841.692982981185, + 82864.314191366429, + 82886.936943703375, + 82909.561239781324, + 82932.187079389638, + 82954.814462317736, + 82977.443388355125, + 83000.073857291369, + 83022.70586891612, + 83045.339423019104, + 83067.974519390089, + 83090.611157818959, + 83113.249338095629, + 83135.8890600101, + 83158.530323352461, + 83181.173127912858, + 83203.817473481497, + 83226.463359848669, + 83249.11078680474, + 83271.759754140134, + 83294.410261645375, + 83317.062309111003, + 83339.715896327703, + 83362.371023086147, + 83385.027689177165, + 83407.685894391587, + 83430.345638520361, + 83453.006921354478, + 83475.669742685001, + 83498.334102303095, + 83520.999999999942, + 83543.667435566866, + 83566.336408795192, + 83589.006919476349, + 83611.678967401851, + 83634.352552363242, + 83657.027674152167, + 83679.704332560359, + 83702.382527379552, + 83725.062258401638, + 83747.743525418511, + 83770.42632822218, + 83793.110666604684, + 83815.796540358162, + 83838.483949274829, + 83861.172893146941, + 83883.863371766842, + 83906.555384926964, + 83929.248932419752, + 83951.944014037799, + 83974.640629573696, + 83997.338778820151, + 84020.038461569929, + 84042.739677615857, + 84065.442426750829, + 84088.146708767847, + 84110.852523459922, + 84133.559870620171, + 84156.268750041796, + 84178.979161518029, + 84201.691104842204, + 84224.404579807713, + 84247.119586208006, + 84269.83612383662, + 84292.55419248715, + 84315.273791953281, + 84337.994922028738, + 84360.717582507335, + 84383.441773182945, + 84406.167493849513, + 84428.894744301069, + 84451.623524331691, + 84474.353833735542, + 84497.085672306828, + 84519.819039839858, + 84542.553936128999, + 84565.290360968676, + 84588.028314153402, + 84610.767795477717, + 84633.508804736295, + 84656.251341723822, + 84678.995406235073, + 84701.740998064924, + 84724.488117008252, + 84747.236762860062, + 84769.986935415407, + 84792.73863446941, + 84815.491859817252, + 84838.246611254188, + 84861.002888575575, + 84883.760691576768, + 84906.520020053256, + 84929.28087380057, + 84952.043252614312, + 84974.807156290146, + 84997.572584623806, + 85020.339537411113, + 85043.108014447949, + 85065.878015530237, + 85088.649540453989, + 85111.422589015303, + 85134.197161010321, + 85156.973256235244, + 85179.750874486374, + 85202.530015560071, + 85225.310679252725, + 85248.092865360857, + 85270.876573681016, + 85293.661804009811, + 85316.448556143951, + 85339.236829880188, + 85362.026625015351, + 85384.817941346351, + 85407.610778670132, + 85430.405136783724, + 85453.201015484257, + 85475.998414568865, + 85498.797333834795, + 85521.597773079353, + 85544.399732099904, + 85567.203210693886, + 85590.008208658808, + 85612.814725792239, + 85635.62276189182, + 85658.432316755265, + 85681.243390180331, + 85704.055981964877, + 85726.870091906807, + 85749.685719804082, + 85772.502865454764, + 85795.321528656961, + 85818.141709208852, + 85840.963406908675, + 85863.78662155474, + 85886.611352945445, + 85909.437600879217, + 85932.26536515457, + 85955.094645570091, + 85977.92544192441, + 86000.757754016275, + 86023.591581644432, + 86046.426924607746, + 86069.263782705122, + 86092.102155735556, + 86114.942043498071, + 86137.783445791807, + 86160.626362415918, + 86183.470793169676, + 86206.316737852379, + 86229.164196263402, + 86252.013168202204, + 86274.863653468303, + 86297.715651861261, + 86320.569163180728, + 86343.424187226425, + 86366.280723798132, + 86389.138772695675, + 86411.998333718977, + 86434.859406668009, + 86457.721991342827, + 86480.586087543532, + 86503.451695070296, + 86526.318813723352, + 86549.187443303032, + 86572.057583609683, + 86594.929234443756, + 86617.802395605773, + 86640.677066896271, + 86663.553248115903, + 86686.43093906538, + 86709.310139545443, + 86732.190849356964, + 86755.073068300815, + 86777.956796177954, + 86800.842032789442, + 86823.728777936354, + 86846.617031419853, + 86869.506793041175, + 86892.398062601613, + 86915.290839902518, + 86938.185124745316, + 86961.080916931489, + 86983.978216262592, + 87006.87702254027, + 87029.777335566177, + 87052.67915514209, + 87075.582481069796, + 87098.487313151185, + 87121.39365118822, + 87144.301494982894, + 87167.210844337285, + 87190.121699053532, + 87213.034058933845, + 87235.947923780506, + 87258.863293395829, + 87281.780167582241, + 87304.698546142172, + 87327.618428878181, + 87350.539815592856, + 87373.462706088845, + 87396.387100168897, + 87419.312997635774, + 87442.240398292357, + 87465.16930194154, + 87488.099708386319, + 87511.031617429733, + 87533.965028874911, + 87556.899942525008, + 87579.836358183282, + 87602.774275653021, + 87625.713694737613, + 87648.654615240492, + 87671.597036965148, + 87694.540959715145, + 87717.486383294105, + 87740.433307505737, + 87763.381732153779, + 87786.331657042057, + 87809.283081974456, + 87832.236006754916, + 87855.190431187453, + 87878.146355076155, + 87901.103778225151, + 87924.062700438633, + 87947.023121520891, + 87969.985041276246, + 87992.948459509105, + 88015.913376023906, + 88038.879790625171, + 88061.847703117513, + 88084.817113305573, + 88107.788020994049, + 88130.760425987726, + 88153.734328091465, + 88176.709727110137, + 88199.686622848749, + 88222.665015112303, + 88245.644903705906, + 88268.626288434709, + 88291.609169103947, + 88314.593545518903, + 88337.579417484914, + 88360.566784807408, + 88383.555647291854, + 88406.546004743795, + 88429.537856968818, + 88452.531203772611, + 88475.52604496089, + 88498.522380339447, + 88521.52020971413, + 88544.519532890874, + 88567.520349675644, + 88590.522659874507, + 88613.526463293543, + 88636.531759738922, + 88659.538549016899, + 88682.546830933745, + 88705.556605295846, + 88728.567871909589, + 88751.580630581491, + 88774.594881118086, + 88797.610623325963, + 88820.62785701183, + 88843.646581982393, + 88866.666798044462, + 88889.688505004888, + 88912.711702670611, + 88935.7363908486, + 88958.762569345898, + 88981.790237969632, + 89004.81939652696, + 89027.850044825114, + 89050.882182671412, + 89073.9158098732, + 89096.950926237885, + 89119.987531572973, + 89143.025625686001, + 89166.065208384563, + 89189.106279476357, + 89212.148838769106, + 89235.192886070581, + 89258.238421188667, + 89281.285443931265, + 89304.333954106376, + 89327.383951522017, + 89350.435435986306, + 89373.488407307406, + 89396.542865293537, + 89419.598809753006, + 89442.656240494165, + 89465.715157325409, + 89488.775560055219, + 89511.837448492137, + 89534.900822444746, + 89557.965681721733, + 89581.032026131812, + 89604.099855483742, + 89627.169169586399, + 89650.239968248672, + 89673.312251279538, + 89696.386018488018, + 89719.461269683205, + 89742.53800467425, + 89765.616223270365, + 89788.69592528083, + 89811.777110514988, + 89834.859778782207, + 89857.943929891975, + 89881.029563653807, + 89904.116679877261, + 89927.205278372014, + 89950.29535894774, + 89973.386921414218, + 89996.479965581268, + 90019.574491258769, + 90042.670498256688, + 90065.767986385021, + 90088.866955453836, + 90111.967405273259, + 90135.069335653476, + 90158.172746404758, + 90181.277637337407, + 90204.384008261797, + 90227.49185898836, + 90250.601189327586, + 90273.711999090039, + 90296.824288086325, + 90319.938056127125, + 90343.053303023189, + 90366.170028585286, + 90389.288232624298, + 90412.407914951138, + 90435.529075376777, + 90458.651713712257, + 90481.775829768681, + 90504.901423357209, + 90528.028494289058, + 90551.157042375504, + 90574.287067427911, + 90597.418569257643, + 90620.551547676194, + 90643.686002495073, + 90666.821933525847, + 90689.959340580186, + 90713.098223469773, + 90736.238582006365, + 90759.380416001804, + 90782.523725267951, + 90805.668509616764, + 90828.814768860233, + 90851.962502810435, + 90875.11171127946, + 90898.262394079517, + 90921.414551022855, + 90944.568181921743, + 90967.72328658856, + 90990.879864835719, + 91014.037916475718, + 91037.19744132107, + 91060.358439184391, + 91083.520909878338, + 91106.684853215629, + 91129.850269009039, + 91153.017157071401, + 91176.185517215621, + 91199.355349254649, + 91222.526653001492, + 91245.699428269247, + 91268.873674871036, + 91292.049392620058, + 91315.226581329553, + 91338.405240812834, + 91361.585370883287, + 91384.766971354344, + 91407.950042039476, + 91431.134582752245, + 91454.320593306256, + 91477.508073515171, + 91500.697023192712, + 91523.887442152685, + 91547.07933020893, + 91570.272687175326, + 91593.467512865856, + 91616.663807094534, + 91639.861569675442, + 91663.060800422725, + 91686.261499150554, + 91709.463665673218, + 91732.66729980502, + 91755.872401360321, + 91779.078970153569, + 91802.287005999257, + 91825.49650871192, + 91848.707478106167, + 91871.91991399668, + 91895.133816198169, + 91918.349184525418, + 91941.566018793281, + 91964.784318816659, + 91988.004084410495, + 92011.22531538982, + 92034.448011569708, + 92057.672172765277, + 92080.897798791746, + 92104.124889464365, + 92127.353444598411, + 92150.58346400928, + 92173.814947512379, + 92197.04789492322, + 92220.282306057314, + 92243.518180730272, + 92266.755518757753, + 92289.994319955469, + 92313.234584139194, + 92336.476311124774, + 92359.719500728082, + 92382.964152765067, + 92406.210267051734, + 92429.457843404161, + 92452.706881638471, + 92475.957381570814, + 92499.209343017443, + 92522.462765794655, + 92545.717649718805, + 92568.973994606305, + 92592.231800273614, + 92615.491066537259, + 92638.751793213814, + 92662.01398011994, + 92685.277627072326, + 92708.54273388772, + 92731.809300382942, + 92755.077326374871, + 92778.346811680414, + 92801.617756116568, + 92824.890159500384, + 92848.164021648947, + 92871.439342379424, + 92894.716121509016, + 92917.994358855023, + 92941.274054234746, + 92964.555207465572, + 92987.837818364962, + 93011.121886750407, + 93034.407412439468, + 93057.694395249753, + 93080.982834998955, + 93104.272731504767, + 93127.564084584999, + 93150.856894057491, + 93174.15115974014, + 93197.446881450916, + 93220.744059007804, + 93244.04269222889, + 93267.342780932304, + 93290.644324936235, + 93313.947324058914, + 93337.251778118633, + 93360.557686933767, + 93383.865050322696, + 93407.173868103928, + 93430.484140095941, + 93453.795866117362, + 93477.109045986799, + 93500.423679522952, + 93523.739766544561, + 93547.057306870454, + 93570.376300319491, + 93593.696746710571, + 93617.018645862699, + 93640.341997594893, + 93663.666801726242, + 93686.993058075881, + 93710.320766463032, + 93733.64992670693, + 93756.980538626914, + 93780.312602042337, + 93803.646116772637, + 93826.981082637285, + 93850.317499455836, + 93873.655367047861, + 93896.994685233032, + 93920.335453831038, + 93943.677672661666, + 93967.021341544707, + 93990.366460300051, + 94013.713028747632, + 94037.061046707429, + 94060.410513999494, + 94083.761430443905, + 94107.113795860845, + 94130.467610070496, + 94153.822872893157, + 94177.179584149111, + 94200.537743658759, + 94223.897351242529, + 94247.25840672091, + 94270.620909914433, + 94293.98486064373, + 94317.350258729421, + 94340.71710399224, + 94364.085396252936, + 94387.455135332348, + 94410.82632105134, + 94434.198953230851, + 94457.573031691878, + 94480.948556255447, + 94504.325526742658, + 94527.70394297468, + 94551.083804772716, + 94574.465111958023, + 94597.847864351934, + 94621.232061775823, + 94644.617704051096, + 94668.004790999272, + 94691.393322441872, + 94714.783298200506, + 94738.174718096794, + 94761.567581952477, + 94784.961889589307, + 94808.357640829097, + 94831.754835493703, + 94855.153473405066, + 94878.553554385173, + 94901.955078256055, + 94925.358044839784, + 94948.762453958523, + 94972.168305434476, + 94995.575599089891, + 95018.984334747074, + 95042.394512228391, + 95065.806131356265, + 95089.219191953176, + 95112.633693841635, + 95136.04963684424, + 95159.467020783617, + 95182.885845482466, + 95206.306110763529, + 95229.727816449609, + 95253.150962363579, + 95276.575548328314, + 95300.001574166803, + 95323.429039702052, + 95346.857944757154, + 95370.288289155214, + 95393.720072719429, + 95417.153295273019, + 95440.587956639298, + 95464.024056641589, + 95487.461595103305, + 95510.900571847902, + 95534.340986698866, + 95557.782839479783, + 95581.226130014256, + 95604.670858125959, + 95628.117023638595, + 95651.564626375985, + 95675.013666161918, + 95698.464142820303, + 95721.916056175076, + 95745.369406050231, + 95768.824192269807, + 95792.280414657915, + 95815.738073038709, + 95839.197167236387, + 95862.657697075221, + 95886.11966237954, + 95909.583062973688, + 95933.047898682111, + 95956.514169329268, + 95979.981874739708, + 96003.451014738006, + 96026.921589148798, + 96050.393597796792, + 96073.867040506724, + 96097.341917103375, + 96120.818227411626, + 96144.295971256375, + 96167.775148462577, + 96191.255758855244, + 96214.737802259449, + 96238.221278500292, + 96261.70618740299, + 96285.192528792715, + 96308.680302494788, + 96332.169508334526, + 96355.660146137321, + 96379.152215728609, + 96402.645716933868, + 96426.14064957868, + 96449.637013488609, + 96473.134808489311, + 96496.63403440651, + 96520.134691065963, + 96543.636778293469, + 96567.140295914898, + 96590.645243756153, + 96614.151621643221, + 96637.659429402134, + 96661.168666858954, + 96684.679333839798, + 96708.191430170875, + 96731.70495567839, + 96755.219910188665, + 96778.736293528011, + 96802.254105522836, + 96825.77334599958, + 96849.29401478474, + 96872.816111704873, + 96896.339636586577, + 96919.864589256511, + 96943.390969541389, + 96966.918777267958, + 96990.448012263048, + 97013.978674353522, + 97037.510763366285, + 97061.044279128328, + 97084.579221466673, + 97108.115590208385, + 97131.653385180587, + 97155.19260621049, + 97178.733253125291, + 97202.2753257523, + 97225.81882391886, + 97249.363747452342, + 97272.910096180189, + 97296.457869929916, + 97320.007068529041, + 97343.557691805196, + 97367.109739586012, + 97390.663211699197, + 97414.218107972498, + 97437.774428233737, + 97461.332172310766, + 97484.891340031507, + 97508.451931223899, + 97532.013945715982, + 97555.577383335811, + 97579.142243911512, + 97602.708527271257, + 97626.276233243261, + 97649.845361655811, + 97673.415912337223, + 97696.987885115886, + 97720.561279820206, + 97744.1360962787, + 97767.712334319876, + 97791.289993772341, + 97814.869074464703, + 97838.449576225685, + 97862.031498883996, + 97885.614842268449, + 97909.199606207883, + 97932.785790531183, + 97956.37339506732, + 97979.962419645264, + 98003.552864094076, + 98027.144728242856, + 98050.738011920766, + 98074.332714956996, + 98097.928837180807, + 98121.526378421506, + 98145.125338508456, + 98168.725717271067, + 98192.327514538789, + 98215.930730141132, + 98239.535363907664, + 98263.141415668011, + 98286.748885251814, + 98310.357772488816, + 98333.968077208759, + 98357.579799241488, + 98381.192938416847, + 98404.807494564782, + 98428.42346751524, + 98452.040857098269, + 98475.659663143917, + 98499.27988548232, + 98522.901523943656, + 98546.524578358163, + 98570.149048556093, + 98593.774934367786, + 98617.402235623624, + 98641.030952154048, + 98664.661083789513, + 98688.292630360564, + 98711.925591697771, + 98735.559967631794, + 98759.195757993293, + 98782.832962613014, + 98806.471581321734, + 98830.111613950285, + 98853.753060329575, + 98877.39592029051, + 98901.040193664099, + 98924.68588028138, + 98948.33297997342, + 98971.981492571387, + 98995.63141790645, + 99019.282755809851, + 99042.935506112874, + 99066.589668646877, + 99090.245243243233, + 99113.902229733401, + 99137.560627948857, + 99161.220437721131, + 99184.881658881859, + 99208.544291262631, + 99232.208334695169, + 99255.87378901121, + 99279.540654042547, + 99303.208929621018, + 99326.878615578535, + 99350.549711746993, + 99374.222217958435, + 99397.896134044888, + 99421.571459838422, + 99445.248195171211, + 99468.926339875441, + 99492.605893783344, + 99516.286856727209, + 99539.969228539398, + 99563.653009052287, + 99587.338198098325, + 99611.024795510006, + 99634.712801119866, + 99658.402214760499, + 99682.093036264545, + 99705.785265464699, + 99729.478902193689, + 99753.173946284325, + 99776.870397569437, + 99800.56825588191, + 99824.267521054688, + 99847.968192920773, + 99871.670271313182, + 99895.373756065004, + 99919.078647009388, + 99942.78494397951, + 99966.492646808634, + 99990.20175533001, + 100013.91226937699, + 100037.62418878295, + 100061.33751338134, + 100085.05224300563, + 100108.76837748935, + 100132.4859166661, + 100156.2048603695, + 100179.92520843323, + 100203.64696069101, + 100227.37011697664, + 100251.09467712394, + 100274.82064096678, + 100298.54800833909, + 100322.27677907483, + 100346.00695300807, + 100369.73852997283, + 100393.47150980328, + 100417.20589233354, + 100440.94167739789, + 100464.67886483055, + 100488.41745446586, + 100512.1574461382, + 100535.89883968196, + 100559.64163493161, + 100583.38583172169, + 100607.13142988674, + 100630.87842926137, + 100654.62682968024, + 100678.37663097809, + 100702.12783298964, + 100725.88043554971, + 100749.63443849317, + 100773.38984165489, + 100797.14664486986, + 100820.90484797307, + 100844.66445079957, + 100868.42545318443, + 100892.18785496285, + 100915.95165596998, + 100939.71685604109, + 100963.48345501146, + 100987.25145271645, + 101011.02084899142, + 101034.79164367182, + 101058.56383659317, + 101082.33742759094, + 101106.11241650078, + 101129.88880315828, + 101153.66658739912, + 101177.44576905905, + 101201.22634797383, + 101225.00832397929, + 101248.7916969113, + 101272.57646660579, + 101296.36263289873, + 101320.15019562612, + 101343.93915462404, + 101367.7295097286, + 101391.52126077596, + 101415.31440760233, + 101439.10895004397, + 101462.9048879372, + 101486.70222111834, + 101510.50094942382, + 101534.30107269008, + 101558.10259075361, + 101581.90550345098, + 101605.70981061876, + 101629.5155120936, + 101653.32260771218, + 101677.13109731126, + 101700.9409807276, + 101724.75225779804, + 101748.56492835947, + 101772.37899224881, + 101796.19444930303, + 101820.01129935916, + 101843.82954225427, + 101867.64917782549, + 101891.47020590997, + 101915.29262634492, + 101939.11643896763, + 101962.94164361537, + 101986.76824012553, + 102010.59622833549, + 102034.42560808272, + 102058.25637920471, + 102082.08854153901, + 102105.9220949232, + 102129.75703919494, + 102153.59337419191, + 102177.43109975185, + 102201.27021571253, + 102225.1107219118, + 102248.95261818753, + 102272.79590437764, + 102296.64058032009, + 102320.48664585294, + 102344.33410081422, + 102368.18294504205, + 102392.03317837461, + 102415.88480065008, + 102439.73781170673, + 102463.59221138287, + 102487.44799951684, + 102511.30517594704, + 102535.1637405119, + 102559.02369304992, + 102582.88503339965, + 102606.74776139967, + 102630.61187688859, + 102654.4773797051, + 102678.34426968795, + 102702.21254667587, + 102726.08221050771, + 102749.95326102231, + 102773.8256980586, + 102797.69952145554, + 102821.57473105213, + 102845.45132668741, + 102869.32930820051, + 102893.20867543056, + 102917.08942821674, + 102940.97156639832, + 102964.85508981455, + 102988.73999830478, + 103012.6262917084, + 103036.51396986481, + 103060.40303261351, + 103084.293479794, + 103108.18531124585, + 103132.07852680866, + 103155.97312632212, + 103179.8691096259, + 103203.76647655977, + 103227.66522696352, + 103251.56536067701, + 103275.46687754011, + 103299.36977739276, + 103323.27406007495, + 103347.1797254267, + 103371.0867732881, + 103394.99520349925, + 103418.90501590034, + 103442.81621033157, + 103466.72878663319, + 103490.64274464553, + 103514.55808420894, + 103538.4748051638, + 103562.39290735057, + 103586.31239060973, + 103610.23325478184, + 103634.15549970744, + 103658.07912522719, + 103682.00413118176, + 103705.93051741188, + 103729.85828375829, + 103753.78743006183, + 103777.71795616332, + 103801.64986190372, + 103825.58314712394, + 103849.51781166498, + 103873.4538553679, + 103897.39127807376, + 103921.33007962372, + 103945.27025985894, + 103969.21181862066, + 103993.15475575015, + 104017.0990710887, + 104041.0447644777, + 104064.99183575854, + 104088.94028477269, + 104112.89011136163, + 104136.84131536692, + 104160.79389663014, + 104184.74785499295, + 104208.70319029699, + 104232.65990238401, + 104256.61799109577, + 104280.57745627411, + 104304.53829776087, + 104328.50051539797, + 104352.46410902737, + 104376.42907849104, + 104400.39542363105, + 104424.36314428948, + 104448.33224030846, + 104472.3027115302, + 104496.27455779689, + 104520.24777895081, + 104544.22237483428, + 104568.19834528965, + 104592.17569015936, + 104616.15440928582, + 104640.13450251156, + 104664.1159696791, + 104688.09881063103, + 104712.08302520998, + 104736.06861325864, + 104760.05557461972, + 104784.043909136, + 104808.03361665027, + 104832.0246970054, + 104856.01715004431, + 104880.01097560991, + 104904.00617354522, + 104928.00274369326, + 104952.00068589712, + 104975.99999999993, + 105000.00068584486, + 105024.00274327511, + 105048.00617213396, + 105072.0109722647, + 105096.0171435107, + 105120.02468571534, + 105144.03359872208, + 105168.04388237436, + 105192.05553651576, + 105216.06856098982, + 105240.08295564017, + 105264.09872031047, + 105288.11585484444, + 105312.13435908582, + 105336.1542328784, + 105360.17547606604, + 105384.19808849262, + 105408.22207000206, + 105432.24742043833, + 105456.27413964548, + 105480.30222746753, + 105504.33168374863, + 105528.36250833291, + 105552.39470106458, + 105576.42826178786, + 105600.46319034706, + 105624.49948658649, + 105648.53715035053, + 105672.5761814836, + 105696.61657983017, + 105720.65834523473, + 105744.70147754184, + 105768.7459765961, + 105792.79184224214, + 105816.83907432464, + 105840.88767268835, + 105864.93763717801, + 105888.98896763846, + 105913.04166391456, + 105937.09572585119, + 105961.15115329332, + 105985.20794608595, + 106009.26610407409, + 106033.32562710284, + 106057.38651501729, + 106081.44876766266, + 106105.51238488412, + 106129.57736652695, + 106153.64371243643, + 106177.71142245791, + 106201.78049643678, + 106225.85093421848, + 106249.92273564848, + 106273.99590057228, + 106298.07042883546, + 106322.14632028362, + 106346.22357476239, + 106370.30219211751, + 106394.38217219469, + 106418.46351483969, + 106442.54621989837, + 106466.63028721658, + 106490.71571664025, + 106514.80250801529, + 106538.89066118775, + 106562.98017600364, + 106587.07105230905, + 106611.16328995011, + 106635.25688877302, + 106659.35184862395, + 106683.44816934918, + 106707.54585079502, + 106731.64489280782, + 106755.74529523395, + 106779.84705791986, + 106803.95018071201, + 106828.05466345693, + 106852.16050600118, + 106876.26770819137, + 106900.37626987413, + 106924.48619089619, + 106948.59747110425, + 106972.71011034511, + 106996.82410846559, + 107020.93946531253, + 107045.05618073288, + 107069.17425457356, + 107093.29368668159, + 107117.41447690397, + 107141.53662508781, + 107165.66013108024, + 107189.7849947284, + 107213.91121587952, + 107238.03879438085, + 107262.16773007967, + 107286.29802282334, + 107310.42967245923, + 107334.56267883476, + 107358.69704179741, + 107382.83276119467, + 107406.96983687414, + 107431.10826868335, + 107455.24805646999, + 107479.38920008171, + 107503.53169936626, + 107527.67555417139, + 107551.82076434491, + 107575.96732973469, + 107600.11525018861, + 107624.26452555459, + 107648.41515568066, + 107672.56714041479, + 107696.72047960508, + 107720.87517309963, + 107745.03122074658, + 107769.18862239413, + 107793.34737789053, + 107817.50748708403, + 107841.66894982298, + 107865.83176595572, + 107889.99593533068, + 107914.16145779629, + 107938.32833320105, + 107962.49656139348, + 107986.66614222217, + 108010.83707553572, + 108035.00936118282, + 108059.18299901215, + 108083.35798887245, + 108107.53433061253, + 108131.71202408121, + 108155.89106912735, + 108180.07146559987, + 108204.25321334775, + 108228.43631221994, + 108252.62076206553, + 108276.80656273357, + 108300.99371407321, + 108325.18221593359, + 108349.37206816394, + 108373.56327061349, + 108397.75582313156, + 108421.94972556747, + 108446.1449777706, + 108470.34157959036, + 108494.53953087622, + 108518.73883147769, + 108542.93948124432, + 108567.14148002568, + 108591.34482767139, + 108615.54952403114, + 108639.75556895464, + 108663.96296229165, + 108688.17170389196, + 108712.38179360541, + 108736.59323128188, + 108760.80601677128, + 108785.02014992358, + 108809.23563058881, + 108833.45245861699, + 108857.67063385822, + 108881.89015616261, + 108906.11102538036, + 108930.33324136167, + 108954.55680395682, + 108978.78171301607, + 109003.00796838976, + 109027.23556992831, + 109051.46451748211, + 109075.69481090162, + 109099.92645003737, + 109124.15943473989, + 109148.39376485976, + 109172.62944024763, + 109196.86646075416, + 109221.10482623006, + 109245.34453652608, + 109269.58559149304, + 109293.82799098175, + 109318.07173484311, + 109342.31682292801, + 109366.56325508743, + 109390.81103117237, + 109415.06015103387, + 109439.31061452301, + 109463.56242149093, + 109487.8155717888, + 109512.07006526781, + 109536.3259017792, + 109560.58308117429, + 109584.8416033044, + 109609.1014680209, + 109633.36267517522, + 109657.62522461878, + 109681.88911620311, + 109706.15434977971, + 109730.4209252002, + 109754.68884231619, + 109778.95810097932, + 109803.22870104131, + 109827.50064235389, + 109851.77392476884, + 109876.04854813802, + 109900.32451231324, + 109924.60181714644, + 109948.88046248957, + 109973.1604481946, + 109997.44177411357, + 110021.72444009855, + 110046.00844600165, + 110070.29379167501, + 110094.58047697082, + 110118.86850174134, + 110143.15786583882, + 110167.44856911557, + 110191.74061142397, + 110216.03399261639, + 110240.32871254528, + 110264.62477106311, + 110288.9221680224, + 110313.22090327571, + 110337.52097667565, + 110361.82238807483, + 110386.12513732594, + 110410.42922428172, + 110434.73464879491, + 110459.04141071832, + 110483.34950990479, + 110507.6589462072, + 110531.96971947847, + 110556.28182957157, + 110580.5952763395, + 110604.91005963532, + 110629.22617931209, + 110653.54363522294, + 110677.86242722106, + 110702.18255515963, + 110726.50401889188, + 110750.82681827113, + 110775.1509531507, + 110799.47642338395, + 110823.80322882428, + 110848.13136932514, + 110872.46084474004, + 110896.79165492248, + 110921.12379972603, + 110945.4572790043, + 110969.79209261097, + 110994.12824039967, + 111018.46572222417, + 111042.80453793822, + 111067.14468739564, + 111091.48617045028, + 111115.82898695602, + 111140.1731367668, + 111164.51861973655, + 111188.86543571933, + 111213.21358456917, + 111237.56306614014, + 111261.91388028639, + 111286.26602686207, + 111310.61950572141, + 111334.97431671864, + 111359.33045970804, + 111383.68793454397, + 111408.04674108078, + 111432.40687917286, + 111456.76834867468, + 111481.13114944073, + 111505.49528132551, + 111529.86074418361, + 111554.22753786964, + 111578.59566223821, + 111602.96511714405, + 111627.33590244185, + 111651.7080179864, + 111676.08146363248, + 111700.45623923496, + 111724.8323446487, + 111749.20977972864, + 111773.58854432974, + 111797.96863830699, + 111822.35006151545, + 111846.73281381019, + 111871.11689504632, + 111895.50230507903, + 111919.8890437635, + 111944.27711095495, + 111968.6665065087, + 111993.05723028004, + 112017.44928212435, + 112041.842661897, + 112066.23736945343, + 112090.63340464912, + 112115.03076733962, + 112139.42945738042, + 112163.82947462716, + 112188.23081893545, + 112212.63349016097, + 112237.03748815943, + 112261.44281278658, + 112285.84946389822, + 112310.25744135017, + 112334.66674499828, + 112359.07737469849, + 112383.48933030672, + 112407.90261167898, + 112432.31721867126, + 112456.73315113965, + 112481.15040894024, + 112505.56899192919, + 112529.98889996267, + 112554.41013289688, + 112578.8326905881, + 112603.25657289263, + 112627.68177966679, + 112652.10831076698, + 112676.53616604958, + 112700.96534537108, + 112725.39584858794, + 112749.82767555672, + 112774.26082613398, + 112798.6953001763, + 112823.13109754038, + 112847.56821808286, + 112872.00666166049, + 112896.44642813003, + 112920.88751734827, + 112945.32992917208, + 112969.77366345831, + 112994.21872006389, + 113018.66509884578, + 113043.11279966099, + 113067.56182236652, + 113092.01216681948, + 113116.46383287695, + 113140.9168203961, + 113165.37112923413, + 113189.82675924824, + 113214.28371029573, + 113238.74198223387, + 113263.20157492002, + 113287.66248821157, + 113312.12472196593, + 113336.58827604055, + 113361.05315029295, + 113385.51934458067, + 113409.98685876124, + 113434.45569269233, + 113458.92584623155, + 113483.39731923661, + 113507.87011156522, + 113532.34422307517, + 113556.81965362425, + 113581.2964030703, + 113605.77447127122, + 113630.25385808491, + 113654.73456336933, + 113679.2165869825, + 113703.69992878241, + 113728.18458862718, + 113752.67056637487, + 113777.15786188368, + 113801.64647501177, + 113826.13640561736, + 113850.62765355874, + 113875.12021869418, + 113899.61410088204, + 113924.1092999807, + 113948.60581584855, + 113973.10364834407, + 113997.60279732574, + 114022.1032626521, + 114046.60504418171, + 114071.10814177318, + 114095.61255528514, + 114120.11828457628, + 114144.62532950533, + 114169.13368993104, + 114193.6433657122, + 114218.15435670764, + 114242.66666277625, + 114267.18028377694, + 114291.69521956862, + 114316.21147001031, + 114340.72903496103, + 114365.24791427983, + 114389.7681078258, + 114414.2896154581, + 114438.81243703589, + 114463.33657241837, + 114487.8620214648, + 114512.38878403447, + 114536.91685998671, + 114561.44624918087, + 114585.97695147636, + 114610.5089667326, + 114635.04229480909, + 114659.57693556532, + 114684.11288886084, + 114708.65015455526, + 114733.18873250818, + 114757.72862257928, + 114782.26982462825, + 114806.81233851484, + 114831.35616409882, + 114855.90130123998, + 114880.44774979822, + 114904.99550963337, + 114929.5445806054, + 114954.09496257425, + 114978.64665539992, + 115003.19965894247, + 115027.75397306195, + 115052.30959761847, + 115076.86653247218, + 115101.42477748329, + 115125.984332512, + 115150.54519741859, + 115175.10737206334, + 115199.67085630659, + 115224.23565000873, + 115248.80175303014, + 115273.3691652313, + 115297.93788647266, + 115322.50791661476, + 115347.07925551817, + 115371.65190304347, + 115396.22585905129, + 115420.80112340231, + 115445.37769595724, + 115469.95557657682, + 115494.53476512182, + 115519.11526145306, + 115543.69706543141, + 115568.28017691776, + 115592.86459577303, + 115617.4503218582, + 115642.03735503425, + 115666.62569516223, + 115691.21534210323, + 115715.80629571836, + 115740.39855586876, + 115764.99212241563, + 115789.58699522018, + 115814.18317414368, + 115838.78065904744, + 115863.37944979276, + 115887.97954624105, + 115912.5809482537, + 115937.18365569216, + 115961.78766841792, + 115986.39298629249, + 116010.99960917742, + 116035.60753693432, + 116060.21676942479, + 116084.82730651053, + 116109.43914805322, + 116134.0522939146, + 116158.66674395646, + 116183.2824980406, + 116207.89955602887, + 116232.51791778316, + 116257.13758316539, + 116281.75855203751, + 116306.38082426153, + 116331.00439969949, + 116355.62927821343, + 116380.25545966547, + 116404.88294391775, + 116429.51173083246, + 116454.14182027178, + 116478.77321209799, + 116503.40590617337, + 116528.03990236025, + 116552.67520052097, + 116577.31180051794, + 116601.94970221359, + 116626.5889054704, + 116651.22941015086, + 116675.87121611751, + 116700.51432323294, + 116725.15873135976, + 116749.8044403606, + 116774.45145009817, + 116799.0997604352, + 116823.74937123443, + 116848.40028235866, + 116873.05249367072, + 116897.70600503348, + 116922.36081630984, + 116947.01692736275, + 116971.67433805518, + 116996.33304825013, + 117020.99305781067, + 117045.65436659988, + 117070.31697448085, + 117094.98088131678, + 117119.64608697082, + 117144.31259130624, + 117168.98039418629, + 117193.64949547425, + 117218.31989503348, + 117242.99159272734, + 117267.66458841923, + 117292.33888197262, + 117317.01447325097, + 117341.6913621178, + 117366.36954843666, + 117391.04903207115, + 117415.72981288488, + 117440.41189074152, + 117465.09526550474, + 117489.77993703831, + 117514.46590520597, + 117539.15316987153, + 117563.84173089883, + 117588.53158815173, + 117613.22274149416, + 117637.91519079007, + 117662.60893590341, + 117687.30397669821, + 117712.00031303853, + 117736.69794478847, + 117761.39687181212, + 117786.09709397367, + 117810.7986111373, + 117835.50142316725, + 117860.20552992777, + 117884.91093128319, + 117909.6176270978, + 117934.32561723603, + 117959.03490156225, + 117983.74547994092, + 118008.45735223651, + 118033.17051831353, + 118057.88497803656, + 118082.60073127014, + 118107.31777787894, + 118132.03611772758, + 118156.75575068076, + 118181.47667660323, + 118206.19889535972, + 118230.92240681504, + 118255.64721083404, + 118280.37330728157, + 118305.10069602253, + 118329.82937692189, + 118354.55934984458, + 118379.29061465565, + 118404.02317122012, + 118428.75701940308, + 118453.49215906965, + 118478.22859008498, + 118502.96631231424, + 118527.70532562268, + 118552.44562987552, + 118577.18722493808, + 118601.93011067568, + 118626.67428695368, + 118651.41975363747, + 118676.16651059251, + 118700.91455768423, + 118725.66389477813, + 118750.41452173979, + 118775.16643843475, + 118799.91964472862, + 118824.67414048707, + 118849.42992557574, + 118874.18699986035, + 118898.94536320666, + 118923.70501548045, + 118948.46595654752, + 118973.22818627374, + 118997.99170452499, + 119022.7565111672, + 119047.52260606633, + 119072.28998908834, + 119097.0586600993, + 119121.82861896523, + 119146.59986555226, + 119171.3723997265, + 119196.14622135412, + 119220.92133030134, + 119245.69772643436, + 119270.47540961947, + 119295.25437972297, + 119320.03463661121, + 119344.81618015055, + 119369.5990102074, + 119394.38312664822, + 119419.16852933947, + 119443.95521814766, + 119468.74319293935, + 119493.53245358112, + 119518.32299993958, + 119543.11483188139, + 119567.90794927324, + 119592.70235198183, + 119617.49803987393, + 119642.29501281632, + 119667.09327067583, + 119691.89281331931, + 119716.69364061367, + 119741.49575242582, + 119766.29914862274, + 119791.10382907141, + 119815.90979363887, + 119840.71704219218, + 119865.52557459843, + 119890.33539072477, + 119915.14649043836, + 119939.95887360642, + 119964.77254009615, + 119989.58748977486, + 120014.40372250983, + 120039.22123816841, + 120064.04003661797, + 120088.86011772591, + 120113.6814813597, + 120138.5041273868, + 120163.3280556747, + 120188.15326609099, + 120212.97975850321, + 120237.807532779, + 120262.63658878599, + 120287.46692639188, + 120312.29854546436, + 120337.13144587121, + 120361.9656274802, + 120386.80109015915, + 120411.63783377589, + 120436.47585819835, + 120461.31516329442, + 120486.15574893207, + 120510.99761497928, + 120535.84076130406, + 120560.68518777451, + 120585.53089425867, + 120610.3778806247, + 120635.22614674074, + 120660.07569247499, + 120684.92651769568, + 120709.77862227106, + 120734.63200606944, + 120759.48666895913, + 120784.3426108085, + 120809.19983148595, + 120834.05833085992, + 120858.91810879884, + 120883.77916517125, + 120908.64149984565, + 120933.5051126906, + 120958.37000357473, + 120983.23617236665, + 121008.10361893504, + 121032.97234314861, + 121057.84234487606, + 121082.71362398617, + 121107.58618034775, + 121132.46001382964, + 121157.33512430069, + 121182.21151162982, + 121207.08917568595, + 121231.96811633807, + 121256.84833345517, + 121281.72982690629, + 121306.61259656049, + 121331.49664228689, + 121356.38196395461, + 121381.26856143285, + 121406.15643459078, + 121431.04558329767, + 121455.93600742276, + 121480.82770683538, + 121505.72068140487, + 121530.61493100057, + 121555.51045549192, + 121580.40725474835, + 121605.30532863933, + 121630.20467703436, + 121655.10529980299, + 121680.00719681478, + 121704.91036793934, + 121729.81481304632, + 121754.72053200539, + 121779.62752468624, + 121804.53579095862, + 121829.44533069231, + 121854.3561437571, + 121879.26823002285, + 121904.1815893594, + 121929.09622163669, + 121954.01212672464, + 121978.92930449323, + 122003.84775481246, + 122028.76747755238, + 122053.68847258303, + 122078.61073977455, + 122103.53427899707, + 122128.45909012076, + 122153.38517301581, + 122178.31252755247, + 122203.24115360099, + 122228.17105103172, + 122253.10221971494, + 122278.03465952107, + 122302.96837032049, + 122327.90335198362, + 122352.83960438096, + 122377.777127383, + 122402.71592086025, + 122427.65598468333, + 122452.59731872278, + 122477.53992284928, + 122502.48379693348, + 122527.42894084606, + 122552.37535445779, + 122577.32303763942, + 122602.27199026172, + 122627.22221219557, + 122652.17370331181, + 122677.12646348133, + 122702.08049257506, + 122727.03579046397, + 122751.99235701906, + 122776.95019211136, + 122801.9092956119, + 122826.8696673918, + 122851.83130732219, + 122876.79421527422, + 122901.75839111909, + 122926.72383472799, + 122951.69054597223, + 122976.65852472307, + 123001.62777085182, + 123026.59828422987, + 123051.57006472857, + 123076.54311221937, + 123101.5174265737, + 123126.49300766307, + 123151.46985535898, + 123176.44796953299, + 123201.42735005668, + 123226.40799680166, + 123251.38990963959, + 123276.37308844214, + 123301.35753308103, + 123326.343243428, + 123351.33021935483, + 123376.31846073334, + 123401.30796743535, + 123426.29873933276, + 123451.29077629748, + 123476.28407820144, + 123501.2786449166, + 123526.27447631498, + 123551.27157226863, + 123576.26993264959, + 123601.26955732999, + 123626.27044618195, + 123651.27259907764, + 123676.27601588926, + 123701.28069648903, + 123726.28664074924, + 123751.29384854218, + 123776.30231974016, + 123801.31205421555, + 123826.32305184075, + 123851.33531248817, + 123876.34883603029, + 123901.36362233957, + 123926.37967128855, + 123951.39698274979, + 123976.41555659588, + 124001.43539269941, + 124026.45649093305, + 124051.47885116948, + 124076.50247328142, + 124101.5273571416, + 124126.55350262282, + 124151.58090959788, + 124176.60957793961, + 124201.63950752091, + 124226.67069821467, + 124251.70314989384, + 124276.73686243138, + 124301.7718357003, + 124326.80806957364, + 124351.84556392446, + 124376.88431862585, + 124401.92433355095, + 124426.96560857294, + 124452.00814356498, + 124477.05193840031, + 124502.0969929522, + 124527.14330709392, + 124552.19088069882, + 124577.23971364023, + 124602.28980579154, + 124627.34115702618, + 124652.3937672176, + 124677.44763623926, + 124702.50276396469, + 124727.55915026742, + 124752.61679502104, + 124777.67569809916, + 124802.73585937542, + 124827.79727872348, + 124852.85995601704, + 124877.92389112986, + 124902.98908393568, + 124928.05553430831, + 124953.1232421216, + 124978.19220724938, + 125003.26242956554, + 125028.33390894404, + 125053.40664525882, + 125078.48063838384, + 125103.55588819318, + 125128.63239456083, + 125153.71015736091, + 125178.78917646752, + 125203.86945175481, + 125228.95098309696, + 125254.03377036817, + 125279.1178134427, + 125304.20311219479, + 125329.28966649878, + 125354.37747622898, + 125379.46654125977, + 125404.55686146552, + 125429.6484367207, + 125454.74126689974, + 125479.83535187715, + 125504.93069152744, + 125530.02728572517, + 125555.12513434493, + 125580.22423726133, + 125605.32459434902, + 125630.4262054827, + 125655.52907053704, + 125680.63318938682, + 125705.73856190679, + 125730.84518797178, + 125755.9530674566, + 125781.06220023613, + 125806.17258618528, + 125831.28422517896, + 125856.39711709213, + 125881.51126179981, + 125906.62665917698, + 125931.74330909875, + 125956.86121144016, + 125981.98036607634, + 126007.10077288245, + 126032.22243173365, + 126057.34534250517, + 126082.46950507225, + 126107.59491931014, + 126132.72158509417, + 126157.84950229966, + 126182.97867080198, + 126208.10909047653, + 126233.24076119871, + 126258.37368284403, + 126283.50785528794, + 126308.64327840599, + 126333.77995207369, + 126358.91787616667, + 126384.0570505605, + 126409.19747513086, + 126434.3391497534, + 126459.48207430386, + 126484.62624865794, + 126509.77167269142, + 126534.9183462801, + 126560.06626929982, + 126585.21544162642, + 126610.36586313581, + 126635.51753370393, + 126660.67045320668, + 126685.82462152008, + 126710.98003852014, + 126736.13670408291, + 126761.29461808444, + 126786.45378040087, + 126811.61419090834, + 126836.77584948298, + 126861.93875600102, + 126887.10291033868, + 126912.26831237224, + 126937.43496197795, + 126962.60285903217, + 126987.77200341123, + 127012.94239499152, + 127038.11403364947, + 127063.2869192615, + 127088.46105170409, + 127113.63643085376, + 127138.81305658702, + 127163.99092878048, + 127189.17004731069, + 127214.35041205429, + 127239.53202288797, + 127264.71487968838, + 127289.89898233226, + 127315.08433069635, + 127340.27092465744, + 127365.45876409234, + 127390.64784887788, + 127415.83817889093, + 127441.02975400841, + 127466.22257410725, + 127491.41663906439, + 127516.61194875685, + 127541.80850306165, + 127567.00630185583, + 127592.20534501647, + 127617.4056324207, + 127642.60716394568, + 127667.80993946856, + 127693.01395886653, + 127718.21922201688, + 127743.42572879682, + 127768.63347908368, + 127793.84247275478, + 127819.05270968749, + 127844.26418975917, + 127869.47691284724, + 127894.69087882918, + 127919.90608758242, + 127945.12253898452, + 127970.34023291297, + 127995.55916924537, + 128020.77934785932, + 128046.00076863244, + 128071.22343144237, + 128096.44733616684, + 128121.67248268353, + 128146.89887087021, + 128172.12650060465, + 128197.35537176467, + 128222.5854842281, + 128247.81683787282, + 128273.04943257671, + 128298.28326821771, + 128323.51834467379, + 128348.75466182294, + 128373.99221954317, + 128399.23101771252, + 128424.47105620909, + 128449.71233491098, + 128474.95485369631, + 128500.19861244329, + 128525.44361103009, + 128550.68984933494, + 128575.93732723613, + 128601.18604461191, + 128626.43600134061, + 128651.68719730059, + 128676.93963237021, + 128702.1933064279, + 128727.44821935208, + 128752.70437102125, + 128777.96176131385, + 128803.22039010846, + 128828.48025728362, + 128853.74136271792, + 128879.00370628996, + 128904.26728787841, + 128929.53210736193, + 128954.79816461923, + 128980.06545952905, + 129005.33399197015, + 129030.60376182134, + 129055.87476896142, + 129081.14701326926, + 129106.42049462376, + 129131.6952129038, + 129156.97116798835, + 129182.24835975636, + 129207.52678808685, + 129232.80645285884, + 129258.08735395141, + 129283.36949124365, + 129308.65286461466, + 129333.9374739436, + 129359.22331910966, + 129384.51039999202, + 129409.79871646997, + 129435.08826842274, + 129460.37905572963, + 129485.67107826998, + 129510.96433592314, + 129536.25882856851, + 129561.55455608548, + 129586.85151835352, + 129612.14971525209, + 129637.4491466607, + 129662.74981245887, + 129688.0517125262, + 129713.35484674224, + 129738.65921498663, + 129763.96481713903, + 129789.27165307909, + 129814.57972268655, + 129839.88902584116, + 129865.19956242264, + 129890.51133231082, + 129915.82433538554, + 129941.13857152662, + 129966.45404061397, + 129991.7707425275, + 130017.08867714716, + 130042.4078443529, + 130067.72824402474, + 130093.04987604271, + 130118.37274028687, + 130143.69683663732, + 130169.02216497416, + 130194.34872517755, + 130219.67651712766, + 130245.0055407047, + 130270.33579578891, + 130295.66728226055, + 130320.99999999991, + 130346.33394888733, + 130371.66912880314, + 130397.00553962773, + 130422.34318124152, + 130447.68205352494, + 130473.02215635845, + 130498.36348962256, + 130523.70605319779, + 130549.0498469647, + 130574.39487080388, + 130599.74112459592, + 130625.08860822149, + 130650.43732156123, + 130675.78726449587, + 130701.13843690613, + 130726.49083867275, + 130751.84446967654, + 130777.19932979831, + 130802.5554189189, + 130827.91273691918, + 130853.27128368006, + 130878.63105908247, + 130903.99206300738, + 130929.35429533575, + 130954.71775594862, + 130980.08244472703, + 131005.44836155206, + 131030.81550630482, + 131056.18387886642, + 131081.55347911804, + 131106.92430694087, + 131132.29636221612, + 131157.66964482504, + 131183.0441546489, + 131208.41989156904, + 131233.79685546676, + 131259.17504622342, + 131284.55446372041, + 131309.93510783918, + 131335.31697846117, + 131360.70007546784, + 131386.0843987407, + 131411.46994816128, + 131436.85672361116, + 131462.24472497194, + 131487.63395212521, + 131513.02440495262, + 131538.41608333588, + 131563.80898715663, + 131589.2031162967, + 131614.59847063778, + 131639.9950500617, + 131665.39285445024, + 131690.79188368531, + 131716.19213764873, + 131741.59361622241, + 131766.99631928833, + 131792.40024672839, + 131817.80539842462, + 131843.21177425905, + 131868.61937411371, + 131894.02819787065, + 131919.43824541202, + 131944.84951661993, + 131970.26201137656, + 131995.67572956407, + 132021.09067106468, + 132046.50683576067, + 132071.9242235343, + 132097.34283426782, + 132122.76266784366, + 132148.1837241441, + 132173.60600305157, + 132199.02950444847, + 132224.45422821722, + 132249.88017424036, + 132275.30734240031, + 132300.73573257966, + 132326.16534466096, + 132351.59617852676, + 132377.02823405969, + 132402.46151114244, + 132427.89600965759, + 132453.33172948789, + 132478.76867051609, + 132504.20683262491, + 132529.64621569714, + 132555.08681961559, + 132580.5286442631, + 132605.97168952253, + 132631.41595527678, + 132656.86144140881, + 132682.30814780149, + 132707.75607433787, + 132733.20522090094, + 132758.65558737374, + 132784.10717363929, + 132809.55997958075, + 132835.01400508118, + 132860.46925002377, + 132885.92571429166, + 132911.38339776811, + 132936.84230033628, + 132962.30242187946, + 132987.76376228096, + 133013.22632142407, + 133038.69009919214, + 133064.15509546854, + 133089.62131013666, + 133115.08874307995, + 133140.55739418184, + 133166.02726332581, + 133191.49835039541, + 133216.97065527414, + 133242.44417784561, + 133267.91891799335, + 133293.39487560102, + 133318.87205055228, + 133344.35044273079, + 133369.83005202023, + 133395.31087830439, + 133420.79292146701, + 133446.27618139185, + 133471.76065796276, + 133497.24635106357, + 133522.73326057816, + 133548.22138639039, + 133573.71072838426, + 133599.20128644365, + 133624.69306045261, + 133650.1860502951, + 133675.68025585517, + 133701.1756770169, + 133726.67231366437, + 133752.17016568172, + 133777.66923295305, + 133803.16951536259, + 133828.67101279454, + 133854.17372513309, + 133879.67765226253, + 133905.18279406714, + 133930.68915043125, + 133956.19672123916, + 133981.70550637526, + 134007.21550572399, + 134032.7267191697, + 134058.23914659687, + 134083.75278789, + 134109.26764293358, + 134134.78371161217, + 134160.30099381026, + 134185.8194894125, + 134211.33919830353, + 134236.8601203679, + 134262.38225549037, + 134287.90560355558, + 134313.43016444831, + 134338.95593805326, + 134364.48292425525, + 134390.01112293909, + 134415.54053398955, + 134441.07115729159, + 134466.60299273001, + 134492.1360401898, + 134517.67029955584, + 134543.20577071316, + 134568.74245354676, + 134594.28034794159, + 134619.81945378278, + 134645.35977095537, + 134670.90129934452, + 134696.4440388353, + 134721.98798931291, + 134747.53315066252, + 134773.07952276937, + 134798.62710551871, + 134824.17589879577, + 134849.72590248589, + 134875.27711647438, + 134900.82954064661, + 134926.38317488792, + 134951.93801908373, + 134977.49407311951, + 135003.05133688069, + 135028.60981025276, + 135054.16949312127, + 135079.73038537172, + 135105.29248688967, + 135130.85579756077, + 135156.42031727062, + 135181.98604590484, + 135207.55298334916, + 135233.12112948924, + 135258.69048421088, + 135284.26104739975, + 135309.83281894168, + 135335.4057987225, + 135360.97998662802, + 135386.55538254412, + 135412.13198635669, + 135437.70979795168, + 135463.28881721498, + 135488.86904403262, + 135514.45047829056, + 135540.03311987486, + 135565.61696867159, + 135591.20202456677, + 135616.78828744654, + 135642.37575719706, + 135667.96443370447, + 135693.55431685498, + 135719.14540653475, + 135744.73770263011, + 135770.33120502727, + 135795.92591361253, + 135821.52182827223, + 135847.11894889272, + 135872.7172753604, + 135898.31680756161, + 135923.91754538284, + 135949.51948871053, + 135975.12263743114, + 136000.72699143123, + 136026.33255059729, + 136051.93931481591, + 136077.54728397369, + 136103.15645795723, + 136128.76683665317, + 136154.37841994822, + 136179.99120772901, + 136205.60519988232, + 136231.2203962949, + 136256.83679685349, + 136282.45440144493, + 136308.07320995603, + 136333.69322227367, + 136359.31443828469, + 136384.93685787608, + 136410.56048093468, + 136436.18530734754, + 136461.81133700156, + 136487.43856978384, + 136513.06700558143, + 136538.6966442813, + 136564.32748577066, + 136589.95952993655, + 136615.59277666616, + 136641.22722584667, + 136666.86287736523, + 136692.49973110916, + 136718.13778696564, + 136743.77704482197, + 136769.41750456547, + 136795.05916608346, + 136820.70202926331, + 136846.34609399244, + 136871.99136015819, + 136897.63782764805, + 136923.28549634948, + 136948.93436614997, + 136974.58443693706, + 137000.23570859825, + 137025.88818102115, + 137051.54185409332, + 137077.19672770242, + 137102.85280173609, + 137128.51007608202, + 137154.16855062786, + 137179.82822526142, + 137205.48909987041, + 137231.15117434258, + 137256.8144485658, + 137282.47892242789, + 137308.14459581667, + 137333.81146862009, + 137359.47954072602, + 137385.14881202241, + 137410.81928239719, + 137436.49095173844, + 137462.16381993407, + 137487.83788687221, + 137513.51315244089, + 137539.18961652822, + 137564.86727902229, + 137590.54613981131, + 137616.22619878338, + 137641.90745582676, + 137667.58991082967, + 137693.27356368033, + 137718.95841426702, + 137744.64446247809, + 137770.33170820182, + 137796.02015132661, + 137821.70979174081, + 137847.40062933284, + 137873.09266399115, + 137898.78589560417, + 137924.48032406042, + 137950.17594924837, + 137975.8727710566, + 138001.57078937365, + 138027.27000408815, + 138052.97041508864, + 138078.67202226384, + 138104.3748255024, + 138130.07882469296, + 138155.78401972432, + 138181.49041048516, + 138207.1979968643, + 138232.9067787505, + 138258.61675603263, + 138284.32792859949, + 138310.04029633995, + 138335.75385914298, + 138361.46861689744, + 138387.18456949232, + 138412.90171681659, + 138438.62005875923, + 138464.33959520931, + 138490.06032605586, + 138515.78225118798, + 138541.50537049473, + 138567.2296838653, + 138592.95519118884, + 138618.68189235451, + 138644.40978725153, + 138670.13887576913, + 138695.86915779658, + 138721.60063322316, + 138747.33330193823, + 138773.06716383106, + 138798.80221879104, + 138824.53846670757, + 138850.27590747006, + 138876.01454096794, + 138901.7543670907, + 138927.49538572782, + 138953.2375967688, + 138978.9810001032, + 139004.72559562061, + 139030.47138321059, + 139056.2183627628, + 139081.96653416683, + 139107.71589731239, + 139133.46645208917, + 139159.21819838689, + 139184.97113609532, + 139210.72526510421, + 139236.48058530336, + 139262.23709658257, + 139287.99479883176, + 139313.75369194071, + 139339.51377579942, + 139365.27505029776, + 139391.03751532568, + 139416.80117077316, + 139442.56601653024, + 139468.33205248689, + 139494.09927853322, + 139519.86769455927, + 139545.63730045516, + 139571.408096111, + 139597.18008141697, + 139622.95325626322, + 139648.72762054001, + 139674.5031741375, + 139700.27991694602, + 139726.05784885579, + 139751.83696975713, + 139777.61727954043, + 139803.39877809596, + 139829.18146531415, + 139854.96534108539, + 139880.75040530015, + 139906.53665784886, + 139932.32409862199, + 139958.11272751007, + 139983.90254440365, + 140009.69354919327, + 140035.48574176949, + 140061.27912202294, + 140087.07368984428, + 140112.86944512415, + 140138.66638775321, + 140164.4645176222, + 140190.26383462184, + 140216.06433864293, + 140241.86602957622, + 140267.66890731253, + 140293.47297174268, + 140319.27822275754, + 140345.08466024802, + 140370.89228410498, + 140396.70109421943, + 140422.51109048226, + 140448.32227278448, + 140474.13464101712, + 140499.94819507122, + 140525.76293483781, + 140551.57886020801, + 140577.3959710729, + 140603.21426732364, + 140629.03374885136, + 140654.85441554731, + 140680.67626730262, + 140706.49930400858, + 140732.32352555645, + 140758.1489318375, + 140783.97552274304, + 140809.80329816442, + 140835.63225799298, + 140861.46240212015, + 140887.29373043729, + 140913.12624283586, + 140938.95993920733, + 140964.79481944317, + 140990.63088343487, + 141016.46813107401, + 141042.30656225214, + 141068.14617686081, + 141093.98697479168, + 141119.82895593636, + 141145.6721201865, + 141171.51646743377, + 141197.36199756994, + 141223.20871048668, + 141249.05660607578, + 141274.90568422904, + 141300.75594483822, + 141326.6073877952, + 141352.4600129918, + 141378.31382031992, + 141404.16880967148, + 141430.02498093838, + 141455.8823340126, + 141481.74086878612, + 141507.60058515094, + 141533.46148299909, + 141559.32356222265, + 141585.18682271364, + 141611.05126436421, + 141636.9168870665, + 141662.78369071262, + 141688.65167519479, + 141714.5208404052, + 141740.39118623605, + 141766.26271257963, + 141792.1354193282, + 141818.00930637406, + 141843.88437360956, + 141869.760620927, + 141895.6380482188, + 141921.51665537735, + 141947.39644229505, + 141973.27740886438, + 141999.15955497778, + 142025.04288052776, + 142050.92738540689, + 142076.81306950765, + 142102.69993272264, + 142128.58797494444, + 142154.47719606571, + 142180.36759597904, + 142206.25917457714, + 142232.15193175265, + 142258.04586739838, + 142283.94098140698, + 142309.83727367126, + 142335.73474408401, + 142361.63339253806, + 142387.5332189262, + 142413.43422314132, + 142439.33640507635, + 142465.23976462413, + 142491.14430167765, + 142517.05001612983, + 142542.95690787368, + 142568.86497680223, + 142594.77422280848, + 142620.68464578551, + 142646.5962456264, + 142672.50902222423, + 142698.42297547215, + 142724.33810526333, + 142750.25441149093, + 142776.17189404817, + 142802.09055282827, + 142828.01038772447, + 142853.93139863008, + 142879.85358543837, + 142905.77694804268, + 142931.70148633636, + 142957.62720021277, + 142983.55408956532, + 143009.48215428743, + 143035.41139427255, + 143061.34180941415, + 143087.27339960571, + 143113.20616474075, + 143139.14010471283, + 143165.07521941551, + 143191.01150874238, + 143216.94897258704, + 143242.88761084314, + 143268.82742340435, + 143294.76841016437, + 143320.71057101688, + 143346.65390585564, + 143372.59841457437, + 143398.54409706692, + 143424.49095322701, + 143450.43898294857, + 143476.38818612538, + 143502.33856265133, + 143528.29011242036, + 143554.24283532638, + 143580.19673126334, + 143606.1518001252, + 143632.10804180597, + 143658.06545619969, + 143684.02404320039, + 143709.98380270213, + 143735.944734599, + 143761.90683878519, + 143787.87011515474, + 143813.83456360188, + 143839.8001840208, + 143865.76697630569, + 143891.73494035081, + 143917.7040760504, + 143943.67438329876, + 143969.6458619902, + 143995.61851201905, + 144021.59233327967, + 144047.56732566646, + 144073.54348907378, + 144099.52082339607, + 144125.49932852783, + 144151.4790043635, + 144177.45985079758, + 144203.44186772458, + 144229.42505503909, + 144255.40941263564, + 144281.39494040885, + 144307.38163825331, + 144333.36950606373, + 144359.35854373468, + 144385.34875116093, + 144411.34012823718, + 144437.33267485813, + 144463.32639091855, + 144489.32127631325, + 144515.31733093705, + 144541.31455468474, + 144567.3129474512, + 144593.3125091313, + 144619.31323961995, + 144645.31513881206, + 144671.31820660262, + 144697.32244288657, + 144723.32784755889, + 144749.33442051467, + 144775.34216164888, + 144801.35107085665, + 144827.36114803303, + 144853.37239307314, + 144879.38480587213, + 144905.39838632516, + 144931.41313432742, + 144957.4290497741, + 144983.44613256046, + 145009.46438258173, + 145035.48379973322, + 145061.50438391021, + 145087.52613500805, + 145113.54905292206, + 145139.57313754765, + 145165.59838878017, + 145191.62480651509, + 145217.65239064783, + 145243.68114107384, + 145269.71105768863, + 145295.74214038774, + 145321.77438906668, + 145347.80780362099, + 145373.84238394629, + 145399.87812993818, + 145425.91504149229, + 145451.95311850426, + 145477.9923608698, + 145504.03276848458, + 145530.07434124436, + 145556.11707904484, + 145582.16098178181, + 145608.20604935108, + 145634.25228164849, + 145660.29967856981, + 145686.34824001096, + 145712.39796586783, + 145738.4488560363, + 145764.50091041232, + 145790.55412889185, + 145816.60851137087, + 145842.66405774537, + 145868.72076791141, + 145894.77864176501, + 145920.83767920226, + 145946.89788011924, + 145972.95924441208, + 145999.02177197693, + 146025.08546270995, + 146051.15031650732, + 146077.21633326527, + 146103.28351288004, + 146129.35185524789, + 146155.42136026506, + 146181.49202782792, + 146207.56385783272, + 146233.63685017588, + 146259.71100475377, + 146285.78632146274, + 146311.86280019928, + 146337.94044085976, + 146364.01924334071, + 146390.09920753856, + 146416.18033334985, + 146442.26262067116, + 146468.34606939898, + 146494.43067942993, + 146520.51645066062, + 146546.60338298764, + 146572.69147630769, + 146598.78073051744, + 146624.87114551352, + 146650.96272119274, + 146677.05545745179, + 146703.14935418745, + 146729.2444112965, + 146755.34062867577, + 146781.43800622207, + 146807.53654383228, + 146833.63624140329, + 146859.73709883197, + 146885.83911601527, + 146911.94229285014, + 146938.04662923355, + 146964.15212506248, + 146990.25878023397, + 147016.36659464505, + 147042.47556819281, + 147068.58570077427, + 147094.6969922866, + 147120.80944262692, + 147146.92305169237, + 147173.03781938017, + 147199.15374558745, + 147225.27083021149, + 147251.38907314953, + 147277.50847429881, + 147303.62903355664, + 147329.75075082036, + 147355.87362598727, + 147381.99765895473, + 147408.12284962015, + 147434.24919788091, + 147460.37670363448, + 147486.50536677826, + 147512.63518720976, + 147538.76616482646, + 147564.89829952587, + 147591.03159120557, + 147617.16603976308, + 147643.30164509601, + 147669.43840710199, + 147695.57632567859, + 147721.71540072354, + 147747.85563213445, + 147773.99701980909, + 147800.13956364512, + 147826.28326354033, + 147852.42811939248, + 147878.57413109933, + 147904.72129855872, + 147930.86962166851, + 147957.01910032652, + 147983.16973443062, + 148009.32152387875, + 148035.47446856883, + 148061.62856839882, + 148087.78382326665, + 148113.94023307035, + 148140.09779770792, + 148166.25651707739, + 148192.41639107687, + 148218.57741960438, + 148244.73960255808, + 148270.90293983606, + 148297.0674313365, + 148323.23307695755, + 148349.39987659742, + 148375.56783015432, + 148401.73693752653, + 148427.90719861226, + 148454.07861330983, + 148480.25118151752, + 148506.42490313368, + 148532.59977805667, + 148558.77580618486, + 148584.95298741665, + 148611.13132165043, + 148637.31080878471, + 148663.49144871789, + 148689.6732413485, + 148715.85618657502, + 148742.040284296, + 148768.22553440998, + 148794.41193681557, + 148820.59949141133, + 148846.78819809589, + 148872.97805676793, + 148899.16906732606, + 148925.36122966901, + 148951.55454369547, + 148977.74900930419, + 149003.9446263939, + 149030.1413948634, + 149056.33931461151, + 149082.53838553699, + 149108.73860753875, + 149134.9399805156, + 149161.14250436646, + 149187.34617899026, + 149213.5510042859, + 149239.75698015234, + 149265.96410648854, + 149292.17238319354, + 149318.38181016635, + 149344.59238730598, + 149370.80411451156, + 149397.01699168212, + 149423.23101871679, + 149449.44619551473, + 149475.66252197503, + 149501.87999799693, + 149528.0986234796, + 149554.31839832227, + 149580.53932242419, + 149606.76139568459, + 149632.98461800278, + 149659.20898927809, + 149685.43450940982, + 149711.66117829733, + 149737.88899584001, + 149764.11796193724, + 149790.34807648844, + 149816.57933939309, + 149842.81175055061, + 149869.04530986046, + 149895.28001722222, + 149921.51587253538, + 149947.75287569952, + 149973.99102661415, + 150000.23032517891, + 150026.47077129342, + 150052.71236485732, + 150078.95510577026, + 150105.1989939319, + 150131.444029242, + 150157.69021160025, + 150183.93754090639, + 150210.18601706024, + 150236.43563996154, + 150262.68640951012, + 150288.93832560582, + 150315.19138814852, + 150341.44559703805, + 150367.70095217437, + 150393.95745345735, + 150420.21510078697, + 150446.47389406321, + 150472.73383318601, + 150498.99491805542, + 150525.25714857146, + 150551.52052463419, + 150577.78504614369, + 150604.05071300003, + 150630.31752510337, + 150656.58548235384, + 150682.85458465159, + 150709.1248318968, + 150735.39622398972, + 150761.66876083051, + 150787.9424423195, + 150814.21726835691, + 150840.49323884305, + 150866.77035367821, + 150893.04861276277, + 150919.32801599705, + 150945.60856328148, + 150971.89025451642, + 150998.17308960229, + 151024.45706843957, + 151050.74219092872, + 151077.02845697021, + 151103.31586646455, + 151129.60441931229, + 151155.894115414, + 151182.1849546702, + 151208.47693698155, + 151234.77006224863, + 151261.06433037209, + 151287.35974125259, + 151313.65629479082, + 151339.95399088747, + 151366.25282944329, + 151392.55281035902, + 151418.85393353543, + 151445.1561988733, + 151471.45960627345, + 151497.76415563675, + 151524.06984686397, + 151550.37667985607, + 151576.68465451393, + 151602.99377073845, + 151629.30402843058, + 151655.61542749128, + 151681.92796782157, + 151708.24164932242, + 151734.55647189484, + 151760.87243543993, + 151787.18953985872, + 151813.50778505235, + 151839.82717092187, + 151866.14769736846, + 151892.46936429327, + 151918.79217159748, + 151945.11611918229, + 151971.44120694889, + 151997.76743479856, + 152024.09480263255, + 152050.42331035214, + 152076.75295785864, + 152103.08374505339, + 152129.41567183775, + 152155.74873811303, + 152182.08294378067, + 152208.41828874208, + 152234.75477289871, + 152261.09239615197, + 152287.43115840337, + 152313.77105955439, + 152340.11209950657, + 152366.45427816146, + 152392.79759542056, + 152419.14205118554, + 152445.48764535793, + 152471.8343778394, + 152498.18224853161, + 152524.53125733617, + 152550.88140415482, + 152577.23268888926, + 152603.58511144121, + 152629.93867171241, + 152656.29336960468, + 152682.64920501978, + 152709.00617785956, + 152735.36428802583, + 152761.72353542043, + 152788.08391994529, + 152814.44544150229, + 152840.80809999333, + 152867.17189532038, + 152893.53682738543, + 152919.90289609041, + 152946.27010133737, + 152972.63844302832, + 152999.00792106529, + 153025.37853535041, + 153051.7502857857, + 153078.12317227334, + 153104.4971947154, + 153130.8723530141, + 153157.24864707157, + 153183.62607679001, + 153210.00464207167, + 153236.38434281875, + 153262.76517893354, + 153289.14715031831, + 153315.53025687535, + 153341.91449850702, + 153368.2998751156, + 153394.68638660354, + 153421.07403287315, + 153447.46281382689, + 153473.85272936718, + 153500.24377939643, + 153526.63596381716, + 153553.02928253182, + 153579.42373544298, + 153605.81932245308, + 153632.21604346478, + 153658.61389838057, + 153685.0128871031, + 153711.41300953497, + 153737.81426557881, + 153764.21665513728, + 153790.62017811305, + 153817.02483440886, + 153843.43062392739, + 153869.83754657139, + 153896.24560224367, + 153922.65479084692, + 153949.06511228404, + 153975.4765664578, + 154001.88915327107, + 154028.30287262669, + 154054.71772442761, + 154081.13370857667, + 154107.55082497682, + 154133.96907353101, + 154160.38845414223, + 154186.80896671346, + 154213.23061114774, + 154239.65338734805, + 154266.07729521746, + 154292.50233465908, + 154318.92850557598, + 154345.35580787127, + 154371.7842414481, + 154398.21380620965, + 154424.64450205903, + 154451.07632889951, + 154477.50928663427, + 154503.94337516659, + 154530.37859439969, + 154556.81494423689, + 154583.25242458144, + 154609.69103533673, + 154636.13077640603, + 154662.57164769279, + 154689.01364910032, + 154715.45678053208, + 154741.90104189145, + 154768.34643308193, + 154794.79295400696, + 154821.24060457002, + 154847.68938467462, + 154874.13929422433, + 154900.59033312264, + 154927.04250127316, + 154953.49579857948, + 154979.95022494521, + 155006.40578027396, + 155032.86246446942, + 155059.32027743524, + 155085.77921907514, + 155112.2392892928, + 155138.70048799197, + 155165.16281507642, + 155191.62627044989, + 155218.09085401625, + 155244.55656567923, + 155271.02340534274, + 155297.49137291059, + 155323.96046828668, + 155350.4306913749, + 155376.90204207919, + 155403.37452030348, + 155429.84812595171, + 155456.32285892789, + 155482.79871913602, + 155509.27570648011, + 155535.75382086422, + 155562.23306219239, + 155588.71343036872, + 155615.19492529731, + 155641.67754688227, + 155668.16129502779, + 155694.64616963797, + 155721.13217061706, + 155747.61929786921, + 155774.10755129869, + 155800.59693080973, + 155827.08743630661, + 155853.57906769359, + 155880.07182487496, + 155906.56570775513, + 155933.06071623837, + 155959.55685022907, + 155986.05410963166, + 156012.5524943505, + 156039.05200429002, + 156065.55263935472, + 156092.054399449, + 156118.5572844774, + 156145.06129434443, + 156171.5664289546, + 156198.07268821247, + 156224.5800720226, + 156251.08858028959, + 156277.59821291809, + 156304.10896981266, + 156330.62085087801, + 156357.1338560188, + 156383.64798513969, + 156410.16323814544, + 156436.67961494075, + 156463.1971154304, + 156489.71573951913, + 156516.23548711176, + 156542.75635811311, + 156569.27835242799, + 156595.80146996127, + 156622.32571061782, + 156648.85107430254, + 156675.37756092031, + 156701.90517037612, + 156728.43390257491, + 156754.96375742162, + 156781.49473482129, + 156808.02683467892, + 156834.5600568995, + 156861.09440138817, + 156887.62986804993, + 156914.16645678994, + 156940.70416751326, + 156967.24300012505, + 156993.78295453047, + 157020.32403063469, + 157046.8662283429, + 157073.40954756032, + 157099.9539881922, + 157126.49955014378, + 157153.04623332032, + 157179.59403762716, + 157206.14296296958, + 157232.69300925292, + 157259.24417638258, + 157285.79646426387, + 157312.34987280221, + 157338.90440190304, + 157365.46005147175, + 157392.01682141385, + 157418.57471163478, + 157445.13372204005, + 157471.69385253513, + 157498.25510302564, + 157524.81747341706, + 157551.38096361503, + 157577.9455735251, + 157604.51130305286, + 157631.07815210402, + 157657.64612058419, + 157684.21520839902, + 157710.78541545427, + 157737.35674165559, + 157763.92918690876, + 157790.50275111952, + 157817.07743419363, + 157843.65323603692, + 157870.23015655516, + 157896.80819565422, + 157923.3873532399, + 157949.96762921812, + 157976.54902349479, + 158003.13153597576, + 158029.71516656701, + 158056.29991517449, + 158082.88578170416, + 158109.47276606198, + 158136.06086815402, + 158162.65008788629, + 158189.24042516484, + 158215.83187989573, + 158242.42445198505, + 158269.01814133892, + 158295.61294786347, + 158322.20887146486, + 158348.80591204923, + 158375.4040695228, + 158402.00334379176, + 158428.60373476235, + 158455.2052423408, + 158481.80786643337, + 158508.41160694641, + 158535.01646378616, + 158561.62243685898, + 158588.2295260712, + 158614.8377313292, + 158641.44705253936, + 158668.05748960807, + 158694.66904244179, + 158721.28171094693, + 158747.89549502998, + 158774.5103945974, + 158801.12640955573, + 158827.74353981143, + 158854.36178527112, + 158880.9811458413, + 158907.60162142856, + 158934.22321193956, + 158960.84591728085, + 158987.46973735912, + 159014.09467208097, + 159040.72072135314, + 159067.3478850823, + 159093.97616317519, + 159120.60555553852, + 159147.23606207906, + 159173.8676827036, + 159200.50041731889, + 159227.13426583182, + 159253.76922814918, + 159280.40530417781, + 159307.04249382461, + 159333.68079699649, + 159360.32021360032, + 159386.96074354305, + 159413.60238673165, + 159440.24514307309, + 159466.88901247433, + 159493.53399484244, + 159520.18009008438, + 159546.82729810724, + 159573.47561881805, + 159600.12505212394, + 159626.77559793202, + 159653.42725614941, + 159680.08002668325, + 159706.73390944069, + 159733.38890432892, + 159760.04501125516, + 159786.70223012666, + 159813.36056085059, + 159840.02000333427, + 159866.68055748497, + 159893.34222320997, + 159920.00500041663, + 159946.66888901225, + 159973.33388890422, + 159999.99999999988, + 160026.66722220668, + 160053.33555543202, + 160080.0049995833, + 160106.67555456801, + 160133.3472202936, + 160160.0199966676, + 160186.6938835975, + 160213.36888099083, + 160240.04498875517, + 160266.72220679806, + 160293.40053502709, + 160320.07997334987, + 160346.76052167406, + 160373.44217990729, + 160400.1249479572, + 160426.80882573154, + 160453.49381313793, + 160480.17991008417, + 160506.86711647795, + 160533.55543222709, + 160560.24485723933, + 160586.93539142248, + 160613.62703468435, + 160640.31978693281, + 160667.01364807569, + 160693.70861802087, + 160720.40469667627, + 160747.1018839498, + 160773.80017974938, + 160800.49958398298, + 160827.20009655855, + 160853.90171738411, + 160880.60444636765, + 160907.30828341722, + 160934.01322844089, + 160960.71928134665, + 160987.42644204266, + 161014.13471043704, + 161040.84408643784, + 161067.55456995327, + 161094.26616089148, + 161120.97885916062, + 161147.69266466892, + 161174.40757732463, + 161201.12359703594, + 161227.84072371112, + 161254.55895725847, + 161281.27829758628, + 161307.99874460287, + 161334.72029821656, + 161361.44295833571, + 161388.1667248687, + 161414.89159772391, + 161441.61757680977, + 161468.34466203468, + 161495.07285330712, + 161521.80215053557, + 161548.53255362847, + 161575.26406249436, + 161601.99667704175, + 161628.7303971792, + 161655.46522281526, + 161682.20115385848, + 161708.93819021754, + 161735.67633180099, + 161762.41557851751, + 161789.15593027571, + 161815.89738698432, + 161842.63994855201, + 161869.38361488748, + 161896.1283858995, + 161922.87426149679, + 161949.62124158812, + 161976.36932608229, + 162003.1185148881, + 162029.8688079144, + 162056.62020507001, + 162083.37270626382, + 162110.12631140469, + 162136.88102040152, + 162163.63683316324, + 162190.39374959879, + 162217.15176961714, + 162243.91089312723, + 162270.67112003808, + 162297.43245025873, + 162324.19488369819, + 162350.9584202655, + 162377.72305986975, + 162404.48880242003, + 162431.25564782543, + 162458.02359599507, + 162484.79264683815, + 162511.56280026378, + 162538.33405618116, + 162565.10641449949, + 162591.87987512801, + 162618.65443797593, + 162645.43010295252, + 162672.20686996708, + 162698.98473892888, + 162725.76370974723, + 162752.54378233149, + 162779.32495659095, + 162806.10723243505, + 162832.89060977317, + 162859.67508851466, + 162886.46066856899, + 162913.24734984562, + 162940.03513225398, + 162966.82401570358, + 162993.6140001039, + 163020.40508536444, + 163047.19727139481, + 163073.99055810447, + 163100.78494540305, + 163127.58043320014, + 163154.37702140535, + 163181.17470992831, + 163207.97349867865, + 163234.77338756606, + 163261.57437650024, + 163288.37646539087, + 163315.17965414765, + 163341.98394268038, + 163368.78933089875, + 163395.59581871261, + 163422.40340603172, + 163449.2120927659, + 163476.02187882498, + 163502.83276411882, + 163529.6447485573, + 163556.45783205028, + 163583.2720145077, + 163610.08729583945, + 163636.90367595552, + 163663.72115476584, + 163690.53973218042, + 163717.35940810922, + 163744.18018246227, + 163771.00205514964, + 163797.82502608138, + 163824.64909516752, + 163851.4742623182, + 163878.3005274435, + 163905.12789045356, + 163931.95635125853, + 163958.78590976857, + 163985.61656589387, + 164012.44831954464, + 164039.28117063109, + 164066.11511906344, + 164092.95016475199, + 164119.78630760699, + 164146.62354753874, + 164173.46188445756, + 164200.30131827376, + 164227.14184889771, + 164253.98347623978, + 164280.82620021031, + 164307.67002071979, + 164334.51493767856, + 164361.3609509971, + 164388.20806058586, + 164415.05626635533, + 164441.905568216, + 164468.75596607837, + 164495.607459853, + 164522.4600494504, + 164549.31373478117, + 164576.16851575591, + 164603.02439228518, + 164629.88136427966, + 164656.73943164994, + 164683.59859430668, + 164710.45885216061, + 164737.32020512238, + 164764.1826531027, + 164791.04619601235, + 164817.91083376206, + 164844.77656626256, + 164871.64339342469, + 164898.51131515924, + 164925.38033137703, + 164952.25044198887, + 164979.1216469057, + 165005.9939460383, + 165032.86733929763, + 165059.7418265946, + 165086.61740784015, + 165113.4940829452 }; #else -static real_t iq_table[] = +#define IQ_TABLE_SIZE 1026 + +ALIGN static const real_t iq_table[IQ_TABLE_SIZE] = { - 0x0, - 0x80, - 0x142, - 0x229, - 0x32C, - 0x446, - 0x573, - 0x6B1, - 0x7FF, - 0x95C, - 0xAC5, - 0xC3B, - 0xDBC, - 0xF48, - 0x10DE, - 0x127F, - 0x1428, - 0x15DB, - 0x1796, - 0x1959, - 0x1B24, - 0x1CF7, - 0x1ED2, - 0x20B4, - 0x229D, - 0x248C, - 0x2683, - 0x287F, - 0x2A83, - 0x2C8C, - 0x2E9B, - 0x30B0, - 0x32CB, - 0x34EC, - 0x3712, - 0x393E, - 0x3B6F, - 0x3DA5, - 0x3FE0, - 0x4220, - 0x4466, - 0x46B0, - 0x48FF, - 0x4B52, - 0x4DAA, - 0x5007, - 0x5268, - 0x54CE, - 0x5738, - 0x59A7, - 0x5C19, - 0x5E90, - 0x610B, - 0x638A, - 0x660D, - 0x6894, - 0x6B1F, - 0x6DAE, - 0x7041, - 0x72D7, - 0x7572, - 0x7810, - 0x7AB1, - 0x7D57, - 0x7FFF, - 0x82AC, - 0x855C, - 0x880F, - 0x8AC6, - 0x8D81, - 0x903E, - 0x92FF, - 0x95C4, - 0x988B, - 0x9B56, - 0x9E24, - 0xA0F6, - 0xA3CA, - 0xA6A2, - 0xA97C, - 0xAC5A, - 0xAF3B, - 0xB21F, - 0xB506, - 0xB7F0, - 0xBADD, - 0xBDCD, - 0xC0C0, - 0xC3B5, - 0xC6AE, - 0xC9A9, - 0xCCA8, - 0xCFA9, - 0xD2AC, - 0xD5B3, - 0xD8BC, - 0xDBC8, - 0xDED7, - 0xE1E9, - 0xE4FD, - 0xE814, - 0xEB2D, - 0xEE49, - 0xF168, - 0xF489, - 0xF7AD, - 0xFAD4, - 0xFDFD, - 0x10128, - 0x10456, - 0x10787, - 0x10ABA, - 0x10DEF, - 0x11127, - 0x11461, - 0x1179E, - 0x11ADD, - 0x11E1F, - 0x12163, - 0x124A9, - 0x127F2, - 0x12B3D, - 0x12E8A, - 0x131D9, - 0x1352B, - 0x1387F, - 0x13BD6, - 0x13F2F, - 0x1428A, - 0x145E7, - 0x14946, - 0x14CA8, - 0x1500C, - 0x15372, - 0x156DA, - 0x15A45, - 0x15DB1, - 0x16120, - 0x16491, - 0x16804, - 0x16B79, - 0x16EF0, - 0x1726A, - 0x175E5, - 0x17963, - 0x17CE2, - 0x18064, - 0x183E7, - 0x1876D, - 0x18AF5, - 0x18E7F, - 0x1920B, - 0x19598, - 0x19928, - 0x19CBA, - 0x1A04E, - 0x1A3E3, - 0x1A77B, - 0x1AB15, - 0x1AEB0, - 0x1B24E, - 0x1B5EE, - 0x1B98F, - 0x1BD32, - 0x1C0D7, - 0x1C47F, - 0x1C828, - 0x1CBD3, - 0x1CF7F, - 0x1D32E, - 0x1D6DE, - 0x1DA91, - 0x1DE45, - 0x1E1FB, - 0x1E5B3, - 0x1E96D, - 0x1ED28, - 0x1F0E6, - 0x1F4A5, - 0x1F866, - 0x1FC28, - 0x1FFED, - 0x203B3, - 0x2077B, - 0x20B45, - 0x20F11, - 0x212DE, - 0x216AD, - 0x21A7E, - 0x21E50, - 0x22225, - 0x225FB, - 0x229D2, - 0x22DAC, - 0x23187, - 0x23564, - 0x23942, - 0x23D23, - 0x24104, - 0x244E8, - 0x248CD, - 0x24CB4, - 0x2509D, - 0x25487, - 0x25873, - 0x25C60, - 0x2604F, - 0x26440, - 0x26832, - 0x26C26, - 0x2701C, - 0x27413, - 0x2780C, - 0x27C07, - 0x28003, - 0x28400, - 0x287FF, - 0x28C00, - 0x29003, - 0x29407, - 0x2980C, - 0x29C13, - 0x2A01C, - 0x2A426, - 0x2A832, - 0x2AC3F, - 0x2B04E, - 0x2B45E, - 0x2B870, - 0x2BC83, - 0x2C098, - 0x2C4AF, - 0x2C8C7, - 0x2CCE0, - 0x2D0FB, - 0x2D517, - 0x2D935, - 0x2DD55, - 0x2E176, - 0x2E598, - 0x2E9BC, - 0x2EDE1, - 0x2F208, - 0x2F630, - 0x2FA5A, - 0x2FE85, - 0x302B2, - 0x306E0, - 0x30B0F, - 0x30F40, - 0x31373, - 0x317A7, - 0x31BDC, - 0x32013, - 0x3244B, - 0x32884, - 0x32CBF, - 0x330FC, - 0x33539, - 0x33979, - 0x33DB9, - 0x341FB, - 0x3463F, - 0x34A83, - 0x34ECA, - 0x35311, - 0x3575A, - 0x35BA4, - 0x35FF0, - 0x3643D, - 0x3688B, - 0x36CDB, - 0x3712C, - 0x3757F, - 0x379D2, - 0x37E28, - 0x3827E, - 0x386D6, - 0x38B2F, - 0x38F8A, - 0x393E6, - 0x39843, - 0x39CA1, - 0x3A101, - 0x3A562, - 0x3A9C5, - 0x3AE28, - 0x3B28E, - 0x3B6F4, - 0x3BB5C, - 0x3BFC5, - 0x3C42F, - 0x3C89B, - 0x3CD08, - 0x3D176, - 0x3D5E5, - 0x3DA56, - 0x3DEC8, - 0x3E33B, - 0x3E7B0, - 0x3EC26, - 0x3F09D, - 0x3F515, - 0x3F98F, - 0x3FE0A, - 0x40286, - 0x40703, - 0x40B82, - 0x41002, - 0x41483, - 0x41906, - 0x41D89, - 0x4220E, - 0x42694, - 0x42B1C, - 0x42FA4, - 0x4342E, - 0x438B9, - 0x43D46, - 0x441D3, - 0x44662, - 0x44AF2, - 0x44F83, - 0x45415, - 0x458A9, - 0x45D3E, - 0x461D4, - 0x4666B, - 0x46B03, - 0x46F9D, - 0x47438, - 0x478D4, - 0x47D71, - 0x4820F, - 0x486AF, - 0x48B50, - 0x48FF1, - 0x49494, - 0x49939, - 0x49DDE, - 0x4A285, - 0x4A72C, - 0x4ABD5, - 0x4B07F, - 0x4B52B, - 0x4B9D7, - 0x4BE85, - 0x4C333, - 0x4C7E3, - 0x4CC94, - 0x4D146, - 0x4D5FA, - 0x4DAAE, - 0x4DF64, - 0x4E41B, - 0x4E8D2, - 0x4ED8B, - 0x4F246, - 0x4F701, - 0x4FBBD, - 0x5007B, - 0x50539, - 0x509F9, - 0x50EBA, - 0x5137C, - 0x5183F, - 0x51D03, - 0x521C9, - 0x5268F, - 0x52B57, - 0x53020, - 0x534E9, - 0x539B4, - 0x53E80, - 0x5434D, - 0x5481B, - 0x54CEB, - 0x551BB, - 0x5568C, - 0x55B5F, - 0x56033, - 0x56507, - 0x569DD, - 0x56EB4, - 0x5738C, - 0x57865, - 0x57D3F, - 0x5821A, - 0x586F6, - 0x58BD4, - 0x590B2, - 0x59592, - 0x59A72, - 0x59F54, - 0x5A436, - 0x5A91A, - 0x5ADFF, - 0x5B2E5, - 0x5B7CB, - 0x5BCB3, - 0x5C19C, - 0x5C686, - 0x5CB71, - 0x5D05D, - 0x5D54B, - 0x5DA39, - 0x5DF28, - 0x5E418, - 0x5E90A, - 0x5EDFC, - 0x5F2EF, - 0x5F7E4, - 0x5FCD9, - 0x601D0, - 0x606C7, - 0x60BBF, - 0x610B9, - 0x615B4, - 0x61AAF, - 0x61FAC, - 0x624A9, - 0x629A8, - 0x62EA8, - 0x633A8, - 0x638AA, - 0x63DAC, - 0x642B0, - 0x647B5, - 0x64CBA, - 0x651C1, - 0x656C9, - 0x65BD1, - 0x660DB, - 0x665E6, - 0x66AF1, - 0x66FFE, - 0x6750C, - 0x67A1A, - 0x67F2A, - 0x6843A, - 0x6894C, - 0x68E5F, - 0x69372, - 0x69887, - 0x69D9C, - 0x6A2B3, - 0x6A7CA, - 0x6ACE3, - 0x6B1FC, - 0x6B716, - 0x6BC32, - 0x6C14E, - 0x6C66B, - 0x6CB8A, - 0x6D0A9, - 0x6D5C9, - 0x6DAEA, - 0x6E00C, - 0x6E52F, - 0x6EA53, - 0x6EF78, - 0x6F49E, - 0x6F9C5, - 0x6FEED, - 0x70416, - 0x7093F, - 0x70E6A, - 0x71396, - 0x718C2, - 0x71DF0, - 0x7231E, - 0x7284E, - 0x72D7E, - 0x732AF, - 0x737E2, - 0x73D15, - 0x74249, - 0x7477E, - 0x74CB4, - 0x751EB, - 0x75722, - 0x75C5B, - 0x76195, - 0x766CF, - 0x76C0B, - 0x77147, - 0x77685, - 0x77BC3, - 0x78102, - 0x78642, - 0x78B83, - 0x790C5, - 0x79608, - 0x79B4C, - 0x7A091, - 0x7A5D6, - 0x7AB1D, - 0x7B064, - 0x7B5AC, - 0x7BAF6, - 0x7C040, - 0x7C58B, - 0x7CAD7, - 0x7D024, - 0x7D571, - 0x7DAC0, - 0x7E010, - 0x7E560, - 0x7EAB1, - 0x7F004, - 0x7F557, - 0x7FAAB, - 0x7FFFF, - 0x80555, - 0x80AAC, - 0x81003, - 0x8155C, - 0x81AB5, - 0x8200F, - 0x8256B, - 0x82AC7, - 0x83023, - 0x83581, - 0x83AE0, - 0x8403F, - 0x845A0, - 0x84B01, - 0x85063, - 0x855C6, - 0x85B2A, - 0x8608E, - 0x865F4, - 0x86B5A, - 0x870C2, - 0x8762A, - 0x87B93, - 0x880FD, - 0x88668, - 0x88BD3, - 0x89140, - 0x896AD, - 0x89C1B, - 0x8A18A, - 0x8A6FA, - 0x8AC6B, - 0x8B1DD, - 0x8B74F, - 0x8BCC3, - 0x8C237, - 0x8C7AC, - 0x8CD22, - 0x8D298, - 0x8D810, - 0x8DD88, - 0x8E302, - 0x8E87C, - 0x8EDF7, - 0x8F373, - 0x8F8EF, - 0x8FE6D, - 0x903EB, - 0x9096A, - 0x90EEA, - 0x9146B, - 0x919ED, - 0x91F6F, - 0x924F2, - 0x92A77, - 0x92FFC, - 0x93581, - 0x93B08, - 0x9408F, - 0x94618, - 0x94BA1, - 0x9512B, - 0x956B6, - 0x95C41, - 0x961CE, - 0x9675B, - 0x96CE9, - 0x97278, - 0x97807, - 0x97D98, - 0x98329, - 0x988BB, - 0x98E4E, - 0x993E2, - 0x99977, - 0x99F0C, - 0x9A4A2, - 0x9AA39, - 0x9AFD1, - 0x9B56A, - 0x9BB03, - 0x9C09D, - 0x9C639, - 0x9CBD4, - 0x9D171, - 0x9D70E, - 0x9DCAD, - 0x9E24C, - 0x9E7EC, - 0x9ED8C, - 0x9F32E, - 0x9F8D0, - 0x9FE73, - 0xA0417, - 0xA09BC, - 0xA0F61, - 0xA1507, - 0xA1AAE, - 0xA2056, - 0xA25FF, - 0xA2BA8, - 0xA3152, - 0xA36FD, - 0xA3CA9, - 0xA4255, - 0xA4803, - 0xA4DB1, - 0xA5360, - 0xA590F, - 0xA5EC0, - 0xA6471, - 0xA6A23, - 0xA6FD6, - 0xA7589, - 0xA7B3E, - 0xA80F3, - 0xA86A9, - 0xA8C5F, - 0xA9217, - 0xA97CF, - 0xA9D88, - 0xAA342, - 0xAA8FC, - 0xAAEB8, - 0xAB474, - 0xABA31, - 0xABFEE, - 0xAC5AD, - 0xACB6C, - 0xAD12C, - 0xAD6EC, - 0xADCAE, - 0xAE270, - 0xAE833, - 0xAEDF7, - 0xAF3BB, - 0xAF980, - 0xAFF46, - 0xB050D, - 0xB0AD5, - 0xB109D, - 0xB1666, - 0xB1C30, - 0xB21FA, - 0xB27C6, - 0xB2D92, - 0xB335E, - 0xB392C, - 0xB3EFA, - 0xB44C9, - 0xB4A99, - 0xB506A, - 0xB563B, - 0xB5C0D, - 0xB61E0, - 0xB67B3, - 0xB6D88, - 0xB735D, - 0xB7932, - 0xB7F09, - 0xB84E0, - 0xB8AB8, - 0xB9091, - 0xB966A, - 0xB9C45, - 0xBA220, - 0xBA7FB, - 0xBADD8, - 0xBB3B5, - 0xBB993, - 0xBBF71, - 0xBC551, - 0xBCB31, - 0xBD112, - 0xBD6F3, - 0xBDCD5, - 0xBE2B8, - 0xBE89C, - 0xBEE81, - 0xBF466, - 0xBFA4C, - 0xC0032, - 0xC061A, - 0xC0C02, - 0xC11EB, - 0xC17D4, - 0xC1DBE, - 0xC23A9, - 0xC2995, - 0xC2F82, - 0xC356F, - 0xC3B5D, - 0xC414B, - 0xC473B, - 0xC4D2B, - 0xC531B, - 0xC590D, - 0xC5EFF, - 0xC64F2, - 0xC6AE6, - 0xC70DA, - 0xC76CF, - 0xC7CC5, - 0xC82BB, - 0xC88B2, - 0xC8EAA, - 0xC94A3, - 0xC9A9C, - 0xCA096, - 0xCA691, - 0xCAC8C, - 0xCB288, - 0xCB885, - 0xCBE83, - 0xCC481, - 0xCCA80, - 0xCD07F, - 0xCD680, - 0xCDC81, - 0xCE283, - 0xCE885, - 0xCEE88, - 0xCF48C, - 0xCFA91, - 0xD0096, - 0xD069C, - 0xD0CA3, - 0xD12AA, - 0xD18B2, - 0xD1EBB, - 0xD24C4, - 0xD2ACE, - 0xD30D9, - 0xD36E4, - 0xD3CF1, - 0xD42FE, - 0xD490B, - 0xD4F19, - 0xD5528, - 0xD5B38, - 0xD6148, - 0xD6759, - 0xD6D6B, - 0xD737D, - 0xD7991, - 0xD7FA4, - 0xD85B9, - 0xD8BCE, - 0xD91E4, - 0xD97FA, - 0xD9E11, - 0xDA429, - 0xDAA42, - 0xDB05B, - 0xDB675, - 0xDBC8F, - 0xDC2AB, - 0xDC8C7, - 0xDCEE3, - 0xDD500, - 0xDDB1E, - 0xDE13D, - 0xDE75C, - 0xDED7C, - 0xDF39D, - 0xDF9BE, - 0xDFFE0, - 0xE0603, - 0xE0C26, - 0xE124A, - 0xE186F, - 0xE1E95, - 0xE24BB, - 0xE2AE1, - 0xE3109, - 0xE3731, - 0xE3D59, - 0xE4383, - 0xE49AD, - 0xE4FD7, - 0xE5603, - 0xE5C2F, - 0xE625C, - 0xE6889, - 0xE6EB7, - 0xE74E6, - 0xE7B15, - 0xE8145, - 0xE8776, - 0xE8DA7, - 0xE93D9, - 0xE9A0B, - 0xEA03F, - 0xEA673, - 0xEACA7, - 0xEB2DD, - 0xEB913, - 0xEBF49, - 0xEC580, - 0xECBB8, - 0xED1F1, - 0xED82A, - 0xEDE64, - 0xEE49E, - 0xEEAD9, - 0xEF115, - 0xEF752, - 0xEFD8F, - 0xF03CD, - 0xF0A0B, - 0xF104A, - 0xF168A, - 0xF1CCA, - 0xF230B, - 0xF294D, - 0xF2F8F, - 0xF35D2, - 0xF3C15, - 0xF425A, - 0xF489E, - 0xF4EE4, - 0xF552A, - 0xF5B71, - 0xF61B8, - 0xF6800, - 0xF6E49, - 0xF7492, - 0xF7ADC, - 0xF8127, - 0xF8772, - 0xF8DBE, - 0xF940B, - 0xF9A58, - 0xFA0A6, - 0xFA6F4, - 0xFAD43, - 0xFB393, - 0xFB9E3, - 0xFC034, - 0xFC686, - 0xFCCD8, - 0xFD32B, - 0xFD97F, - 0xFDFD3, - 0xFE628, - 0xFEC7D, - 0xFF2D3, - 0xFF92A, - 0xFFF81, - 0x1005D9, - 0x100C31, - 0x10128B, - 0x1018E4, - 0x101F3F, - 0x10259A, - 0x102BF6, - 0x103252, - 0x1038AF, - 0x103F0C, - 0x10456B, - 0x104BC9, - 0x105229, - 0x105889, - 0x105EEA, - 0x10654B, - 0x106BAD, - 0x10720F, - 0x107873, - 0x107ED6, - 0x10853B, - 0x108BA0, - 0x109205, - 0x10986C, - 0x109ED3, - 0x10A53A, - 0x10ABA2, - 0x10B20B, - 0x10B874, - 0x10BEDE, - 0x10C549, - 0x10CBB4, - 0x10D220, - 0x10D88C, - 0x10DEF9, - 0x10E567, - 0x10EBD5, - 0x10F244, - 0x10F8B3, - 0x10FF23, - 0x110594, - 0x110C05, - 0x111277, - 0x1118EA, - 0x111F5D, - 0x1125D1, - 0x112C45, - 0x1132BA, - 0x11392F, - 0x113FA6, - 0x11461C, - 0x114C94, - 0x11530C, - 0x115984, - 0x115FFD, - 0x116677, - 0x116CF2, - 0x11736D, - 0x1179E8, - 0x118064, - 0x1186E1, - 0x118D5E, - 0x1193DC, - 0x119A5B, - 0x11A0DA, - 0x11A75A, - 0x11ADDA, - 0x11B45B, - 0x11BADD, - 0x11C15F, - 0x11C7E2, - 0x11CE65, - 0x11D4E9, - 0x11DB6E, - 0x11E1F3, - 0x11E879, - 0x11EEFF, - 0x11F586, - 0x11FC0E, - 0x120296, - 0x12091E, - 0x120FA8, - 0x121632, - 0x121CBC, - 0x122347, - 0x1229D3, - 0x12305F, - 0x1236EC, - 0x123D79, - 0x124407, - 0x124A96, - 0x125125, - 0x1257B5, - 0x125E45, - 0x1264D6, - 0x126B68, - 0x1271FA, - 0x12788D, - 0x127F20, - 0x1285B4, - 0x128C48, - 0x1292DD, - 0x129973, - 0x12A009, - 0x12A6A0, - 0x12AD38, - 0x12B3D0, - 0x12BA68, - 0x12C101, - 0x12C79B, - 0x12CE35, - 0x12D4D0, - 0x12DB6C, - 0x12E208, - 0x12E8A4, - 0x12EF41, - 0x12F5DF, - 0x12FC7E, - 0x13031C, - 0x1309BC, - 0x13105C, - 0x1316FD, - 0x131D9E, - 0x132440, - 0x132AE2, - 0x133185, - 0x133829, - 0x133ECD, - 0x134571, - 0x134C17, - 0x1352BC, - 0x135963, - 0x13600A, - 0x1366B1, - 0x136D59, - 0x137402, - 0x137AAB, - 0x138155, - 0x1387FF, - 0x138EAA, - 0x139556, - 0x139C02, - 0x13A2AF, - 0x13A95C, - 0x13B00A, - 0x13B6B8, - 0x13BD67, - 0x13C416, - 0x13CAC7, - 0x13D177, - 0x13D828, - 0x13DEDA, - 0x13E58C, - 0x13EC3F, - 0x13F2F3, - 0x13F9A7, - 0x14005B, - 0x140710, - 0x140DC6, - 0x14147C, - 0x141B33, - 0x1421EB, - 0x1428A2, - 0x142F5B + REAL_CONST(0.0), + REAL_CONST(1.0/8.0), + REAL_CONST(2.5198420997897464/8.0), + REAL_CONST(4.3267487109222245/8.0), + REAL_CONST(6.3496042078727974/8.0), + REAL_CONST(8.5498797333834844/8.0), + REAL_CONST(10.902723556992836/8.0), + REAL_CONST(13.390518279406722/8.0), + REAL_CONST(15.999999999999998/8.0), + REAL_CONST(18.720754407467133/8.0), + REAL_CONST(21.544346900318832/8.0), + REAL_CONST(24.463780996262464/8.0), + REAL_CONST(27.47314182127996/8.0), + REAL_CONST(30.567350940369842/8.0), + REAL_CONST(33.741991698453212/8.0), + REAL_CONST(36.993181114957046/8.0), + REAL_CONST(40.317473596635935/8.0), + REAL_CONST(43.711787041189993/8.0), + REAL_CONST(47.173345095760126/8.0), + REAL_CONST(50.699631325716943/8.0), + REAL_CONST(54.288352331898118/8.0), + REAL_CONST(57.937407704003519/8.0), + REAL_CONST(61.6448652744185/8.0), + REAL_CONST(65.408940536585988/8.0), + REAL_CONST(69.227979374755591/8.0), + REAL_CONST(73.100443455321638/8.0), + REAL_CONST(77.024897778591622/8.0), + REAL_CONST(80.999999999999986/8.0), + REAL_CONST(85.024491212518527/8.0), + REAL_CONST(89.097187944889555/8.0), + REAL_CONST(93.216975178615741/8.0), + REAL_CONST(97.382800224133163/8.0), + REAL_CONST(101.59366732596474/8.0), + REAL_CONST(105.84863288986224/8.0), + REAL_CONST(110.14680124343441/8.0), + REAL_CONST(114.4873208566006/8.0), + REAL_CONST(118.86938096020653/8.0), + REAL_CONST(123.29220851090024/8.0), + REAL_CONST(127.75506545836058/8.0), + REAL_CONST(132.25724627755247/8.0), + REAL_CONST(136.79807573413572/8.0), + REAL_CONST(141.37690685569191/8.0), + REAL_CONST(145.99311908523086/8.0), + REAL_CONST(150.6461165966291/8.0), + REAL_CONST(155.33532675434674/8.0), + REAL_CONST(160.06019870205279/8.0), + REAL_CONST(164.82020206673349/8.0), + REAL_CONST(169.61482576651861/8.0), + REAL_CONST(174.44357691188537/8.0), + REAL_CONST(179.30597979112557/8.0), + REAL_CONST(184.20157493201927/8.0), + REAL_CONST(189.12991823257562/8.0), + REAL_CONST(194.09058015449685/8.0), + REAL_CONST(199.08314497371677/8.0), + REAL_CONST(204.1072100829694/8.0), + REAL_CONST(209.16238534187647/8.0), + REAL_CONST(214.24829247050752/8.0), + REAL_CONST(219.36456448277784/8.0), + REAL_CONST(224.51084515641216/8.0), + REAL_CONST(229.6867885365223/8.0), + REAL_CONST(234.89205847013176/8.0), + REAL_CONST(240.12632816923249/8.0), + REAL_CONST(245.38927980018505/8.0), + REAL_CONST(250.68060409747261/8.0), + REAL_CONST(255.99999999999991/8.0), + REAL_CONST(261.34717430828869/8.0), + REAL_CONST(266.72184136106449/8.0), + REAL_CONST(272.12372272986045/8.0), + REAL_CONST(277.55254693037961/8.0), + REAL_CONST(283.0080491494619/8.0), + REAL_CONST(288.48997098659891/8.0), + REAL_CONST(293.99806020902247/8.0), + REAL_CONST(299.53207051947408/8.0), + REAL_CONST(305.0917613358298/8.0), + REAL_CONST(310.67689758182206/8.0), + REAL_CONST(316.28724948815585/8.0), + REAL_CONST(321.92259240337177/8.0), + REAL_CONST(327.58270661385535/8.0), + REAL_CONST(333.26737717243742/8.0), + REAL_CONST(338.97639373507025/8.0), + REAL_CONST(344.70955040510125/8.0), + REAL_CONST(350.46664558470013/8.0), + REAL_CONST(356.24748183302603/8.0), + REAL_CONST(362.05186573075139/8.0), + REAL_CONST(367.87960775058258/8.0), + REAL_CONST(373.73052213344511/8.0), + REAL_CONST(379.60442677002078/8.0), + REAL_CONST(385.50114308734607/8.0), + REAL_CONST(391.42049594019937/8.0), + REAL_CONST(397.36231350702371/8.0), + REAL_CONST(403.32642719014467/8.0), + REAL_CONST(409.31267152006262/8.0), + REAL_CONST(415.32088406360799/8.0), + REAL_CONST(421.35090533576471/8.0), + REAL_CONST(427.40257871497619/8.0), + REAL_CONST(433.4757503617617/8.0), + REAL_CONST(439.5702691404793/8.0), + REAL_CONST(445.68598654408271/8.0), + REAL_CONST(451.82275662172759/8.0), + REAL_CONST(457.98043590909128/8.0), + REAL_CONST(464.15888336127773/8.0), + REAL_CONST(470.35796028818726/8.0), + REAL_CONST(476.5775302922363/8.0), + REAL_CONST(482.81745920832043/8.0), + REAL_CONST(489.07761504591741/8.0), + REAL_CONST(495.35786793323581/8.0), + REAL_CONST(501.65809006331688/8.0), + REAL_CONST(507.97815564200368/8.0), + REAL_CONST(514.31794083769648/8.0), + REAL_CONST(520.67732373281672/8.0), + REAL_CONST(527.05618427690604/8.0), + REAL_CONST(533.45440424129174/8.0), + REAL_CONST(539.87186717525128/8.0), + REAL_CONST(546.30845836361505/8.0), + REAL_CONST(552.76406478574609/8.0), + REAL_CONST(559.23857507584194/8.0), + REAL_CONST(565.73187948450413/8.0), + REAL_CONST(572.24386984152341/8.0), + REAL_CONST(578.77443951983378/8.0), + REAL_CONST(585.32348340058843/8.0), + REAL_CONST(591.89089783931263/8.0), + REAL_CONST(598.47658063309257/8.0), + REAL_CONST(605.08043098876044/8.0), + REAL_CONST(611.70234949203643/8.0), + REAL_CONST(618.3422380775919/8.0), + REAL_CONST(624.99999999999977/8.0), + REAL_CONST(631.67553980553748/8.0), + REAL_CONST(638.36876330481164/8.0), + REAL_CONST(645.07957754617485/8.0), + REAL_CONST(651.80789078990415/8.0), + REAL_CONST(658.55361248311499/8.0), + REAL_CONST(665.31665323538357/8.0), + REAL_CONST(672.09692479505225/8.0), + REAL_CONST(678.8943400261943/8.0), + REAL_CONST(685.70881288621433/8.0), + REAL_CONST(692.540258404062/8.0), + REAL_CONST(699.38859265903977/8.0), + REAL_CONST(706.25373276018058/8.0), + REAL_CONST(713.13559682617972/8.0), + REAL_CONST(720.03410396586037/8.0), + REAL_CONST(726.94917425915435/8.0), + REAL_CONST(733.88072873858209/8.0), + REAL_CONST(740.82868937121543/8.0), + REAL_CONST(747.79297904110535/8.0), + REAL_CONST(754.77352153216191/8.0), + REAL_CONST(761.77024151147043/8.0), + REAL_CONST(768.78306451302956/8.0), + REAL_CONST(775.81191692189896/8.0), + REAL_CONST(782.85672595874246/8.0), + REAL_CONST(789.91741966475445/8.0), + REAL_CONST(796.99392688695798/8.0), + REAL_CONST(804.08617726386274/8.0), + REAL_CONST(811.19410121147098/8.0), + REAL_CONST(818.31762990962227/8.0), + REAL_CONST(825.45669528866563/8.0), + REAL_CONST(832.61123001644864/8.0), + REAL_CONST(839.78116748561604/8.0), + REAL_CONST(846.96644180120552/8.0), + REAL_CONST(854.16698776853514/8.0), + REAL_CONST(861.38274088137143/8.0), + REAL_CONST(868.61363731036977/8.0), + REAL_CONST(875.85961389178203/8.0), + REAL_CONST(883.12060811641959/8.0), + REAL_CONST(890.39655811886757/8.0), + REAL_CONST(897.68740266694181/8.0), + REAL_CONST(904.99308115138172/8.0), + REAL_CONST(912.31353357577188/8.0), + REAL_CONST(919.64870054668756/8.0), + REAL_CONST(926.99852326405619/8.0), + REAL_CONST(934.36294351172899/8.0), + REAL_CONST(941.74190364825859/8.0), + REAL_CONST(949.13534659787422/8.0), + REAL_CONST(956.54321584165211/8.0), + REAL_CONST(963.96545540887348/8.0), + REAL_CONST(971.40200986856541/8.0), + REAL_CONST(978.85282432122176/8.0), + REAL_CONST(986.31784439069588/8.0), + REAL_CONST(993.7970162162635/8.0), + REAL_CONST(1001.29028644485/8.0), + REAL_CONST(1008.797602223418/8.0), + REAL_CONST(1016.3189111915103/8.0), + REAL_CONST(1023.8541614739464/8.0), + REAL_CONST(1031.4033016736653/8.0), + REAL_CONST(1038.9662808647138/8.0), + REAL_CONST(1046.5430485853758/8.0), + REAL_CONST(1054.1335548314366/8.0), + REAL_CONST(1061.7377500495838/8.0), + REAL_CONST(1069.3555851309357/8.0), + REAL_CONST(1076.9870114046978/8.0), + REAL_CONST(1084.6319806319441/8.0), + REAL_CONST(1092.2904449995174/8.0), + REAL_CONST(1099.9623571140482/8.0), + REAL_CONST(1107.6476699960892/8.0), + REAL_CONST(1115.3463370743607/8.0), + REAL_CONST(1123.058312180106/8.0), + REAL_CONST(1130.7835495415541/8.0), + REAL_CONST(1138.5220037784854/8.0), + REAL_CONST(1146.273629896901/8.0), + REAL_CONST(1154.0383832837879/8.0), + REAL_CONST(1161.816219701986/8.0), + REAL_CONST(1169.607095285146/8.0), + REAL_CONST(1177.4109665327808/8.0), + REAL_CONST(1185.2277903054078/8.0), + REAL_CONST(1193.0575238197798/8.0), + REAL_CONST(1200.9001246442001/8.0), + REAL_CONST(1208.7555506939248/8.0), + REAL_CONST(1216.6237602266442/8.0), + REAL_CONST(1224.5047118380478/8.0), + REAL_CONST(1232.3983644574657/8.0), + REAL_CONST(1240.3046773435874/8.0), + REAL_CONST(1248.2236100802568/8.0), + REAL_CONST(1256.1551225723395/8.0), + REAL_CONST(1264.099175041662/8.0), + REAL_CONST(1272.0557280230228/8.0), + REAL_CONST(1280.0247423602691/8.0), + REAL_CONST(1288.0061792024444/8.0), + REAL_CONST(1295.9999999999995/8.0), + REAL_CONST(1304.006166501068/8.0), + REAL_CONST(1312.0246407478062/8.0), + REAL_CONST(1320.0553850727929/8.0), + REAL_CONST(1328.0983620954903/8.0), + REAL_CONST(1336.1535347187651/8.0), + REAL_CONST(1344.2208661254647/8.0), + REAL_CONST(1352.3003197750522/8.0), + REAL_CONST(1360.3918594002962/8.0), + REAL_CONST(1368.4954490040145/8.0), + REAL_CONST(1376.6110528558709/8.0), + REAL_CONST(1384.7386354892244/8.0), + REAL_CONST(1392.8781616980295/8.0), + REAL_CONST(1401.0295965337855/8.0), + REAL_CONST(1409.1929053025353/8.0), + REAL_CONST(1417.3680535619119/8.0), + REAL_CONST(1425.5550071182327/8.0), + REAL_CONST(1433.7537320236374/8.0), + REAL_CONST(1441.9641945732744/8.0), + REAL_CONST(1450.1863613025282/8.0), + REAL_CONST(1458.4201989842913/8.0), + REAL_CONST(1466.6656746262797/8.0), + REAL_CONST(1474.9227554683875/8.0), + REAL_CONST(1483.1914089800841/8.0), + REAL_CONST(1491.4716028578516/8.0), + REAL_CONST(1499.7633050226596/8.0), + REAL_CONST(1508.0664836174794/8.0), + REAL_CONST(1516.3811070048375/8.0), + REAL_CONST(1524.7071437644029/8.0), + REAL_CONST(1533.0445626906128/8.0), + REAL_CONST(1541.3933327903342/8.0), + REAL_CONST(1549.7534232805581/8.0), + REAL_CONST(1558.1248035861302/8.0), + REAL_CONST(1566.507443337515/8.0), + REAL_CONST(1574.9013123685909/8.0), + REAL_CONST(1583.3063807144795/8.0), + REAL_CONST(1591.7226186094069/8.0), + REAL_CONST(1600.1499964845941/8.0), + REAL_CONST(1608.58848496618/8.0), + REAL_CONST(1617.0380548731737/8.0), + REAL_CONST(1625.4986772154357/8.0), + REAL_CONST(1633.9703231916887/8.0), + REAL_CONST(1642.4529641875577/8.0), + REAL_CONST(1650.9465717736346/8.0), + REAL_CONST(1659.4511177035752/8.0), + REAL_CONST(1667.9665739122186/8.0), + REAL_CONST(1676.4929125137353/8.0), + REAL_CONST(1685.030105799801/8.0), + REAL_CONST(1693.5781262377957/8.0), + REAL_CONST(1702.136946469027/8.0), + REAL_CONST(1710.7065393069795/8.0), + REAL_CONST(1719.2868777355877/8.0), + REAL_CONST(1727.8779349075323/8.0), + REAL_CONST(1736.4796841425596/8.0), + REAL_CONST(1745.092098925825/8.0), + REAL_CONST(1753.7151529062583/8.0), + REAL_CONST(1762.3488198949503/8.0), + REAL_CONST(1770.9930738635628/8.0), + REAL_CONST(1779.6478889427597/8.0), + REAL_CONST(1788.3132394206564/8.0), + REAL_CONST(1796.9890997412947/8.0), + REAL_CONST(1805.6754445031333/8.0), + REAL_CONST(1814.3722484575621/8.0), + REAL_CONST(1823.0794865074322/8.0), + REAL_CONST(1831.7971337056094/8.0), + REAL_CONST(1840.5251652535437/8.0), + REAL_CONST(1849.2635564998579/8.0), + REAL_CONST(1858.0122829389563/8.0), + REAL_CONST(1866.7713202096493/8.0), + REAL_CONST(1875.5406440937966/8.0), + REAL_CONST(1884.3202305149687/8.0), + REAL_CONST(1893.110055537124/8.0), + REAL_CONST(1901.9100953633042/8.0), + REAL_CONST(1910.7203263343454/8.0), + REAL_CONST(1919.5407249276057/8.0), + REAL_CONST(1928.3712677557098/8.0), + REAL_CONST(1937.2119315653083/8.0), + REAL_CONST(1946.0626932358525/8.0), + REAL_CONST(1954.923529778386/8.0), + REAL_CONST(1963.79441833435/8.0), + REAL_CONST(1972.6753361744036/8.0), + REAL_CONST(1981.5662606972594/8.0), + REAL_CONST(1990.467169428533/8.0), + REAL_CONST(1999.3780400196069/8.0), + REAL_CONST(2008.2988502465078/8.0), + REAL_CONST(2017.2295780087982/8.0), + REAL_CONST(2026.1702013284819/8.0), + REAL_CONST(2035.1206983489212/8.0), + REAL_CONST(2044.0810473337688/8.0), + REAL_CONST(2053.0512266659125/8.0), + REAL_CONST(2062.0312148464309/8.0), + REAL_CONST(2071.0209904935646/8.0), + REAL_CONST(2080.0205323416958/8.0), + REAL_CONST(2089.0298192403443/8.0), + REAL_CONST(2098.0488301531714/8.0), + REAL_CONST(2107.0775441569995/8.0), + REAL_CONST(2116.115940440839/8.0), + REAL_CONST(2125.1639983049317/8.0), + REAL_CONST(2134.2216971597995/8.0), + REAL_CONST(2143.2890165253098/8.0), + REAL_CONST(2152.3659360297484/8.0), + REAL_CONST(2161.4524354089031/8.0), + REAL_CONST(2170.5484945051617/8.0), + REAL_CONST(2179.6540932666144/8.0), + REAL_CONST(2188.7692117461711/8.0), + REAL_CONST(2197.8938301006888/8.0), + REAL_CONST(2207.0279285901042/8.0), + REAL_CONST(2216.1714875765838/8.0), + REAL_CONST(2225.324487523676/8.0), + REAL_CONST(2234.4869089954782/8.0), + REAL_CONST(2243.6587326558101/8.0), + REAL_CONST(2252.8399392673982/8.0), + REAL_CONST(2262.0305096910702/8.0), + REAL_CONST(2271.2304248849537/8.0), + REAL_CONST(2280.4396659036897/8.0), + REAL_CONST(2289.6582138976523/8.0), + REAL_CONST(2298.8860501121762/8.0), + REAL_CONST(2308.1231558867926/8.0), + REAL_CONST(2317.3695126544767/8.0), + REAL_CONST(2326.6251019409005/8.0), + REAL_CONST(2335.8899053636933/8.0), + REAL_CONST(2345.1639046317132/8.0), + REAL_CONST(2354.4470815443233/8.0), + REAL_CONST(2363.7394179906792/8.0), + REAL_CONST(2373.0408959490205/8.0), + REAL_CONST(2382.3514974859731/8.0), + REAL_CONST(2391.6712047558558/8.0), + REAL_CONST(2400.9999999999991/8.0), + REAL_CONST(2410.3378655460651/8.0), + REAL_CONST(2419.6847838073813/8.0), + REAL_CONST(2429.0407372822747/8.0), + REAL_CONST(2438.4057085534191/8.0), + REAL_CONST(2447.7796802871858/8.0), + REAL_CONST(2457.1626352330004/8.0), + REAL_CONST(2466.5545562227112/8.0), + REAL_CONST(2475.9554261699564/8.0), + REAL_CONST(2485.3652280695474/8.0), + REAL_CONST(2494.7839449968492/8.0), + REAL_CONST(2504.2115601071737/8.0), + REAL_CONST(2513.6480566351788/8.0), + REAL_CONST(2523.0934178942675/8.0), + REAL_CONST(2532.5476272760025/8.0), + REAL_CONST(2542.0106682495189/8.0), + REAL_CONST(2551.482524360948/8.0), + REAL_CONST(2560.9631792328441/8.0), + REAL_CONST(2570.4526165636184/8.0), + REAL_CONST(2579.9508201269791/8.0), + REAL_CONST(2589.4577737713744/8.0), + REAL_CONST(2598.9734614194458/8.0), + REAL_CONST(2608.4978670674823/8.0), + REAL_CONST(2618.0309747848837/8.0), + REAL_CONST(2627.5727687136259/8.0), + REAL_CONST(2637.1232330677353/8.0), + REAL_CONST(2646.6823521327647/8.0), + REAL_CONST(2656.2501102652768/8.0), + REAL_CONST(2665.8264918923328/8.0), + REAL_CONST(2675.4114815109842/8.0), + REAL_CONST(2685.0050636877722/8.0), + REAL_CONST(2694.6072230582295/8.0), + REAL_CONST(2704.2179443263894/8.0), + REAL_CONST(2713.8372122642972/8.0), + REAL_CONST(2723.4650117115279/8.0), + REAL_CONST(2733.1013275747096/8.0), + REAL_CONST(2742.7461448270483/8.0), + REAL_CONST(2752.3994485078601/8.0), + REAL_CONST(2762.0612237221085/8.0), + REAL_CONST(2771.7314556399419/8.0), + REAL_CONST(2781.4101294962406/8.0), + REAL_CONST(2791.0972305901655/8.0), + REAL_CONST(2800.7927442847094/8.0), + REAL_CONST(2810.4966560062589/8.0), + REAL_CONST(2820.2089512441521/8.0), + REAL_CONST(2829.9296155502466/8.0), + REAL_CONST(2839.6586345384894/8.0), + REAL_CONST(2849.3959938844923/8.0), + REAL_CONST(2859.1416793251065/8.0), + REAL_CONST(2868.8956766580086/8.0), + REAL_CONST(2878.6579717412847/8.0), + REAL_CONST(2888.4285504930212/8.0), + REAL_CONST(2898.2073988908974/8.0), + REAL_CONST(2907.9945029717837/8.0), + REAL_CONST(2917.789848831344/8.0), + REAL_CONST(2927.5934226236377/8.0), + REAL_CONST(2937.4052105607311/8.0), + REAL_CONST(2947.2251989123079/8.0), + REAL_CONST(2957.0533740052865/8.0), + REAL_CONST(2966.8897222234368/8.0), + REAL_CONST(2976.734230007005/8.0), + REAL_CONST(2986.5868838523397/8.0), + REAL_CONST(2996.4476703115197/8.0), + REAL_CONST(3006.3165759919889/8.0), + REAL_CONST(3016.1935875561908/8.0), + REAL_CONST(3026.0786917212095/8.0), + REAL_CONST(3035.9718752584108/8.0), + REAL_CONST(3045.8731249930906/8.0), + REAL_CONST(3055.7824278041207/8.0), + REAL_CONST(3065.6997706236039/8.0), + REAL_CONST(3075.625140436528/8.0), + REAL_CONST(3085.5585242804245/8.0), + REAL_CONST(3095.4999092450298/8.0), + REAL_CONST(3105.4492824719491/8.0), + REAL_CONST(3115.4066311543256/8.0), + REAL_CONST(3125.3719425365089/8.0), + REAL_CONST(3135.3452039137287/8.0), + REAL_CONST(3145.3264026317715/8.0), + REAL_CONST(3155.3155260866592/8.0), + REAL_CONST(3165.3125617243295/8.0), + REAL_CONST(3175.3174970403229/8.0), + REAL_CONST(3185.3303195794679/8.0), + REAL_CONST(3195.35101693557/8.0), + REAL_CONST(3205.3795767511078/8.0), + REAL_CONST(3215.4159867169251/8.0), + REAL_CONST(3225.460234571929/8.0), + REAL_CONST(3235.5123081027928/8.0), + REAL_CONST(3245.5721951436558/8.0), + REAL_CONST(3255.63988357583/8.0), + REAL_CONST(3265.7153613275095/8.0), + REAL_CONST(3275.7986163734795/8.0), + REAL_CONST(3285.8896367348289/8.0), + REAL_CONST(3295.9884104786665/8.0), + REAL_CONST(3306.0949257178395/8.0), + REAL_CONST(3316.2091706106517/8.0), + REAL_CONST(3326.331133360588/8.0), + REAL_CONST(3336.4608022160378/8.0), + REAL_CONST(3346.5981654700231/8.0), + REAL_CONST(3356.7432114599264/8.0), + REAL_CONST(3366.8959285672249/8.0), + REAL_CONST(3377.0563052172211/8.0), + REAL_CONST(3387.2243298787821/8.0), + REAL_CONST(3397.3999910640764/8.0), + REAL_CONST(3407.5832773283128/8.0), + REAL_CONST(3417.7741772694862/8.0), + REAL_CONST(3427.9726795281199/8.0), + REAL_CONST(3438.1787727870123/8.0), + REAL_CONST(3448.3924457709873/8.0), + REAL_CONST(3458.6136872466445/8.0), + REAL_CONST(3468.8424860221107/8.0), + REAL_CONST(3479.0788309467976/8.0), + REAL_CONST(3489.3227109111554/8.0), + REAL_CONST(3499.5741148464344/8.0), + REAL_CONST(3509.8330317244445/8.0), + REAL_CONST(3520.0994505573185/8.0), + REAL_CONST(3530.3733603972751/8.0), + REAL_CONST(3540.6547503363886/8.0), + REAL_CONST(3550.9436095063534/8.0), + REAL_CONST(3561.239927078258/8.0), + REAL_CONST(3571.5436922623535/8.0), + REAL_CONST(3581.8548943078308/8.0), + REAL_CONST(3592.1735225025936/8.0), + REAL_CONST(3602.4995661730372/8.0), + REAL_CONST(3612.8330146838275/8.0), + REAL_CONST(3623.1738574376814/8.0), + REAL_CONST(3633.5220838751502/8.0), + REAL_CONST(3643.8776834744031/8.0), + REAL_CONST(3654.2406457510142/8.0), + REAL_CONST(3664.6109602577494/8.0), + REAL_CONST(3674.9886165843564/8.0), + REAL_CONST(3685.3736043573545/8.0), + REAL_CONST(3695.7659132398294/8.0), + REAL_CONST(3706.1655329312248/8.0), + REAL_CONST(3716.5724531671399/8.0), + REAL_CONST(3726.9866637191262/8.0), + REAL_CONST(3737.4081543944876/8.0), + REAL_CONST(3747.8369150360782/8.0), + REAL_CONST(3758.2729355221072/8.0), + REAL_CONST(3768.7162057659411/8.0), + REAL_CONST(3779.1667157159077/8.0), + REAL_CONST(3789.6244553551055/8.0), + REAL_CONST(3800.0894147012082/8.0), + REAL_CONST(3810.5615838062768/8.0), + REAL_CONST(3821.0409527565694/8.0), + REAL_CONST(3831.5275116723533/8.0), + REAL_CONST(3842.0212507077194/8.0), + REAL_CONST(3852.522160050396/8.0), + REAL_CONST(3863.0302299215673/8.0), + REAL_CONST(3873.5454505756893/8.0), + REAL_CONST(3884.0678123003108/8.0), + REAL_CONST(3894.5973054158922/8.0), + REAL_CONST(3905.1339202756285/8.0), + REAL_CONST(3915.6776472652732/8.0), + REAL_CONST(3926.2284768029604/8.0), + REAL_CONST(3936.7863993390338/8.0), + REAL_CONST(3947.3514053558706/8.0), + REAL_CONST(3957.9234853677135/8.0), + REAL_CONST(3968.5026299204969/8.0), + REAL_CONST(3979.0888295916798/8.0), + REAL_CONST(3989.6820749900776/8.0), + REAL_CONST(4000.2823567556948/8.0), + REAL_CONST(4010.8896655595613/8.0), + REAL_CONST(4021.5039921035655/8.0), + REAL_CONST(4032.1253271202945/8.0), + REAL_CONST(4042.7536613728694/8.0), + REAL_CONST(4053.3889856547858/8.0), + REAL_CONST(4064.0312907897551/8.0), + REAL_CONST(4074.6805676315448/8.0), + REAL_CONST(4085.3368070638221/8.0), + REAL_CONST(4095.9999999999982/8.0), + REAL_CONST(4106.6701373830711/8.0), + REAL_CONST(4117.347210185475/8.0), + REAL_CONST(4128.0312094089259/8.0), + REAL_CONST(4138.722126084268/8.0), + REAL_CONST(4149.4199512713267/8.0), + REAL_CONST(4160.1246760587583/8.0), + REAL_CONST(4170.8362915638982/8.0), + REAL_CONST(4181.5547889326181/8.0), + REAL_CONST(4192.2801593391769/8.0), + REAL_CONST(4203.0123939860741/8.0), + REAL_CONST(4213.7514841039101/8.0), + REAL_CONST(4224.4974209512384/8.0), + REAL_CONST(4235.2501958144258/8.0), + REAL_CONST(4246.0098000075095/8.0), + REAL_CONST(4256.7762248720574/8.0), + REAL_CONST(4267.549461777031/8.0), + REAL_CONST(4278.3295021186423/8.0), + REAL_CONST(4289.1163373202198/8.0), + REAL_CONST(4299.9099588320714/8.0), + REAL_CONST(4310.7103581313495/8.0), + REAL_CONST(4321.5175267219138/8.0), + REAL_CONST(4332.3314561342004/8.0), + REAL_CONST(4343.152137925088/8.0), + REAL_CONST(4353.9795636777671/8.0), + REAL_CONST(4364.8137250016052/8.0), + REAL_CONST(4375.6546135320223/8.0), + REAL_CONST(4386.5022209303588/8.0), + REAL_CONST(4397.3565388837469/8.0), + REAL_CONST(4408.2175591049827/8.0), + REAL_CONST(4419.0852733324018/8.0), + REAL_CONST(4429.9596733297531/8.0), + REAL_CONST(4440.8407508860728/8.0), + REAL_CONST(4451.7284978155603/8.0), + REAL_CONST(4462.6229059574571/8.0), + REAL_CONST(4473.5239671759227/8.0), + REAL_CONST(4484.4316733599126/8.0), + REAL_CONST(4495.3460164230582/8.0), + REAL_CONST(4506.2669883035496/8.0), + REAL_CONST(4517.1945809640119/8.0), + REAL_CONST(4528.1287863913894/8.0), + REAL_CONST(4539.069596596828/8.0), + REAL_CONST(4550.0170036155587/8.0), + REAL_CONST(4560.9709995067806/8.0), + REAL_CONST(4571.931576353546/8.0), + REAL_CONST(4582.898726262647/8.0), + REAL_CONST(4593.8724413645004/8.0), + REAL_CONST(4604.8527138130348/8.0), + REAL_CONST(4615.8395357855816/8.0), + REAL_CONST(4626.8328994827571/8.0), + REAL_CONST(4637.8327971283588/8.0), + REAL_CONST(4648.8392209692511/8.0), + REAL_CONST(4659.8521632752563/8.0), + REAL_CONST(4670.8716163390473/8.0), + REAL_CONST(4681.8975724760394/8.0), + REAL_CONST(4692.9300240242837/8.0), + REAL_CONST(4703.9689633443595/8.0), + REAL_CONST(4715.0143828192668/8.0), + REAL_CONST(4726.0662748543255/8.0), + REAL_CONST(4737.1246318770682/8.0), + REAL_CONST(4748.1894463371373/8.0), + REAL_CONST(4759.2607107061804/8.0), + REAL_CONST(4770.3384174777493/8.0), + REAL_CONST(4781.4225591671993/8.0), + REAL_CONST(4792.5131283115852/8.0), + REAL_CONST(4803.6101174695614/8.0), + REAL_CONST(4814.7135192212854/8.0), + REAL_CONST(4825.8233261683154/8.0), + REAL_CONST(4836.9395309335096/8.0), + REAL_CONST(4848.0621261609349/8.0), + REAL_CONST(4859.1911045157631/8.0), + REAL_CONST(4870.3264586841779/8.0), + REAL_CONST(4881.4681813732768/8.0), + REAL_CONST(4892.6162653109768/8.0), + REAL_CONST(4903.7707032459193/8.0), + REAL_CONST(4914.931487947375/8.0), + REAL_CONST(4926.0986122051509/8.0), + REAL_CONST(4937.2720688294967/8.0), + REAL_CONST(4948.4518506510112/8.0), + REAL_CONST(4959.637950520555/8.0), + REAL_CONST(4970.8303613091521/8.0), + REAL_CONST(4982.0290759079044/8.0), + REAL_CONST(4993.2340872278974/8.0), + REAL_CONST(5004.4453882001153/8.0), + REAL_CONST(5015.6629717753467/8.0), + REAL_CONST(5026.8868309241007/8.0), + REAL_CONST(5038.1169586365131/8.0), + REAL_CONST(5049.353347922266/8.0), + REAL_CONST(5060.5959918104927/8.0), + REAL_CONST(5071.8448833496996/8.0), + REAL_CONST(5083.1000156076734/8.0), + REAL_CONST(5094.3613816713996/8.0), + REAL_CONST(5105.6289746469747/8.0), + REAL_CONST(5116.9027876595246/8.0), + REAL_CONST(5128.18281385312/8.0), + REAL_CONST(5139.4690463906918/8.0), + REAL_CONST(5150.7614784539473/8.0), + REAL_CONST(5162.0601032432933/8.0), + REAL_CONST(5173.3649139777472/8.0), + REAL_CONST(5184.6759038948594/8.0), + REAL_CONST(5195.9930662506322/8.0), + REAL_CONST(5207.3163943194386/8.0), + REAL_CONST(5218.6458813939435/8.0), + REAL_CONST(5229.9815207850224/8.0), + REAL_CONST(5241.3233058216847/8.0), + REAL_CONST(5252.6712298509919/8.0), + REAL_CONST(5264.025286237983/8.0), + REAL_CONST(5275.3854683655954/8.0), + REAL_CONST(5286.7517696345885/8.0), + REAL_CONST(5298.1241834634639/8.0), + REAL_CONST(5309.5027032883945/8.0), + REAL_CONST(5320.887322563146/8.0), + REAL_CONST(5332.2780347589978/8.0), + REAL_CONST(5343.6748333646756/8.0), + REAL_CONST(5355.0777118862716/8.0), + REAL_CONST(5366.4866638471722/8.0), + REAL_CONST(5377.901682787985/8.0), + REAL_CONST(5389.3227622664635/8.0), + REAL_CONST(5400.749895857437/8.0), + REAL_CONST(5412.1830771527357/8.0), + REAL_CONST(5423.622299761123/8.0), + REAL_CONST(5435.067557308219/8.0), + REAL_CONST(5446.5188434364318/8.0), + REAL_CONST(5457.9761518048872/8.0), + REAL_CONST(5469.4394760893592/8.0), + REAL_CONST(5480.9088099821975/8.0), + REAL_CONST(5492.3841471922606/8.0), + REAL_CONST(5503.8654814448455/8.0), + REAL_CONST(5515.3528064816201/8.0), + REAL_CONST(5526.846116060552/8.0), + REAL_CONST(5538.3454039558474/8.0), + REAL_CONST(5549.8506639578736/8.0), + REAL_CONST(5561.3618898731029/8.0), + REAL_CONST(5572.8790755240361/8.0), + REAL_CONST(5584.4022147491451/8.0), + REAL_CONST(5595.9313014027975/8.0), + REAL_CONST(5607.4663293552012/8.0), + REAL_CONST(5619.0072924923297/8.0), + REAL_CONST(5630.5541847158656/8.0), + REAL_CONST(5642.1069999431284/8.0), + REAL_CONST(5653.665732107017/8.0), + REAL_CONST(5665.230375155943/8.0), + REAL_CONST(5676.8009230537655/8.0), + REAL_CONST(5688.3773697797333/8.0), + REAL_CONST(5699.9597093284156/8.0), + REAL_CONST(5711.5479357096474/8.0), + REAL_CONST(5723.1420429484588/8.0), + REAL_CONST(5734.7420250850209/8.0), + REAL_CONST(5746.347876174581/8.0), + REAL_CONST(5757.9595902874016/8.0), + REAL_CONST(5769.5771615087006/8.0), + REAL_CONST(5781.2005839385911/8.0), + REAL_CONST(5792.8298516920213/8.0), + REAL_CONST(5804.4649588987149/8.0), + REAL_CONST(5816.1058997031105/8.0), + REAL_CONST(5827.7526682643065/8.0), + REAL_CONST(5839.4052587559972/8.0), + REAL_CONST(5851.0636653664196/8.0), + REAL_CONST(5862.7278822982908/8.0), + REAL_CONST(5874.3979037687541/8.0), + REAL_CONST(5886.0737240093204/8.0), + REAL_CONST(5897.7553372658094/8.0), + REAL_CONST(5909.4427377982956/8.0), + REAL_CONST(5921.1359198810505/8.0), + REAL_CONST(5932.8348778024874/8.0), + REAL_CONST(5944.5396058651031/8.0), + REAL_CONST(5956.2500983854261/8.0), + REAL_CONST(5967.9663496939575/8.0), + REAL_CONST(5979.6883541351208/8.0), + REAL_CONST(5991.4161060672022/8.0), + REAL_CONST(6003.1495998623004/8.0), + REAL_CONST(6014.8888299062692/8.0), + REAL_CONST(6026.6337905986684/8.0), + REAL_CONST(6038.3844763527022/8.0), + REAL_CONST(6050.1408815951781/8.0), + REAL_CONST(6061.9030007664414/8.0), + REAL_CONST(6073.6708283203316/8.0), + REAL_CONST(6085.4443587241267/8.0), + REAL_CONST(6097.2235864584891/8.0), + REAL_CONST(6109.0085060174197/8.0), + REAL_CONST(6120.7991119081998/8.0), + REAL_CONST(6132.595398651345/8.0), + REAL_CONST(6144.3973607805519/8.0), + REAL_CONST(6156.2049928426459/8.0), + REAL_CONST(6168.0182893975361/8.0), + REAL_CONST(6179.8372450181578/8.0), + REAL_CONST(6191.6618542904307/8.0), + REAL_CONST(6203.4921118132024/8.0), + REAL_CONST(6215.3280121982016/8.0), + REAL_CONST(6227.1695500699925/8.0), + REAL_CONST(6239.0167200659189/8.0), + REAL_CONST(6250.8695168360628/8.0), + REAL_CONST(6262.7279350431891/8.0), + REAL_CONST(6274.5919693627056/8.0), + REAL_CONST(6286.4616144826068/8.0), + REAL_CONST(6298.3368651034316/8.0), + REAL_CONST(6310.2177159382172/8.0), + REAL_CONST(6322.1041617124456/8.0), + REAL_CONST(6333.9961971640032/8.0), + REAL_CONST(6345.8938170431311/8.0), + REAL_CONST(6357.7970161123785/8.0), + REAL_CONST(6369.7057891465583/8.0), + REAL_CONST(6381.6201309327007/8.0), + REAL_CONST(6393.5400362700075/8.0), + REAL_CONST(6405.4654999698032/8.0), + REAL_CONST(6417.3965168554978/8.0), + REAL_CONST(6429.3330817625329/8.0), + REAL_CONST(6441.2751895383453/8.0), + REAL_CONST(6453.2228350423138/8.0), + REAL_CONST(6465.176013145724/8.0), + REAL_CONST(6477.134718731716/8.0), + REAL_CONST(6489.0989466952469/8.0), + REAL_CONST(6501.0686919430445/8.0), + REAL_CONST(6513.0439493935628/8.0), + REAL_CONST(6525.0247139769417/8.0), + REAL_CONST(6537.010980634961/8.0), + REAL_CONST(6549.002744321001/8.0), + REAL_CONST(6560.9999999999973/8.0), + REAL_CONST(6573.0027426483985/8.0), + REAL_CONST(6585.0109672541284/8.0), + REAL_CONST(6597.0246688165371/8.0), + REAL_CONST(6609.0438423463656/8.0), + REAL_CONST(6621.0684828657004/8.0), + REAL_CONST(6633.0985854079354/8.0), + REAL_CONST(6645.134145017727/8.0), + REAL_CONST(6657.1751567509573/8.0), + REAL_CONST(6669.2216156746908/8.0), + REAL_CONST(6681.2735168671343/8.0), + REAL_CONST(6693.3308554176001/8.0), + REAL_CONST(6705.3936264264594/8.0), + REAL_CONST(6717.461825005108/8.0), + REAL_CONST(6729.535446275926/8.0), + REAL_CONST(6741.6144853722335/8.0), + REAL_CONST(6753.6989374382601/8.0), + REAL_CONST(6765.7887976290967/8.0), + REAL_CONST(6777.8840611106634/8.0), + REAL_CONST(6789.9847230596661/8.0), + REAL_CONST(6802.0907786635626/8.0), + REAL_CONST(6814.2022231205201/8.0), + REAL_CONST(6826.3190516393797/8.0), + REAL_CONST(6838.4412594396181/8.0), + REAL_CONST(6850.5688417513074/8.0), + REAL_CONST(6862.701793815083/8.0), + REAL_CONST(6874.840110882099/8.0), + REAL_CONST(6886.9837882139991/8.0), + REAL_CONST(6899.1328210828724/8.0), + REAL_CONST(6911.2872047712199/8.0), + REAL_CONST(6923.4469345719199/8.0), + REAL_CONST(6935.6120057881863/8.0), + REAL_CONST(6947.7824137335365/8.0), + REAL_CONST(6959.9581537317536/8.0), + REAL_CONST(6972.1392211168532/8.0), + REAL_CONST(6984.3256112330409/8.0), + REAL_CONST(6996.5173194346862/8.0), + REAL_CONST(7008.7143410862773/8.0), + REAL_CONST(7020.9166715623942/8.0), + REAL_CONST(7033.1243062476678/8.0), + REAL_CONST(7045.3372405367481/8.0), + REAL_CONST(7057.5554698342685/8.0), + REAL_CONST(7069.7789895548103/8.0), + REAL_CONST(7082.0077951228714/8.0), + REAL_CONST(7094.2418819728273/8.0), + REAL_CONST(7106.4812455489018/8.0), + REAL_CONST(7118.7258813051285/8.0), + REAL_CONST(7130.9757847053224/8.0), + REAL_CONST(7143.2309512230404/8.0), + REAL_CONST(7155.4913763415516/8.0), + REAL_CONST(7167.7570555538041/8.0), + REAL_CONST(7180.0279843623894/8.0), + REAL_CONST(7192.3041582795131/8.0), + REAL_CONST(7204.5855728269571/8.0), + REAL_CONST(7216.8722235360519/8.0), + REAL_CONST(7229.1641059476406/8.0), + REAL_CONST(7241.4612156120484/8.0), + REAL_CONST(7253.7635480890503/8.0), + REAL_CONST(7266.0710989478375/8.0), + REAL_CONST(7278.3838637669869/8.0), + REAL_CONST(7290.7018381344296/8.0), + REAL_CONST(7303.0250176474174/8.0), + REAL_CONST(7315.3533979124932/8.0), + REAL_CONST(7327.6869745454596/8.0), + REAL_CONST(7340.0257431713462/8.0), + REAL_CONST(7352.3696994243801/8.0), + REAL_CONST(7364.7188389479543/8.0), + REAL_CONST(7377.0731573945968/8.0), + REAL_CONST(7389.4326504259407/8.0), + REAL_CONST(7401.7973137126937/8.0), + REAL_CONST(7414.1671429346061/8.0), + REAL_CONST(7426.5421337804428/8.0), + REAL_CONST(7438.922281947951/8.0), + REAL_CONST(7451.3075831438346/8.0), + REAL_CONST(7463.6980330837177/8.0), + REAL_CONST(7476.0936274921214/8.0), + REAL_CONST(7488.4943621024304/8.0), + REAL_CONST(7500.9002326568652/8.0), + REAL_CONST(7513.3112349064522/8.0), + REAL_CONST(7525.7273646109943/8.0), + REAL_CONST(7538.1486175390446/8.0), + REAL_CONST(7550.5749894678729/8.0), + REAL_CONST(7563.0064761834419/8.0), + REAL_CONST(7575.4430734803736/8.0), + REAL_CONST(7587.8847771619248/8.0), + REAL_CONST(7600.3315830399597/8.0), + REAL_CONST(7612.7834869349153/8.0), + REAL_CONST(7625.24048467578/8.0), + REAL_CONST(7637.7025721000637/8.0), + REAL_CONST(7650.1697450537677/8.0), + REAL_CONST(7662.6419993913596/8.0), + REAL_CONST(7675.1193309757446/8.0), + REAL_CONST(7687.6017356782404/8.0), + REAL_CONST(7700.0892093785433/8.0), + REAL_CONST(7712.5817479647112/8.0), + REAL_CONST(7725.079347333125/8.0), + REAL_CONST(7737.5820033884729/8.0), + REAL_CONST(7750.0897120437139/8.0), + REAL_CONST(7762.6024692200581/8.0), + REAL_CONST(7775.1202708469355/8.0), + REAL_CONST(7787.6431128619733/8.0), + REAL_CONST(7800.1709912109645/8.0), + REAL_CONST(7812.7039018478481/8.0), + REAL_CONST(7825.2418407346768/8.0), + REAL_CONST(7837.7848038415968/8.0), + REAL_CONST(7850.3327871468155/8.0), + REAL_CONST(7862.8857866365806/8.0), + REAL_CONST(7875.4437983051539/8.0), + REAL_CONST(7888.006818154784/8.0), + REAL_CONST(7900.5748421956796/8.0), + REAL_CONST(7913.1478664459901/8.0), + REAL_CONST(7925.725886931772/8.0), + REAL_CONST(7938.3088996869719/8.0), + REAL_CONST(7950.8969007533951/8.0), + REAL_CONST(7963.4898861806851/8.0), + REAL_CONST(7976.0878520262959/8.0), + REAL_CONST(7988.6907943554688/8.0), + REAL_CONST(8001.2987092412086/8.0), + REAL_CONST(8013.911592764257/8.0), + REAL_CONST(8026.5294410130691/8.0), + REAL_CONST(8039.1522500837891/8.0), + REAL_CONST(8051.7800160802271/8.0), + REAL_CONST(8064.412735113835/8.0), + REAL_CONST(8077.0504033036796/8.0), + REAL_CONST(8089.6930167764222/8.0), + REAL_CONST(8102.3405716662946/8.0), + REAL_CONST(8114.9930641150731/8.0), + REAL_CONST(8127.6504902720571/8.0), + REAL_CONST(8140.3128462940449/8.0), + REAL_CONST(8152.9801283453098/8.0), + REAL_CONST(8165.6523325975786/8.0), + REAL_CONST(8178.3294552300049/8.0), + REAL_CONST(8191.0114924291529/8.0), + REAL_CONST(8203.6984403889655/8.0), + REAL_CONST(8216.3902953107463/8.0), + REAL_CONST(8229.0870534031419/8.0), + REAL_CONST(8241.7887108821069/8.0), + REAL_CONST(8254.4952639708936/8.0), + REAL_CONST(8267.2067089000211/8.0), + REAL_CONST(8279.9230419072574/8.0), + REAL_CONST(8292.6442592375952/8.0), + REAL_CONST(8305.3703571432306/8.0), + REAL_CONST(8318.101331883543/8.0), + REAL_CONST(8330.8371797250657/8.0), + REAL_CONST(8343.577896941475/8.0), + REAL_CONST(8356.3234798135582/8.0), + REAL_CONST(8369.0739246291978/8.0), + REAL_CONST(8381.8292276833508/8.0), + REAL_CONST(8394.5893852780209/8.0), + REAL_CONST(8407.3543937222421/8.0), + REAL_CONST(8420.1242493320569/8.0), + REAL_CONST(8432.8989484304948/8.0), + REAL_CONST(8445.6784873475499/8.0), + REAL_CONST(8458.4628624201578/8.0), + REAL_CONST(8471.2520699921806/8.0), + REAL_CONST(8484.0461064143838/8.0), + REAL_CONST(8496.8449680444082/8.0), + REAL_CONST(8509.6486512467636/8.0), + REAL_CONST(8522.4571523927953/8.0), + REAL_CONST(8535.270467860666/8.0), + REAL_CONST(8548.0885940353437/8.0), + REAL_CONST(8560.9115273085663/8.0), + REAL_CONST(8573.7392640788403/8.0), + REAL_CONST(8586.5718007514006/8.0), + REAL_CONST(8599.4091337382069/8.0), + REAL_CONST(8612.2512594579148/8.0), + REAL_CONST(8625.0981743358552/8.0), + REAL_CONST(8637.9498748040205/8.0), + REAL_CONST(8650.8063573010386/8.0), + REAL_CONST(8663.6676182721567/8.0), + REAL_CONST(8676.533654169225/8.0), + REAL_CONST(8689.4044614506638/8.0), + REAL_CONST(8702.2800365814601/8.0), + REAL_CONST(8715.1603760331418/8.0), + REAL_CONST(8728.0454762837508/8.0), + REAL_CONST(8740.9353338178389/8.0), + REAL_CONST(8753.8299451264356/8.0), + REAL_CONST(8766.7293067070332/8.0), + REAL_CONST(8779.6334150635721/8.0), + REAL_CONST(8792.5422667064158/8.0), + REAL_CONST(8805.4558581523324/8.0), + REAL_CONST(8818.3741859244819/8.0), + REAL_CONST(8831.2972465523908/8.0), + REAL_CONST(8844.2250365719356/8.0), + REAL_CONST(8857.1575525253265/8.0), + REAL_CONST(8870.0947909610859/8.0), + REAL_CONST(8883.0367484340295/8.0), + REAL_CONST(8895.9834215052524/8.0), + REAL_CONST(8908.934806742107/8.0), + REAL_CONST(8921.8909007181846/8.0), + REAL_CONST(8934.8517000132997/8.0), + REAL_CONST(8947.817201213471/8.0), + REAL_CONST(8960.7874009109/8.0), + REAL_CONST(8973.7622957039603/8.0), + REAL_CONST(8986.7418821971733/8.0), + REAL_CONST(8999.7261570011924/8.0), + REAL_CONST(9012.7151167327884/8.0), + REAL_CONST(9025.7087580148236/8.0), + REAL_CONST(9038.7070774762469/8.0), + REAL_CONST(9051.7100717520643/8.0), + REAL_CONST(9064.7177374833282/8.0), + REAL_CONST(9077.7300713171153/8.0), + REAL_CONST(9090.7470699065179/8.0), + REAL_CONST(9103.7687299106146/8.0), + REAL_CONST(9116.7950479944648/8.0), + REAL_CONST(9129.8260208290812/8.0), + REAL_CONST(9142.8616450914233/8.0), + REAL_CONST(9155.9019174643727/8.0), + REAL_CONST(9168.9468346367157/8.0), + REAL_CONST(9181.9963933031358/8.0), + REAL_CONST(9195.0505901641845/8.0), + REAL_CONST(9208.1094219262741/8.0), + REAL_CONST(9221.1728853016557/8.0), + REAL_CONST(9234.240977008405/8.0), + REAL_CONST(9247.3136937704076/8.0), + REAL_CONST(9260.3910323173386/8.0), + REAL_CONST(9273.472989384647/8.0), + REAL_CONST(9286.5595617135423/8.0), + REAL_CONST(9299.6507460509747/8.0), + REAL_CONST(9312.7465391496207/8.0), + REAL_CONST(9325.8469377678684/8.0), + REAL_CONST(9338.9519386698012/8.0), + REAL_CONST(9352.0615386251757/8.0), + REAL_CONST(9365.1757344094131/8.0), + REAL_CONST(9378.2945228035842/8.0), + REAL_CONST(9391.4179005943843/8.0), + REAL_CONST(9404.5458645741273/8.0), + REAL_CONST(9417.6784115407263/8.0), + REAL_CONST(9430.8155382976747/8.0), + REAL_CONST(9443.9572416540359/8.0), + REAL_CONST(9457.1035184244265/8.0), + REAL_CONST(9470.2543654290002/8.0), + REAL_CONST(9483.4097794934296/8.0), + REAL_CONST(9496.5697574488931/8.0), + REAL_CONST(9509.7342961320664/8.0), + REAL_CONST(9522.9033923850911/8.0), + REAL_CONST(9536.0770430555804/8.0), + REAL_CONST(9549.2552449965824/8.0), + REAL_CONST(9562.4379950665825/8.0), + REAL_CONST(9575.6252901294793/8.0), + REAL_CONST(9588.8171270545736/8.0), + REAL_CONST(9602.0135027165488/8.0), + REAL_CONST(9615.2144139954635/8.0), + REAL_CONST(9628.4198577767274/8.0), + REAL_CONST(9641.629830951093/8.0), + REAL_CONST(9654.844330414644/8.0), + REAL_CONST(9668.0633530687719/8.0), + REAL_CONST(9681.286895820167/8.0), + REAL_CONST(9694.5149555808002/8.0), + REAL_CONST(9707.7475292679192/8.0), + REAL_CONST(9720.9846138040157/8.0), + REAL_CONST(9734.2262061168276/8.0), + REAL_CONST(9747.4723031393187/8.0), + REAL_CONST(9760.7229018096641/8.0), + REAL_CONST(9773.9779990712323/8.0), + REAL_CONST(9787.2375918725811/8.0), + REAL_CONST(9800.5016771674327/8.0), + REAL_CONST(9813.7702519146696/8.0), + REAL_CONST(9827.0433130783094/8.0), + REAL_CONST(9840.3208576275028/8.0), + REAL_CONST(9853.602882536512/8.0), + REAL_CONST(9866.8893847846994/8.0), + REAL_CONST(9880.1803613565116/8.0), + REAL_CONST(9893.4758092414686/8.0), + REAL_CONST(9906.7757254341523/8.0), + REAL_CONST(9920.0801069341851/8.0), + REAL_CONST(9933.3889507462245/8.0), + REAL_CONST(9946.7022538799429/8.0), + REAL_CONST(9960.0200133500221/8.0), + REAL_CONST(9973.3422261761298/8.0), + REAL_CONST(9986.6688893829159/8.0), + REAL_CONST(9999.9999999999945/8.0), + REAL_CONST(10013.335555061929/8.0), + REAL_CONST(10026.675551608221/8.0), + REAL_CONST(10040.019986683301/8.0), + REAL_CONST(10053.368857336509/8.0), + REAL_CONST(10066.722160622081/8.0), + REAL_CONST(10080.079893599144/8.0), + REAL_CONST(10093.442053331697/8.0), + REAL_CONST(10106.808636888598/8.0), + REAL_CONST(10120.179641343551/8.0), + REAL_CONST(10133.555063775095/8.0), + REAL_CONST(10146.934901266595/8.0), + REAL_CONST(10160.31915090622/8.0), + REAL_CONST(10173.707809786936/8.0), + REAL_CONST(10187.100875006496/8.0), + REAL_CONST(10200.498343667417/8.0), + REAL_CONST(10213.900212876984/8.0), + REAL_CONST(10227.306479747222/8.0), + REAL_CONST(10240.717141394889/8.0), + REAL_CONST(10254.132194941467/8.0), + REAL_CONST(10267.551637513146/8.0), + REAL_CONST(10280.975466240814/8.0), + REAL_CONST(10294.40367826004/8.0), + REAL_CONST(10307.836270711066/8.0), + REAL_CONST(10321.273240738796/8.0), + REAL_CONST(10334.71458549278/8.0) }; #endif diff --git a/src/libfaad/is.c b/src/libfaad/is.c index 8a4d50b5c..3437d712a 100644 --- a/src/libfaad/is.c +++ b/src/libfaad/is.c @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: is.c,v 1.2 2002/12/16 19:00:26 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: is.c,v 1.3 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #include "common.h" @@ -70,8 +76,8 @@ void is_decode(ic_stream *ics, ic_stream *icsr, real_t *l_spec, real_t *r_spec, #ifndef FIXED_POINT scale = (real_t)pow(0.5, (0.25*icsr->scale_factors[g][sfb])); #else - exp = icsr->scale_factors[g][sfb] / 4; - frac = icsr->scale_factors[g][sfb] % 4; + exp = icsr->scale_factors[g][sfb] >> 2; + frac = icsr->scale_factors[g][sfb] & 3; #endif /* Scale from left to right channel, @@ -80,13 +86,13 @@ void is_decode(ic_stream *ics, ic_stream *icsr, real_t *l_spec, real_t *r_spec, { k = (group*nshort)+i; #ifndef FIXED_POINT - r_spec[k] = MUL(l_spec[k], scale); + r_spec[k] = MUL_R(l_spec[k], scale); #else if (exp < 0) r_spec[k] = l_spec[k] << -exp; else r_spec[k] = l_spec[k] >> exp; - r_spec[k] = MUL_R_C(r_spec[k], pow05_table[frac + 3]); + r_spec[k] = MUL_C(r_spec[k], pow05_table[frac + 3]); #endif if (is_intensity(icsr, g, sfb) != invert_intensity(ics, g, sfb)) r_spec[k] = -r_spec[k]; diff --git a/src/libfaad/is.h b/src/libfaad/is.h index 3233f5242..dfa963013 100644 --- a/src/libfaad/is.h +++ b/src/libfaad/is.h @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: is.h,v 1.2 2002/12/16 19:00:31 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: is.h,v 1.3 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #ifndef __IS_H__ diff --git a/src/libfaad/kbd_win.h b/src/libfaad/kbd_win.h index c08603167..c3a148522 100644 --- a/src/libfaad/kbd_win.h +++ b/src/libfaad/kbd_win.h @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: kbd_win.h,v 1.2 2002/12/16 19:00:31 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: kbd_win.h,v 1.3 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #ifndef __KBD_WIN_H__ @@ -26,4510 +32,2260 @@ extern "C" { #endif -#ifndef FIXED_POINT - #ifdef _MSC_VER #pragma warning(disable:4305) #pragma warning(disable:4244) #endif -real_t kbd_long_1024[] = -{ - 0.00029256153896361, - 0.00042998567353047, - 0.00054674074589540, - 0.00065482304299792, - 0.00075870195068747, - 0.00086059331713336, - 0.00096177541439010, - 0.0010630609410878, - 0.0011650036308132, - 0.0012680012194148, - 0.0013723517232956, - 0.0014782864109136, - 0.0015859901976719, - 0.0016956148252373, - 0.0018072876903517, - 0.0019211179405514, - 0.0020372007924215, - 0.0021556206591754, - 0.0022764534599614, - 0.0023997683540995, - 0.0025256290631156, - 0.0026540948920831, - 0.0027852215281403, - 0.0029190616715331, - 0.0030556655443223, - 0.0031950812943391, - 0.0033373553240392, - 0.0034825325586930, - 0.0036306566699199, - 0.0037817702604646, - 0.0039359150179719, - 0.0040931318437260, - 0.0042534609610026, - 0.0044169420066964, - 0.0045836141091341, - 0.0047535159544086, - 0.0049266858431214, - 0.0051031617390698, - 0.0052829813111335, - 0.0054661819693975, - 0.0056528008963682, - 0.0058428750739943, - 0.0060364413070882, - 0.0062335362436492, - 0.0064341963925079, - 0.0066384581386503, - 0.0068463577565218, - 0.0070579314215715, - 0.0072732152202559, - 0.0074922451586909, - 0.0077150571701162, - 0.0079416871213115, - 0.0081721708180857, - 0.0084065440099458, - 0.0086448423940363, - 0.0088871016184291, - 0.0091333572848345, - 0.0093836449507939, - 0.0096380001314086, - 0.0098964583006517, - 0.010159054892306, - 0.010425825300561, - 0.010696804880310, - 0.010972028947167, - 0.011251532777236, - 0.011535351606646, - 0.011823520630897, - 0.012116075003993, - 0.012413049837429, - 0.012714480198999, - 0.013020401111478, - 0.013330847551161, - 0.013645854446288, - 0.013965456675352, - 0.014289689065314, - 0.014618586389712, - 0.014952183366697, - 0.015290514656976, - 0.015633614861688, - 0.015981518520214, - 0.016334260107915, - 0.016691874033817, - 0.017054394638241, - 0.017421856190380, - 0.017794292885832, - 0.018171738844085, - 0.018554228105962, - 0.018941794631032, - 0.019334472294980, - 0.019732294886947, - 0.020135296106839, - 0.020543509562604, - 0.020956968767488, - 0.021375707137257, - 0.021799757987407, - 0.022229154530343, - 0.022663929872540, - 0.023104117011689, - 0.023549748833816, - 0.024000858110398, - 0.024457477495451, - 0.024919639522613, - 0.025387376602207, - 0.025860721018295, - 0.026339704925726, - 0.026824360347160, - 0.027314719170100, - 0.027810813143900, - 0.028312673876775, - 0.028820332832801, - 0.029333821328905, - 0.029853170531859, - 0.030378411455255, - 0.030909574956490, - 0.031446691733739, - 0.031989792322926, - 0.032538907094693, - 0.033094066251369, - 0.033655299823935, - 0.034222637668991, - 0.034796109465717, - 0.035375744712844, - 0.035961572725616, - 0.036553622632758, - 0.037151923373446, - 0.037756503694277, - 0.038367392146243, - 0.038984617081711, - 0.039608206651398, - 0.040238188801359, - 0.040874591269976, - 0.041517441584950, - 0.042166767060301, - 0.042822594793376, - 0.043484951661852, - 0.044153864320760, - 0.044829359199509, - 0.045511462498913, - 0.046200200188234, - 0.046895598002228, - 0.047597681438201, - 0.048306475753074, - 0.049022005960455, - 0.049744296827725, - 0.050473372873129, - 0.051209258362879, - 0.051951977308273, - 0.052701553462813, - 0.053458010319350, - 0.054221371107223, - 0.054991658789428, - 0.055768896059787, - 0.056553105340134, - 0.057344308777513, - 0.058142528241393, - 0.058947785320893, - 0.059760101322019, - 0.060579497264926, - 0.061405993881180, - 0.062239611611049, - 0.063080370600799, - 0.063928290700012, - 0.064783391458919, - 0.065645692125747, - 0.066515211644086, - 0.067391968650269, - 0.068275981470777, - 0.069167268119652, - 0.070065846295935, - 0.070971733381121, - 0.071884946436630, - 0.072805502201299, - 0.073733417088896, - 0.074668707185649, - 0.075611388247794, - 0.076561475699152, - 0.077518984628715, - 0.078483929788261, - 0.079456325589986, - 0.080436186104162, - 0.081423525056808, - 0.082418355827392, - 0.083420691446553, - 0.084430544593841, - 0.085447927595483, - 0.086472852422178, - 0.087505330686900, - 0.088545373642744, - 0.089592992180780, - 0.090648196827937, - 0.091710997744919, - 0.092781404724131, - 0.093859427187640, - 0.094945074185163, - 0.096038354392069, - 0.097139276107423, - 0.098247847252041, - 0.099364075366580, - 0.10048796760965, - 0.10161953075597, - 0.10275877119451, - 0.10390569492671, - 0.10506030756469, - 0.10622261432949, - 0.10739262004941, - 0.10857032915821, - 0.10975574569357, - 0.11094887329534, - 0.11214971520402, - 0.11335827425914, - 0.11457455289772, - 0.11579855315274, - 0.11703027665170, - 0.11826972461510, - 0.11951689785504, - 0.12077179677383, - 0.12203442136263, - 0.12330477120008, - 0.12458284545102, - 0.12586864286523, - 0.12716216177615, - 0.12846340009971, - 0.12977235533312, - 0.13108902455375, - 0.13241340441801, - 0.13374549116025, - 0.13508528059173, - 0.13643276809961, - 0.13778794864595, - 0.13915081676677, - 0.14052136657114, - 0.14189959174027, - 0.14328548552671, - 0.14467904075349, - 0.14608024981336, - 0.14748910466804, - 0.14890559684750, - 0.15032971744929, - 0.15176145713790, - 0.15320080614414, - 0.15464775426459, - 0.15610229086100, - 0.15756440485987, - 0.15903408475193, - 0.16051131859170, - 0.16199609399712, - 0.16348839814917, - 0.16498821779156, - 0.16649553923042, - 0.16801034833404, - 0.16953263053270, - 0.17106237081842, - 0.17259955374484, - 0.17414416342714, - 0.17569618354193, - 0.17725559732720, - 0.17882238758238, - 0.18039653666830, - 0.18197802650733, - 0.18356683858343, - 0.18516295394233, - 0.18676635319174, - 0.18837701650148, - 0.18999492360384, - 0.19162005379380, - 0.19325238592940, - 0.19489189843209, - 0.19653856928714, - 0.19819237604409, - 0.19985329581721, - 0.20152130528605, - 0.20319638069594, - 0.20487849785865, - 0.20656763215298, - 0.20826375852540, - 0.20996685149083, - 0.21167688513330, - 0.21339383310678, - 0.21511766863598, - 0.21684836451719, - 0.21858589311922, - 0.22033022638425, - 0.22208133582887, - 0.22383919254503, - 0.22560376720111, - 0.22737503004300, - 0.22915295089517, - 0.23093749916189, - 0.23272864382838, - 0.23452635346201, - 0.23633059621364, - 0.23814133981883, - 0.23995855159925, - 0.24178219846403, - 0.24361224691114, - 0.24544866302890, - 0.24729141249740, - 0.24914046059007, - 0.25099577217522, - 0.25285731171763, - 0.25472504328019, - 0.25659893052556, - 0.25847893671788, - 0.26036502472451, - 0.26225715701781, - 0.26415529567692, - 0.26605940238966, - 0.26796943845439, - 0.26988536478190, - 0.27180714189742, - 0.27373472994256, - 0.27566808867736, - 0.27760717748238, - 0.27955195536071, - 0.28150238094021, - 0.28345841247557, - 0.28542000785059, - 0.28738712458038, - 0.28935971981364, - 0.29133775033492, - 0.29332117256704, - 0.29530994257338, - 0.29730401606034, - 0.29930334837974, - 0.30130789453132, - 0.30331760916521, - 0.30533244658452, - 0.30735236074785, - 0.30937730527195, - 0.31140723343430, - 0.31344209817583, - 0.31548185210356, - 0.31752644749341, - 0.31957583629288, - 0.32162997012390, - 0.32368880028565, - 0.32575227775738, - 0.32782035320134, - 0.32989297696566, - 0.33197009908736, - 0.33405166929523, - 0.33613763701295, - 0.33822795136203, - 0.34032256116495, - 0.34242141494820, - 0.34452446094547, - 0.34663164710072, - 0.34874292107143, - 0.35085823023181, - 0.35297752167598, - 0.35510074222129, - 0.35722783841160, - 0.35935875652060, - 0.36149344255514, - 0.36363184225864, - 0.36577390111444, - 0.36791956434930, - 0.37006877693676, - 0.37222148360070, - 0.37437762881878, - 0.37653715682603, - 0.37870001161834, - 0.38086613695607, - 0.38303547636766, - 0.38520797315322, - 0.38738357038821, - 0.38956221092708, - 0.39174383740701, - 0.39392839225157, - 0.39611581767449, - 0.39830605568342, - 0.40049904808370, - 0.40269473648218, - 0.40489306229101, - 0.40709396673153, - 0.40929739083810, - 0.41150327546197, - 0.41371156127524, - 0.41592218877472, - 0.41813509828594, - 0.42035022996702, - 0.42256752381274, - 0.42478691965848, - 0.42700835718423, - 0.42923177591866, - 0.43145711524314, - 0.43368431439580, - 0.43591331247564, - 0.43814404844658, - 0.44037646114161, - 0.44261048926688, - 0.44484607140589, - 0.44708314602359, - 0.44932165147057, - 0.45156152598727, - 0.45380270770813, - 0.45604513466581, - 0.45828874479543, - 0.46053347593880, - 0.46277926584861, - 0.46502605219277, - 0.46727377255861, - 0.46952236445718, - 0.47177176532752, - 0.47402191254100, - 0.47627274340557, - 0.47852419517009, - 0.48077620502869, - 0.48302871012505, - 0.48528164755674, - 0.48753495437962, - 0.48978856761212, - 0.49204242423966, - 0.49429646121898, - 0.49655061548250, - 0.49880482394273, - 0.50105902349665, - 0.50331315103004, - 0.50556714342194, - 0.50782093754901, - 0.51007447028990, - 0.51232767852971, - 0.51458049916433, - 0.51683286910489, - 0.51908472528213, - 0.52133600465083, - 0.52358664419420, - 0.52583658092832, - 0.52808575190648, - 0.53033409422367, - 0.53258154502092, - 0.53482804148974, - 0.53707352087652, - 0.53931792048690, - 0.54156117769021, - 0.54380322992385, - 0.54604401469766, - 0.54828346959835, - 0.55052153229384, - 0.55275814053768, - 0.55499323217338, - 0.55722674513883, - 0.55945861747062, - 0.56168878730842, - 0.56391719289930, - 0.56614377260214, - 0.56836846489188, - 0.57059120836390, - 0.57281194173835, - 0.57503060386439, - 0.57724713372458, - 0.57946147043912, - 0.58167355327012, - 0.58388332162591, - 0.58609071506528, - 0.58829567330173, - 0.59049813620770, - 0.59269804381879, - 0.59489533633802, - 0.59708995413996, - 0.59928183777495, - 0.60147092797329, - 0.60365716564937, - 0.60584049190582, - 0.60802084803764, - 0.61019817553632, - 0.61237241609393, - 0.61454351160718, - 0.61671140418155, - 0.61887603613527, - 0.62103735000336, - 0.62319528854167, - 0.62534979473088, - 0.62750081178042, - 0.62964828313250, - 0.63179215246597, - 0.63393236370030, - 0.63606886099946, - 0.63820158877577, - 0.64033049169379, - 0.64245551467413, - 0.64457660289729, - 0.64669370180740, - 0.64880675711607, - 0.65091571480603, - 0.65302052113494, - 0.65512112263906, - 0.65721746613689, - 0.65930949873289, - 0.66139716782102, - 0.66348042108842, - 0.66555920651892, - 0.66763347239664, - 0.66970316730947, - 0.67176824015260, - 0.67382864013196, - 0.67588431676768, - 0.67793521989751, - 0.67998129968017, - 0.68202250659876, - 0.68405879146403, - 0.68609010541774, - 0.68811639993588, - 0.69013762683195, - 0.69215373826012, - 0.69416468671849, - 0.69617042505214, - 0.69817090645634, - 0.70016608447958, - 0.70215591302664, - 0.70414034636163, - 0.70611933911096, - 0.70809284626630, - 0.71006082318751, - 0.71202322560554, - 0.71398000962530, - 0.71593113172842, - 0.71787654877613, - 0.71981621801195, - 0.72175009706445, - 0.72367814394990, - 0.72560031707496, - 0.72751657523927, - 0.72942687763803, - 0.73133118386457, - 0.73322945391280, - 0.73512164817975, - 0.73700772746796, - 0.73888765298787, - 0.74076138636020, - 0.74262888961827, - 0.74449012521027, - 0.74634505600152, - 0.74819364527663, - 0.75003585674175, - 0.75187165452661, - 0.75370100318668, - 0.75552386770515, - 0.75734021349500, - 0.75915000640095, - 0.76095321270137, - 0.76274979911019, - 0.76453973277875, - 0.76632298129757, - 0.76809951269819, - 0.76986929545481, - 0.77163229848604, - 0.77338849115651, - 0.77513784327849, - 0.77688032511340, - 0.77861590737340, - 0.78034456122283, - 0.78206625827961, - 0.78378097061667, - 0.78548867076330, - 0.78718933170643, - 0.78888292689189, - 0.79056943022564, - 0.79224881607494, - 0.79392105926949, - 0.79558613510249, - 0.79724401933170, - 0.79889468818046, - 0.80053811833858, - 0.80217428696334, - 0.80380317168028, - 0.80542475058405, - 0.80703900223920, - 0.80864590568089, - 0.81024544041560, - 0.81183758642175, - 0.81342232415032, - 0.81499963452540, - 0.81656949894467, - 0.81813189927991, - 0.81968681787738, - 0.82123423755821, - 0.82277414161874, - 0.82430651383076, - 0.82583133844180, - 0.82734860017528, - 0.82885828423070, - 0.83036037628369, - 0.83185486248609, - 0.83334172946597, - 0.83482096432759, - 0.83629255465130, - 0.83775648849344, - 0.83921275438615, - 0.84066134133716, - 0.84210223882952, - 0.84353543682130, - 0.84496092574524, - 0.84637869650833, - 0.84778874049138, - 0.84919104954855, - 0.85058561600677, - 0.85197243266520, - 0.85335149279457, - 0.85472279013653, - 0.85608631890295, - 0.85744207377513, - 0.85879004990298, - 0.86013024290422, - 0.86146264886346, - 0.86278726433124, - 0.86410408632306, - 0.86541311231838, - 0.86671434025950, - 0.86800776855046, - 0.86929339605590, - 0.87057122209981, - 0.87184124646433, - 0.87310346938840, - 0.87435789156650, - 0.87560451414719, - 0.87684333873173, - 0.87807436737261, - 0.87929760257204, - 0.88051304728038, - 0.88172070489456, - 0.88292057925645, - 0.88411267465117, - 0.88529699580537, - 0.88647354788545, - 0.88764233649580, - 0.88880336767692, - 0.88995664790351, - 0.89110218408260, - 0.89223998355154, - 0.89337005407600, - 0.89449240384793, - 0.89560704148345, - 0.89671397602074, - 0.89781321691786, - 0.89890477405053, - 0.89998865770993, - 0.90106487860034, - 0.90213344783689, - 0.90319437694315, - 0.90424767784873, - 0.90529336288690, - 0.90633144479201, - 0.90736193669708, - 0.90838485213119, - 0.90940020501694, - 0.91040800966776, - 0.91140828078533, - 0.91240103345685, - 0.91338628315231, - 0.91436404572173, - 0.91533433739238, - 0.91629717476594, - 0.91725257481564, - 0.91820055488334, - 0.91914113267664, - 0.92007432626589, - 0.92100015408120, - 0.92191863490944, - 0.92282978789113, - 0.92373363251740, - 0.92463018862687, - 0.92551947640245, - 0.92640151636824, - 0.92727632938624, - 0.92814393665320, - 0.92900435969727, - 0.92985762037477, - 0.93070374086684, - 0.93154274367610, - 0.93237465162328, - 0.93319948784382, - 0.93401727578443, - 0.93482803919967, - 0.93563180214841, - 0.93642858899043, - 0.93721842438279, - 0.93800133327637, - 0.93877734091223, - 0.93954647281807, - 0.94030875480458, - 0.94106421296182, - 0.94181287365556, - 0.94255476352362, - 0.94328990947213, - 0.94401833867184, - 0.94474007855439, - 0.94545515680855, - 0.94616360137644, - 0.94686544044975, - 0.94756070246592, - 0.94824941610434, - 0.94893161028248, - 0.94960731415209, - 0.95027655709525, - 0.95093936872056, - 0.95159577885924, - 0.95224581756115, - 0.95288951509097, - 0.95352690192417, - 0.95415800874314, - 0.95478286643320, - 0.95540150607863, - 0.95601395895871, - 0.95662025654373, - 0.95722043049100, - 0.95781451264084, - 0.95840253501260, - 0.95898452980058, - 0.95956052937008, - 0.96013056625336, - 0.96069467314557, - 0.96125288290073, - 0.96180522852773, - 0.96235174318622, - 0.96289246018262, - 0.96342741296604, - 0.96395663512424, - 0.96448016037959, - 0.96499802258499, - 0.96551025571985, - 0.96601689388602, - 0.96651797130376, - 0.96701352230768, - 0.96750358134269, - 0.96798818295998, - 0.96846736181297, - 0.96894115265327, - 0.96940959032667, - 0.96987270976912, - 0.97033054600270, - 0.97078313413161, - 0.97123050933818, - 0.97167270687887, - 0.97210976208030, - 0.97254171033525, - 0.97296858709871, - 0.97339042788392, - 0.97380726825843, - 0.97421914384017, - 0.97462609029350, - 0.97502814332534, - 0.97542533868127, - 0.97581771214160, - 0.97620529951759, - 0.97658813664749, - 0.97696625939282, - 0.97733970363445, - 0.97770850526884, - 0.97807270020427, - 0.97843232435704, - 0.97878741364771, - 0.97913800399743, - 0.97948413132414, - 0.97982583153895, - 0.98016314054243, - 0.98049609422096, - 0.98082472844313, - 0.98114907905608, - 0.98146918188197, - 0.98178507271438, - 0.98209678731477, - 0.98240436140902, - 0.98270783068385, - 0.98300723078342, - 0.98330259730589, - 0.98359396579995, - 0.98388137176152, - 0.98416485063031, - 0.98444443778651, - 0.98472016854752, - 0.98499207816463, - 0.98526020181980, - 0.98552457462240, - 0.98578523160609, - 0.98604220772560, - 0.98629553785362, - 0.98654525677772, - 0.98679139919726, - 0.98703399972035, - 0.98727309286089, - 0.98750871303556, - 0.98774089456089, - 0.98796967165036, - 0.98819507841154, - 0.98841714884323, - 0.98863591683269, - 0.98885141615285, - 0.98906368045957, - 0.98927274328896, - 0.98947863805473, - 0.98968139804554, - 0.98988105642241, - 0.99007764621618, - 0.99027120032501, - 0.99046175151186, - 0.99064933240208, - 0.99083397548099, - 0.99101571309153, - 0.99119457743191, - 0.99137060055337, - 0.99154381435784, - 0.99171425059582, - 0.99188194086414, - 0.99204691660388, - 0.99220920909823, - 0.99236884947045, - 0.99252586868186, - 0.99268029752989, - 0.99283216664606, - 0.99298150649419, - 0.99312834736847, - 0.99327271939167, - 0.99341465251338, - 0.99355417650825, - 0.99369132097430, - 0.99382611533130, - 0.99395858881910, - 0.99408877049612, - 0.99421668923778, - 0.99434237373503, - 0.99446585249289, - 0.99458715382906, - 0.99470630587254, - 0.99482333656229, - 0.99493827364600, - 0.99505114467878, - 0.99516197702200, - 0.99527079784214, - 0.99537763410962, - 0.99548251259777, - 0.99558545988178, - 0.99568650233767, - 0.99578566614138, - 0.99588297726783, - 0.99597846149005, - 0.99607214437834, - 0.99616405129947, - 0.99625420741595, - 0.99634263768527, - 0.99642936685928, - 0.99651441948352, - 0.99659781989663, - 0.99667959222978, - 0.99675976040620, - 0.99683834814063, - 0.99691537893895, - 0.99699087609774, - 0.99706486270391, - 0.99713736163442, - 0.99720839555593, - 0.99727798692461, - 0.99734615798589, - 0.99741293077431, - 0.99747832711337, - 0.99754236861541, - 0.99760507668158, - 0.99766647250181, - 0.99772657705478, - 0.99778541110799, - 0.99784299521785, - 0.99789934972976, - 0.99795449477828, - 0.99800845028730, - 0.99806123597027, - 0.99811287133042, - 0.99816337566108, - 0.99821276804596, - 0.99826106735952, - 0.99830829226732, - 0.99835446122649, - 0.99839959248609, - 0.99844370408765, - 0.99848681386566, - 0.99852893944805, - 0.99857009825685, - 0.99861030750869, - 0.99864958421549, - 0.99868794518504, - 0.99872540702178, - 0.99876198612738, - 0.99879769870160, - 0.99883256074295, - 0.99886658804953, - 0.99889979621983, - 0.99893220065356, - 0.99896381655254, - 0.99899465892154, - 0.99902474256924, - 0.99905408210916, - 0.99908269196056, - 0.99911058634952, - 0.99913777930986, - 0.99916428468421, - 0.99919011612505, - 0.99921528709576, - 0.99923981087174, - 0.99926370054150, - 0.99928696900779, - 0.99930962898876, - 0.99933169301910, - 0.99935317345126, - 0.99937408245662, - 0.99939443202674, - 0.99941423397457, - 0.99943349993572, - 0.99945224136972, - 0.99947046956130, - 0.99948819562171, - 0.99950543049000, - 0.99952218493439, - 0.99953846955355, - 0.99955429477803, - 0.99956967087154, - 0.99958460793242, - 0.99959911589494, - 0.99961320453077, - 0.99962688345035, - 0.99964016210433, - 0.99965304978499, - 0.99966555562769, - 0.99967768861231, - 0.99968945756473, - 0.99970087115825, - 0.99971193791510, - 0.99972266620792, - 0.99973306426121, - 0.99974314015288, - 0.99975290181568, - 0.99976235703876, - 0.99977151346914, - 0.99978037861326, - 0.99978895983845, - 0.99979726437448, - 0.99980529931507, - 0.99981307161943, - 0.99982058811377, - 0.99982785549283, - 0.99983488032144, - 0.99984166903600, - 0.99984822794606, - 0.99985456323584, - 0.99986068096572, - 0.99986658707386, - 0.99987228737764, - 0.99987778757524, - 0.99988309324717, - 0.99988820985777, - 0.99989314275675, - 0.99989789718072, - 0.99990247825468, - 0.99990689099357, - 0.99991114030376, - 0.99991523098456, - 0.99991916772971, - 0.99992295512891, - 0.99992659766930, - 0.99993009973692, - 0.99993346561824, - 0.99993669950161, - 0.99993980547870, - 0.99994278754604, - 0.99994564960642, - 0.99994839547033, - 0.99995102885747, - 0.99995355339809, - 0.99995597263451, - 0.99995829002249, - 0.99996050893264, - 0.99996263265183, - 0.99996466438460, - 0.99996660725452, - 0.99996846430558, - 0.99997023850356, - 0.99997193273736, - 0.99997354982037, - 0.99997509249183, - 0.99997656341810, - 0.99997796519400, - 0.99997930034415, - 0.99998057132421, - 0.99998178052220, - 0.99998293025975, - 0.99998402279338, - 0.99998506031574, - 0.99998604495686, - 0.99998697878536, - 0.99998786380966, - 0.99998870197921, - 0.99998949518567, - 0.99999024526408, - 0.99999095399401, - 0.99999162310077, - 0.99999225425649, - 0.99999284908128, - 0.99999340914435, - 0.99999393596510, - 0.99999443101421, - 0.99999489571473, - 0.99999533144314, - 0.99999573953040, - 0.99999612126300, - 0.99999647788395, - 0.99999681059383, - 0.99999712055178, - 0.99999740887647, - 0.99999767664709, - 0.99999792490431, - 0.99999815465123, - 0.99999836685427, - 0.99999856244415, - 0.99999874231676, - 0.99999890733405, - 0.99999905832493, - 0.99999919608613, - 0.99999932138304, - 0.99999943495056, - 0.99999953749392, - 0.99999962968950, - 0.99999971218563, - 0.99999978560337, - 0.99999985053727, - 0.99999990755616, - 0.99999995720387 -}; - -real_t kbd_long_960[] = { - 0.0003021562530949, - 0.0004452267024786, - 0.0005674947527496, - 0.0006812465553466, - 0.0007910496776387, - 0.0008991655033895, - 0.0010068978259384, - 0.0011150758515751, - 0.0012242653193642, - 0.0013348735658205, - 0.0014472068670273, - 0.0015615039850448, - 0.0016779568885263, - 0.0017967241232412, - 0.0019179397560955, - 0.0020417195415393, - 0.0021681652836642, - 0.0022973679910599, - 0.0024294102029937, - 0.0025643677339078, - 0.0027023110014772, - 0.0028433060512612, - 0.0029874153568025, - 0.0031346984511728, - 0.0032852124303662, - 0.0034390123581190, - 0.0035961515940931, - 0.0037566820618961, - 0.0039206544694386, - 0.0040881184912194, - 0.0042591229199617, - 0.0044337157933972, - 0.0046119445007641, - 0.0047938558726415, - 0.0049794962570131, - 0.0051689115838900, - 0.0053621474203763, - 0.0055592490177131, - 0.0057602613515573, - 0.0059652291565289, - 0.0061741969558843, - 0.0063872090870253, - 0.0066043097234387, - 0.0068255428935640, - 0.0070509524970088, - 0.0072805823184660, - 0.0075144760396340, - 0.0077526772493942, - 0.0079952294524673, - 0.0082421760767325, - 0.0084935604793733, - 0.0087494259519870, - 0.0090098157247792, - 0.0092747729699467, - 0.0095443408043399, - 0.0098185622914832, - 0.0100974804430226, - 0.0103811382196612, - 0.0106695785316351, - 0.0109628442387771, - 0.0112609781502091, - 0.0115640230236993, - 0.0118720215647169, - 0.0121850164252137, - 0.0125030502021561, - 0.0128261654358321, - 0.0131544046079532, - 0.0134878101395681, - 0.0138264243888068, - 0.0141702896484671, - 0.0145194481434592, - 0.0148739420281182, - 0.0152338133833959, - 0.0155991042139432, - 0.0159698564450882, - 0.0163461119197227, - 0.0167279123950996, - 0.0171152995395520, - 0.0175083149291368, - 0.0179070000442104, - 0.0183113962659409, - 0.0187215448727609, - 0.0191374870367659, - 0.0195592638200623, - 0.0199869161710679, - 0.0204204849207691, - 0.0208600107789370, - 0.0213055343303066, - 0.0217570960307201, - 0.0222147362032386, - 0.0226784950342228, - 0.0231484125693867, - 0.0236245287098244, - 0.0241068832080138, - 0.0245955156637973, - 0.0250904655203431, - 0.0255917720600868, - 0.0260994744006559, - 0.0266136114907790, - 0.0271342221061795, - 0.0276613448454576, - 0.0281950181259587, - 0.0287352801796329, - 0.0292821690488833, - 0.0298357225824074, - 0.0303959784310299, - 0.0309629740435296, - 0.0315367466624615, - 0.0321173333199732, - 0.0327047708336193, - 0.0332990958021720, - 0.0339003446014307, - 0.0345085533800302, - 0.0351237580552491, - 0.0357459943088193, - 0.0363752975827358, - 0.0370117030750704, - 0.0376552457357870, - 0.0383059602625614, - 0.0389638810966056, - 0.0396290424184964, - 0.0403014781440112, - 0.0409812219199691, - 0.0416683071200799, - 0.0423627668408009, - 0.0430646338972016, - 0.0437739408188385, - 0.0444907198456388, - 0.0452150029237951, - 0.0459468217016708, - 0.0466862075257170, - 0.0474331914364021, - 0.0481878041641539, - 0.0489500761253148, - 0.0497200374181119, - 0.0504977178186404, - 0.0512831467768636, - 0.0520763534126273, - 0.0528773665116913, - 0.0536862145217772, - 0.0545029255486345, - 0.0553275273521232, - 0.0561600473423164, - 0.0570005125756209, - 0.0578489497509179, - 0.0587053852057233, - 0.0595698449123695, - 0.0604423544742077, - 0.0613229391218317, - 0.0622116237093247, - 0.0631084327105284, - 0.0640133902153352, - 0.0649265199260043, - 0.0658478451535027, - 0.0667773888138695, - 0.0677151734246072, - 0.0686612211010977, - 0.0696155535530446, - 0.0705781920809429, - 0.0715491575725758, - 0.0725284704995383, - 0.0735161509137906, - 0.0745122184442388, - 0.0755166922933461, - 0.0765295912337720, - 0.0775509336050437, - 0.0785807373102561, - 0.0796190198128044, - 0.0806657981331473, - 0.0817210888456026, - 0.0827849080751753, - 0.0838572714944183, - 0.0849381943203265, - 0.0860276913112652, - 0.0871257767639319, - 0.0882324645103534, - 0.0893477679149177, - 0.0904716998714418, - 0.0916042728002747, - 0.0927454986454381, - 0.0938953888718020, - 0.0950539544622996, - 0.0962212059151784, - 0.0973971532412897, - 0.0985818059614169, - 0.0997751731036425, - 0.1009772632007537, - 0.1021880842876888, - 0.1034076438990227, - 0.1046359490664932, - 0.1058730063165681, - 0.1071188216680533, - 0.1083734006297428, - 0.1096367481981100, - 0.1109088688550422, - 0.1121897665656167, - 0.1134794447759207, - 0.1147779064109143, - 0.1160851538723372, - 0.1174011890366591, - 0.1187260132530751, - 0.1200596273415457, - 0.1214020315908810, - 0.1227532257568719, - 0.1241132090604651, - 0.1254819801859856, - 0.1268595372794049, - 0.1282458779466558, - 0.1296409992519942, - 0.1310448977164081, - 0.1324575693160745, - 0.1338790094808633, - 0.1353092130928902, - 0.1367481744851168, - 0.1381958874400010, - 0.1396523451881945, - 0.1411175404072910, - 0.1425914652206223, - 0.1440741111961058, - 0.1455654693451402, - 0.1470655301215526, - 0.1485742834205956, - 0.1500917185779945, - 0.1516178243690463, - 0.1531525890077689, - 0.1546960001461024, - 0.1562480448731608, - 0.1578087097145364, - 0.1593779806316558, - 0.1609558430211876, - 0.1625422817145027, - 0.1641372809771871, - 0.1657408245086070, - 0.1673528954415270, - 0.1689734763417811, - 0.1706025492079969, - 0.1722400954713725, - 0.1738860959955082, - 0.1755405310762898, - 0.1772033804418275, - 0.1788746232524467, - 0.1805542381007349, - 0.1822422030116404, - 0.1839384954426268, - 0.1856430922838810, - 0.1873559698585756, - 0.1890771039231862, - 0.1908064696678625, - 0.1925440417168546, - 0.1942897941289937, - 0.1960437003982277, - 0.1978057334542116, - 0.1995758656629525, - 0.2013540688275098, - 0.2031403141887507, - 0.2049345724261595, - 0.2067368136587033, - 0.2085470074457521, - 0.2103651227880538, - 0.2121911281287646, - 0.2140249913545346, - 0.2158666797966480, - 0.2177161602322188, - 0.2195733988854414, - 0.2214383614288963, - 0.2233110129849106, - 0.2251913181269740, - 0.2270792408812093, - 0.2289747447278976, - 0.2308777926030592, - 0.2327883469000885, - 0.2347063694714437, - 0.2366318216303919, - 0.2385646641528076, - 0.2405048572790267, - 0.2424523607157545, - 0.2444071336380283, - 0.2463691346912334, - 0.2483383219931741, - 0.2503146531361985, - 0.2522980851893767, - 0.2542885747007335, - 0.2562860776995335, - 0.2582905496986215, - 0.2603019456968142, - 0.2623202201813464, - 0.2643453271303700, - 0.2663772200155053, - 0.2684158518044454, - 0.2704611749636135, - 0.2725131414608710, - 0.2745717027682799, - 0.2766368098649151, - 0.2787084132397296, - 0.2807864628944707, - 0.2828709083466482, - 0.2849616986325523, - 0.2870587823103237, - 0.2891621074630737, - 0.2912716217020546, - 0.2933872721698803, - 0.2955090055437973, - 0.2976367680390041, - 0.2997705054120213, - 0.3019101629641097, - 0.3040556855447379, - 0.3062070175550981, - 0.3083641029516701, - 0.3105268852498334, - 0.3126953075275265, - 0.3148693124289546, - 0.3170488421683428, - 0.3192338385337370, - 0.3214242428908514, - 0.3236199961869606, - 0.3258210389548392, - 0.3280273113167459, - 0.3302387529884521, - 0.3324553032833160, - 0.3346769011164010, - 0.3369034850086373, - 0.3391349930910280, - 0.3413713631088974, - 0.3436125324261830, - 0.3458584380297697, - 0.3481090165338656, - 0.3503642041844199, - 0.3526239368635820, - 0.3548881500942010, - 0.3571567790443668, - 0.3594297585319891, - 0.3617070230294185, - 0.3639885066681048, - 0.3662741432432950, - 0.3685638662187693, - 0.3708576087316147, - 0.3731553035970366, - 0.3754568833132069, - 0.3777622800661488, - 0.3800714257346570, - 0.3823842518952546, - 0.3847006898271841, - 0.3870206705174334, - 0.3893441246657958, - 0.3916709826899639, - 0.3940011747306560, - 0.3963346306567764, - 0.3986712800706062, - 0.4010110523130271, - 0.4033538764687756, - 0.4056996813717284, - 0.4080483956102172, - 0.4103999475323736, - 0.4127542652515031, - 0.4151112766514873, - 0.4174709093922143, - 0.4198330909150365, - 0.4221977484482556, - 0.4245648090126334, - 0.4269341994269293, - 0.4293058463134616, - 0.4316796761036958, - 0.4340556150438547, - 0.4364335892005536, - 0.4388135244664580, - 0.4411953465659639, - 0.4435789810609000, - 0.4459643533562509, - 0.4483513887059016, - 0.4507400122184019, - 0.4531301488627497, - 0.4555217234741947, - 0.4579146607600593, - 0.4603088853055777, - 0.4627043215797521, - 0.4651008939412254, - 0.4674985266441709, - 0.4698971438441951, - 0.4722966696042580, - 0.4746970279006055, - 0.4770981426287164, - 0.4794999376092619, - 0.4819023365940778, - 0.4843052632721476, - 0.4867086412755978, - 0.4891123941857028, - 0.4915164455388997, - 0.4939207188328126, - 0.4963251375322855, - 0.4987296250754225, - 0.5011341048796359, - 0.5035385003477012, - 0.5059427348738168, - 0.5083467318496706, - 0.5107504146705106, - 0.5131537067412193, - 0.5155565314823923, - 0.5179588123364193, - 0.5203604727735667, - 0.5227614362980630, - 0.5251616264541841, - 0.5275609668323384, - 0.5299593810751532, - 0.5323567928835578, - 0.5347531260228663, - 0.5371483043288580, - 0.5395422517138538, - 0.5419348921727899, - 0.5443261497892862, - 0.5467159487417104, - 0.5491042133092364, - 0.5514908678778958, - 0.5538758369466227, - 0.5562590451332913, - 0.5586404171807443, - 0.5610198779628133, - 0.5633973524903286, - 0.5657727659171199, - 0.5681460435460047, - 0.5705171108347663, - 0.5728858934021188, - 0.5752523170336598, - 0.5776163076878088, - 0.5799777915017323, - 0.5823366947972535, - 0.5846929440867458, - 0.5870464660790119, - 0.5893971876851449, - 0.5917450360243719, - 0.5940899384298793, - 0.5964318224546208, - 0.5987706158771039, - 0.6011062467071583, - 0.6034386431916822, - 0.6057677338203681, - 0.6080934473314057, - 0.6104157127171639, - 0.6127344592298474, - 0.6150496163871310, - 0.6173611139777690, - 0.6196688820671789, - 0.6219728510029997, - 0.6242729514206247, - 0.6265691142487051, - 0.6288612707146283, - 0.6311493523499663, - 0.6334332909958958, - 0.6357130188085891, - 0.6379884682645743, - 0.6402595721660647, - 0.6425262636462578, - 0.6447884761746012, - 0.6470461435620266, - 0.6492991999661505, - 0.6515475798964411, - 0.6537912182193508, - 0.6560300501634142, - 0.6582640113243098, - 0.6604930376698862, - 0.6627170655451516, - 0.6649360316772256, - 0.6671498731802533, - 0.6693585275602818, - 0.6715619327200959, - 0.6737600269640164, - 0.6759527490026566, - 0.6781400379576392, - 0.6803218333662715, - 0.6824980751861787, - 0.6846687037998949, - 0.6868336600194123, - 0.6889928850906855, - 0.6911463206980928, - 0.6932939089688525, - 0.6954355924773949, - 0.6975713142496884, - 0.6997010177675195, - 0.7018246469727265, - 0.7039421462713862, - 0.7060534605379528, - 0.7081585351193496, - 0.7102573158390105, - 0.7123497490008750, - 0.7144357813933307, - 0.7165153602931092, - 0.7185884334691287, - 0.7206549491862871, - 0.7227148562092042, - 0.7247681038059106, - 0.7268146417514855, - 0.7288544203316418, - 0.7308873903462577, - 0.7329135031128549, - 0.7349327104700221, - 0.7369449647807855, - 0.7389502189359237, - 0.7409484263572271, - 0.7429395410007016, - 0.7449235173597176, - 0.7469003104681008, - 0.7488698759031670, - 0.7508321697887005, - 0.7527871487978728, - 0.7547347701561059, - 0.7566749916438754, - 0.7586077715994560, - 0.7605330689216074, - 0.7624508430722016, - 0.7643610540787891, - 0.7662636625371070, - 0.7681586296135255, - 0.7700459170474343, - 0.7719254871535672, - 0.7737973028242671, - 0.7756613275316875, - 0.7775175253299340, - 0.7793658608571425, - 0.7812062993374951, - 0.7830388065831744, - 0.7848633489962533, - 0.7866798935705233, - 0.7884884078932579, - 0.7902888601469138, - 0.7920812191107668, - 0.7938654541624850, - 0.7956415352796368, - 0.7974094330411343, - 0.7991691186286133, - 0.8009205638277465, - 0.8026637410294932, - 0.8043986232312831, - 0.8061251840381346, - 0.8078433976637077, - 0.8095532389312917, - 0.8112546832747255, - 0.8129477067392539, - 0.8146322859823164, - 0.8163083982742698, - 0.8179760214990457, - 0.8196351341547393, - 0.8212857153541345, - 0.8229277448251595, - 0.8245612029112778, - 0.8261860705718113, - 0.8278023293821971, - 0.8294099615341773, - 0.8310089498359212, - 0.8325992777120815, - 0.8341809292037831, - 0.8357538889685445, - 0.8373181422801330, - 0.8388736750283521, - 0.8404204737187619, - 0.8419585254723335, - 0.8434878180250348, - 0.8450083397273509, - 0.8465200795437368, - 0.8480230270520029, - 0.8495171724426350, - 0.8510025065180464, - 0.8524790206917633, - 0.8539467069875448, - 0.8554055580384357, - 0.8568555670857525, - 0.8582967279780043, - 0.8597290351697464, - 0.8611524837203691, - 0.8625670692928198, - 0.8639727881522599, - 0.8653696371646555, - 0.8667576137953045, - 0.8681367161072958, - 0.8695069427599065, - 0.8708682930069319, - 0.8722207666949527, - 0.8735643642615368, - 0.8748990867333771, - 0.8762249357243662, - 0.8775419134336067, - 0.8788500226433579, - 0.8801492667169208, - 0.8814396495964587, - 0.8827211758007560, - 0.8839938504229149, - 0.8852576791279895, - 0.8865126681505587, - 0.8877588242922386, - 0.8889961549191320, - 0.8902246679592184, - 0.8914443718996848, - 0.8926552757841945, - 0.8938573892100969, - 0.8950507223255798, - 0.8962352858267605, - 0.8974110909547198, - 0.8985781494924783, - 0.8997364737619142, - 0.9008860766206249, - 0.9020269714587307, - 0.9031591721956235, - 0.9042826932766591, - 0.9053975496697941, - 0.9065037568621681, - 0.9076013308566311, - 0.9086902881682180, - 0.9097706458205682, - 0.9108424213422940, - 0.9119056327632955, - 0.9129602986110235, - 0.9140064379066919, - 0.9150440701614393, - 0.9160732153724396, - 0.9170938940189634, - 0.9181061270583908, - 0.9191099359221748, - 0.9201053425117579, - 0.9210923691944400, - 0.9220710387992010, - 0.9230413746124764, - 0.9240034003738882, - 0.9249571402719298, - 0.9259026189396085, - 0.9268398614500427, - 0.9277688933120170, - 0.9286897404654957, - 0.9296024292770939, - 0.9305069865355076, - 0.9314034394469048, - 0.9322918156302762, - 0.9331721431127471, - 0.9340444503248519, - 0.9349087660957711, - 0.9357651196485313, - 0.9366135405951697, - 0.9374540589318637, - 0.9382867050340261, - 0.9391115096513655, - 0.9399285039029165, - 0.9407377192720349, - 0.9415391876013639, - 0.9423329410877687, - 0.9431190122772415, - 0.9438974340597782, - 0.9446682396642262, - 0.9454314626531054, - 0.9461871369174033, - 0.9469352966713429, - 0.9476759764471278, - 0.9484092110896616, - 0.9491350357512457, - 0.9498534858862532, - 0.9505645972457831, - 0.9512684058722927, - 0.9519649480942105, - 0.9526542605205314, - 0.9533363800353921, - 0.9540113437926313, - 0.9546791892103320, - 0.9553399539653500, - 0.9559936759878265, - 0.9566403934556893, - 0.9572801447891388, - 0.9579129686451244, - 0.9585389039118085, - 0.9591579897030224, - 0.9597702653527108, - 0.9603757704093711, - 0.9609745446304828, - 0.9615666279769324, - 0.9621520606074324, - 0.9627308828729358, - 0.9633031353110477, - 0.9638688586404335, - 0.9644280937552258, - 0.9649808817194311, - 0.9655272637613366, - 0.9660672812679171, - 0.9666009757792454, - 0.9671283889829055, - 0.9676495627084089, - 0.9681645389216160, - 0.9686733597191652, - 0.9691760673229058, - 0.9696727040743406, - 0.9701633124290767, - 0.9706479349512860, - 0.9711266143081750, - 0.9715993932644684, - 0.9720663146769026, - 0.9725274214887337, - 0.9729827567242596, - 0.9734323634833574, - 0.9738762849360358, - 0.9743145643170059, - 0.9747472449202687, - 0.9751743700937215, - 0.9755959832337850, - 0.9760121277800496, - 0.9764228472099433, - 0.9768281850334235, - 0.9772281847876897, - 0.9776228900319223, - 0.9780123443420448, - 0.9783965913055132, - 0.9787756745161313, - 0.9791496375688939, - 0.9795185240548578, - 0.9798823775560431, - 0.9802412416403639, - 0.9805951598565897, - 0.9809441757293399, - 0.9812883327541090, - 0.9816276743923267, - 0.9819622440664515, - 0.9822920851550995, - 0.9826172409882086, - 0.9829377548422400, - 0.9832536699354163, - 0.9835650294229984, - 0.9838718763926001, - 0.9841742538595437, - 0.9844722047622547, - 0.9847657719576983, - 0.9850549982168574, - 0.9853399262202529, - 0.9856205985535073, - 0.9858970577029519, - 0.9861693460512790, - 0.9864375058732389, - 0.9867015793313820, - 0.9869616084718489, - 0.9872176352202061, - 0.9874697013773301, - 0.9877178486153397, - 0.9879621184735767, - 0.9882025523546365, - 0.9884391915204485, - 0.9886720770884069, - 0.9889012500275530, - 0.9891267511548089, - 0.9893486211312621, - 0.9895669004585049, - 0.9897816294750255, - 0.9899928483526520, - 0.9902005970930525, - 0.9904049155242876, - 0.9906058432974180, - 0.9908034198831690, - 0.9909976845686489, - 0.9911886764541239, - 0.9913764344498495, - 0.9915609972729590, - 0.9917424034444086, - 0.9919206912859797, - 0.9920958989173397, - 0.9922680642531603, - 0.9924372250002933, - 0.9926034186550070, - 0.9927666825002789, - 0.9929270536031491, - 0.9930845688121325, - 0.9932392647546895, - 0.9933911778347579, - 0.9935403442303433, - 0.9936867998911693, - 0.9938305805363887, - 0.9939717216523539, - 0.9941102584904481, - 0.9942462260649764, - 0.9943796591511174, - 0.9945105922829353, - 0.9946390597514524, - 0.9947650956027824, - 0.9948887336363228, - 0.9950100074030103, - 0.9951289502036336, - 0.9952455950872091, - 0.9953599748494155, - 0.9954721220310890, - 0.9955820689167787, - 0.9956898475333619, - 0.9957954896487196, - 0.9958990267704713, - 0.9960004901447701, - 0.9960999107551559, - 0.9961973193214694, - 0.9962927462988245, - 0.9963862218766388, - 0.9964777759777242, - 0.9965674382574342, - 0.9966552381028704, - 0.9967412046321465, - 0.9968253666937095, - 0.9969077528657186, - 0.9969883914554805, - 0.9970673104989413, - 0.9971445377602348, - 0.9972201007312871, - 0.9972940266314749, - 0.9973663424073412, - 0.9974370747323638, - 0.9975062500067785, - 0.9975738943574574, - 0.9976400336378379, - 0.9977046934279079, - 0.9977678990342401, - 0.9978296754900812, - 0.9978900475554902, - 0.9979490397175296, - 0.9980066761905056, - 0.9980629809162593, - 0.9981179775645063, - 0.9981716895332257, - 0.9982241399490979, - 0.9982753516679893, - 0.9983253472754841, - 0.9983741490874634, - 0.9984217791507299, - 0.9984682592436778, - 0.9985136108770075, - 0.9985578552944850, - 0.9986010134737439, - 0.9986431061271304, - 0.9986841537025921, - 0.9987241763846056, - 0.9987631940951476, - 0.9988012264947044, - 0.9988382929833222, - 0.9988744127016956, - 0.9989096045322947, - 0.9989438871005292, - 0.9989772787759494, - 0.9990097976734847, - 0.9990414616547146, - 0.9990722883291779, - 0.9991022950557125, - 0.9991314989438310, - 0.9991599168551279, - 0.9991875654047181, - 0.9992144609627068, - 0.9992406196556911, - 0.9992660573682882, - 0.9992907897446957, - 0.9993148321902777, - 0.9993381998731797, - 0.9993609077259696, - 0.9993829704473038, - 0.9994044025036201, - 0.9994252181308537, - 0.9994454313361775, - 0.9994650558997651, - 0.9994841053765757, - 0.9995025930981609, - 0.9995205321744921, - 0.9995379354958073, - 0.9995548157344778, - 0.9995711853468930, - 0.9995870565753632, - 0.9996024414500382, - 0.9996173517908444, - 0.9996317992094352, - 0.9996457951111574, - 0.9996593506970310, - 0.9996724769657434, - 0.9996851847156547, - 0.9996974845468164, - 0.9997093868630000, - 0.9997209018737374, - 0.9997320395963699, - 0.9997428098581069, - 0.9997532222980933, - 0.9997632863694836, - 0.9997730113415246, - 0.9997824063016426, - 0.9997914801575380, - 0.9998002416392840, - 0.9998086993014300, - 0.9998168615251084, - 0.9998247365201450, - 0.9998323323271717, - 0.9998396568197407, - 0.9998467177064404, - 0.9998535225330116, - 0.9998600786844637, - 0.9998663933871905, - 0.9998724737110845, - 0.9998783265716498, - 0.9998839587321121, - 0.9998893768055266, - 0.9998945872568815, - 0.9998995964051983, - 0.9999044104256269, - 0.9999090353515359, - 0.9999134770765971, - 0.9999177413568642, - 0.9999218338128448, - 0.9999257599315647, - 0.9999295250686255, - 0.9999331344502529, - 0.9999365931753376, - 0.9999399062174669, - 0.9999430784269460, - 0.9999461145328103, - 0.9999490191448277, - 0.9999517967554878, - 0.9999544517419835, - 0.9999569883681778, - 0.9999594107865607, - 0.9999617230401926, - 0.9999639290646355, - 0.9999660326898712, - 0.9999680376422052, - 0.9999699475461585, - 0.9999717659263435, - 0.9999734962093266, - 0.9999751417254756, - 0.9999767057107922, - 0.9999781913087290, - 0.9999796015719915, - 0.9999809394643231, - 0.9999822078622751, - 0.9999834095569596, - 0.9999845472557860, - 0.9999856235841805, - 0.9999866410872889, - 0.9999876022316609, - 0.9999885094069193, - 0.9999893649274085, - 0.9999901710338274, - 0.9999909298948430, - 0.9999916436086862, - 0.9999923142047299, - 0.9999929436450469, - 0.9999935338259505, - 0.9999940865795161, - 0.9999946036750835, - 0.9999950868207405, - 0.9999955376647868, - 0.9999959577971798, - 0.9999963487509599, - 0.9999967120036571, - 0.9999970489786785, - 0.9999973610466748, - 0.9999976495268890, - 0.9999979156884846, - 0.9999981607518545, - 0.9999983858899099, - 0.9999985922293493, - 0.9999987808519092, - 0.9999989527955938, - 0.9999991090558848, - 0.9999992505869332, - 0.9999993783027293, - 0.9999994930782556, - 0.9999995957506171, - 0.9999996871201549, - 0.9999997679515386, - 0.9999998389748399, - 0.9999999008865869, - 0.9999999543507984 -}; - -real_t kbd_short_128[] = -{ - 4.3795702929468881e-005, - 0.00011867384265436617, - 0.0002307165763996192, - 0.00038947282760568383, - 0.00060581272288302553, - 0.00089199695169487453, - 0.0012617254423430522, - 0.0017301724373162003, - 0.0023140071937421476, - 0.0030313989666022221, - 0.0039020049735530842, - 0.0049469401815512024, - 0.0061887279335368318, - 0.0076512306364647726, - 0.0093595599562652423, - 0.011339966208377799, - 0.013619706891715299, - 0.016226894586323766, - 0.019190324717288168, - 0.022539283975960878, - 0.026303340480472455, - 0.030512117046644357, - 0.03519504922365594, - 0.040381130021856941, - 0.046098643518702249, - 0.052374889768730587, - 0.059235903660769147, - 0.066706170556282418, - 0.074808341703430481, - 0.083562952548726227, - 0.092988147159339674, - 0.1030994120216919, - 0.11390932249409955, - 0.12542730516149531, - 0.13765941926783826, - 0.15060816028651081, - 0.16427228853114245, - 0.17864668550988483, - 0.19372224048676889, - 0.20948576943658073, - 0.22591996826744942, - 0.24300340184133981, - 0.26071052995068139, - 0.27901177101369551, - 0.29787360383626599, - 0.3172587073594233, - 0.33712613787396362, - 0.35743154274286698, - 0.37812740923363009, - 0.39916334663203618, - 0.42048639939189658, - 0.4420413886774246, - 0.4637712792815169, - 0.4856175685594023, - 0.50752069370766872, - 0.52942045344797806, - 0.55125643994680196, - 0.57296847662071559, - 0.59449705734411495, - 0.61578378249506627, - 0.63677178724712891, - 0.65740615754163356, - 0.67763432925662526, - 0.69740646622548552, - 0.71667581294953808, - 0.73539901809352737, - 0.75353642514900732, - 0.77105232699609816, - 0.78791518148597028, - 0.80409778560147072, - 0.81957740622770781, - 0.83433586607383625, - 0.84835958382689225, - 0.86163956818294229, - 0.87417136598406997, - 0.88595496528524853, - 0.89699465477567619, - 0.90729884157670959, - 0.91687983002436779, - 0.92575356460899649, - 0.93393934077779084, - 0.94145948779657318, - 0.94833902830402828, - 0.95460531956280026, - 0.96028768170574896, - 0.96541701848104766, - 0.97002543610646474, - 0.97414586584250062, - 0.97781169577969584, - 0.98105641710392333, - 0.98391328975491177, - 0.98641503193166202, - 0.98859353733226141, - 0.99047962335771556, - 0.9921028127769449, - 0.99349115056397752, - 0.99467105680259038, - 0.9956672157341897, - 0.99650250022834352, - 0.99719793020823266, - 0.99777266288955657, - 0.99824401211201486, - 0.99862749357391212, - 0.99893689243401962, - 0.99918434952623147, - 0.99938046234161726, - 0.99953439696357238, - 0.99965400728430465, - 0.99974595807027455, - 0.99981584876278362, - 0.99986833527824281, - 0.99990724749057802, - 0.99993570051598468, - 0.99995619835942084, - 0.99997072890647543, - 0.9999808496399144, - 0.99998776381655818, - 0.99999238714961569, - 0.99999540529959718, - 0.99999732268176988, - 0.99999850325054862, - 0.99999920402413744, - 0.9999996021706401, - 0.99999981649545566, - 0.99999992415545547, - 0.99999997338493041, - 0.99999999295825959, - 0.99999999904096815 -}; - -real_t kbd_short_120[] = +ALIGN static const real_t kbd_long_1024[] = { - 0.0000452320086910, - 0.0001274564692111, - 0.0002529398385345, - 0.0004335140496648, - 0.0006827100966952, - 0.0010158708222246, - 0.0014502162869659, - 0.0020048865156264, - 0.0027009618393178, - 0.0035614590925043, - 0.0046113018122711, - 0.0058772627936484, - 0.0073878776584103, - 0.0091733284512589, - 0.0112652966728373, - 0.0136967855861945, - 0.0165019120857793, - 0.0197156688892217, - 0.0233736582950619, - 0.0275117992367496, - 0.0321660098468534, - 0.0373718682174417, - 0.0431642544948834, - 0.0495769778717676, - 0.0566423924273392, - 0.0643910061132260, - 0.0728510874761729, - 0.0820482749475221, - 0.0920051937045235, - 0.1027410852163450, - 0.1142714546239370, - 0.1266077410648368, - 0.1397570159398145, - 0.1537217139274270, - 0.1684994012857075, - 0.1840825856392944, - 0.2004585710384133, - 0.2176093615976121, - 0.2355116164824983, - 0.2541366584185075, - 0.2734505372545160, - 0.2934141494343369, - 0.3139834135200387, - 0.3351095011824163, - 0.3567391223361566, - 0.3788148623608774, - 0.4012755686250732, - 0.4240567828288110, - 0.4470912150133537, - 0.4703092544619664, - 0.4936395121456694, - 0.5170093888596962, - 0.5403456627591340, - 0.5635750896430154, - 0.5866250090612892, - 0.6094239491338723, - 0.6319022228794100, - 0.6539925088563087, - 0.6756304090216887, - 0.6967549769155277, - 0.7173092095766250, - 0.7372404969921184, - 0.7565010233699827, - 0.7750481150999984, - 0.7928445309277697, - 0.8098586906021583, - 0.8260648390616000, - 0.8414431440907889, - 0.8559797262966709, - 0.8696666212110165, - 0.8825016743142358, - 0.8944883707784486, - 0.9056356027326216, - 0.9159573778427816, - 0.9254724739583072, - 0.9342040454819434, - 0.9421791879559176, - 0.9494284680976784, - 0.9559854271440150, - 0.9618860658493898, - 0.9671683198119525, - 0.9718715339497299, - 0.9760359449042233, - 0.9797021798981759, - 0.9829107801140203, - 0.9857017559923277, - 0.9881141809867999, - 0.9901858292742826, - 0.9919528617340944, - 0.9934495632180476, - 0.9947081327749199, - 0.9957585271195989, - 0.9966283562984427, - 0.9973428292485683, - 0.9979247458259197, - 0.9983945309245774, - 0.9987703055583410, - 0.9990679892449266, - 0.9993014277313617, - 0.9994825400228521, - 0.9996214788122335, - 0.9997267987294857, - 0.9998056273097539, - 0.9998638341781910, - 0.9999061946325793, - 0.9999365445321382, - 0.9999579241373735, - 0.9999727092594598, - 0.9999827287418790, - 0.9999893678912771, - 0.9999936579844555, - 0.9999963523959187, - 0.9999979902130101, - 0.9999989484358076, - 0.9999994840031031, - 0.9999997669534347, - 0.9999999060327799, - 0.9999999680107184, - 0.9999999918774242, - 0.9999999989770326 + FRAC_CONST(0.00029256153896361), + FRAC_CONST(0.00042998567353047), + FRAC_CONST(0.00054674074589540), + FRAC_CONST(0.00065482304299792), + FRAC_CONST(0.00075870195068747), + FRAC_CONST(0.00086059331713336), + FRAC_CONST(0.00096177541439010), + FRAC_CONST(0.0010630609410878), + FRAC_CONST(0.0011650036308132), + FRAC_CONST(0.0012680012194148), + FRAC_CONST(0.0013723517232956), + FRAC_CONST(0.0014782864109136), + FRAC_CONST(0.0015859901976719), + FRAC_CONST(0.0016956148252373), + FRAC_CONST(0.0018072876903517), + FRAC_CONST(0.0019211179405514), + FRAC_CONST(0.0020372007924215), + FRAC_CONST(0.0021556206591754), + FRAC_CONST(0.0022764534599614), + FRAC_CONST(0.0023997683540995), + FRAC_CONST(0.0025256290631156), + FRAC_CONST(0.0026540948920831), + FRAC_CONST(0.0027852215281403), + FRAC_CONST(0.0029190616715331), + FRAC_CONST(0.0030556655443223), + FRAC_CONST(0.0031950812943391), + FRAC_CONST(0.0033373553240392), + FRAC_CONST(0.0034825325586930), + FRAC_CONST(0.0036306566699199), + FRAC_CONST(0.0037817702604646), + FRAC_CONST(0.0039359150179719), + FRAC_CONST(0.0040931318437260), + FRAC_CONST(0.0042534609610026), + FRAC_CONST(0.0044169420066964), + FRAC_CONST(0.0045836141091341), + FRAC_CONST(0.0047535159544086), + FRAC_CONST(0.0049266858431214), + FRAC_CONST(0.0051031617390698), + FRAC_CONST(0.0052829813111335), + FRAC_CONST(0.0054661819693975), + FRAC_CONST(0.0056528008963682), + FRAC_CONST(0.0058428750739943), + FRAC_CONST(0.0060364413070882), + FRAC_CONST(0.0062335362436492), + FRAC_CONST(0.0064341963925079), + FRAC_CONST(0.0066384581386503), + FRAC_CONST(0.0068463577565218), + FRAC_CONST(0.0070579314215715), + FRAC_CONST(0.0072732152202559), + FRAC_CONST(0.0074922451586909), + FRAC_CONST(0.0077150571701162), + FRAC_CONST(0.0079416871213115), + FRAC_CONST(0.0081721708180857), + FRAC_CONST(0.0084065440099458), + FRAC_CONST(0.0086448423940363), + FRAC_CONST(0.0088871016184291), + FRAC_CONST(0.0091333572848345), + FRAC_CONST(0.0093836449507939), + FRAC_CONST(0.0096380001314086), + FRAC_CONST(0.0098964583006517), + FRAC_CONST(0.010159054892306), + FRAC_CONST(0.010425825300561), + FRAC_CONST(0.010696804880310), + FRAC_CONST(0.010972028947167), + FRAC_CONST(0.011251532777236), + FRAC_CONST(0.011535351606646), + FRAC_CONST(0.011823520630897), + FRAC_CONST(0.012116075003993), + FRAC_CONST(0.012413049837429), + FRAC_CONST(0.012714480198999), + FRAC_CONST(0.013020401111478), + FRAC_CONST(0.013330847551161), + FRAC_CONST(0.013645854446288), + FRAC_CONST(0.013965456675352), + FRAC_CONST(0.014289689065314), + FRAC_CONST(0.014618586389712), + FRAC_CONST(0.014952183366697), + FRAC_CONST(0.015290514656976), + FRAC_CONST(0.015633614861688), + FRAC_CONST(0.015981518520214), + FRAC_CONST(0.016334260107915), + FRAC_CONST(0.016691874033817), + FRAC_CONST(0.017054394638241), + FRAC_CONST(0.017421856190380), + FRAC_CONST(0.017794292885832), + FRAC_CONST(0.018171738844085), + FRAC_CONST(0.018554228105962), + FRAC_CONST(0.018941794631032), + FRAC_CONST(0.019334472294980), + FRAC_CONST(0.019732294886947), + FRAC_CONST(0.020135296106839), + FRAC_CONST(0.020543509562604), + FRAC_CONST(0.020956968767488), + FRAC_CONST(0.021375707137257), + FRAC_CONST(0.021799757987407), + FRAC_CONST(0.022229154530343), + FRAC_CONST(0.022663929872540), + FRAC_CONST(0.023104117011689), + FRAC_CONST(0.023549748833816), + FRAC_CONST(0.024000858110398), + FRAC_CONST(0.024457477495451), + FRAC_CONST(0.024919639522613), + FRAC_CONST(0.025387376602207), + FRAC_CONST(0.025860721018295), + FRAC_CONST(0.026339704925726), + FRAC_CONST(0.026824360347160), + FRAC_CONST(0.027314719170100), + FRAC_CONST(0.027810813143900), + FRAC_CONST(0.028312673876775), + FRAC_CONST(0.028820332832801), + FRAC_CONST(0.029333821328905), + FRAC_CONST(0.029853170531859), + FRAC_CONST(0.030378411455255), + FRAC_CONST(0.030909574956490), + FRAC_CONST(0.031446691733739), + FRAC_CONST(0.031989792322926), + FRAC_CONST(0.032538907094693), + FRAC_CONST(0.033094066251369), + FRAC_CONST(0.033655299823935), + FRAC_CONST(0.034222637668991), + FRAC_CONST(0.034796109465717), + FRAC_CONST(0.035375744712844), + FRAC_CONST(0.035961572725616), + FRAC_CONST(0.036553622632758), + FRAC_CONST(0.037151923373446), + FRAC_CONST(0.037756503694277), + FRAC_CONST(0.038367392146243), + FRAC_CONST(0.038984617081711), + FRAC_CONST(0.039608206651398), + FRAC_CONST(0.040238188801359), + FRAC_CONST(0.040874591269976), + FRAC_CONST(0.041517441584950), + FRAC_CONST(0.042166767060301), + FRAC_CONST(0.042822594793376), + FRAC_CONST(0.043484951661852), + FRAC_CONST(0.044153864320760), + FRAC_CONST(0.044829359199509), + FRAC_CONST(0.045511462498913), + FRAC_CONST(0.046200200188234), + FRAC_CONST(0.046895598002228), + FRAC_CONST(0.047597681438201), + FRAC_CONST(0.048306475753074), + FRAC_CONST(0.049022005960455), + FRAC_CONST(0.049744296827725), + FRAC_CONST(0.050473372873129), + FRAC_CONST(0.051209258362879), + FRAC_CONST(0.051951977308273), + FRAC_CONST(0.052701553462813), + FRAC_CONST(0.053458010319350), + FRAC_CONST(0.054221371107223), + FRAC_CONST(0.054991658789428), + FRAC_CONST(0.055768896059787), + FRAC_CONST(0.056553105340134), + FRAC_CONST(0.057344308777513), + FRAC_CONST(0.058142528241393), + FRAC_CONST(0.058947785320893), + FRAC_CONST(0.059760101322019), + FRAC_CONST(0.060579497264926), + FRAC_CONST(0.061405993881180), + FRAC_CONST(0.062239611611049), + FRAC_CONST(0.063080370600799), + FRAC_CONST(0.063928290700012), + FRAC_CONST(0.064783391458919), + FRAC_CONST(0.065645692125747), + FRAC_CONST(0.066515211644086), + FRAC_CONST(0.067391968650269), + FRAC_CONST(0.068275981470777), + FRAC_CONST(0.069167268119652), + FRAC_CONST(0.070065846295935), + FRAC_CONST(0.070971733381121), + FRAC_CONST(0.071884946436630), + FRAC_CONST(0.072805502201299), + FRAC_CONST(0.073733417088896), + FRAC_CONST(0.074668707185649), + FRAC_CONST(0.075611388247794), + FRAC_CONST(0.076561475699152), + FRAC_CONST(0.077518984628715), + FRAC_CONST(0.078483929788261), + FRAC_CONST(0.079456325589986), + FRAC_CONST(0.080436186104162), + FRAC_CONST(0.081423525056808), + FRAC_CONST(0.082418355827392), + FRAC_CONST(0.083420691446553), + FRAC_CONST(0.084430544593841), + FRAC_CONST(0.085447927595483), + FRAC_CONST(0.086472852422178), + FRAC_CONST(0.087505330686900), + FRAC_CONST(0.088545373642744), + FRAC_CONST(0.089592992180780), + FRAC_CONST(0.090648196827937), + FRAC_CONST(0.091710997744919), + FRAC_CONST(0.092781404724131), + FRAC_CONST(0.093859427187640), + FRAC_CONST(0.094945074185163), + FRAC_CONST(0.096038354392069), + FRAC_CONST(0.097139276107423), + FRAC_CONST(0.098247847252041), + FRAC_CONST(0.099364075366580), + FRAC_CONST(0.10048796760965), + FRAC_CONST(0.10161953075597), + FRAC_CONST(0.10275877119451), + FRAC_CONST(0.10390569492671), + FRAC_CONST(0.10506030756469), + FRAC_CONST(0.10622261432949), + FRAC_CONST(0.10739262004941), + FRAC_CONST(0.10857032915821), + FRAC_CONST(0.10975574569357), + FRAC_CONST(0.11094887329534), + FRAC_CONST(0.11214971520402), + FRAC_CONST(0.11335827425914), + FRAC_CONST(0.11457455289772), + FRAC_CONST(0.11579855315274), + FRAC_CONST(0.11703027665170), + FRAC_CONST(0.11826972461510), + FRAC_CONST(0.11951689785504), + FRAC_CONST(0.12077179677383), + FRAC_CONST(0.12203442136263), + FRAC_CONST(0.12330477120008), + FRAC_CONST(0.12458284545102), + FRAC_CONST(0.12586864286523), + FRAC_CONST(0.12716216177615), + FRAC_CONST(0.12846340009971), + FRAC_CONST(0.12977235533312), + FRAC_CONST(0.13108902455375), + FRAC_CONST(0.13241340441801), + FRAC_CONST(0.13374549116025), + FRAC_CONST(0.13508528059173), + FRAC_CONST(0.13643276809961), + FRAC_CONST(0.13778794864595), + FRAC_CONST(0.13915081676677), + FRAC_CONST(0.14052136657114), + FRAC_CONST(0.14189959174027), + FRAC_CONST(0.14328548552671), + FRAC_CONST(0.14467904075349), + FRAC_CONST(0.14608024981336), + FRAC_CONST(0.14748910466804), + FRAC_CONST(0.14890559684750), + FRAC_CONST(0.15032971744929), + FRAC_CONST(0.15176145713790), + FRAC_CONST(0.15320080614414), + FRAC_CONST(0.15464775426459), + FRAC_CONST(0.15610229086100), + FRAC_CONST(0.15756440485987), + FRAC_CONST(0.15903408475193), + FRAC_CONST(0.16051131859170), + FRAC_CONST(0.16199609399712), + FRAC_CONST(0.16348839814917), + FRAC_CONST(0.16498821779156), + FRAC_CONST(0.16649553923042), + FRAC_CONST(0.16801034833404), + FRAC_CONST(0.16953263053270), + FRAC_CONST(0.17106237081842), + FRAC_CONST(0.17259955374484), + FRAC_CONST(0.17414416342714), + FRAC_CONST(0.17569618354193), + FRAC_CONST(0.17725559732720), + FRAC_CONST(0.17882238758238), + FRAC_CONST(0.18039653666830), + FRAC_CONST(0.18197802650733), + FRAC_CONST(0.18356683858343), + FRAC_CONST(0.18516295394233), + FRAC_CONST(0.18676635319174), + FRAC_CONST(0.18837701650148), + FRAC_CONST(0.18999492360384), + FRAC_CONST(0.19162005379380), + FRAC_CONST(0.19325238592940), + FRAC_CONST(0.19489189843209), + FRAC_CONST(0.19653856928714), + FRAC_CONST(0.19819237604409), + FRAC_CONST(0.19985329581721), + FRAC_CONST(0.20152130528605), + FRAC_CONST(0.20319638069594), + FRAC_CONST(0.20487849785865), + FRAC_CONST(0.20656763215298), + FRAC_CONST(0.20826375852540), + FRAC_CONST(0.20996685149083), + FRAC_CONST(0.21167688513330), + FRAC_CONST(0.21339383310678), + FRAC_CONST(0.21511766863598), + FRAC_CONST(0.21684836451719), + FRAC_CONST(0.21858589311922), + FRAC_CONST(0.22033022638425), + FRAC_CONST(0.22208133582887), + FRAC_CONST(0.22383919254503), + FRAC_CONST(0.22560376720111), + FRAC_CONST(0.22737503004300), + FRAC_CONST(0.22915295089517), + FRAC_CONST(0.23093749916189), + FRAC_CONST(0.23272864382838), + FRAC_CONST(0.23452635346201), + FRAC_CONST(0.23633059621364), + FRAC_CONST(0.23814133981883), + FRAC_CONST(0.23995855159925), + FRAC_CONST(0.24178219846403), + FRAC_CONST(0.24361224691114), + FRAC_CONST(0.24544866302890), + FRAC_CONST(0.24729141249740), + FRAC_CONST(0.24914046059007), + FRAC_CONST(0.25099577217522), + FRAC_CONST(0.25285731171763), + FRAC_CONST(0.25472504328019), + FRAC_CONST(0.25659893052556), + FRAC_CONST(0.25847893671788), + FRAC_CONST(0.26036502472451), + FRAC_CONST(0.26225715701781), + FRAC_CONST(0.26415529567692), + FRAC_CONST(0.26605940238966), + FRAC_CONST(0.26796943845439), + FRAC_CONST(0.26988536478190), + FRAC_CONST(0.27180714189742), + FRAC_CONST(0.27373472994256), + FRAC_CONST(0.27566808867736), + FRAC_CONST(0.27760717748238), + FRAC_CONST(0.27955195536071), + FRAC_CONST(0.28150238094021), + FRAC_CONST(0.28345841247557), + FRAC_CONST(0.28542000785059), + FRAC_CONST(0.28738712458038), + FRAC_CONST(0.28935971981364), + FRAC_CONST(0.29133775033492), + FRAC_CONST(0.29332117256704), + FRAC_CONST(0.29530994257338), + FRAC_CONST(0.29730401606034), + FRAC_CONST(0.29930334837974), + FRAC_CONST(0.30130789453132), + FRAC_CONST(0.30331760916521), + FRAC_CONST(0.30533244658452), + FRAC_CONST(0.30735236074785), + FRAC_CONST(0.30937730527195), + FRAC_CONST(0.31140723343430), + FRAC_CONST(0.31344209817583), + FRAC_CONST(0.31548185210356), + FRAC_CONST(0.31752644749341), + FRAC_CONST(0.31957583629288), + FRAC_CONST(0.32162997012390), + FRAC_CONST(0.32368880028565), + FRAC_CONST(0.32575227775738), + FRAC_CONST(0.32782035320134), + FRAC_CONST(0.32989297696566), + FRAC_CONST(0.33197009908736), + FRAC_CONST(0.33405166929523), + FRAC_CONST(0.33613763701295), + FRAC_CONST(0.33822795136203), + FRAC_CONST(0.34032256116495), + FRAC_CONST(0.34242141494820), + FRAC_CONST(0.34452446094547), + FRAC_CONST(0.34663164710072), + FRAC_CONST(0.34874292107143), + FRAC_CONST(0.35085823023181), + FRAC_CONST(0.35297752167598), + FRAC_CONST(0.35510074222129), + FRAC_CONST(0.35722783841160), + FRAC_CONST(0.35935875652060), + FRAC_CONST(0.36149344255514), + FRAC_CONST(0.36363184225864), + FRAC_CONST(0.36577390111444), + FRAC_CONST(0.36791956434930), + FRAC_CONST(0.37006877693676), + FRAC_CONST(0.37222148360070), + FRAC_CONST(0.37437762881878), + FRAC_CONST(0.37653715682603), + FRAC_CONST(0.37870001161834), + FRAC_CONST(0.38086613695607), + FRAC_CONST(0.38303547636766), + FRAC_CONST(0.38520797315322), + FRAC_CONST(0.38738357038821), + FRAC_CONST(0.38956221092708), + FRAC_CONST(0.39174383740701), + FRAC_CONST(0.39392839225157), + FRAC_CONST(0.39611581767449), + FRAC_CONST(0.39830605568342), + FRAC_CONST(0.40049904808370), + FRAC_CONST(0.40269473648218), + FRAC_CONST(0.40489306229101), + FRAC_CONST(0.40709396673153), + FRAC_CONST(0.40929739083810), + FRAC_CONST(0.41150327546197), + FRAC_CONST(0.41371156127524), + FRAC_CONST(0.41592218877472), + FRAC_CONST(0.41813509828594), + FRAC_CONST(0.42035022996702), + FRAC_CONST(0.42256752381274), + FRAC_CONST(0.42478691965848), + FRAC_CONST(0.42700835718423), + FRAC_CONST(0.42923177591866), + FRAC_CONST(0.43145711524314), + FRAC_CONST(0.43368431439580), + FRAC_CONST(0.43591331247564), + FRAC_CONST(0.43814404844658), + FRAC_CONST(0.44037646114161), + FRAC_CONST(0.44261048926688), + FRAC_CONST(0.44484607140589), + FRAC_CONST(0.44708314602359), + FRAC_CONST(0.44932165147057), + FRAC_CONST(0.45156152598727), + FRAC_CONST(0.45380270770813), + FRAC_CONST(0.45604513466581), + FRAC_CONST(0.45828874479543), + FRAC_CONST(0.46053347593880), + FRAC_CONST(0.46277926584861), + FRAC_CONST(0.46502605219277), + FRAC_CONST(0.46727377255861), + FRAC_CONST(0.46952236445718), + FRAC_CONST(0.47177176532752), + FRAC_CONST(0.47402191254100), + FRAC_CONST(0.47627274340557), + FRAC_CONST(0.47852419517009), + FRAC_CONST(0.48077620502869), + FRAC_CONST(0.48302871012505), + FRAC_CONST(0.48528164755674), + FRAC_CONST(0.48753495437962), + FRAC_CONST(0.48978856761212), + FRAC_CONST(0.49204242423966), + FRAC_CONST(0.49429646121898), + FRAC_CONST(0.49655061548250), + FRAC_CONST(0.49880482394273), + FRAC_CONST(0.50105902349665), + FRAC_CONST(0.50331315103004), + FRAC_CONST(0.50556714342194), + FRAC_CONST(0.50782093754901), + FRAC_CONST(0.51007447028990), + FRAC_CONST(0.51232767852971), + FRAC_CONST(0.51458049916433), + FRAC_CONST(0.51683286910489), + FRAC_CONST(0.51908472528213), + FRAC_CONST(0.52133600465083), + FRAC_CONST(0.52358664419420), + FRAC_CONST(0.52583658092832), + FRAC_CONST(0.52808575190648), + FRAC_CONST(0.53033409422367), + FRAC_CONST(0.53258154502092), + FRAC_CONST(0.53482804148974), + FRAC_CONST(0.53707352087652), + FRAC_CONST(0.53931792048690), + FRAC_CONST(0.54156117769021), + FRAC_CONST(0.54380322992385), + FRAC_CONST(0.54604401469766), + FRAC_CONST(0.54828346959835), + FRAC_CONST(0.55052153229384), + FRAC_CONST(0.55275814053768), + FRAC_CONST(0.55499323217338), + FRAC_CONST(0.55722674513883), + FRAC_CONST(0.55945861747062), + FRAC_CONST(0.56168878730842), + FRAC_CONST(0.56391719289930), + FRAC_CONST(0.56614377260214), + FRAC_CONST(0.56836846489188), + FRAC_CONST(0.57059120836390), + FRAC_CONST(0.57281194173835), + FRAC_CONST(0.57503060386439), + FRAC_CONST(0.57724713372458), + FRAC_CONST(0.57946147043912), + FRAC_CONST(0.58167355327012), + FRAC_CONST(0.58388332162591), + FRAC_CONST(0.58609071506528), + FRAC_CONST(0.58829567330173), + FRAC_CONST(0.59049813620770), + FRAC_CONST(0.59269804381879), + FRAC_CONST(0.59489533633802), + FRAC_CONST(0.59708995413996), + FRAC_CONST(0.59928183777495), + FRAC_CONST(0.60147092797329), + FRAC_CONST(0.60365716564937), + FRAC_CONST(0.60584049190582), + FRAC_CONST(0.60802084803764), + FRAC_CONST(0.61019817553632), + FRAC_CONST(0.61237241609393), + FRAC_CONST(0.61454351160718), + FRAC_CONST(0.61671140418155), + FRAC_CONST(0.61887603613527), + FRAC_CONST(0.62103735000336), + FRAC_CONST(0.62319528854167), + FRAC_CONST(0.62534979473088), + FRAC_CONST(0.62750081178042), + FRAC_CONST(0.62964828313250), + FRAC_CONST(0.63179215246597), + FRAC_CONST(0.63393236370030), + FRAC_CONST(0.63606886099946), + FRAC_CONST(0.63820158877577), + FRAC_CONST(0.64033049169379), + FRAC_CONST(0.64245551467413), + FRAC_CONST(0.64457660289729), + FRAC_CONST(0.64669370180740), + FRAC_CONST(0.64880675711607), + FRAC_CONST(0.65091571480603), + FRAC_CONST(0.65302052113494), + FRAC_CONST(0.65512112263906), + FRAC_CONST(0.65721746613689), + FRAC_CONST(0.65930949873289), + FRAC_CONST(0.66139716782102), + FRAC_CONST(0.66348042108842), + FRAC_CONST(0.66555920651892), + FRAC_CONST(0.66763347239664), + FRAC_CONST(0.66970316730947), + FRAC_CONST(0.67176824015260), + FRAC_CONST(0.67382864013196), + FRAC_CONST(0.67588431676768), + FRAC_CONST(0.67793521989751), + FRAC_CONST(0.67998129968017), + FRAC_CONST(0.68202250659876), + FRAC_CONST(0.68405879146403), + FRAC_CONST(0.68609010541774), + FRAC_CONST(0.68811639993588), + FRAC_CONST(0.69013762683195), + FRAC_CONST(0.69215373826012), + FRAC_CONST(0.69416468671849), + FRAC_CONST(0.69617042505214), + FRAC_CONST(0.69817090645634), + FRAC_CONST(0.70016608447958), + FRAC_CONST(0.70215591302664), + FRAC_CONST(0.70414034636163), + FRAC_CONST(0.70611933911096), + FRAC_CONST(0.70809284626630), + FRAC_CONST(0.71006082318751), + FRAC_CONST(0.71202322560554), + FRAC_CONST(0.71398000962530), + FRAC_CONST(0.71593113172842), + FRAC_CONST(0.71787654877613), + FRAC_CONST(0.71981621801195), + FRAC_CONST(0.72175009706445), + FRAC_CONST(0.72367814394990), + FRAC_CONST(0.72560031707496), + FRAC_CONST(0.72751657523927), + FRAC_CONST(0.72942687763803), + FRAC_CONST(0.73133118386457), + FRAC_CONST(0.73322945391280), + FRAC_CONST(0.73512164817975), + FRAC_CONST(0.73700772746796), + FRAC_CONST(0.73888765298787), + FRAC_CONST(0.74076138636020), + FRAC_CONST(0.74262888961827), + FRAC_CONST(0.74449012521027), + FRAC_CONST(0.74634505600152), + FRAC_CONST(0.74819364527663), + FRAC_CONST(0.75003585674175), + FRAC_CONST(0.75187165452661), + FRAC_CONST(0.75370100318668), + FRAC_CONST(0.75552386770515), + FRAC_CONST(0.75734021349500), + FRAC_CONST(0.75915000640095), + FRAC_CONST(0.76095321270137), + FRAC_CONST(0.76274979911019), + FRAC_CONST(0.76453973277875), + FRAC_CONST(0.76632298129757), + FRAC_CONST(0.76809951269819), + FRAC_CONST(0.76986929545481), + FRAC_CONST(0.77163229848604), + FRAC_CONST(0.77338849115651), + FRAC_CONST(0.77513784327849), + FRAC_CONST(0.77688032511340), + FRAC_CONST(0.77861590737340), + FRAC_CONST(0.78034456122283), + FRAC_CONST(0.78206625827961), + FRAC_CONST(0.78378097061667), + FRAC_CONST(0.78548867076330), + FRAC_CONST(0.78718933170643), + FRAC_CONST(0.78888292689189), + FRAC_CONST(0.79056943022564), + FRAC_CONST(0.79224881607494), + FRAC_CONST(0.79392105926949), + FRAC_CONST(0.79558613510249), + FRAC_CONST(0.79724401933170), + FRAC_CONST(0.79889468818046), + FRAC_CONST(0.80053811833858), + FRAC_CONST(0.80217428696334), + FRAC_CONST(0.80380317168028), + FRAC_CONST(0.80542475058405), + FRAC_CONST(0.80703900223920), + FRAC_CONST(0.80864590568089), + FRAC_CONST(0.81024544041560), + FRAC_CONST(0.81183758642175), + FRAC_CONST(0.81342232415032), + FRAC_CONST(0.81499963452540), + FRAC_CONST(0.81656949894467), + FRAC_CONST(0.81813189927991), + FRAC_CONST(0.81968681787738), + FRAC_CONST(0.82123423755821), + FRAC_CONST(0.82277414161874), + FRAC_CONST(0.82430651383076), + FRAC_CONST(0.82583133844180), + FRAC_CONST(0.82734860017528), + FRAC_CONST(0.82885828423070), + FRAC_CONST(0.83036037628369), + FRAC_CONST(0.83185486248609), + FRAC_CONST(0.83334172946597), + FRAC_CONST(0.83482096432759), + FRAC_CONST(0.83629255465130), + FRAC_CONST(0.83775648849344), + FRAC_CONST(0.83921275438615), + FRAC_CONST(0.84066134133716), + FRAC_CONST(0.84210223882952), + FRAC_CONST(0.84353543682130), + FRAC_CONST(0.84496092574524), + FRAC_CONST(0.84637869650833), + FRAC_CONST(0.84778874049138), + FRAC_CONST(0.84919104954855), + FRAC_CONST(0.85058561600677), + FRAC_CONST(0.85197243266520), + FRAC_CONST(0.85335149279457), + FRAC_CONST(0.85472279013653), + FRAC_CONST(0.85608631890295), + FRAC_CONST(0.85744207377513), + FRAC_CONST(0.85879004990298), + FRAC_CONST(0.86013024290422), + FRAC_CONST(0.86146264886346), + FRAC_CONST(0.86278726433124), + FRAC_CONST(0.86410408632306), + FRAC_CONST(0.86541311231838), + FRAC_CONST(0.86671434025950), + FRAC_CONST(0.86800776855046), + FRAC_CONST(0.86929339605590), + FRAC_CONST(0.87057122209981), + FRAC_CONST(0.87184124646433), + FRAC_CONST(0.87310346938840), + FRAC_CONST(0.87435789156650), + FRAC_CONST(0.87560451414719), + FRAC_CONST(0.87684333873173), + FRAC_CONST(0.87807436737261), + FRAC_CONST(0.87929760257204), + FRAC_CONST(0.88051304728038), + FRAC_CONST(0.88172070489456), + FRAC_CONST(0.88292057925645), + FRAC_CONST(0.88411267465117), + FRAC_CONST(0.88529699580537), + FRAC_CONST(0.88647354788545), + FRAC_CONST(0.88764233649580), + FRAC_CONST(0.88880336767692), + FRAC_CONST(0.88995664790351), + FRAC_CONST(0.89110218408260), + FRAC_CONST(0.89223998355154), + FRAC_CONST(0.89337005407600), + FRAC_CONST(0.89449240384793), + FRAC_CONST(0.89560704148345), + FRAC_CONST(0.89671397602074), + FRAC_CONST(0.89781321691786), + FRAC_CONST(0.89890477405053), + FRAC_CONST(0.89998865770993), + FRAC_CONST(0.90106487860034), + FRAC_CONST(0.90213344783689), + FRAC_CONST(0.90319437694315), + FRAC_CONST(0.90424767784873), + FRAC_CONST(0.90529336288690), + FRAC_CONST(0.90633144479201), + FRAC_CONST(0.90736193669708), + FRAC_CONST(0.90838485213119), + FRAC_CONST(0.90940020501694), + FRAC_CONST(0.91040800966776), + FRAC_CONST(0.91140828078533), + FRAC_CONST(0.91240103345685), + FRAC_CONST(0.91338628315231), + FRAC_CONST(0.91436404572173), + FRAC_CONST(0.91533433739238), + FRAC_CONST(0.91629717476594), + FRAC_CONST(0.91725257481564), + FRAC_CONST(0.91820055488334), + FRAC_CONST(0.91914113267664), + FRAC_CONST(0.92007432626589), + FRAC_CONST(0.92100015408120), + FRAC_CONST(0.92191863490944), + FRAC_CONST(0.92282978789113), + FRAC_CONST(0.92373363251740), + FRAC_CONST(0.92463018862687), + FRAC_CONST(0.92551947640245), + FRAC_CONST(0.92640151636824), + FRAC_CONST(0.92727632938624), + FRAC_CONST(0.92814393665320), + FRAC_CONST(0.92900435969727), + FRAC_CONST(0.92985762037477), + FRAC_CONST(0.93070374086684), + FRAC_CONST(0.93154274367610), + FRAC_CONST(0.93237465162328), + FRAC_CONST(0.93319948784382), + FRAC_CONST(0.93401727578443), + FRAC_CONST(0.93482803919967), + FRAC_CONST(0.93563180214841), + FRAC_CONST(0.93642858899043), + FRAC_CONST(0.93721842438279), + FRAC_CONST(0.93800133327637), + FRAC_CONST(0.93877734091223), + FRAC_CONST(0.93954647281807), + FRAC_CONST(0.94030875480458), + FRAC_CONST(0.94106421296182), + FRAC_CONST(0.94181287365556), + FRAC_CONST(0.94255476352362), + FRAC_CONST(0.94328990947213), + FRAC_CONST(0.94401833867184), + FRAC_CONST(0.94474007855439), + FRAC_CONST(0.94545515680855), + FRAC_CONST(0.94616360137644), + FRAC_CONST(0.94686544044975), + FRAC_CONST(0.94756070246592), + FRAC_CONST(0.94824941610434), + FRAC_CONST(0.94893161028248), + FRAC_CONST(0.94960731415209), + FRAC_CONST(0.95027655709525), + FRAC_CONST(0.95093936872056), + FRAC_CONST(0.95159577885924), + FRAC_CONST(0.95224581756115), + FRAC_CONST(0.95288951509097), + FRAC_CONST(0.95352690192417), + FRAC_CONST(0.95415800874314), + FRAC_CONST(0.95478286643320), + FRAC_CONST(0.95540150607863), + FRAC_CONST(0.95601395895871), + FRAC_CONST(0.95662025654373), + FRAC_CONST(0.95722043049100), + FRAC_CONST(0.95781451264084), + FRAC_CONST(0.95840253501260), + FRAC_CONST(0.95898452980058), + FRAC_CONST(0.95956052937008), + FRAC_CONST(0.96013056625336), + FRAC_CONST(0.96069467314557), + FRAC_CONST(0.96125288290073), + FRAC_CONST(0.96180522852773), + FRAC_CONST(0.96235174318622), + FRAC_CONST(0.96289246018262), + FRAC_CONST(0.96342741296604), + FRAC_CONST(0.96395663512424), + FRAC_CONST(0.96448016037959), + FRAC_CONST(0.96499802258499), + FRAC_CONST(0.96551025571985), + FRAC_CONST(0.96601689388602), + FRAC_CONST(0.96651797130376), + FRAC_CONST(0.96701352230768), + FRAC_CONST(0.96750358134269), + FRAC_CONST(0.96798818295998), + FRAC_CONST(0.96846736181297), + FRAC_CONST(0.96894115265327), + FRAC_CONST(0.96940959032667), + FRAC_CONST(0.96987270976912), + FRAC_CONST(0.97033054600270), + FRAC_CONST(0.97078313413161), + FRAC_CONST(0.97123050933818), + FRAC_CONST(0.97167270687887), + FRAC_CONST(0.97210976208030), + FRAC_CONST(0.97254171033525), + FRAC_CONST(0.97296858709871), + FRAC_CONST(0.97339042788392), + FRAC_CONST(0.97380726825843), + FRAC_CONST(0.97421914384017), + FRAC_CONST(0.97462609029350), + FRAC_CONST(0.97502814332534), + FRAC_CONST(0.97542533868127), + FRAC_CONST(0.97581771214160), + FRAC_CONST(0.97620529951759), + FRAC_CONST(0.97658813664749), + FRAC_CONST(0.97696625939282), + FRAC_CONST(0.97733970363445), + FRAC_CONST(0.97770850526884), + FRAC_CONST(0.97807270020427), + FRAC_CONST(0.97843232435704), + FRAC_CONST(0.97878741364771), + FRAC_CONST(0.97913800399743), + FRAC_CONST(0.97948413132414), + FRAC_CONST(0.97982583153895), + FRAC_CONST(0.98016314054243), + FRAC_CONST(0.98049609422096), + FRAC_CONST(0.98082472844313), + FRAC_CONST(0.98114907905608), + FRAC_CONST(0.98146918188197), + FRAC_CONST(0.98178507271438), + FRAC_CONST(0.98209678731477), + FRAC_CONST(0.98240436140902), + FRAC_CONST(0.98270783068385), + FRAC_CONST(0.98300723078342), + FRAC_CONST(0.98330259730589), + FRAC_CONST(0.98359396579995), + FRAC_CONST(0.98388137176152), + FRAC_CONST(0.98416485063031), + FRAC_CONST(0.98444443778651), + FRAC_CONST(0.98472016854752), + FRAC_CONST(0.98499207816463), + FRAC_CONST(0.98526020181980), + FRAC_CONST(0.98552457462240), + FRAC_CONST(0.98578523160609), + FRAC_CONST(0.98604220772560), + FRAC_CONST(0.98629553785362), + FRAC_CONST(0.98654525677772), + FRAC_CONST(0.98679139919726), + FRAC_CONST(0.98703399972035), + FRAC_CONST(0.98727309286089), + FRAC_CONST(0.98750871303556), + FRAC_CONST(0.98774089456089), + FRAC_CONST(0.98796967165036), + FRAC_CONST(0.98819507841154), + FRAC_CONST(0.98841714884323), + FRAC_CONST(0.98863591683269), + FRAC_CONST(0.98885141615285), + FRAC_CONST(0.98906368045957), + FRAC_CONST(0.98927274328896), + FRAC_CONST(0.98947863805473), + FRAC_CONST(0.98968139804554), + FRAC_CONST(0.98988105642241), + FRAC_CONST(0.99007764621618), + FRAC_CONST(0.99027120032501), + FRAC_CONST(0.99046175151186), + FRAC_CONST(0.99064933240208), + FRAC_CONST(0.99083397548099), + FRAC_CONST(0.99101571309153), + FRAC_CONST(0.99119457743191), + FRAC_CONST(0.99137060055337), + FRAC_CONST(0.99154381435784), + FRAC_CONST(0.99171425059582), + FRAC_CONST(0.99188194086414), + FRAC_CONST(0.99204691660388), + FRAC_CONST(0.99220920909823), + FRAC_CONST(0.99236884947045), + FRAC_CONST(0.99252586868186), + FRAC_CONST(0.99268029752989), + FRAC_CONST(0.99283216664606), + FRAC_CONST(0.99298150649419), + FRAC_CONST(0.99312834736847), + FRAC_CONST(0.99327271939167), + FRAC_CONST(0.99341465251338), + FRAC_CONST(0.99355417650825), + FRAC_CONST(0.99369132097430), + FRAC_CONST(0.99382611533130), + FRAC_CONST(0.99395858881910), + FRAC_CONST(0.99408877049612), + FRAC_CONST(0.99421668923778), + FRAC_CONST(0.99434237373503), + FRAC_CONST(0.99446585249289), + FRAC_CONST(0.99458715382906), + FRAC_CONST(0.99470630587254), + FRAC_CONST(0.99482333656229), + FRAC_CONST(0.99493827364600), + FRAC_CONST(0.99505114467878), + FRAC_CONST(0.99516197702200), + FRAC_CONST(0.99527079784214), + FRAC_CONST(0.99537763410962), + FRAC_CONST(0.99548251259777), + FRAC_CONST(0.99558545988178), + FRAC_CONST(0.99568650233767), + FRAC_CONST(0.99578566614138), + FRAC_CONST(0.99588297726783), + FRAC_CONST(0.99597846149005), + FRAC_CONST(0.99607214437834), + FRAC_CONST(0.99616405129947), + FRAC_CONST(0.99625420741595), + FRAC_CONST(0.99634263768527), + FRAC_CONST(0.99642936685928), + FRAC_CONST(0.99651441948352), + FRAC_CONST(0.99659781989663), + FRAC_CONST(0.99667959222978), + FRAC_CONST(0.99675976040620), + FRAC_CONST(0.99683834814063), + FRAC_CONST(0.99691537893895), + FRAC_CONST(0.99699087609774), + FRAC_CONST(0.99706486270391), + FRAC_CONST(0.99713736163442), + FRAC_CONST(0.99720839555593), + FRAC_CONST(0.99727798692461), + FRAC_CONST(0.99734615798589), + FRAC_CONST(0.99741293077431), + FRAC_CONST(0.99747832711337), + FRAC_CONST(0.99754236861541), + FRAC_CONST(0.99760507668158), + FRAC_CONST(0.99766647250181), + FRAC_CONST(0.99772657705478), + FRAC_CONST(0.99778541110799), + FRAC_CONST(0.99784299521785), + FRAC_CONST(0.99789934972976), + FRAC_CONST(0.99795449477828), + FRAC_CONST(0.99800845028730), + FRAC_CONST(0.99806123597027), + FRAC_CONST(0.99811287133042), + FRAC_CONST(0.99816337566108), + FRAC_CONST(0.99821276804596), + FRAC_CONST(0.99826106735952), + FRAC_CONST(0.99830829226732), + FRAC_CONST(0.99835446122649), + FRAC_CONST(0.99839959248609), + FRAC_CONST(0.99844370408765), + FRAC_CONST(0.99848681386566), + FRAC_CONST(0.99852893944805), + FRAC_CONST(0.99857009825685), + FRAC_CONST(0.99861030750869), + FRAC_CONST(0.99864958421549), + FRAC_CONST(0.99868794518504), + FRAC_CONST(0.99872540702178), + FRAC_CONST(0.99876198612738), + FRAC_CONST(0.99879769870160), + FRAC_CONST(0.99883256074295), + FRAC_CONST(0.99886658804953), + FRAC_CONST(0.99889979621983), + FRAC_CONST(0.99893220065356), + FRAC_CONST(0.99896381655254), + FRAC_CONST(0.99899465892154), + FRAC_CONST(0.99902474256924), + FRAC_CONST(0.99905408210916), + FRAC_CONST(0.99908269196056), + FRAC_CONST(0.99911058634952), + FRAC_CONST(0.99913777930986), + FRAC_CONST(0.99916428468421), + FRAC_CONST(0.99919011612505), + FRAC_CONST(0.99921528709576), + FRAC_CONST(0.99923981087174), + FRAC_CONST(0.99926370054150), + FRAC_CONST(0.99928696900779), + FRAC_CONST(0.99930962898876), + FRAC_CONST(0.99933169301910), + FRAC_CONST(0.99935317345126), + FRAC_CONST(0.99937408245662), + FRAC_CONST(0.99939443202674), + FRAC_CONST(0.99941423397457), + FRAC_CONST(0.99943349993572), + FRAC_CONST(0.99945224136972), + FRAC_CONST(0.99947046956130), + FRAC_CONST(0.99948819562171), + FRAC_CONST(0.99950543049000), + FRAC_CONST(0.99952218493439), + FRAC_CONST(0.99953846955355), + FRAC_CONST(0.99955429477803), + FRAC_CONST(0.99956967087154), + FRAC_CONST(0.99958460793242), + FRAC_CONST(0.99959911589494), + FRAC_CONST(0.99961320453077), + FRAC_CONST(0.99962688345035), + FRAC_CONST(0.99964016210433), + FRAC_CONST(0.99965304978499), + FRAC_CONST(0.99966555562769), + FRAC_CONST(0.99967768861231), + FRAC_CONST(0.99968945756473), + FRAC_CONST(0.99970087115825), + FRAC_CONST(0.99971193791510), + FRAC_CONST(0.99972266620792), + FRAC_CONST(0.99973306426121), + FRAC_CONST(0.99974314015288), + FRAC_CONST(0.99975290181568), + FRAC_CONST(0.99976235703876), + FRAC_CONST(0.99977151346914), + FRAC_CONST(0.99978037861326), + FRAC_CONST(0.99978895983845), + FRAC_CONST(0.99979726437448), + FRAC_CONST(0.99980529931507), + FRAC_CONST(0.99981307161943), + FRAC_CONST(0.99982058811377), + FRAC_CONST(0.99982785549283), + FRAC_CONST(0.99983488032144), + FRAC_CONST(0.99984166903600), + FRAC_CONST(0.99984822794606), + FRAC_CONST(0.99985456323584), + FRAC_CONST(0.99986068096572), + FRAC_CONST(0.99986658707386), + FRAC_CONST(0.99987228737764), + FRAC_CONST(0.99987778757524), + FRAC_CONST(0.99988309324717), + FRAC_CONST(0.99988820985777), + FRAC_CONST(0.99989314275675), + FRAC_CONST(0.99989789718072), + FRAC_CONST(0.99990247825468), + FRAC_CONST(0.99990689099357), + FRAC_CONST(0.99991114030376), + FRAC_CONST(0.99991523098456), + FRAC_CONST(0.99991916772971), + FRAC_CONST(0.99992295512891), + FRAC_CONST(0.99992659766930), + FRAC_CONST(0.99993009973692), + FRAC_CONST(0.99993346561824), + FRAC_CONST(0.99993669950161), + FRAC_CONST(0.99993980547870), + FRAC_CONST(0.99994278754604), + FRAC_CONST(0.99994564960642), + FRAC_CONST(0.99994839547033), + FRAC_CONST(0.99995102885747), + FRAC_CONST(0.99995355339809), + FRAC_CONST(0.99995597263451), + FRAC_CONST(0.99995829002249), + FRAC_CONST(0.99996050893264), + FRAC_CONST(0.99996263265183), + FRAC_CONST(0.99996466438460), + FRAC_CONST(0.99996660725452), + FRAC_CONST(0.99996846430558), + FRAC_CONST(0.99997023850356), + FRAC_CONST(0.99997193273736), + FRAC_CONST(0.99997354982037), + FRAC_CONST(0.99997509249183), + FRAC_CONST(0.99997656341810), + FRAC_CONST(0.99997796519400), + FRAC_CONST(0.99997930034415), + FRAC_CONST(0.99998057132421), + FRAC_CONST(0.99998178052220), + FRAC_CONST(0.99998293025975), + FRAC_CONST(0.99998402279338), + FRAC_CONST(0.99998506031574), + FRAC_CONST(0.99998604495686), + FRAC_CONST(0.99998697878536), + FRAC_CONST(0.99998786380966), + FRAC_CONST(0.99998870197921), + FRAC_CONST(0.99998949518567), + FRAC_CONST(0.99999024526408), + FRAC_CONST(0.99999095399401), + FRAC_CONST(0.99999162310077), + FRAC_CONST(0.99999225425649), + FRAC_CONST(0.99999284908128), + FRAC_CONST(0.99999340914435), + FRAC_CONST(0.99999393596510), + FRAC_CONST(0.99999443101421), + FRAC_CONST(0.99999489571473), + FRAC_CONST(0.99999533144314), + FRAC_CONST(0.99999573953040), + FRAC_CONST(0.99999612126300), + FRAC_CONST(0.99999647788395), + FRAC_CONST(0.99999681059383), + FRAC_CONST(0.99999712055178), + FRAC_CONST(0.99999740887647), + FRAC_CONST(0.99999767664709), + FRAC_CONST(0.99999792490431), + FRAC_CONST(0.99999815465123), + FRAC_CONST(0.99999836685427), + FRAC_CONST(0.99999856244415), + FRAC_CONST(0.99999874231676), + FRAC_CONST(0.99999890733405), + FRAC_CONST(0.99999905832493), + FRAC_CONST(0.99999919608613), + FRAC_CONST(0.99999932138304), + FRAC_CONST(0.99999943495056), + FRAC_CONST(0.99999953749392), + FRAC_CONST(0.99999962968950), + FRAC_CONST(0.99999971218563), + FRAC_CONST(0.99999978560337), + FRAC_CONST(0.99999985053727), + FRAC_CONST(0.99999990755616), + FRAC_CONST(0.99999995720387) }; -#else - -real_t kbd_long_1024[] = -{ - 0x132C5, - 0x1C2DF, - 0x23D4C, - 0x2AEA1, - 0x31B8E, - 0x38665, - 0x3F07E, - 0x45AB3, - 0x4C598, - 0x53198, - 0x59F03, - 0x60E18, - 0x67F08, - 0x6F1FB, - 0x76714, - 0x7DE70, - 0x85828, - 0x8D455, - 0x95308, - 0x9D456, - 0xA5850, - 0xADF05, - 0xB6884, - 0xBF4DB, - 0xC8419, - 0xD1649, - 0xDAB78, - 0xE43B3, - 0xEDF05, - 0xF7D79, - 0x101F1B, - 0x10C3F5, - 0x116C13, - 0x12177F, - 0x12C644, - 0x13786C, - 0x142E01, - 0x14E70D, - 0x15A39B, - 0x1663B5, - 0x172764, - 0x17EEB2, - 0x18B9AA, - 0x198856, - 0x1A5ABE, - 0x1B30ED, - 0x1C0AED, - 0x1CE8C7, - 0x1DCA84, - 0x1EB030, - 0x1F99D2, - 0x208776, - 0x217924, - 0x226EE6, - 0x2368C6, - 0x2466CD, - 0x256905, - 0x266F77, - 0x277A2D, - 0x288930, - 0x299C8A, - 0x2AB445, - 0x2BD069, - 0x2CF101, - 0x2E1616, - 0x2F3FB1, - 0x306DDC, - 0x31A0A0, - 0x32D806, - 0x341419, - 0x3554E1, - 0x369A68, - 0x37E4B7, - 0x3933D7, - 0x3A87D3, - 0x3BE0B3, - 0x3D3E80, - 0x3EA144, - 0x400908, - 0x4175D6, - 0x42E7B6, - 0x445EB3, - 0x45DAD4, - 0x475C24, - 0x48E2AB, - 0x4A6E73, - 0x4BFF84, - 0x4D95E9, - 0x4F31AA, - 0x50D2CF, - 0x527963, - 0x54256E, - 0x55D6F9, - 0x578E0D, - 0x594AB4, - 0x5B0CF5, - 0x5CD4DA, - 0x5EA26C, - 0x6075B3, - 0x624EB9, - 0x642D86, - 0x661223, - 0x67FC98, - 0x69ECEE, - 0x6BE32E, - 0x6DDF61, - 0x6FE18F, - 0x71E9C0, - 0x73F7FD, - 0x760C4F, - 0x7826BD, - 0x7A4751, - 0x7C6E12, - 0x7E9B0A, - 0x80CE3F, - 0x8307BA, - 0x854784, - 0x878DA5, - 0x89DA24, - 0x8C2D09, - 0x8E865E, - 0x90E628, - 0x934C71, - 0x95B940, - 0x982C9D, - 0x9AA690, - 0x9D2720, - 0x9FAE55, - 0xA23C37, - 0xA4D0CD, - 0xA76C1E, - 0xAA0E31, - 0xACB70F, - 0xAF66BF, - 0xB21D47, - 0xB4DAAF, - 0xB79EFD, - 0xBA6A3A, - 0xBD3C6C, - 0xC01599, - 0xC2F5C9, - 0xC5DD03, - 0xC8CB4D, - 0xCBC0AD, - 0xCEBD2B, - 0xD1C0CD, - 0xD4CB99, - 0xD7DD96, - 0xDAF6C9, - 0xDE173A, - 0xE13EEF, - 0xE46DED, - 0xE7A43B, - 0xEAE1DE, - 0xEE26DC, - 0xF1733C, - 0xF4C702, - 0xF82235, - 0xFB84DA, - 0xFEEEF7, - 0x1026090, - 0x105D9AC, - 0x1095A50, - 0x10CE280, - 0x1107242, - 0x114099A, - 0x117A88E, - 0x11B4F24, - 0x11EFD5E, - 0x122B342, - 0x12670D4, - 0x12A361A, - 0x12E0318, - 0x131D7D0, - 0x135B44A, - 0x1399886, - 0x13D848C, - 0x141785E, - 0x14573FE, - 0x1497774, - 0x14D82C2, - 0x15195E8, - 0x155B0F0, - 0x159D3D8, - 0x15DFEA6, - 0x162315C, - 0x1666BFE, - 0x16AAE8E, - 0x16EF910, - 0x1734B86, - 0x177A5F4, - 0x17C085A, - 0x18072BE, - 0x184E520, - 0x1895F84, - 0x18DE1EA, - 0x1926C56, - 0x196FEC8, - 0x19B9946, - 0x1A03BCE, - 0x1A4E662, - 0x1A99904, - 0x1AE53B8, - 0x1B3167C, - 0x1B7E152, - 0x1BCB43E, - 0x1C18F3E, - 0x1C67254, - 0x1CB5D80, - 0x1D050C4, - 0x1D54C20, - 0x1DA4F96, - 0x1DF5B24, - 0x1E46ECC, - 0x1E98A8C, - 0x1EEAE68, - 0x1F3DA5E, - 0x1F90E6C, - 0x1FE4A94, - 0x2038ED8, - 0x208DB30, - 0x20E2FA4, - 0x2138C2C, - 0x218F0D0, - 0x21E5D84, - 0x223D250, - 0x2294F30, - 0x22ED420, - 0x2346124, - 0x239F634, - 0x23F9354, - 0x2453880, - 0x24AE5B8, - 0x2509AF8, - 0x2565840, - 0x25C1D88, - 0x261EAD4, - 0x267C024, - 0x26D9D6C, - 0x27382B0, - 0x2796FEC, - 0x27F651C, - 0x2856240, - 0x28B6754, - 0x2917450, - 0x2978938, - 0x29DA604, - 0x2A3CAB0, - 0x2A9F738, - 0x2B02BA0, - 0x2B667D8, - 0x2BCABE4, - 0x2C2F7C0, - 0x2C94B64, - 0x2CFA6CC, - 0x2D609F8, - 0x2DC74DC, - 0x2E2E77C, - 0x2E961CC, - 0x2EFE3C8, - 0x2F66D6C, - 0x2FCFEB8, - 0x30397A0, - 0x30A381C, - 0x310E030, - 0x3178FD0, - 0x31E46F8, - 0x32505A0, - 0x32BCBC4, - 0x3329960, - 0x3396E68, - 0x3404AD8, - 0x3472EAC, - 0x34E19DC, - 0x3550C60, - 0x35C0634, - 0x363074C, - 0x36A0FA8, - 0x3711F38, - 0x37835FC, - 0x37F53EC, - 0x38678FC, - 0x38DA528, - 0x394D868, - 0x39C12B4, - 0x3A35400, - 0x3AA9C48, - 0x3B1EB84, - 0x3B941AC, - 0x3C09EB4, - 0x3C80298, - 0x3CF6D4C, - 0x3D6DEC8, - 0x3DE5704, - 0x3E5D5F4, - 0x3ED5B94, - 0x3F4E7D8, - 0x3FC7AB4, - 0x4041428, - 0x40BB418, - 0x4135A90, - 0x41B0778, - 0x422BAD0, - 0x42A7488, - 0x4323490, - 0x439FAE8, - 0x441C780, - 0x4499A50, - 0x4517350, - 0x4595270, - 0x46137A8, - 0x46922F0, - 0x4711438, - 0x4790B78, - 0x48108A0, - 0x4890BB0, - 0x4911490, - 0x4992340, - 0x4A137A8, - 0x4A951C8, - 0x4B17188, - 0x4B996E8, - 0x4C1C1D8, - 0x4C9F250, - 0x4D22838, - 0x4DA6390, - 0x4E2A448, - 0x4EAEA50, - 0x4F335A0, - 0x4FB8628, - 0x503DBE0, - 0x50C36B0, - 0x51496A0, - 0x51CFB90, - 0x5256578, - 0x52DD450, - 0x5364808, - 0x53EC090, - 0x5473DD8, - 0x54FBFE0, - 0x5584690, - 0x560D1D8, - 0x56961B8, - 0x571F610, - 0x57A8EE0, - 0x5832C18, - 0x58BCDA0, - 0x5947378, - 0x59D1D88, - 0x5A5CBC0, - 0x5AE7E20, - 0x5B73488, - 0x5BFEEF8, - 0x5C8AD58, - 0x5D16FA0, - 0x5DA35B8, - 0x5E2FFA0, - 0x5EBCD40, - 0x5F49E80, - 0x5FD7368, - 0x6064BD0, - 0x60F27C0, - 0x6180718, - 0x620E9D0, - 0x629CFD8, - 0x632B920, - 0x63BA598, - 0x6449530, - 0x64D87D8, - 0x6567D88, - 0x65F7628, - 0x66871B0, - 0x6717008, - 0x67A7128, - 0x68374F8, - 0x68C7B68, - 0x6958478, - 0x69E9000, - 0x6A79E08, - 0x6B0AE70, - 0x6B9C128, - 0x6C2D628, - 0x6CBED60, - 0x6D506B8, - 0x6DE2220, - 0x6E73F90, - 0x6F05EF8, - 0x6F98040, - 0x702A358, - 0x70BC830, - 0x714EEC0, - 0x71E16E8, - 0x72740A8, - 0x7306BE8, - 0x7399898, - 0x742C6A0, - 0x74BF5F8, - 0x7552698, - 0x75E5858, - 0x7678B38, - 0x770BF28, - 0x779F410, - 0x78329E0, - 0x78C6090, - 0x7959800, - 0x79ED028, - 0x7A80900, - 0x7B14260, - 0x7BA7C50, - 0x7C3B6B0, - 0x7CCF170, - 0x7D62C88, - 0x7DF67E0, - 0x7E8A368, - 0x7F1DF10, - 0x7FB1AC8, - 0x8045670, - 0x80D9210, - 0x816CD90, - 0x82008E0, - 0x82943E0, - 0x8327E80, - 0x83BB8C0, - 0x844F290, - 0x84E2BD0, - 0x8576470, - 0x8609C60, - 0x869D3A0, - 0x8730A10, - 0x87C3FA0, - 0x8857440, - 0x88EA7E0, - 0x897DA60, - 0x8A10BD0, - 0x8AA3C10, - 0x8B36B00, - 0x8BC98A0, - 0x8C5C4E0, - 0x8CEEFB0, - 0x8D818F0, - 0x8E14090, - 0x8EA6690, - 0x8F38AE0, - 0x8FCAD60, - 0x905CE10, - 0x90EECC0, - 0x9180990, - 0x9212440, - 0x92A3CE0, - 0x9335350, - 0x93C6780, - 0x9457960, - 0x94E88F0, - 0x9579610, - 0x960A0B0, - 0x969A8C0, - 0x972AE30, - 0x97BB0F0, - 0x984B100, - 0x98DAE30, - 0x996A890, - 0x99FA000, - 0x9A89470, - 0x9B185D0, - 0x9BA7410, - 0x9C35F30, - 0x9CC4700, - 0x9D52B90, - 0x9DE0CC0, - 0x9E6EA90, - 0x9EFC4E0, - 0x9F89BA0, - 0xA016ED0, - 0xA0A3E50, - 0xA130A10, - 0xA1BD210, - 0xA249640, - 0xA2D5690, - 0xA3612E0, - 0xA3ECB30, - 0xA477F70, - 0xA502F90, - 0xA58DB80, - 0xA618330, - 0xA6A26A0, - 0xA72C5A0, - 0xA7B6050, - 0xA83F670, - 0xA8C8820, - 0xA951530, - 0xA9D9DA0, - 0xAA62170, - 0xAAEA070, - 0xAB71AB0, - 0xABF9010, - 0xAC80090, - 0xAD06C10, - 0xAD8D2A0, - 0xAE13410, - 0xAE99070, - 0xAF1E7A0, - 0xAFA39A0, - 0xB028650, - 0xB0ACDC0, - 0xB130FD0, - 0xB1B4C70, - 0xB2383A0, - 0xB2BB540, - 0xB33E160, - 0xB3C07D0, - 0xB4428B0, - 0xB4C43D0, - 0xB545930, - 0xB5C68C0, - 0xB647270, - 0xB6C7650, - 0xB747430, - 0xB7C6C20, - 0xB845E00, - 0xB8C49D0, - 0xB942F90, - 0xB9C0F10, - 0xBA3E870, - 0xBABBB80, - 0xBB38850, - 0xBBB4ED0, - 0xBC30EF0, - 0xBCAC8A0, - 0xBD27BE0, - 0xBDA28A0, - 0xBE1CED0, - 0xBE96E80, - 0xBF10780, - 0xBF899E0, - 0xC0025A0, - 0xC07AA90, - 0xC0F28D0, - 0xC16A030, - 0xC1E10C0, - 0xC257A80, - 0xC2CDD40, - 0xC343920, - 0xC3B8E00, - 0xC42DBE0, - 0xC4A22B0, - 0xC516270, - 0xC589B20, - 0xC5FCCA0, - 0xC66F6F0, - 0xC6E1A10, - 0xC7535F0, - 0xC7C4A90, - 0xC8357F0, - 0xC8A5DF0, - 0xC915C90, - 0xC9853D0, - 0xC9F43B0, - 0xCA62C20, - 0xCAD0D20, - 0xCB3E690, - 0xCBAB880, - 0xCC182F0, - 0xCC845D0, - 0xCCF0110, - 0xCD5B4B0, - 0xCDC60B0, - 0xCE30510, - 0xCE9A1C0, - 0xCF036B0, - 0xCF6C3F0, - 0xCFD4970, - 0xD03C720, - 0xD0A3D10, - 0xD10AB30, - 0xD171180, - 0xD1D6FF0, - 0xD23C680, - 0xD2A1530, - 0xD305C00, - 0xD369AF0, - 0xD3CD1E0, - 0xD4300E0, - 0xD4927F0, - 0xD4F4710, - 0xD555E20, - 0xD5B6D40, - 0xD617450, - 0xD677360, - 0xD6D6A60, - 0xD735950, - 0xD794030, - 0xD7F1F00, - 0xD84F5C0, - 0xD8AC460, - 0xD908AF0, - 0xD964960, - 0xD9BFFB0, - 0xDA1ADE0, - 0xDA753E0, - 0xDACF1D0, - 0xDB28790, - 0xDB81530, - 0xDBD9AA0, - 0xDC317F0, - 0xDC88D10, - 0xDCDFA00, - 0xDD35ED0, - 0xDD8BB70, - 0xDDE0FE0, - 0xDE35C20, - 0xDE8A030, - 0xDEDDC10, - 0xDF30FD0, - 0xDF83B50, - 0xDFD5EB0, - 0xE0279E0, - 0xE078CE0, - 0xE0C97B0, - 0xE119A60, - 0xE1694E0, - 0xE1B8730, - 0xE207150, - 0xE255350, - 0xE2A2D30, - 0xE2EFEE0, - 0xE33C870, - 0xE3889E0, - 0xE3D4330, - 0xE41F460, - 0xE469D70, - 0xE4B3E60, - 0xE4FD740, - 0xE546810, - 0xE58F0C0, - 0xE5D7160, - 0xE61EA00, - 0xE665A80, - 0xE6AC300, - 0xE6F2380, - 0xE737BF0, - 0xE77CC70, - 0xE7C14E0, - 0xE805560, - 0xE848DF0, - 0xE88BE90, - 0xE8CE740, - 0xE910800, - 0xE9520E0, - 0xE9931D0, - 0xE9D3AF0, - 0xEA13C30, - 0xEA535A0, - 0xEA92740, - 0xEAD1110, - 0xEB0F310, - 0xEB4CD50, - 0xEB89FE0, - 0xEBC6AB0, - 0xEC02DC0, - 0xEC3E930, - 0xEC79CF0, - 0xECB4900, - 0xECEED80, - 0xED28A60, - 0xED61FB0, - 0xED9AD70, - 0xEDD33B0, - 0xEE0B260, - 0xEE429A0, - 0xEE79960, - 0xEEB01B0, - 0xEEE6290, - 0xEF1BC20, - 0xEF50E40, - 0xEF85910, - 0xEFB9C90, - 0xEFED8C0, - 0xF020DB0, - 0xF053B60, - 0xF0861E0, - 0xF0B8130, - 0xF0E9960, - 0xF11AA60, - 0xF14B450, - 0xF17B730, - 0xF1AB300, - 0xF1DA7C0, - 0xF209590, - 0xF237C70, - 0xF265C60, - 0xF293570, - 0xF2C0790, - 0xF2ED2F0, - 0xF319770, - 0xF345530, - 0xF370C30, - 0xF39BC80, - 0xF3C6620, - 0xF3F0910, - 0xF41A570, - 0xF443B30, - 0xF46CA60, - 0xF495310, - 0xF4BD550, - 0xF4E5110, - 0xF50C660, - 0xF533550, - 0xF559DE0, - 0xF580030, - 0xF5A5C20, - 0xF5CB1E0, - 0xF5F0160, - 0xF614AB0, - 0xF638DE0, - 0xF65CAF0, - 0xF6801F0, - 0xF6A32E0, - 0xF6C5DD0, - 0xF6E82C0, - 0xF70A1C0, - 0xF72BAE0, - 0xF74CE20, - 0xF76DB90, - 0xF78E330, - 0xF7AE510, - 0xF7CE130, - 0xF7ED7A0, - 0xF80C870, - 0xF82B3A0, - 0xF849940, - 0xF867950, - 0xF8853E0, - 0xF8A2900, - 0xF8BF8B0, - 0xF8DC2F0, - 0xF8F87E0, - 0xF914780, - 0xF9301D0, - 0xF94B6F0, - 0xF9666D0, - 0xF981180, - 0xF99B720, - 0xF9B57A0, - 0xF9CF310, - 0xF9E8970, - 0xFA01AE0, - 0xFA1A760, - 0xFA32EF0, - 0xFA4B1B0, - 0xFA62F90, - 0xFA7A8A0, - 0xFA91D00, - 0xFAA8CA0, - 0xFABF790, - 0xFAD5DE0, - 0xFAEBF90, - 0xFB01CB0, - 0xFB17540, - 0xFB2C960, - 0xFB41900, - 0xFB56440, - 0xFB6AB20, - 0xFB7EDA0, - 0xFB92BE0, - 0xFBA65D0, - 0xFBB9B80, - 0xFBCCD00, - 0xFBDFA60, - 0xFBF23A0, - 0xFC048D0, - 0xFC169F0, - 0xFC28710, - 0xFC3A030, - 0xFC4B570, - 0xFC5C6C0, - 0xFC6D430, - 0xFC7DDD0, - 0xFC8E3B0, - 0xFC9E5C0, - 0xFCAE430, - 0xFCBDEE0, - 0xFCCD5F0, - 0xFCDC960, - 0xFCEB950, - 0xFCFA5A0, - 0xFD08E80, - 0xFD173E0, - 0xFD255E0, - 0xFD33470, - 0xFD40FA0, - 0xFD4E790, - 0xFD5BC30, - 0xFD68D80, - 0xFD75BB0, - 0xFD826A0, - 0xFD8EE70, - 0xFD9B320, - 0xFDA74C0, - 0xFDB3350, - 0xFDBEEE0, - 0xFDCA770, - 0xFDD5D10, - 0xFDE0FC0, - 0xFDEBFA0, - 0xFDF6C90, - 0xFE016C0, - 0xFE0BE30, - 0xFE162D0, - 0xFE204C0, - 0xFE2A400, - 0xFE34090, - 0xFE3DA90, - 0xFE471F0, - 0xFE506C0, - 0xFE59910, - 0xFE628E0, - 0xFE6B630, - 0xFE74120, - 0xFE7C9A0, - 0xFE84FC0, - 0xFE8D390, - 0xFE95500, - 0xFE9D440, - 0xFEA5130, - 0xFEACBE0, - 0xFEB4460, - 0xFEBBAC0, - 0xFEC2EF0, - 0xFECA110, - 0xFED1120, - 0xFED7F10, - 0xFEDEB00, - 0xFEE5500, - 0xFEEBCF0, - 0xFEF2300, - 0xFEF8720, - 0xFEFE960, - 0xFF049B0, - 0xFF0A840, - 0xFF10500, - 0xFF15FF0, - 0xFF1B920, - 0xFF21090, - 0xFF26650, - 0xFF2BA60, - 0xFF30CC0, - 0xFF35D90, - 0xFF3ACB0, - 0xFF3FA50, - 0xFF44650, - 0xFF490D0, - 0xFF4D9C0, - 0xFF52140, - 0xFF56740, - 0xFF5ABD0, - 0xFF5EF00, - 0xFF630C0, - 0xFF67120, - 0xFF6B020, - 0xFF6EDD0, - 0xFF72A30, - 0xFF76550, - 0xFF79F20, - 0xFF7D7B0, - 0xFF80F10, - 0xFF84530, - 0xFF87A30, - 0xFF8ADF0, - 0xFF8E0A0, - 0xFF91220, - 0xFF94280, - 0xFF971E0, - 0xFF9A020, - 0xFF9CD50, - 0xFF9F980, - 0xFFA24A0, - 0xFFA4ED0, - 0xFFA7800, - 0xFFAA030, - 0xFFAC780, - 0xFFAEDE0, - 0xFFB1350, - 0xFFB37E0, - 0xFFB5B90, - 0xFFB7E60, - 0xFFBA050, - 0xFFBC180, - 0xFFBE1D0, - 0xFFC0160, - 0xFFC2020, - 0xFFC3E20, - 0xFFC5B60, - 0xFFC77E0, - 0xFFC93B0, - 0xFFCAEC0, - 0xFFCC930, - 0xFFCE2E0, - 0xFFCFBF0, - 0xFFD1450, - 0xFFD2C10, - 0xFFD4340, - 0xFFD59C0, - 0xFFD6FB0, - 0xFFD8500, - 0xFFD99C0, - 0xFFDAE00, - 0xFFDC1A0, - 0xFFDD4C0, - 0xFFDE750, - 0xFFDF970, - 0xFFE0B00, - 0xFFE1C10, - 0xFFE2CA0, - 0xFFE3CC0, - 0xFFE4C70, - 0xFFE5BA0, - 0xFFE6A70, - 0xFFE78C0, - 0xFFE86B0, - 0xFFE9430, - 0xFFEA150, - 0xFFEAE10, - 0xFFEBA60, - 0xFFEC650, - 0xFFED1F0, - 0xFFEDD30, - 0xFFEE820, - 0xFFEF2B0, - 0xFFEFCE0, - 0xFFF06D0, - 0xFFF1070, - 0xFFF19B0, - 0xFFF22B0, - 0xFFF2B70, - 0xFFF33D0, - 0xFFF3C00, - 0xFFF43E0, - 0xFFF4B80, - 0xFFF52E0, - 0xFFF5A00, - 0xFFF60E0, - 0xFFF6780, - 0xFFF6DF0, - 0xFFF7420, - 0xFFF7A10, - 0xFFF7FE0, - 0xFFF8570, - 0xFFF8AC0, - 0xFFF8FF0, - 0xFFF94F0, - 0xFFF99C0, - 0xFFF9E60, - 0xFFFA2D0, - 0xFFFA720, - 0xFFFAB40, - 0xFFFAF30, - 0xFFFB310, - 0xFFFB6B0, - 0xFFFBA40, - 0xFFFBDA0, - 0xFFFC0E0, - 0xFFFC400, - 0xFFFC700, - 0xFFFC9E0, - 0xFFFCCA0, - 0xFFFCF50, - 0xFFFD1D0, - 0xFFFD440, - 0xFFFD690, - 0xFFFD8D0, - 0xFFFDAF0, - 0xFFFDD00, - 0xFFFDEF0, - 0xFFFE0D0, - 0xFFFE290, - 0xFFFE440, - 0xFFFE5E0, - 0xFFFE770, - 0xFFFE8E0, - 0xFFFEA50, - 0xFFFEBA0, - 0xFFFECE0, - 0xFFFEE20, - 0xFFFEF40, - 0xFFFF050, - 0xFFFF160, - 0xFFFF260, - 0xFFFF340, - 0xFFFF420, - 0xFFFF500, - 0xFFFF5C0, - 0xFFFF680, - 0xFFFF730, - 0xFFFF7E0, - 0xFFFF880, - 0xFFFF910, - 0xFFFF9A0, - 0xFFFFA30, - 0xFFFFAA0, - 0xFFFFB20, - 0xFFFFB90, - 0xFFFFBF0, - 0xFFFFC50, - 0xFFFFCA0, - 0xFFFFD00, - 0xFFFFD50, - 0xFFFFD90, - 0xFFFFDD0, - 0xFFFFE10, - 0xFFFFE50, - 0xFFFFE80, - 0xFFFFEB0, - 0xFFFFEE0, - 0xFFFFF00, - 0xFFFFF30, - 0xFFFFF50, - 0xFFFFF70, - 0xFFFFF80, - 0xFFFFFA0, - 0xFFFFFB0, - 0xFFFFFC0, - 0xFFFFFD0, - 0xFFFFFE0, - 0xFFFFFF0 -}; - -real_t kbd_long_960[] = -{ - 0x13CD5, - 0x1D2DA, - 0x2530F, - 0x2CA56, - 0x33D79, - 0x3AED7, - 0x41FCF, - 0x4913D, - 0x503BC, - 0x577B7, - 0x5ED81, - 0x6655B, - 0x6DF77, - 0x75C00, - 0x7DB1B, - 0x85CE5, - 0x8E17C, - 0x968F7, - 0x9F36B, - 0xA80EF, - 0xB1194, - 0xBA56C, - 0xC3C88, - 0xCD6F8, - 0xD74CB, - 0xE1610, - 0xEBAD6, - 0xF632A, - 0x100F1A, - 0x10BEB4, - 0x117203, - 0x122916, - 0x12E3F9, - 0x13A2B8, - 0x146561, - 0x152BFF, - 0x15F69E, - 0x16C54B, - 0x179812, - 0x186EFF, - 0x194A1D, - 0x1A2979, - 0x1B0D1E, - 0x1BF519, - 0x1CE175, - 0x1DD23E, - 0x1EC77F, - 0x1FC145, - 0x20BF9B, - 0x21C28C, - 0x22CA24, - 0x23D670, - 0x24E77A, - 0x25FD4E, - 0x2717F7, - 0x283782, - 0x295BF9, - 0x2A8569, - 0x2BB3DD, - 0x2CE760, - 0x2E1FFD, - 0x2F5DC1, - 0x30A0B7, - 0x31E8EA, - 0x333666, - 0x348935, - 0x35E164, - 0x373EFE, - 0x38A20E, - 0x3A0AA0, - 0x3B78BE, - 0x3CEC75, - 0x3E65CF, - 0x3FE4D8, - 0x41699B, - 0x42F424, - 0x44847D, - 0x461AB1, - 0x47B6CC, - 0x4958D9, - 0x4B00E4, - 0x4CAEF6, - 0x4E631C, - 0x501D60, - 0x51DDCD, - 0x53A46E, - 0x55714E, - 0x574479, - 0x591DF8, - 0x5AFDD7, - 0x5CE420, - 0x5ED0DE, - 0x60C41D, - 0x62BDE6, - 0x64BE44, - 0x66C542, - 0x68D2EB, - 0x6AE748, - 0x6D0265, - 0x6F244B, - 0x714D05, - 0x737C9E, - 0x75B320, - 0x77F094, - 0x7A3506, - 0x7C807E, - 0x7ED308, - 0x812CAD, - 0x838D77, - 0x85F570, - 0x8864A2, - 0x8ADB16, - 0x8D58D7, - 0x8FDDEE, - 0x926A64, - 0x94FE44, - 0x979995, - 0x9A3C63, - 0x9CE6B6, - 0x9F9897, - 0xA25210, - 0xA5132A, - 0xA7DBED, - 0xAAAC63, - 0xAD8495, - 0xB0648B, - 0xB34C4E, - 0xB63BE7, - 0xB9335E, - 0xBC32BC, - 0xBF3A09, - 0xC2494E, - 0xC56093, - 0xC87FE0, - 0xCBA73D, - 0xCED6B2, - 0xD20E47, - 0xD54E04, - 0xD895F0, - 0xDBE613, - 0xDF3E76, - 0xE29F1E, - 0xE60814, - 0xE9795F, - 0xECF305, - 0xF0750F, - 0xF3FF82, - 0xF79267, - 0xFB2DC3, - 0xFED19E, - 0x1027DFC, - 0x10632E8, - 0x109F064, - 0x10DB678, - 0x111852A, - 0x1155C82, - 0x1193C82, - 0x11D2532, - 0x121169A, - 0x12510BA, - 0x129139E, - 0x12D1F46, - 0x13133BA, - 0x13550FE, - 0x1397718, - 0x13DA60C, - 0x141DDE0, - 0x1461E98, - 0x14A6838, - 0x14EBAC6, - 0x1531644, - 0x1577AB8, - 0x15BE826, - 0x1605E92, - 0x164DE00, - 0x1696672, - 0x16DF7EC, - 0x1729274, - 0x177360A, - 0x17BE2B4, - 0x1809874, - 0x185574C, - 0x18A1F40, - 0x18EF052, - 0x193CA84, - 0x198ADDA, - 0x19D9A56, - 0x1A28FFA, - 0x1A78EC6, - 0x1AC96BE, - 0x1B1A7E4, - 0x1B6C23A, - 0x1BBE5C0, - 0x1C11276, - 0x1C64860, - 0x1CB8780, - 0x1D0CFD2, - 0x1D6215C, - 0x1DB7C1C, - 0x1E0E012, - 0x1E64D40, - 0x1EBC3A4, - 0x1F14342, - 0x1F6CC16, - 0x1FC5E22, - 0x201F964, - 0x2079DDC, - 0x20D4B8C, - 0x2130270, - 0x218C288, - 0x21E8BD4, - 0x2245E50, - 0x22A3A00, - 0x2301EDC, - 0x2360CE4, - 0x23C0418, - 0x2420478, - 0x2480DFC, - 0x24E20A8, - 0x2543C74, - 0x25A6164, - 0x2608F6C, - 0x266C694, - 0x26D06D0, - 0x2735020, - 0x279A284, - 0x27FFDF4, - 0x286626C, - 0x28CCFEC, - 0x2934670, - 0x299C5F0, - 0x2A04E68, - 0x2A6DFD8, - 0x2AD7A3C, - 0x2B41D88, - 0x2BAC9BC, - 0x2C17ED4, - 0x2C83CC8, - 0x2CF0398, - 0x2D5D338, - 0x2DCABA4, - 0x2E38CD8, - 0x2EA76CC, - 0x2F1697C, - 0x2F864E4, - 0x2FF68F8, - 0x30675B8, - 0x30D8B14, - 0x314A910, - 0x31BCF9C, - 0x322FEB8, - 0x32A3658, - 0x3317678, - 0x338BF0C, - 0x3401010, - 0x3476978, - 0x34ECB44, - 0x3563564, - 0x35DA7D0, - 0x3652288, - 0x36CA578, - 0x37430A0, - 0x37BC3F0, - 0x3835F64, - 0x38B02F4, - 0x392AE90, - 0x39A6238, - 0x3A21DD8, - 0x3A9E16C, - 0x3B1ACE8, - 0x3B98048, - 0x3C15B78, - 0x3C93E74, - 0x3D12930, - 0x3D91BA0, - 0x3E115BC, - 0x3E91774, - 0x3F120C4, - 0x3F9319C, - 0x40149F0, - 0x40969B8, - 0x41190E8, - 0x419BF70, - 0x421F548, - 0x42A3260, - 0x43276B0, - 0x43AC228, - 0x44314C0, - 0x44B6E68, - 0x453CF18, - 0x45C36C0, - 0x464A550, - 0x46D1AB8, - 0x47596F0, - 0x47E19F0, - 0x486A3A8, - 0x48F3400, - 0x497CAF0, - 0x4A06870, - 0x4A90C70, - 0x4B1B6D8, - 0x4BA67A8, - 0x4C31EC8, - 0x4CBDC28, - 0x4D49FC0, - 0x4DD6980, - 0x4E63958, - 0x4EF0F30, - 0x4F7EB08, - 0x500CCC8, - 0x509B468, - 0x512A1D0, - 0x51B94F0, - 0x5248DC0, - 0x52D8C28, - 0x5369020, - 0x53F9990, - 0x548A870, - 0x551BCA8, - 0x55AD628, - 0x563F4E8, - 0x56D18D0, - 0x57641D0, - 0x57F6FD8, - 0x588A2D8, - 0x591DAC0, - 0x59B1780, - 0x5A45900, - 0x5AD9F30, - 0x5B6EA08, - 0x5C03968, - 0x5C98D50, - 0x5D2E5A0, - 0x5DC4248, - 0x5E5A338, - 0x5EF0860, - 0x5F871B0, - 0x601DF10, - 0x60B5078, - 0x614C5C8, - 0x61E3EF0, - 0x627BBE8, - 0x6313C98, - 0x63AC0E8, - 0x64448C8, - 0x64DD430, - 0x65762F8, - 0x660F520, - 0x66A8A90, - 0x6742330, - 0x67DBEF0, - 0x6875DC0, - 0x690FF88, - 0x69AA438, - 0x6A44BB8, - 0x6ADF5F8, - 0x6B7A2E8, - 0x6C15270, - 0x6CB0478, - 0x6D4B8F8, - 0x6DE6FD0, - 0x6E828F0, - 0x6F1E450, - 0x6FBA1C8, - 0x7056158, - 0x70F22D8, - 0x718E648, - 0x722AB88, - 0x72C7280, - 0x7363B28, - 0x7400568, - 0x749D128, - 0x7539E50, - 0x75D6CD8, - 0x7673CA8, - 0x7710DA0, - 0x77ADFC0, - 0x784B2E0, - 0x78E86F0, - 0x7985BE8, - 0x7A231A8, - 0x7AC0820, - 0x7B5DF38, - 0x7BFB6E0, - 0x7C98F00, - 0x7D36788, - 0x7DD4058, - 0x7E71968, - 0x7F0F2A0, - 0x7FACBE8, - 0x804A530, - 0x80E7E60, - 0x8185770, - 0x8223030, - 0x82C08A0, - 0x835E0B0, - 0x83FB830, - 0x8498F30, - 0x8536580, - 0x85D3B20, - 0x8670FE0, - 0x870E3C0, - 0x87AB6B0, - 0x8848890, - 0x88E5950, - 0x89828D0, - 0x8A1F710, - 0x8ABC3F0, - 0x8B58F50, - 0x8BF5940, - 0x8C92180, - 0x8D2E810, - 0x8DCACF0, - 0x8E66FE0, - 0x8F030F0, - 0x8F9F000, - 0x903ACF0, - 0x90D67C0, - 0x9172050, - 0x920D690, - 0x92A8A60, - 0x9343BC0, - 0x93DEAA0, - 0x94796D0, - 0x9514050, - 0x95AE700, - 0x9648AD0, - 0x96E2BC0, - 0x977C9A0, - 0x9816470, - 0x98AFC20, - 0x9949080, - 0x99E2190, - 0x9A7AF40, - 0x9B13980, - 0x9BAC030, - 0x9C44340, - 0x9CDC2A0, - 0x9D73E40, - 0x9E0B610, - 0x9EA29F0, - 0x9F399D0, - 0x9FD05A0, - 0xA066D50, - 0xA0FD0D0, - 0xA193010, - 0xA228AF0, - 0xA2BE170, - 0xA353360, - 0xA3E80D0, - 0xA47C9A0, - 0xA510DC0, - 0xA5A4D10, - 0xA638790, - 0xA6CBD20, - 0xA75EDC0, - 0xA7F1960, - 0xA883FE0, - 0xA916120, - 0xA9A7D30, - 0xAA393F0, - 0xAACA560, - 0xAB5B150, - 0xABEB7C0, - 0xAC7B8A0, - 0xAD0B3D0, - 0xAD9A960, - 0xAE29920, - 0xAEB8320, - 0xAF46730, - 0xAFD4550, - 0xB061D60, - 0xB0EEF70, - 0xB17BB60, - 0xB208110, - 0xB294090, - 0xB31F9B0, - 0xB3AAC80, - 0xB4358D0, - 0xB4BFEB0, - 0xB549E10, - 0xB5D36C0, - 0xB65C8E0, - 0xB6E5430, - 0xB76D8D0, - 0xB7F5690, - 0xB87CD80, - 0xB903D70, - 0xB98A670, - 0xBA10860, - 0xBA96340, - 0xBB1B700, - 0xBBA0380, - 0xBC248D0, - 0xBCA86D0, - 0xBD2BD70, - 0xBDAECC0, - 0xBE31490, - 0xBEB34F0, - 0xBF34DC0, - 0xBFB5F00, - 0xC036890, - 0xC0B6A90, - 0xC1364C0, - 0xC1B5740, - 0xC2341E0, - 0xC2B24C0, - 0xC32FFA0, - 0xC3AD2B0, - 0xC429DB0, - 0xC4A60B0, - 0xC521BB0, - 0xC59CE90, - 0xC617940, - 0xC691BE0, - 0xC70B630, - 0xC784850, - 0xC7FD230, - 0xC8753B0, - 0xC8ECCE0, - 0xC963DA0, - 0xC9DA600, - 0xCA505F0, - 0xCAC5D60, - 0xCB3AC40, - 0xCBAF2A0, - 0xCC23060, - 0xCC96590, - 0xCD09210, - 0xCD7B5F0, - 0xCDED110, - 0xCE5E380, - 0xCECED30, - 0xCF3EE20, - 0xCFAE630, - 0xD01D570, - 0xD08BBE0, - 0xD0F9960, - 0xD166E00, - 0xD1D39C0, - 0xD23FC80, - 0xD2AB650, - 0xD316710, - 0xD380EE0, - 0xD3EADA0, - 0xD454360, - 0xD4BD010, - 0xD5253A0, - 0xD58CE20, - 0xD5F3F80, - 0xD65A7B0, - 0xD6C06D0, - 0xD725CC0, - 0xD78A980, - 0xD7EED10, - 0xD852770, - 0xD8B58A0, - 0xD918090, - 0xD979F50, - 0xD9DB4D0, - 0xDA3C110, - 0xDA9C400, - 0xDAFBDC0, - 0xDB5AE30, - 0xDBB9560, - 0xDC17340, - 0xDC747D0, - 0xDCD1320, - 0xDD2D520, - 0xDD88DD0, - 0xDDE3D40, - 0xDE3E350, - 0xDE98020, - 0xDEF1390, - 0xDF49DC0, - 0xDFA1EA0, - 0xDFF9630, - 0xE050470, - 0xE0A6960, - 0xE0FC510, - 0xE151760, - 0xE1A6070, - 0xE1FA040, - 0xE24D6C0, - 0xE2A03F0, - 0xE2F27F0, - 0xE3442A0, - 0xE395410, - 0xE3E5C40, - 0xE435B30, - 0xE4850E0, - 0xE4D3D60, - 0xE5220B0, - 0xE56FAD0, - 0xE5BCBC0, - 0xE609380, - 0xE655210, - 0xE6A0780, - 0xE6EB3D0, - 0xE735710, - 0xE77F120, - 0xE7C8220, - 0xE810A10, - 0xE858900, - 0xE89FED0, - 0xE8E6BB0, - 0xE92CF80, - 0xE972A60, - 0xE9B7C40, - 0xE9FC530, - 0xEA40540, - 0xEA83C60, - 0xEAC6AA0, - 0xEB09010, - 0xEB4ACA0, - 0xEB8C060, - 0xEBCCB60, - 0xEC0CD90, - 0xEC4C710, - 0xEC8B7D0, - 0xECC9FE0, - 0xED07F40, - 0xED45610, - 0xED82430, - 0xEDBE9C0, - 0xEDFA6D0, - 0xEE35B50, - 0xEE70750, - 0xEEAAAD0, - 0xEEE45F0, - 0xEF1D890, - 0xEF562E0, - 0xEF8E4E0, - 0xEFC5E80, - 0xEFFCFD0, - 0xF0338F0, - 0xF0699D0, - 0xF09F280, - 0xF0D4300, - 0xF108B60, - 0xF13CBB0, - 0xF1703F0, - 0xF1A3430, - 0xF1D5C70, - 0xF207CC0, - 0xF239520, - 0xF26A5A0, - 0xF29AE50, - 0xF2CAF20, - 0xF2FA840, - 0xF329990, - 0xF358340, - 0xF386540, - 0xF3B3FA0, - 0xF3E1260, - 0xF40DDA0, - 0xF43A160, - 0xF465DB0, - 0xF491290, - 0xF4BC000, - 0xF4E6630, - 0xF510500, - 0xF539C90, - 0xF562CE0, - 0xF58B610, - 0xF5B3810, - 0xF5DB300, - 0xF6026E0, - 0xF6293B0, - 0xF64F990, - 0xF675880, - 0xF69B090, - 0xF6C01C0, - 0xF6E4C20, - 0xF708FD0, - 0xF72CCB0, - 0xF7502F0, - 0xF773290, - 0xF795BA0, - 0xF7B7E20, - 0xF7D9A20, - 0xF7FAFA0, - 0xF81BEC0, - 0xF83C780, - 0xF85C9F0, - 0xF87C620, - 0xF89BC10, - 0xF8BABD0, - 0xF8D9570, - 0xF8F78F0, - 0xF915660, - 0xF932DD0, - 0xF94FF50, - 0xF96CAE0, - 0xF989090, - 0xF9A5070, - 0xF9C0A90, - 0xF9DBEE0, - 0xF9F6D90, - 0xFA11690, - 0xFA2BA00, - 0xFA457E0, - 0xFA5F040, - 0xFA78330, - 0xFA910B0, - 0xFAA98D0, - 0xFAC1BA0, - 0xFAD9920, - 0xFAF1170, - 0xFB08490, - 0xFB1F280, - 0xFB35B60, - 0xFB4BF40, - 0xFB61E10, - 0xFB777E0, - 0xFB8CCE0, - 0xFBA1CF0, - 0xFBB6830, - 0xFBCAEB0, - 0xFBDF070, - 0xFBF2D80, - 0xFC065F0, - 0xFC199C0, - 0xFC2C900, - 0xFC3F3D0, - 0xFC51A20, - 0xFC63C00, - 0xFC75980, - 0xFC872B0, - 0xFC987A0, - 0xFCA9840, - 0xFCBA4C0, - 0xFCCAD00, - 0xFCDB140, - 0xFCEB160, - 0xFCFAD80, - 0xFD0A5A0, - 0xFD199D0, - 0xFD28A20, - 0xFD37690, - 0xFD45F40, - 0xFD54420, - 0xFD62540, - 0xFD702C0, - 0xFD7DC90, - 0xFD8B2D0, - 0xFD98580, - 0xFDA54B0, - 0xFDB2060, - 0xFDBE8B0, - 0xFDCAD90, - 0xFDD6F10, - 0xFDE2D50, - 0xFDEE840, - 0xFDF9FF0, - 0xFE05480, - 0xFE105E0, - 0xFE1B420, - 0xFE25F50, - 0xFE30780, - 0xFE3ACA0, - 0xFE44EE0, - 0xFE4EE20, - 0xFE58A90, - 0xFE62420, - 0xFE6BAE0, - 0xFE74EE0, - 0xFE7E030, - 0xFE86EC0, - 0xFE8FAA0, - 0xFE983F0, - 0xFEA0AA0, - 0xFEA8ED0, - 0xFEB1070, - 0xFEB8FA0, - 0xFEC0C50, - 0xFEC86A0, - 0xFECFE90, - 0xFED7430, - 0xFEDE770, - 0xFEE5880, - 0xFEEC740, - 0xFEF33D0, - 0xFEF9E30, - 0xFF00670, - 0xFF06CA0, - 0xFF0D0B0, - 0xFF132B0, - 0xFF192B0, - 0xFF1F0B0, - 0xFF24CC0, - 0xFF2A6E0, - 0xFF2FF20, - 0xFF35590, - 0xFF3AA20, - 0xFF3FCE0, - 0xFF44DD0, - 0xFF49D10, - 0xFF4EA90, - 0xFF53670, - 0xFF58090, - 0xFF5C920, - 0xFF61010, - 0xFF65560, - 0xFF69930, - 0xFF6DB80, - 0xFF71C40, - 0xFF75B90, - 0xFF79970, - 0xFF7D5E0, - 0xFF810E0, - 0xFF84A90, - 0xFF882E0, - 0xFF8B9E0, - 0xFF8EF90, - 0xFF92400, - 0xFF95730, - 0xFF98920, - 0xFF9B9E0, - 0xFF9E970, - 0xFFA17D0, - 0xFFA4510, - 0xFFA7130, - 0xFFA9C40, - 0xFFAC630, - 0xFFAEF20, - 0xFFB1700, - 0xFFB3DE0, - 0xFFB63C0, - 0xFFB88A0, - 0xFFBAC90, - 0xFFBCFA0, - 0xFFBF1B0, - 0xFFC12E0, - 0xFFC3340, - 0xFFC52B0, - 0xFFC7150, - 0xFFC8F20, - 0xFFCAC20, - 0xFFCC850, - 0xFFCE3C0, - 0xFFCFE60, - 0xFFD1850, - 0xFFD3190, - 0xFFD4A10, - 0xFFD61E0, - 0xFFD7900, - 0xFFD8F80, - 0xFFDA550, - 0xFFDBA80, - 0xFFDCF10, - 0xFFDE310, - 0xFFDF670, - 0xFFE0940, - 0xFFE1B80, - 0xFFE2D30, - 0xFFE3E60, - 0xFFE4F00, - 0xFFE5F20, - 0xFFE6EC0, - 0xFFE7DF0, - 0xFFE8C90, - 0xFFE9AD0, - 0xFFEA890, - 0xFFEB5E0, - 0xFFEC2D0, - 0xFFECF40, - 0xFFEDB60, - 0xFFEE700, - 0xFFEF250, - 0xFFEFD40, - 0xFFF07D0, - 0xFFF1200, - 0xFFF1BD0, - 0xFFF2560, - 0xFFF2E90, - 0xFFF3770, - 0xFFF3FF0, - 0xFFF4840, - 0xFFF5030, - 0xFFF57E0, - 0xFFF5F40, - 0xFFF6670, - 0xFFF6D50, - 0xFFF73E0, - 0xFFF7A40, - 0xFFF8070, - 0xFFF8650, - 0xFFF8C00, - 0xFFF9170, - 0xFFF96C0, - 0xFFF9BC0, - 0xFFFA0A0, - 0xFFFA540, - 0xFFFA9C0, - 0xFFFAE10, - 0xFFFB220, - 0xFFFB620, - 0xFFFB9E0, - 0xFFFBD80, - 0xFFFC100, - 0xFFFC450, - 0xFFFC780, - 0xFFFCA90, - 0xFFFCD70, - 0xFFFD040, - 0xFFFD2E0, - 0xFFFD570, - 0xFFFD7E0, - 0xFFFDA30, - 0xFFFDC60, - 0xFFFDE80, - 0xFFFE080, - 0xFFFE260, - 0xFFFE430, - 0xFFFE5F0, - 0xFFFE790, - 0xFFFE920, - 0xFFFEAA0, - 0xFFFEC00, - 0xFFFED50, - 0xFFFEEA0, - 0xFFFEFD0, - 0xFFFF0F0, - 0xFFFF200, - 0xFFFF300, - 0xFFFF3F0, - 0xFFFF4E0, - 0xFFFF5B0, - 0xFFFF680, - 0xFFFF740, - 0xFFFF7F0, - 0xFFFF8A0, - 0xFFFF940, - 0xFFFF9D0, - 0xFFFFA50, - 0xFFFFAE0, - 0xFFFFB50, - 0xFFFFBC0, - 0xFFFFC30, - 0xFFFFC90, - 0xFFFFCE0, - 0xFFFFD40, - 0xFFFFD90, - 0xFFFFDD0, - 0xFFFFE10, - 0xFFFFE50, - 0xFFFFE80, - 0xFFFFEC0, - 0xFFFFEE0, - 0xFFFFF10, - 0xFFFFF30, - 0xFFFFF60, - 0xFFFFF70, - 0xFFFFF90, - 0xFFFFFB0, - 0xFFFFFC0, - 0xFFFFFD0, - 0xFFFFFE0, - 0xFFFFFF0 +#ifdef ALLOW_SMALL_FRAMELENGTH +ALIGN static const real_t kbd_long_960[] = { + FRAC_CONST(0.0003021562530949), + FRAC_CONST(0.0004452267024786), + FRAC_CONST(0.0005674947527496), + FRAC_CONST(0.0006812465553466), + FRAC_CONST(0.0007910496776387), + FRAC_CONST(0.0008991655033895), + FRAC_CONST(0.0010068978259384), + FRAC_CONST(0.0011150758515751), + FRAC_CONST(0.0012242653193642), + FRAC_CONST(0.0013348735658205), + FRAC_CONST(0.0014472068670273), + FRAC_CONST(0.0015615039850448), + FRAC_CONST(0.0016779568885263), + FRAC_CONST(0.0017967241232412), + FRAC_CONST(0.0019179397560955), + FRAC_CONST(0.0020417195415393), + FRAC_CONST(0.0021681652836642), + FRAC_CONST(0.0022973679910599), + FRAC_CONST(0.0024294102029937), + FRAC_CONST(0.0025643677339078), + FRAC_CONST(0.0027023110014772), + FRAC_CONST(0.0028433060512612), + FRAC_CONST(0.0029874153568025), + FRAC_CONST(0.0031346984511728), + FRAC_CONST(0.0032852124303662), + FRAC_CONST(0.0034390123581190), + FRAC_CONST(0.0035961515940931), + FRAC_CONST(0.0037566820618961), + FRAC_CONST(0.0039206544694386), + FRAC_CONST(0.0040881184912194), + FRAC_CONST(0.0042591229199617), + FRAC_CONST(0.0044337157933972), + FRAC_CONST(0.0046119445007641), + FRAC_CONST(0.0047938558726415), + FRAC_CONST(0.0049794962570131), + FRAC_CONST(0.0051689115838900), + FRAC_CONST(0.0053621474203763), + FRAC_CONST(0.0055592490177131), + FRAC_CONST(0.0057602613515573), + FRAC_CONST(0.0059652291565289), + FRAC_CONST(0.0061741969558843), + FRAC_CONST(0.0063872090870253), + FRAC_CONST(0.0066043097234387), + FRAC_CONST(0.0068255428935640), + FRAC_CONST(0.0070509524970088), + FRAC_CONST(0.0072805823184660), + FRAC_CONST(0.0075144760396340), + FRAC_CONST(0.0077526772493942), + FRAC_CONST(0.0079952294524673), + FRAC_CONST(0.0082421760767325), + FRAC_CONST(0.0084935604793733), + FRAC_CONST(0.0087494259519870), + FRAC_CONST(0.0090098157247792), + FRAC_CONST(0.0092747729699467), + FRAC_CONST(0.0095443408043399), + FRAC_CONST(0.0098185622914832), + FRAC_CONST(0.0100974804430226), + FRAC_CONST(0.0103811382196612), + FRAC_CONST(0.0106695785316351), + FRAC_CONST(0.0109628442387771), + FRAC_CONST(0.0112609781502091), + FRAC_CONST(0.0115640230236993), + FRAC_CONST(0.0118720215647169), + FRAC_CONST(0.0121850164252137), + FRAC_CONST(0.0125030502021561), + FRAC_CONST(0.0128261654358321), + FRAC_CONST(0.0131544046079532), + FRAC_CONST(0.0134878101395681), + FRAC_CONST(0.0138264243888068), + FRAC_CONST(0.0141702896484671), + FRAC_CONST(0.0145194481434592), + FRAC_CONST(0.0148739420281182), + FRAC_CONST(0.0152338133833959), + FRAC_CONST(0.0155991042139432), + FRAC_CONST(0.0159698564450882), + FRAC_CONST(0.0163461119197227), + FRAC_CONST(0.0167279123950996), + FRAC_CONST(0.0171152995395520), + FRAC_CONST(0.0175083149291368), + FRAC_CONST(0.0179070000442104), + FRAC_CONST(0.0183113962659409), + FRAC_CONST(0.0187215448727609), + FRAC_CONST(0.0191374870367659), + FRAC_CONST(0.0195592638200623), + FRAC_CONST(0.0199869161710679), + FRAC_CONST(0.0204204849207691), + FRAC_CONST(0.0208600107789370), + FRAC_CONST(0.0213055343303066), + FRAC_CONST(0.0217570960307201), + FRAC_CONST(0.0222147362032386), + FRAC_CONST(0.0226784950342228), + FRAC_CONST(0.0231484125693867), + FRAC_CONST(0.0236245287098244), + FRAC_CONST(0.0241068832080138), + FRAC_CONST(0.0245955156637973), + FRAC_CONST(0.0250904655203431), + FRAC_CONST(0.0255917720600868), + FRAC_CONST(0.0260994744006559), + FRAC_CONST(0.0266136114907790), + FRAC_CONST(0.0271342221061795), + FRAC_CONST(0.0276613448454576), + FRAC_CONST(0.0281950181259587), + FRAC_CONST(0.0287352801796329), + FRAC_CONST(0.0292821690488833), + FRAC_CONST(0.0298357225824074), + FRAC_CONST(0.0303959784310299), + FRAC_CONST(0.0309629740435296), + FRAC_CONST(0.0315367466624615), + FRAC_CONST(0.0321173333199732), + FRAC_CONST(0.0327047708336193), + FRAC_CONST(0.0332990958021720), + FRAC_CONST(0.0339003446014307), + FRAC_CONST(0.0345085533800302), + FRAC_CONST(0.0351237580552491), + FRAC_CONST(0.0357459943088193), + FRAC_CONST(0.0363752975827358), + FRAC_CONST(0.0370117030750704), + FRAC_CONST(0.0376552457357870), + FRAC_CONST(0.0383059602625614), + FRAC_CONST(0.0389638810966056), + FRAC_CONST(0.0396290424184964), + FRAC_CONST(0.0403014781440112), + FRAC_CONST(0.0409812219199691), + FRAC_CONST(0.0416683071200799), + FRAC_CONST(0.0423627668408009), + FRAC_CONST(0.0430646338972016), + FRAC_CONST(0.0437739408188385), + FRAC_CONST(0.0444907198456388), + FRAC_CONST(0.0452150029237951), + FRAC_CONST(0.0459468217016708), + FRAC_CONST(0.0466862075257170), + FRAC_CONST(0.0474331914364021), + FRAC_CONST(0.0481878041641539), + FRAC_CONST(0.0489500761253148), + FRAC_CONST(0.0497200374181119), + FRAC_CONST(0.0504977178186404), + FRAC_CONST(0.0512831467768636), + FRAC_CONST(0.0520763534126273), + FRAC_CONST(0.0528773665116913), + FRAC_CONST(0.0536862145217772), + FRAC_CONST(0.0545029255486345), + FRAC_CONST(0.0553275273521232), + FRAC_CONST(0.0561600473423164), + FRAC_CONST(0.0570005125756209), + FRAC_CONST(0.0578489497509179), + FRAC_CONST(0.0587053852057233), + FRAC_CONST(0.0595698449123695), + FRAC_CONST(0.0604423544742077), + FRAC_CONST(0.0613229391218317), + FRAC_CONST(0.0622116237093247), + FRAC_CONST(0.0631084327105284), + FRAC_CONST(0.0640133902153352), + FRAC_CONST(0.0649265199260043), + FRAC_CONST(0.0658478451535027), + FRAC_CONST(0.0667773888138695), + FRAC_CONST(0.0677151734246072), + FRAC_CONST(0.0686612211010977), + FRAC_CONST(0.0696155535530446), + FRAC_CONST(0.0705781920809429), + FRAC_CONST(0.0715491575725758), + FRAC_CONST(0.0725284704995383), + FRAC_CONST(0.0735161509137906), + FRAC_CONST(0.0745122184442388), + FRAC_CONST(0.0755166922933461), + FRAC_CONST(0.0765295912337720), + FRAC_CONST(0.0775509336050437), + FRAC_CONST(0.0785807373102561), + FRAC_CONST(0.0796190198128044), + FRAC_CONST(0.0806657981331473), + FRAC_CONST(0.0817210888456026), + FRAC_CONST(0.0827849080751753), + FRAC_CONST(0.0838572714944183), + FRAC_CONST(0.0849381943203265), + FRAC_CONST(0.0860276913112652), + FRAC_CONST(0.0871257767639319), + FRAC_CONST(0.0882324645103534), + FRAC_CONST(0.0893477679149177), + FRAC_CONST(0.0904716998714418), + FRAC_CONST(0.0916042728002747), + FRAC_CONST(0.0927454986454381), + FRAC_CONST(0.0938953888718020), + FRAC_CONST(0.0950539544622996), + FRAC_CONST(0.0962212059151784), + FRAC_CONST(0.0973971532412897), + FRAC_CONST(0.0985818059614169), + FRAC_CONST(0.0997751731036425), + FRAC_CONST(0.1009772632007537), + FRAC_CONST(0.1021880842876888), + FRAC_CONST(0.1034076438990227), + FRAC_CONST(0.1046359490664932), + FRAC_CONST(0.1058730063165681), + FRAC_CONST(0.1071188216680533), + FRAC_CONST(0.1083734006297428), + FRAC_CONST(0.1096367481981100), + FRAC_CONST(0.1109088688550422), + FRAC_CONST(0.1121897665656167), + FRAC_CONST(0.1134794447759207), + FRAC_CONST(0.1147779064109143), + FRAC_CONST(0.1160851538723372), + FRAC_CONST(0.1174011890366591), + FRAC_CONST(0.1187260132530751), + FRAC_CONST(0.1200596273415457), + FRAC_CONST(0.1214020315908810), + FRAC_CONST(0.1227532257568719), + FRAC_CONST(0.1241132090604651), + FRAC_CONST(0.1254819801859856), + FRAC_CONST(0.1268595372794049), + FRAC_CONST(0.1282458779466558), + FRAC_CONST(0.1296409992519942), + FRAC_CONST(0.1310448977164081), + FRAC_CONST(0.1324575693160745), + FRAC_CONST(0.1338790094808633), + FRAC_CONST(0.1353092130928902), + FRAC_CONST(0.1367481744851168), + FRAC_CONST(0.1381958874400010), + FRAC_CONST(0.1396523451881945), + FRAC_CONST(0.1411175404072910), + FRAC_CONST(0.1425914652206223), + FRAC_CONST(0.1440741111961058), + FRAC_CONST(0.1455654693451402), + FRAC_CONST(0.1470655301215526), + FRAC_CONST(0.1485742834205956), + FRAC_CONST(0.1500917185779945), + FRAC_CONST(0.1516178243690463), + FRAC_CONST(0.1531525890077689), + FRAC_CONST(0.1546960001461024), + FRAC_CONST(0.1562480448731608), + FRAC_CONST(0.1578087097145364), + FRAC_CONST(0.1593779806316558), + FRAC_CONST(0.1609558430211876), + FRAC_CONST(0.1625422817145027), + FRAC_CONST(0.1641372809771871), + FRAC_CONST(0.1657408245086070), + FRAC_CONST(0.1673528954415270), + FRAC_CONST(0.1689734763417811), + FRAC_CONST(0.1706025492079969), + FRAC_CONST(0.1722400954713725), + FRAC_CONST(0.1738860959955082), + FRAC_CONST(0.1755405310762898), + FRAC_CONST(0.1772033804418275), + FRAC_CONST(0.1788746232524467), + FRAC_CONST(0.1805542381007349), + FRAC_CONST(0.1822422030116404), + FRAC_CONST(0.1839384954426268), + FRAC_CONST(0.1856430922838810), + FRAC_CONST(0.1873559698585756), + FRAC_CONST(0.1890771039231862), + FRAC_CONST(0.1908064696678625), + FRAC_CONST(0.1925440417168546), + FRAC_CONST(0.1942897941289937), + FRAC_CONST(0.1960437003982277), + FRAC_CONST(0.1978057334542116), + FRAC_CONST(0.1995758656629525), + FRAC_CONST(0.2013540688275098), + FRAC_CONST(0.2031403141887507), + FRAC_CONST(0.2049345724261595), + FRAC_CONST(0.2067368136587033), + FRAC_CONST(0.2085470074457521), + FRAC_CONST(0.2103651227880538), + FRAC_CONST(0.2121911281287646), + FRAC_CONST(0.2140249913545346), + FRAC_CONST(0.2158666797966480), + FRAC_CONST(0.2177161602322188), + FRAC_CONST(0.2195733988854414), + FRAC_CONST(0.2214383614288963), + FRAC_CONST(0.2233110129849106), + FRAC_CONST(0.2251913181269740), + FRAC_CONST(0.2270792408812093), + FRAC_CONST(0.2289747447278976), + FRAC_CONST(0.2308777926030592), + FRAC_CONST(0.2327883469000885), + FRAC_CONST(0.2347063694714437), + FRAC_CONST(0.2366318216303919), + FRAC_CONST(0.2385646641528076), + FRAC_CONST(0.2405048572790267), + FRAC_CONST(0.2424523607157545), + FRAC_CONST(0.2444071336380283), + FRAC_CONST(0.2463691346912334), + FRAC_CONST(0.2483383219931741), + FRAC_CONST(0.2503146531361985), + FRAC_CONST(0.2522980851893767), + FRAC_CONST(0.2542885747007335), + FRAC_CONST(0.2562860776995335), + FRAC_CONST(0.2582905496986215), + FRAC_CONST(0.2603019456968142), + FRAC_CONST(0.2623202201813464), + FRAC_CONST(0.2643453271303700), + FRAC_CONST(0.2663772200155053), + FRAC_CONST(0.2684158518044454), + FRAC_CONST(0.2704611749636135), + FRAC_CONST(0.2725131414608710), + FRAC_CONST(0.2745717027682799), + FRAC_CONST(0.2766368098649151), + FRAC_CONST(0.2787084132397296), + FRAC_CONST(0.2807864628944707), + FRAC_CONST(0.2828709083466482), + FRAC_CONST(0.2849616986325523), + FRAC_CONST(0.2870587823103237), + FRAC_CONST(0.2891621074630737), + FRAC_CONST(0.2912716217020546), + FRAC_CONST(0.2933872721698803), + FRAC_CONST(0.2955090055437973), + FRAC_CONST(0.2976367680390041), + FRAC_CONST(0.2997705054120213), + FRAC_CONST(0.3019101629641097), + FRAC_CONST(0.3040556855447379), + FRAC_CONST(0.3062070175550981), + FRAC_CONST(0.3083641029516701), + FRAC_CONST(0.3105268852498334), + FRAC_CONST(0.3126953075275265), + FRAC_CONST(0.3148693124289546), + FRAC_CONST(0.3170488421683428), + FRAC_CONST(0.3192338385337370), + FRAC_CONST(0.3214242428908514), + FRAC_CONST(0.3236199961869606), + FRAC_CONST(0.3258210389548392), + FRAC_CONST(0.3280273113167459), + FRAC_CONST(0.3302387529884521), + FRAC_CONST(0.3324553032833160), + FRAC_CONST(0.3346769011164010), + FRAC_CONST(0.3369034850086373), + FRAC_CONST(0.3391349930910280), + FRAC_CONST(0.3413713631088974), + FRAC_CONST(0.3436125324261830), + FRAC_CONST(0.3458584380297697), + FRAC_CONST(0.3481090165338656), + FRAC_CONST(0.3503642041844199), + FRAC_CONST(0.3526239368635820), + FRAC_CONST(0.3548881500942010), + FRAC_CONST(0.3571567790443668), + FRAC_CONST(0.3594297585319891), + FRAC_CONST(0.3617070230294185), + FRAC_CONST(0.3639885066681048), + FRAC_CONST(0.3662741432432950), + FRAC_CONST(0.3685638662187693), + FRAC_CONST(0.3708576087316147), + FRAC_CONST(0.3731553035970366), + FRAC_CONST(0.3754568833132069), + FRAC_CONST(0.3777622800661488), + FRAC_CONST(0.3800714257346570), + FRAC_CONST(0.3823842518952546), + FRAC_CONST(0.3847006898271841), + FRAC_CONST(0.3870206705174334), + FRAC_CONST(0.3893441246657958), + FRAC_CONST(0.3916709826899639), + FRAC_CONST(0.3940011747306560), + FRAC_CONST(0.3963346306567764), + FRAC_CONST(0.3986712800706062), + FRAC_CONST(0.4010110523130271), + FRAC_CONST(0.4033538764687756), + FRAC_CONST(0.4056996813717284), + FRAC_CONST(0.4080483956102172), + FRAC_CONST(0.4103999475323736), + FRAC_CONST(0.4127542652515031), + FRAC_CONST(0.4151112766514873), + FRAC_CONST(0.4174709093922143), + FRAC_CONST(0.4198330909150365), + FRAC_CONST(0.4221977484482556), + FRAC_CONST(0.4245648090126334), + FRAC_CONST(0.4269341994269293), + FRAC_CONST(0.4293058463134616), + FRAC_CONST(0.4316796761036958), + FRAC_CONST(0.4340556150438547), + FRAC_CONST(0.4364335892005536), + FRAC_CONST(0.4388135244664580), + FRAC_CONST(0.4411953465659639), + FRAC_CONST(0.4435789810609000), + FRAC_CONST(0.4459643533562509), + FRAC_CONST(0.4483513887059016), + FRAC_CONST(0.4507400122184019), + FRAC_CONST(0.4531301488627497), + FRAC_CONST(0.4555217234741947), + FRAC_CONST(0.4579146607600593), + FRAC_CONST(0.4603088853055777), + FRAC_CONST(0.4627043215797521), + FRAC_CONST(0.4651008939412254), + FRAC_CONST(0.4674985266441709), + FRAC_CONST(0.4698971438441951), + FRAC_CONST(0.4722966696042580), + FRAC_CONST(0.4746970279006055), + FRAC_CONST(0.4770981426287164), + FRAC_CONST(0.4794999376092619), + FRAC_CONST(0.4819023365940778), + FRAC_CONST(0.4843052632721476), + FRAC_CONST(0.4867086412755978), + FRAC_CONST(0.4891123941857028), + FRAC_CONST(0.4915164455388997), + FRAC_CONST(0.4939207188328126), + FRAC_CONST(0.4963251375322855), + FRAC_CONST(0.4987296250754225), + FRAC_CONST(0.5011341048796359), + FRAC_CONST(0.5035385003477012), + FRAC_CONST(0.5059427348738168), + FRAC_CONST(0.5083467318496706), + FRAC_CONST(0.5107504146705106), + FRAC_CONST(0.5131537067412193), + FRAC_CONST(0.5155565314823923), + FRAC_CONST(0.5179588123364193), + FRAC_CONST(0.5203604727735667), + FRAC_CONST(0.5227614362980630), + FRAC_CONST(0.5251616264541841), + FRAC_CONST(0.5275609668323384), + FRAC_CONST(0.5299593810751532), + FRAC_CONST(0.5323567928835578), + FRAC_CONST(0.5347531260228663), + FRAC_CONST(0.5371483043288580), + FRAC_CONST(0.5395422517138538), + FRAC_CONST(0.5419348921727899), + FRAC_CONST(0.5443261497892862), + FRAC_CONST(0.5467159487417104), + FRAC_CONST(0.5491042133092364), + FRAC_CONST(0.5514908678778958), + FRAC_CONST(0.5538758369466227), + FRAC_CONST(0.5562590451332913), + FRAC_CONST(0.5586404171807443), + FRAC_CONST(0.5610198779628133), + FRAC_CONST(0.5633973524903286), + FRAC_CONST(0.5657727659171199), + FRAC_CONST(0.5681460435460047), + FRAC_CONST(0.5705171108347663), + FRAC_CONST(0.5728858934021188), + FRAC_CONST(0.5752523170336598), + FRAC_CONST(0.5776163076878088), + FRAC_CONST(0.5799777915017323), + FRAC_CONST(0.5823366947972535), + FRAC_CONST(0.5846929440867458), + FRAC_CONST(0.5870464660790119), + FRAC_CONST(0.5893971876851449), + FRAC_CONST(0.5917450360243719), + FRAC_CONST(0.5940899384298793), + FRAC_CONST(0.5964318224546208), + FRAC_CONST(0.5987706158771039), + FRAC_CONST(0.6011062467071583), + FRAC_CONST(0.6034386431916822), + FRAC_CONST(0.6057677338203681), + FRAC_CONST(0.6080934473314057), + FRAC_CONST(0.6104157127171639), + FRAC_CONST(0.6127344592298474), + FRAC_CONST(0.6150496163871310), + FRAC_CONST(0.6173611139777690), + FRAC_CONST(0.6196688820671789), + FRAC_CONST(0.6219728510029997), + FRAC_CONST(0.6242729514206247), + FRAC_CONST(0.6265691142487051), + FRAC_CONST(0.6288612707146283), + FRAC_CONST(0.6311493523499663), + FRAC_CONST(0.6334332909958958), + FRAC_CONST(0.6357130188085891), + FRAC_CONST(0.6379884682645743), + FRAC_CONST(0.6402595721660647), + FRAC_CONST(0.6425262636462578), + FRAC_CONST(0.6447884761746012), + FRAC_CONST(0.6470461435620266), + FRAC_CONST(0.6492991999661505), + FRAC_CONST(0.6515475798964411), + FRAC_CONST(0.6537912182193508), + FRAC_CONST(0.6560300501634142), + FRAC_CONST(0.6582640113243098), + FRAC_CONST(0.6604930376698862), + FRAC_CONST(0.6627170655451516), + FRAC_CONST(0.6649360316772256), + FRAC_CONST(0.6671498731802533), + FRAC_CONST(0.6693585275602818), + FRAC_CONST(0.6715619327200959), + FRAC_CONST(0.6737600269640164), + FRAC_CONST(0.6759527490026566), + FRAC_CONST(0.6781400379576392), + FRAC_CONST(0.6803218333662715), + FRAC_CONST(0.6824980751861787), + FRAC_CONST(0.6846687037998949), + FRAC_CONST(0.6868336600194123), + FRAC_CONST(0.6889928850906855), + FRAC_CONST(0.6911463206980928), + FRAC_CONST(0.6932939089688525), + FRAC_CONST(0.6954355924773949), + FRAC_CONST(0.6975713142496884), + FRAC_CONST(0.6997010177675195), + FRAC_CONST(0.7018246469727265), + FRAC_CONST(0.7039421462713862), + FRAC_CONST(0.7060534605379528), + FRAC_CONST(0.7081585351193496), + FRAC_CONST(0.7102573158390105), + FRAC_CONST(0.7123497490008750), + FRAC_CONST(0.7144357813933307), + FRAC_CONST(0.7165153602931092), + FRAC_CONST(0.7185884334691287), + FRAC_CONST(0.7206549491862871), + FRAC_CONST(0.7227148562092042), + FRAC_CONST(0.7247681038059106), + FRAC_CONST(0.7268146417514855), + FRAC_CONST(0.7288544203316418), + FRAC_CONST(0.7308873903462577), + FRAC_CONST(0.7329135031128549), + FRAC_CONST(0.7349327104700221), + FRAC_CONST(0.7369449647807855), + FRAC_CONST(0.7389502189359237), + FRAC_CONST(0.7409484263572271), + FRAC_CONST(0.7429395410007016), + FRAC_CONST(0.7449235173597176), + FRAC_CONST(0.7469003104681008), + FRAC_CONST(0.7488698759031670), + FRAC_CONST(0.7508321697887005), + FRAC_CONST(0.7527871487978728), + FRAC_CONST(0.7547347701561059), + FRAC_CONST(0.7566749916438754), + FRAC_CONST(0.7586077715994560), + FRAC_CONST(0.7605330689216074), + FRAC_CONST(0.7624508430722016), + FRAC_CONST(0.7643610540787891), + FRAC_CONST(0.7662636625371070), + FRAC_CONST(0.7681586296135255), + FRAC_CONST(0.7700459170474343), + FRAC_CONST(0.7719254871535672), + FRAC_CONST(0.7737973028242671), + FRAC_CONST(0.7756613275316875), + FRAC_CONST(0.7775175253299340), + FRAC_CONST(0.7793658608571425), + FRAC_CONST(0.7812062993374951), + FRAC_CONST(0.7830388065831744), + FRAC_CONST(0.7848633489962533), + FRAC_CONST(0.7866798935705233), + FRAC_CONST(0.7884884078932579), + FRAC_CONST(0.7902888601469138), + FRAC_CONST(0.7920812191107668), + FRAC_CONST(0.7938654541624850), + FRAC_CONST(0.7956415352796368), + FRAC_CONST(0.7974094330411343), + FRAC_CONST(0.7991691186286133), + FRAC_CONST(0.8009205638277465), + FRAC_CONST(0.8026637410294932), + FRAC_CONST(0.8043986232312831), + FRAC_CONST(0.8061251840381346), + FRAC_CONST(0.8078433976637077), + FRAC_CONST(0.8095532389312917), + FRAC_CONST(0.8112546832747255), + FRAC_CONST(0.8129477067392539), + FRAC_CONST(0.8146322859823164), + FRAC_CONST(0.8163083982742698), + FRAC_CONST(0.8179760214990457), + FRAC_CONST(0.8196351341547393), + FRAC_CONST(0.8212857153541345), + FRAC_CONST(0.8229277448251595), + FRAC_CONST(0.8245612029112778), + FRAC_CONST(0.8261860705718113), + FRAC_CONST(0.8278023293821971), + FRAC_CONST(0.8294099615341773), + FRAC_CONST(0.8310089498359212), + FRAC_CONST(0.8325992777120815), + FRAC_CONST(0.8341809292037831), + FRAC_CONST(0.8357538889685445), + FRAC_CONST(0.8373181422801330), + FRAC_CONST(0.8388736750283521), + FRAC_CONST(0.8404204737187619), + FRAC_CONST(0.8419585254723335), + FRAC_CONST(0.8434878180250348), + FRAC_CONST(0.8450083397273509), + FRAC_CONST(0.8465200795437368), + FRAC_CONST(0.8480230270520029), + FRAC_CONST(0.8495171724426350), + FRAC_CONST(0.8510025065180464), + FRAC_CONST(0.8524790206917633), + FRAC_CONST(0.8539467069875448), + FRAC_CONST(0.8554055580384357), + FRAC_CONST(0.8568555670857525), + FRAC_CONST(0.8582967279780043), + FRAC_CONST(0.8597290351697464), + FRAC_CONST(0.8611524837203691), + FRAC_CONST(0.8625670692928198), + FRAC_CONST(0.8639727881522599), + FRAC_CONST(0.8653696371646555), + FRAC_CONST(0.8667576137953045), + FRAC_CONST(0.8681367161072958), + FRAC_CONST(0.8695069427599065), + FRAC_CONST(0.8708682930069319), + FRAC_CONST(0.8722207666949527), + FRAC_CONST(0.8735643642615368), + FRAC_CONST(0.8748990867333771), + FRAC_CONST(0.8762249357243662), + FRAC_CONST(0.8775419134336067), + FRAC_CONST(0.8788500226433579), + FRAC_CONST(0.8801492667169208), + FRAC_CONST(0.8814396495964587), + FRAC_CONST(0.8827211758007560), + FRAC_CONST(0.8839938504229149), + FRAC_CONST(0.8852576791279895), + FRAC_CONST(0.8865126681505587), + FRAC_CONST(0.8877588242922386), + FRAC_CONST(0.8889961549191320), + FRAC_CONST(0.8902246679592184), + FRAC_CONST(0.8914443718996848), + FRAC_CONST(0.8926552757841945), + FRAC_CONST(0.8938573892100969), + FRAC_CONST(0.8950507223255798), + FRAC_CONST(0.8962352858267605), + FRAC_CONST(0.8974110909547198), + FRAC_CONST(0.8985781494924783), + FRAC_CONST(0.8997364737619142), + FRAC_CONST(0.9008860766206249), + FRAC_CONST(0.9020269714587307), + FRAC_CONST(0.9031591721956235), + FRAC_CONST(0.9042826932766591), + FRAC_CONST(0.9053975496697941), + FRAC_CONST(0.9065037568621681), + FRAC_CONST(0.9076013308566311), + FRAC_CONST(0.9086902881682180), + FRAC_CONST(0.9097706458205682), + FRAC_CONST(0.9108424213422940), + FRAC_CONST(0.9119056327632955), + FRAC_CONST(0.9129602986110235), + FRAC_CONST(0.9140064379066919), + FRAC_CONST(0.9150440701614393), + FRAC_CONST(0.9160732153724396), + FRAC_CONST(0.9170938940189634), + FRAC_CONST(0.9181061270583908), + FRAC_CONST(0.9191099359221748), + FRAC_CONST(0.9201053425117579), + FRAC_CONST(0.9210923691944400), + FRAC_CONST(0.9220710387992010), + FRAC_CONST(0.9230413746124764), + FRAC_CONST(0.9240034003738882), + FRAC_CONST(0.9249571402719298), + FRAC_CONST(0.9259026189396085), + FRAC_CONST(0.9268398614500427), + FRAC_CONST(0.9277688933120170), + FRAC_CONST(0.9286897404654957), + FRAC_CONST(0.9296024292770939), + FRAC_CONST(0.9305069865355076), + FRAC_CONST(0.9314034394469048), + FRAC_CONST(0.9322918156302762), + FRAC_CONST(0.9331721431127471), + FRAC_CONST(0.9340444503248519), + FRAC_CONST(0.9349087660957711), + FRAC_CONST(0.9357651196485313), + FRAC_CONST(0.9366135405951697), + FRAC_CONST(0.9374540589318637), + FRAC_CONST(0.9382867050340261), + FRAC_CONST(0.9391115096513655), + FRAC_CONST(0.9399285039029165), + FRAC_CONST(0.9407377192720349), + FRAC_CONST(0.9415391876013639), + FRAC_CONST(0.9423329410877687), + FRAC_CONST(0.9431190122772415), + FRAC_CONST(0.9438974340597782), + FRAC_CONST(0.9446682396642262), + FRAC_CONST(0.9454314626531054), + FRAC_CONST(0.9461871369174033), + FRAC_CONST(0.9469352966713429), + FRAC_CONST(0.9476759764471278), + FRAC_CONST(0.9484092110896616), + FRAC_CONST(0.9491350357512457), + FRAC_CONST(0.9498534858862532), + FRAC_CONST(0.9505645972457831), + FRAC_CONST(0.9512684058722927), + FRAC_CONST(0.9519649480942105), + FRAC_CONST(0.9526542605205314), + FRAC_CONST(0.9533363800353921), + FRAC_CONST(0.9540113437926313), + FRAC_CONST(0.9546791892103320), + FRAC_CONST(0.9553399539653500), + FRAC_CONST(0.9559936759878265), + FRAC_CONST(0.9566403934556893), + FRAC_CONST(0.9572801447891388), + FRAC_CONST(0.9579129686451244), + FRAC_CONST(0.9585389039118085), + FRAC_CONST(0.9591579897030224), + FRAC_CONST(0.9597702653527108), + FRAC_CONST(0.9603757704093711), + FRAC_CONST(0.9609745446304828), + FRAC_CONST(0.9615666279769324), + FRAC_CONST(0.9621520606074324), + FRAC_CONST(0.9627308828729358), + FRAC_CONST(0.9633031353110477), + FRAC_CONST(0.9638688586404335), + FRAC_CONST(0.9644280937552258), + FRAC_CONST(0.9649808817194311), + FRAC_CONST(0.9655272637613366), + FRAC_CONST(0.9660672812679171), + FRAC_CONST(0.9666009757792454), + FRAC_CONST(0.9671283889829055), + FRAC_CONST(0.9676495627084089), + FRAC_CONST(0.9681645389216160), + FRAC_CONST(0.9686733597191652), + FRAC_CONST(0.9691760673229058), + FRAC_CONST(0.9696727040743406), + FRAC_CONST(0.9701633124290767), + FRAC_CONST(0.9706479349512860), + FRAC_CONST(0.9711266143081750), + FRAC_CONST(0.9715993932644684), + FRAC_CONST(0.9720663146769026), + FRAC_CONST(0.9725274214887337), + FRAC_CONST(0.9729827567242596), + FRAC_CONST(0.9734323634833574), + FRAC_CONST(0.9738762849360358), + FRAC_CONST(0.9743145643170059), + FRAC_CONST(0.9747472449202687), + FRAC_CONST(0.9751743700937215), + FRAC_CONST(0.9755959832337850), + FRAC_CONST(0.9760121277800496), + FRAC_CONST(0.9764228472099433), + FRAC_CONST(0.9768281850334235), + FRAC_CONST(0.9772281847876897), + FRAC_CONST(0.9776228900319223), + FRAC_CONST(0.9780123443420448), + FRAC_CONST(0.9783965913055132), + FRAC_CONST(0.9787756745161313), + FRAC_CONST(0.9791496375688939), + FRAC_CONST(0.9795185240548578), + FRAC_CONST(0.9798823775560431), + FRAC_CONST(0.9802412416403639), + FRAC_CONST(0.9805951598565897), + FRAC_CONST(0.9809441757293399), + FRAC_CONST(0.9812883327541090), + FRAC_CONST(0.9816276743923267), + FRAC_CONST(0.9819622440664515), + FRAC_CONST(0.9822920851550995), + FRAC_CONST(0.9826172409882086), + FRAC_CONST(0.9829377548422400), + FRAC_CONST(0.9832536699354163), + FRAC_CONST(0.9835650294229984), + FRAC_CONST(0.9838718763926001), + FRAC_CONST(0.9841742538595437), + FRAC_CONST(0.9844722047622547), + FRAC_CONST(0.9847657719576983), + FRAC_CONST(0.9850549982168574), + FRAC_CONST(0.9853399262202529), + FRAC_CONST(0.9856205985535073), + FRAC_CONST(0.9858970577029519), + FRAC_CONST(0.9861693460512790), + FRAC_CONST(0.9864375058732389), + FRAC_CONST(0.9867015793313820), + FRAC_CONST(0.9869616084718489), + FRAC_CONST(0.9872176352202061), + FRAC_CONST(0.9874697013773301), + FRAC_CONST(0.9877178486153397), + FRAC_CONST(0.9879621184735767), + FRAC_CONST(0.9882025523546365), + FRAC_CONST(0.9884391915204485), + FRAC_CONST(0.9886720770884069), + FRAC_CONST(0.9889012500275530), + FRAC_CONST(0.9891267511548089), + FRAC_CONST(0.9893486211312621), + FRAC_CONST(0.9895669004585049), + FRAC_CONST(0.9897816294750255), + FRAC_CONST(0.9899928483526520), + FRAC_CONST(0.9902005970930525), + FRAC_CONST(0.9904049155242876), + FRAC_CONST(0.9906058432974180), + FRAC_CONST(0.9908034198831690), + FRAC_CONST(0.9909976845686489), + FRAC_CONST(0.9911886764541239), + FRAC_CONST(0.9913764344498495), + FRAC_CONST(0.9915609972729590), + FRAC_CONST(0.9917424034444086), + FRAC_CONST(0.9919206912859797), + FRAC_CONST(0.9920958989173397), + FRAC_CONST(0.9922680642531603), + FRAC_CONST(0.9924372250002933), + FRAC_CONST(0.9926034186550070), + FRAC_CONST(0.9927666825002789), + FRAC_CONST(0.9929270536031491), + FRAC_CONST(0.9930845688121325), + FRAC_CONST(0.9932392647546895), + FRAC_CONST(0.9933911778347579), + FRAC_CONST(0.9935403442303433), + FRAC_CONST(0.9936867998911693), + FRAC_CONST(0.9938305805363887), + FRAC_CONST(0.9939717216523539), + FRAC_CONST(0.9941102584904481), + FRAC_CONST(0.9942462260649764), + FRAC_CONST(0.9943796591511174), + FRAC_CONST(0.9945105922829353), + FRAC_CONST(0.9946390597514524), + FRAC_CONST(0.9947650956027824), + FRAC_CONST(0.9948887336363228), + FRAC_CONST(0.9950100074030103), + FRAC_CONST(0.9951289502036336), + FRAC_CONST(0.9952455950872091), + FRAC_CONST(0.9953599748494155), + FRAC_CONST(0.9954721220310890), + FRAC_CONST(0.9955820689167787), + FRAC_CONST(0.9956898475333619), + FRAC_CONST(0.9957954896487196), + FRAC_CONST(0.9958990267704713), + FRAC_CONST(0.9960004901447701), + FRAC_CONST(0.9960999107551559), + FRAC_CONST(0.9961973193214694), + FRAC_CONST(0.9962927462988245), + FRAC_CONST(0.9963862218766388), + FRAC_CONST(0.9964777759777242), + FRAC_CONST(0.9965674382574342), + FRAC_CONST(0.9966552381028704), + FRAC_CONST(0.9967412046321465), + FRAC_CONST(0.9968253666937095), + FRAC_CONST(0.9969077528657186), + FRAC_CONST(0.9969883914554805), + FRAC_CONST(0.9970673104989413), + FRAC_CONST(0.9971445377602348), + FRAC_CONST(0.9972201007312871), + FRAC_CONST(0.9972940266314749), + FRAC_CONST(0.9973663424073412), + FRAC_CONST(0.9974370747323638), + FRAC_CONST(0.9975062500067785), + FRAC_CONST(0.9975738943574574), + FRAC_CONST(0.9976400336378379), + FRAC_CONST(0.9977046934279079), + FRAC_CONST(0.9977678990342401), + FRAC_CONST(0.9978296754900812), + FRAC_CONST(0.9978900475554902), + FRAC_CONST(0.9979490397175296), + FRAC_CONST(0.9980066761905056), + FRAC_CONST(0.9980629809162593), + FRAC_CONST(0.9981179775645063), + FRAC_CONST(0.9981716895332257), + FRAC_CONST(0.9982241399490979), + FRAC_CONST(0.9982753516679893), + FRAC_CONST(0.9983253472754841), + FRAC_CONST(0.9983741490874634), + FRAC_CONST(0.9984217791507299), + FRAC_CONST(0.9984682592436778), + FRAC_CONST(0.9985136108770075), + FRAC_CONST(0.9985578552944850), + FRAC_CONST(0.9986010134737439), + FRAC_CONST(0.9986431061271304), + FRAC_CONST(0.9986841537025921), + FRAC_CONST(0.9987241763846056), + FRAC_CONST(0.9987631940951476), + FRAC_CONST(0.9988012264947044), + FRAC_CONST(0.9988382929833222), + FRAC_CONST(0.9988744127016956), + FRAC_CONST(0.9989096045322947), + FRAC_CONST(0.9989438871005292), + FRAC_CONST(0.9989772787759494), + FRAC_CONST(0.9990097976734847), + FRAC_CONST(0.9990414616547146), + FRAC_CONST(0.9990722883291779), + FRAC_CONST(0.9991022950557125), + FRAC_CONST(0.9991314989438310), + FRAC_CONST(0.9991599168551279), + FRAC_CONST(0.9991875654047181), + FRAC_CONST(0.9992144609627068), + FRAC_CONST(0.9992406196556911), + FRAC_CONST(0.9992660573682882), + FRAC_CONST(0.9992907897446957), + FRAC_CONST(0.9993148321902777), + FRAC_CONST(0.9993381998731797), + FRAC_CONST(0.9993609077259696), + FRAC_CONST(0.9993829704473038), + FRAC_CONST(0.9994044025036201), + FRAC_CONST(0.9994252181308537), + FRAC_CONST(0.9994454313361775), + FRAC_CONST(0.9994650558997651), + FRAC_CONST(0.9994841053765757), + FRAC_CONST(0.9995025930981609), + FRAC_CONST(0.9995205321744921), + FRAC_CONST(0.9995379354958073), + FRAC_CONST(0.9995548157344778), + FRAC_CONST(0.9995711853468930), + FRAC_CONST(0.9995870565753632), + FRAC_CONST(0.9996024414500382), + FRAC_CONST(0.9996173517908444), + FRAC_CONST(0.9996317992094352), + FRAC_CONST(0.9996457951111574), + FRAC_CONST(0.9996593506970310), + FRAC_CONST(0.9996724769657434), + FRAC_CONST(0.9996851847156547), + FRAC_CONST(0.9996974845468164), + FRAC_CONST(0.9997093868630000), + FRAC_CONST(0.9997209018737374), + FRAC_CONST(0.9997320395963699), + FRAC_CONST(0.9997428098581069), + FRAC_CONST(0.9997532222980933), + FRAC_CONST(0.9997632863694836), + FRAC_CONST(0.9997730113415246), + FRAC_CONST(0.9997824063016426), + FRAC_CONST(0.9997914801575380), + FRAC_CONST(0.9998002416392840), + FRAC_CONST(0.9998086993014300), + FRAC_CONST(0.9998168615251084), + FRAC_CONST(0.9998247365201450), + FRAC_CONST(0.9998323323271717), + FRAC_CONST(0.9998396568197407), + FRAC_CONST(0.9998467177064404), + FRAC_CONST(0.9998535225330116), + FRAC_CONST(0.9998600786844637), + FRAC_CONST(0.9998663933871905), + FRAC_CONST(0.9998724737110845), + FRAC_CONST(0.9998783265716498), + FRAC_CONST(0.9998839587321121), + FRAC_CONST(0.9998893768055266), + FRAC_CONST(0.9998945872568815), + FRAC_CONST(0.9998995964051983), + FRAC_CONST(0.9999044104256269), + FRAC_CONST(0.9999090353515359), + FRAC_CONST(0.9999134770765971), + FRAC_CONST(0.9999177413568642), + FRAC_CONST(0.9999218338128448), + FRAC_CONST(0.9999257599315647), + FRAC_CONST(0.9999295250686255), + FRAC_CONST(0.9999331344502529), + FRAC_CONST(0.9999365931753376), + FRAC_CONST(0.9999399062174669), + FRAC_CONST(0.9999430784269460), + FRAC_CONST(0.9999461145328103), + FRAC_CONST(0.9999490191448277), + FRAC_CONST(0.9999517967554878), + FRAC_CONST(0.9999544517419835), + FRAC_CONST(0.9999569883681778), + FRAC_CONST(0.9999594107865607), + FRAC_CONST(0.9999617230401926), + FRAC_CONST(0.9999639290646355), + FRAC_CONST(0.9999660326898712), + FRAC_CONST(0.9999680376422052), + FRAC_CONST(0.9999699475461585), + FRAC_CONST(0.9999717659263435), + FRAC_CONST(0.9999734962093266), + FRAC_CONST(0.9999751417254756), + FRAC_CONST(0.9999767057107922), + FRAC_CONST(0.9999781913087290), + FRAC_CONST(0.9999796015719915), + FRAC_CONST(0.9999809394643231), + FRAC_CONST(0.9999822078622751), + FRAC_CONST(0.9999834095569596), + FRAC_CONST(0.9999845472557860), + FRAC_CONST(0.9999856235841805), + FRAC_CONST(0.9999866410872889), + FRAC_CONST(0.9999876022316609), + FRAC_CONST(0.9999885094069193), + FRAC_CONST(0.9999893649274085), + FRAC_CONST(0.9999901710338274), + FRAC_CONST(0.9999909298948430), + FRAC_CONST(0.9999916436086862), + FRAC_CONST(0.9999923142047299), + FRAC_CONST(0.9999929436450469), + FRAC_CONST(0.9999935338259505), + FRAC_CONST(0.9999940865795161), + FRAC_CONST(0.9999946036750835), + FRAC_CONST(0.9999950868207405), + FRAC_CONST(0.9999955376647868), + FRAC_CONST(0.9999959577971798), + FRAC_CONST(0.9999963487509599), + FRAC_CONST(0.9999967120036571), + FRAC_CONST(0.9999970489786785), + FRAC_CONST(0.9999973610466748), + FRAC_CONST(0.9999976495268890), + FRAC_CONST(0.9999979156884846), + FRAC_CONST(0.9999981607518545), + FRAC_CONST(0.9999983858899099), + FRAC_CONST(0.9999985922293493), + FRAC_CONST(0.9999987808519092), + FRAC_CONST(0.9999989527955938), + FRAC_CONST(0.9999991090558848), + FRAC_CONST(0.9999992505869332), + FRAC_CONST(0.9999993783027293), + FRAC_CONST(0.9999994930782556), + FRAC_CONST(0.9999995957506171), + FRAC_CONST(0.9999996871201549), + FRAC_CONST(0.9999997679515386), + FRAC_CONST(0.9999998389748399), + FRAC_CONST(0.9999999008865869), + FRAC_CONST(0.9999999543507984) }; +#endif -real_t kbd_short_128[] = +ALIGN static const real_t kbd_short_128[] = { - 0x2DEC, - 0x7C70, - 0xF1EC, - 0x19864, - 0x27B3D, - 0x3A753, - 0x52B03, - 0x71637, - 0x97A69, - 0xC6AA6, - 0xFFB8C, - 0x14433E, - 0x19595A, - 0x1F56E5, - 0x265635, - 0x2E72D1, - 0x37C94C, - 0x427722, - 0x4E9A83, - 0x5C5227, - 0x6BBD0D, - 0x7CFA46, - 0x9028AF, - 0xA566AF, - 0xBCD1EE, - 0xD6870D, - 0xF2A159, - 0x1113A7E, - 0x1326A3C, - 0x156461C, - 0x17CE124, - 0x1A64B92, - 0x1D29294, - 0x201C010, - 0x233DA5C, - 0x268E41C, - 0x2A0DBFC, - 0x2DBBCA0, - 0x3197C7C, - 0x35A0DC0, - 0x39D5E40, - 0x3E35788, - 0x42BDED0, - 0x476D508, - 0x4C41720, - 0x5137DE0, - 0x564DE60, - 0x5B80A20, - 0x60CCF50, - 0x662F918, - 0x6BA4FF0, - 0x7129A00, - 0x76B9B70, - 0x7C516F0, - 0x81ECE00, - 0x8788190, - 0x8D1F240, - 0x92AE100, - 0x9830F60, - 0x9DA4020, - 0xA3037A0, - 0xA84BC50, - 0xAD79720, - 0xB2893B0, - 0xB778110, - 0xBC431C0, - 0xC0E7C30, - 0xC563AF0, - 0xC9B4CF0, - 0xCDD95A0, - 0xD1CFD30, - 0xD597090, - 0xD92E180, - 0xDC94690, - 0xDFC9B20, - 0xE2CDF20, - 0xE5A1710, - 0xE844BD0, - 0xEAB8A30, - 0xECFE300, - 0xEF16A60, - 0xF1037D0, - 0xF2C6590, - 0xF461040, - 0xF5D56A0, - 0xF725920, - 0xF853960, - 0xF961A00, - 0xFA51DE0, - 0xFB26830, - 0xFBE1BE0, - 0xFC85B20, - 0xFD14770, - 0xFD90130, - 0xFDFA730, - 0xFE55700, - 0xFEA2C30, - 0xFEE40C0, - 0xFF1ACA0, - 0xFF485D0, - 0xFF6E070, - 0xFF8CEB0, - 0xFFA60D0, - 0xFFBA540, - 0xFFCA8C0, - 0xFFD7660, - 0xFFE17C0, - 0xFFE9530, - 0xFFEF5A0, - 0xFFF3EE0, - 0xFFF75F0, - 0xFFF9EC0, - 0xFFFBC90, - 0xFFFD210, - 0xFFFE150, - 0xFFFEBF0, - 0xFFFF330, - 0xFFFF800, - 0xFFFFB30, - 0xFFFFD30, - 0xFFFFE70, - 0xFFFFF30, - 0xFFFFF90, - 0xFFFFFD0, - 0xFFFFFF0, - 0x10000000, - 0x10000000, - 0x10000000 + FRAC_CONST(4.3795702929468881e-005), + FRAC_CONST(0.00011867384265436617), + FRAC_CONST(0.0002307165763996192), + FRAC_CONST(0.00038947282760568383), + FRAC_CONST(0.00060581272288302553), + FRAC_CONST(0.00089199695169487453), + FRAC_CONST(0.0012617254423430522), + FRAC_CONST(0.0017301724373162003), + FRAC_CONST(0.0023140071937421476), + FRAC_CONST(0.0030313989666022221), + FRAC_CONST(0.0039020049735530842), + FRAC_CONST(0.0049469401815512024), + FRAC_CONST(0.0061887279335368318), + FRAC_CONST(0.0076512306364647726), + FRAC_CONST(0.0093595599562652423), + FRAC_CONST(0.011339966208377799), + FRAC_CONST(0.013619706891715299), + FRAC_CONST(0.016226894586323766), + FRAC_CONST(0.019190324717288168), + FRAC_CONST(0.022539283975960878), + FRAC_CONST(0.026303340480472455), + FRAC_CONST(0.030512117046644357), + FRAC_CONST(0.03519504922365594), + FRAC_CONST(0.040381130021856941), + FRAC_CONST(0.046098643518702249), + FRAC_CONST(0.052374889768730587), + FRAC_CONST(0.059235903660769147), + FRAC_CONST(0.066706170556282418), + FRAC_CONST(0.074808341703430481), + FRAC_CONST(0.083562952548726227), + FRAC_CONST(0.092988147159339674), + FRAC_CONST(0.1030994120216919), + FRAC_CONST(0.11390932249409955), + FRAC_CONST(0.12542730516149531), + FRAC_CONST(0.13765941926783826), + FRAC_CONST(0.15060816028651081), + FRAC_CONST(0.16427228853114245), + FRAC_CONST(0.17864668550988483), + FRAC_CONST(0.19372224048676889), + FRAC_CONST(0.20948576943658073), + FRAC_CONST(0.22591996826744942), + FRAC_CONST(0.24300340184133981), + FRAC_CONST(0.26071052995068139), + FRAC_CONST(0.27901177101369551), + FRAC_CONST(0.29787360383626599), + FRAC_CONST(0.3172587073594233), + FRAC_CONST(0.33712613787396362), + FRAC_CONST(0.35743154274286698), + FRAC_CONST(0.37812740923363009), + FRAC_CONST(0.39916334663203618), + FRAC_CONST(0.42048639939189658), + FRAC_CONST(0.4420413886774246), + FRAC_CONST(0.4637712792815169), + FRAC_CONST(0.4856175685594023), + FRAC_CONST(0.50752069370766872), + FRAC_CONST(0.52942045344797806), + FRAC_CONST(0.55125643994680196), + FRAC_CONST(0.57296847662071559), + FRAC_CONST(0.59449705734411495), + FRAC_CONST(0.61578378249506627), + FRAC_CONST(0.63677178724712891), + FRAC_CONST(0.65740615754163356), + FRAC_CONST(0.67763432925662526), + FRAC_CONST(0.69740646622548552), + FRAC_CONST(0.71667581294953808), + FRAC_CONST(0.73539901809352737), + FRAC_CONST(0.75353642514900732), + FRAC_CONST(0.77105232699609816), + FRAC_CONST(0.78791518148597028), + FRAC_CONST(0.80409778560147072), + FRAC_CONST(0.81957740622770781), + FRAC_CONST(0.83433586607383625), + FRAC_CONST(0.84835958382689225), + FRAC_CONST(0.86163956818294229), + FRAC_CONST(0.87417136598406997), + FRAC_CONST(0.88595496528524853), + FRAC_CONST(0.89699465477567619), + FRAC_CONST(0.90729884157670959), + FRAC_CONST(0.91687983002436779), + FRAC_CONST(0.92575356460899649), + FRAC_CONST(0.93393934077779084), + FRAC_CONST(0.94145948779657318), + FRAC_CONST(0.94833902830402828), + FRAC_CONST(0.95460531956280026), + FRAC_CONST(0.96028768170574896), + FRAC_CONST(0.96541701848104766), + FRAC_CONST(0.97002543610646474), + FRAC_CONST(0.97414586584250062), + FRAC_CONST(0.97781169577969584), + FRAC_CONST(0.98105641710392333), + FRAC_CONST(0.98391328975491177), + FRAC_CONST(0.98641503193166202), + FRAC_CONST(0.98859353733226141), + FRAC_CONST(0.99047962335771556), + FRAC_CONST(0.9921028127769449), + FRAC_CONST(0.99349115056397752), + FRAC_CONST(0.99467105680259038), + FRAC_CONST(0.9956672157341897), + FRAC_CONST(0.99650250022834352), + FRAC_CONST(0.99719793020823266), + FRAC_CONST(0.99777266288955657), + FRAC_CONST(0.99824401211201486), + FRAC_CONST(0.99862749357391212), + FRAC_CONST(0.99893689243401962), + FRAC_CONST(0.99918434952623147), + FRAC_CONST(0.99938046234161726), + FRAC_CONST(0.99953439696357238), + FRAC_CONST(0.99965400728430465), + FRAC_CONST(0.99974595807027455), + FRAC_CONST(0.99981584876278362), + FRAC_CONST(0.99986833527824281), + FRAC_CONST(0.99990724749057802), + FRAC_CONST(0.99993570051598468), + FRAC_CONST(0.99995619835942084), + FRAC_CONST(0.99997072890647543), + FRAC_CONST(0.9999808496399144), + FRAC_CONST(0.99998776381655818), + FRAC_CONST(0.99999238714961569), + FRAC_CONST(0.99999540529959718), + FRAC_CONST(0.99999732268176988), + FRAC_CONST(0.99999850325054862), + FRAC_CONST(0.99999920402413744), + FRAC_CONST(0.9999996021706401), + FRAC_CONST(0.99999981649545566), + FRAC_CONST(0.99999992415545547), + FRAC_CONST(0.99999997338493041), + FRAC_CONST(0.99999999295825959), + FRAC_CONST(0.99999999904096815) }; -real_t kbd_short_120[] = +#ifdef ALLOW_SMALL_FRAMELENGTH +ALIGN static const real_t kbd_short_120[] = { - 0x2F6D, - 0x85A5, - 0x1093A, - 0x1C692, - 0x2CBDF, - 0x42937, - 0x5F0A9, - 0x83646, - 0xB1029, - 0xE9675, - 0x12E34C, - 0x1812C1, - 0x1E42C0, - 0x2592EE, - 0x2E2485, - 0x381A1F, - 0x439782, - 0x50C160, - 0x5FBD0E, - 0x70B036, - 0x83C082, - 0x99133E, - 0xB0CD00, - 0xCB113B, - 0xE801DA, - 0x107BEDE, - 0x12A65E6, - 0x15011DA, - 0x178DA70, - 0x1A4D3D6, - 0x1D40E4E, - 0x20695D8, - 0x23C71DC, - 0x275A4E8, - 0x2B22C6C, - 0x2F20094, - 0x335140C, - 0x37B53F4, - 0x3C4A7D4, - 0x410F198, - 0x4600DA8, - 0x4B1D308, - 0x5061378, - 0x55C9BC8, - 0x5B53418, - 0x60FA030, - 0x66B9FF0, - 0x6C8EFC0, - 0x7274920, - 0x7866300, - 0x7E5F288, - 0x845ABA0, - 0x8A54180, - 0x9046750, - 0x962D0E0, - 0x9C03350, - 0xA1C4580, - 0xA76C0E0, - 0xACF61D0, - 0xB25E890, - 0xB7A1940, - 0xBCBBCB0, - 0xC1AA0D0, - 0xC6698E0, - 0xCAF7DC0, - 0xCF52E60, - 0xD378FC0, - 0xD768D10, - 0xDB217D0, - 0xDEA2790, - 0xE1EBA10, - 0xE4FD310, - 0xE7D7BC0, - 0xEA7C2F0, - 0xECEBC40, - 0xEF27FF0, - 0xF132A80, - 0xF30DBE0, - 0xF4BB760, - 0xF63E2A0, - 0xF798580, - 0xF8CC930, - 0xF9DD7E0, - 0xFACDC30, - 0xFBA00A0, - 0xFC56F30, - 0xFCF50D0, - 0xFD7CD20, - 0xFDF09F0, - 0xFE52B60, - 0xFEA5310, - 0xFEEA080, - 0xFF23090, - 0xFF51DC0, - 0xFF77FF0, - 0xFF96C90, - 0xFFAF690, - 0xFFC2EB0, - 0xFFD2380, - 0xFFDE160, - 0xFFE7310, - 0xFFEE180, - 0xFFF3430, - 0xFFF7140, - 0xFFF9DA0, - 0xFFFBD70, - 0xFFFD3E0, - 0xFFFE360, - 0xFFFEDE0, - 0xFFFF4E0, - 0xFFFF960, - 0xFFFFC30, - 0xFFFFDE0, - 0xFFFFEE0, - 0xFFFFF70, - 0xFFFFFC0, - 0xFFFFFE0, - 0xFFFFFF0, - 0x10000000, - 0x10000000 + FRAC_CONST(0.0000452320086910), + FRAC_CONST(0.0001274564692111), + FRAC_CONST(0.0002529398385345), + FRAC_CONST(0.0004335140496648), + FRAC_CONST(0.0006827100966952), + FRAC_CONST(0.0010158708222246), + FRAC_CONST(0.0014502162869659), + FRAC_CONST(0.0020048865156264), + FRAC_CONST(0.0027009618393178), + FRAC_CONST(0.0035614590925043), + FRAC_CONST(0.0046113018122711), + FRAC_CONST(0.0058772627936484), + FRAC_CONST(0.0073878776584103), + FRAC_CONST(0.0091733284512589), + FRAC_CONST(0.0112652966728373), + FRAC_CONST(0.0136967855861945), + FRAC_CONST(0.0165019120857793), + FRAC_CONST(0.0197156688892217), + FRAC_CONST(0.0233736582950619), + FRAC_CONST(0.0275117992367496), + FRAC_CONST(0.0321660098468534), + FRAC_CONST(0.0373718682174417), + FRAC_CONST(0.0431642544948834), + FRAC_CONST(0.0495769778717676), + FRAC_CONST(0.0566423924273392), + FRAC_CONST(0.0643910061132260), + FRAC_CONST(0.0728510874761729), + FRAC_CONST(0.0820482749475221), + FRAC_CONST(0.0920051937045235), + FRAC_CONST(0.1027410852163450), + FRAC_CONST(0.1142714546239370), + FRAC_CONST(0.1266077410648368), + FRAC_CONST(0.1397570159398145), + FRAC_CONST(0.1537217139274270), + FRAC_CONST(0.1684994012857075), + FRAC_CONST(0.1840825856392944), + FRAC_CONST(0.2004585710384133), + FRAC_CONST(0.2176093615976121), + FRAC_CONST(0.2355116164824983), + FRAC_CONST(0.2541366584185075), + FRAC_CONST(0.2734505372545160), + FRAC_CONST(0.2934141494343369), + FRAC_CONST(0.3139834135200387), + FRAC_CONST(0.3351095011824163), + FRAC_CONST(0.3567391223361566), + FRAC_CONST(0.3788148623608774), + FRAC_CONST(0.4012755686250732), + FRAC_CONST(0.4240567828288110), + FRAC_CONST(0.4470912150133537), + FRAC_CONST(0.4703092544619664), + FRAC_CONST(0.4936395121456694), + FRAC_CONST(0.5170093888596962), + FRAC_CONST(0.5403456627591340), + FRAC_CONST(0.5635750896430154), + FRAC_CONST(0.5866250090612892), + FRAC_CONST(0.6094239491338723), + FRAC_CONST(0.6319022228794100), + FRAC_CONST(0.6539925088563087), + FRAC_CONST(0.6756304090216887), + FRAC_CONST(0.6967549769155277), + FRAC_CONST(0.7173092095766250), + FRAC_CONST(0.7372404969921184), + FRAC_CONST(0.7565010233699827), + FRAC_CONST(0.7750481150999984), + FRAC_CONST(0.7928445309277697), + FRAC_CONST(0.8098586906021583), + FRAC_CONST(0.8260648390616000), + FRAC_CONST(0.8414431440907889), + FRAC_CONST(0.8559797262966709), + FRAC_CONST(0.8696666212110165), + FRAC_CONST(0.8825016743142358), + FRAC_CONST(0.8944883707784486), + FRAC_CONST(0.9056356027326216), + FRAC_CONST(0.9159573778427816), + FRAC_CONST(0.9254724739583072), + FRAC_CONST(0.9342040454819434), + FRAC_CONST(0.9421791879559176), + FRAC_CONST(0.9494284680976784), + FRAC_CONST(0.9559854271440150), + FRAC_CONST(0.9618860658493898), + FRAC_CONST(0.9671683198119525), + FRAC_CONST(0.9718715339497299), + FRAC_CONST(0.9760359449042233), + FRAC_CONST(0.9797021798981759), + FRAC_CONST(0.9829107801140203), + FRAC_CONST(0.9857017559923277), + FRAC_CONST(0.9881141809867999), + FRAC_CONST(0.9901858292742826), + FRAC_CONST(0.9919528617340944), + FRAC_CONST(0.9934495632180476), + FRAC_CONST(0.9947081327749199), + FRAC_CONST(0.9957585271195989), + FRAC_CONST(0.9966283562984427), + FRAC_CONST(0.9973428292485683), + FRAC_CONST(0.9979247458259197), + FRAC_CONST(0.9983945309245774), + FRAC_CONST(0.9987703055583410), + FRAC_CONST(0.9990679892449266), + FRAC_CONST(0.9993014277313617), + FRAC_CONST(0.9994825400228521), + FRAC_CONST(0.9996214788122335), + FRAC_CONST(0.9997267987294857), + FRAC_CONST(0.9998056273097539), + FRAC_CONST(0.9998638341781910), + FRAC_CONST(0.9999061946325793), + FRAC_CONST(0.9999365445321382), + FRAC_CONST(0.9999579241373735), + FRAC_CONST(0.9999727092594598), + FRAC_CONST(0.9999827287418790), + FRAC_CONST(0.9999893678912771), + FRAC_CONST(0.9999936579844555), + FRAC_CONST(0.9999963523959187), + FRAC_CONST(0.9999979902130101), + FRAC_CONST(0.9999989484358076), + FRAC_CONST(0.9999994840031031), + FRAC_CONST(0.9999997669534347), + FRAC_CONST(0.9999999060327799), + FRAC_CONST(0.9999999680107184), + FRAC_CONST(0.9999999918774242), + FRAC_CONST(0.9999999989770326) }; - #endif #ifdef __cplusplus diff --git a/src/libfaad/lt_predict.c b/src/libfaad/lt_predict.c index 55e5f3aeb..c81a62def 100644 --- a/src/libfaad/lt_predict.c +++ b/src/libfaad/lt_predict.c @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: lt_predict.c,v 1.2 2002/12/16 19:00:34 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: lt_predict.c,v 1.3 2003/12/30 02:00:10 miguelfreitas Exp $ **/ @@ -31,27 +37,50 @@ #include "filtbank.h" #include "tns.h" -static real_t codebook[8] = +/* check if the object type is an object type that can have LTP */ +uint8_t is_ltp_ot(uint8_t object_type) { - COEF_CONST(0.570829), - COEF_CONST(0.696616), - COEF_CONST(0.813004), - COEF_CONST(0.911304), - COEF_CONST(0.984900), - COEF_CONST(1.067894), - COEF_CONST(1.194601), - COEF_CONST(1.369533) +#ifdef LTP_DEC + if ((object_type == LTP) +#ifdef ERROR_RESILIENCE + || (object_type == ER_LTP) +#endif +#ifdef LD_DEC + || (object_type == LD) +#endif +#ifdef SCALABLE_DEC + || (object_type == 6) /* TODO */ +#endif + ) + { + return 1; + } +#endif + + return 0; +} + +ALIGN static const real_t codebook[8] = +{ + REAL_CONST(0.570829), + REAL_CONST(0.696616), + REAL_CONST(0.813004), + REAL_CONST(0.911304), + REAL_CONST(0.984900), + REAL_CONST(1.067894), + REAL_CONST(1.194601), + REAL_CONST(1.369533) }; void lt_prediction(ic_stream *ics, ltp_info *ltp, real_t *spec, - real_t *lt_pred_stat, fb_info *fb, uint8_t win_shape, + int16_t *lt_pred_stat, fb_info *fb, uint8_t win_shape, uint8_t win_shape_prev, uint8_t sr_index, uint8_t object_type, uint16_t frame_len) { uint8_t sfb; uint16_t bin, i, num_samples; - real_t *x_est; - real_t *X_est; + ALIGN real_t x_est[2048]; + ALIGN real_t X_est[2048]; if (ics->window_sequence != EIGHT_SHORT_SEQUENCE) { @@ -59,15 +88,20 @@ void lt_prediction(ic_stream *ics, ltp_info *ltp, real_t *spec, { num_samples = frame_len << 1; - x_est = (real_t*)malloc(num_samples*sizeof(real_t)); - X_est = (real_t*)malloc(num_samples*sizeof(real_t)); - for(i = 0; i < num_samples; i++) { /* The extra lookback M (N/2 for LD, 0 for LTP) is handled in the buffer updating */ + +#if 0 x_est[i] = MUL_R_C(lt_pred_stat[num_samples + i - ltp->lag], codebook[ltp->coef]); +#else + /* lt_pred_stat is a 16 bit int, multiplied with the fixed point real + this gives a real for x_est + */ + x_est[i] = (real_t)lt_pred_stat[num_samples + i - ltp->lag] * codebook[ltp->coef]; +#endif } filter_bank_ltp(fb, ics->window_sequence, win_shape, win_shape_prev, @@ -89,14 +123,49 @@ void lt_prediction(ic_stream *ics, ltp_info *ltp, real_t *spec, } } } - - free(x_est); - free(X_est); } } } -void lt_update_state(real_t *lt_pred_stat, real_t *time, real_t *overlap, +#ifdef FIXED_POINT +INLINE int16_t real_to_int16(real_t sig_in) +{ + if (sig_in >= 0) + { + sig_in += (1 << (REAL_BITS-1)); + if (sig_in >= REAL_CONST(32768)) + return 32767; + } else { + sig_in += -(1 << (REAL_BITS-1)); + if (sig_in <= REAL_CONST(-32768)) + return -32768; + } + + return (sig_in >> REAL_BITS); +} +#else +INLINE int16_t real_to_int16(real_t sig_in) +{ + if (sig_in >= 0) + { +#ifndef HAS_LRINTF + sig_in += 0.5f; +#endif + if (sig_in >= 32768.0f) + return 32767; + } else { +#ifndef HAS_LRINTF + sig_in += -0.5f; +#endif + if (sig_in <= -32768.0f) + return -32768; + } + + return lrintf(sig_in); +} +#endif + +void lt_update_state(int16_t *lt_pred_stat, real_t *time, real_t *overlap, uint16_t frame_len, uint8_t object_type) { uint16_t i; @@ -119,16 +188,16 @@ void lt_update_state(real_t *lt_pred_stat, real_t *time, real_t *overlap, { lt_pred_stat[i] /* extra 512 */ = lt_pred_stat[i + frame_len]; lt_pred_stat[frame_len + i] = lt_pred_stat[i + (frame_len * 2)]; - lt_pred_stat[(frame_len * 2) + i] = time[i]; - lt_pred_stat[(frame_len * 3) + i] = overlap[i]; + lt_pred_stat[(frame_len * 2) + i] = real_to_int16(time[i]); + lt_pred_stat[(frame_len * 3) + i] = real_to_int16(overlap[i]); } } else { #endif for (i = 0; i < frame_len; i++) { lt_pred_stat[i] = lt_pred_stat[i + frame_len]; - lt_pred_stat[frame_len + i] = time[i]; - lt_pred_stat[(frame_len * 2) + i] = overlap[i]; + lt_pred_stat[frame_len + i] = real_to_int16(time[i]); + lt_pred_stat[(frame_len * 2) + i] = real_to_int16(overlap[i]); #if 0 /* set to zero once upon initialisation */ lt_pred_stat[(frame_len * 3) + i] = 0; #endif diff --git a/src/libfaad/lt_predict.h b/src/libfaad/lt_predict.h index f9b06ab51..7900605e8 100644 --- a/src/libfaad/lt_predict.h +++ b/src/libfaad/lt_predict.h @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: lt_predict.h,v 1.2 2002/12/16 19:00:37 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: lt_predict.h,v 1.3 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #ifdef LTP_DEC @@ -30,10 +36,12 @@ extern "C" { #include "filtbank.h" +uint8_t is_ltp_ot(uint8_t object_type); + void lt_prediction(ic_stream *ics, ltp_info *ltp, real_t *spec, - real_t *lt_pred_stat, + int16_t *lt_pred_stat, fb_info *fb, uint8_t win_shape, uint8_t win_shape_prev, @@ -41,12 +49,15 @@ void lt_prediction(ic_stream *ics, uint8_t object_type, uint16_t frame_len); -void lt_update_state(real_t *lt_pred_stat, +void lt_update_state(int16_t *lt_pred_stat, real_t *time, real_t *overlap, uint16_t frame_len, uint8_t object_type); + +static int16_t real_to_int16(real_t sig_in); + #ifdef __cplusplus } #endif diff --git a/src/libfaad/mdct.c b/src/libfaad/mdct.c index 7c01516be..6c4d3edd7 100644 --- a/src/libfaad/mdct.c +++ b/src/libfaad/mdct.c @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: mdct.c,v 1.6 2003/08/25 21:51:41 f1rmb Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: mdct.c,v 1.7 2003/12/30 02:00:10 miguelfreitas Exp $ **/ /* @@ -58,39 +64,66 @@ #ifdef FIXED_POINT real_t const_tab[][5] = { - { 0x800000, 0xFFFFB10, 0xC90FC, 0xFFFFFF0, 0x1921F }, /* 2048 */ - { 0x8432A5, 0xFFFFA60, 0xD6773, 0xFFFFFF0, 0x1ACEE }, /* 1920 */ - { 0xB504F3, 0xFFFEC40, 0x1921F1, 0xFFFFFB0, 0x3243F }, /* 1024 */ - { 0xBAF4BA, 0xFFFE990, 0x1ACEDD, 0xFFFFFA0, 0x359DD }, /* 960 */ - { 0x16A09E6, 0xFFEC430, 0x648558, 0xFFFFB10, 0xC90FC }, /* 256 */ - { 0x175E974, 0xFFE98B0, 0x6B3885, 0xFFFFA60, 0xD6773 } /* 240 */ -#ifdef SSR_DEC - ,{ 0, 0, 0, 0, 0 }, /* 512 */ - { 0, 0, 0, 0, 0 } /* 64 */ -#endif -}; -#else -#ifdef _MSC_VER -#pragma warning(disable:4305) -#pragma warning(disable:4244) -#endif -real_t const_tab[][5] = -{ - { 0.0312500000, 0.9999952938, 0.0030679568, 0.9999999265, 0.0003834952 }, /* 2048 */ - { 0.0322748612, 0.9999946356, 0.0032724866, 0.9999999404, 0.0004090615 }, /* 1920 */ - { 0.0441941738, 0.9999811649, 0.0061358847, 0.9999997020, 0.0007669903 }, /* 1024 */ - { 0.0456435465, 0.9999786019, 0.0065449383, 0.9999996424, 0.0008181230 }, /* 960 */ - { 0.0883883476, 0.9996988177, 0.0245412290, 0.9999952912, 0.0030679568 }, /* 256 */ - { 0.0912870929, 0.9996573329, 0.0261769500, 0.9999946356, 0.0032724866 } /* 240 */ + { /* 2048 */ + COEF_CONST(1), + FRAC_CONST(0.99999529380957619), + FRAC_CONST(0.0030679567629659761), + FRAC_CONST(0.99999992646571789), + FRAC_CONST(0.00038349518757139556) + }, { /* 1920 */ + COEF_CONST(/* sqrt(1024/960) */ 1.0327955589886444), + FRAC_CONST(0.99999464540169647), + FRAC_CONST(0.0032724865065266251), + FRAC_CONST(0.99999991633432805), + FRAC_CONST(0.00040906153202803459) + }, { /* 1024 */ + COEF_CONST(1), + FRAC_CONST(0.99998117528260111), + FRAC_CONST(0.0061358846491544753), + FRAC_CONST(0.99999970586288223), + FRAC_CONST(0.00076699031874270449) + }, { /* 960 */ + COEF_CONST(/* sqrt(512/480) */ 1.0327955589886444), + FRAC_CONST(0.99997858166412923), + FRAC_CONST(0.0065449379673518581), + FRAC_CONST(0.99999966533732598), + FRAC_CONST(0.00081812299560725323) + }, { /* 256 */ + COEF_CONST(1), + FRAC_CONST(0.99969881869620425), + FRAC_CONST(0.024541228522912288), + FRAC_CONST(0.99999529380957619), + FRAC_CONST(0.0030679567629659761) + }, { /* 240 */ + COEF_CONST(/* sqrt(256/240) */ 1.0327955589886444), + FRAC_CONST(0.99965732497555726), + FRAC_CONST(0.026176948307873149), + FRAC_CONST(0.99999464540169647), + FRAC_CONST(0.0032724865065266251) + } #ifdef SSR_DEC - ,{ 0.062500000, 0.999924702, 0.012271538, 0.999998823, 0.00153398 }, /* 512 */ - { 0.176776695, 0.995184727, 0.09801714, 0.999924702, 0.012271538 } /* 64 */ + ,{ /* 512 */ + COEF_CONST(1), + FRAC_CONST(0.9999247018391445), + FRAC_CONST(0.012271538285719925), + FRAC_CONST(0.99999882345170188), + FRAC_CONST(0.0015339801862847655) + }, { /* 64 */ + COEF_CONST(1), + FRAC_CONST(0.99518472667219693), + FRAC_CONST(0.098017140329560604), + FRAC_CONST(0.9999247018391445), + FRAC_CONST(0.012271538285719925) + } #endif }; #endif -static uint8_t map_N_to_idx(uint16_t N) +uint8_t map_N_to_idx(uint16_t N) { + /* gives an index into const_tab above */ + /* for normal AAC deocding (eg. no scalable profile) only */ + /* index 0 and 4 will be used */ switch(N) { case 2048: return 0; @@ -109,18 +142,21 @@ static uint8_t map_N_to_idx(uint16_t N) mdct_info *faad_mdct_init(uint16_t N) { - uint16_t k, N_idx; + uint16_t k; +#ifdef FIXED_POINT + uint16_t N_idx; real_t cangle, sangle, c, s, cold; +#endif real_t scale; - mdct_info *mdct = (mdct_info*)malloc(sizeof(mdct_info)); + mdct_info *mdct = (mdct_info*)faad_malloc(sizeof(mdct_info)); assert(N % 8 == 0); mdct->N = N; - mdct->sincos = (complex_t*)malloc(N/4*sizeof(complex_t)); - mdct->Z1 = (complex_t*)malloc(N/4*sizeof(complex_t)); + mdct->sincos = (complex_t*)faad_malloc(N/4*sizeof(complex_t)); +#ifdef FIXED_POINT N_idx = map_N_to_idx(N); scale = const_tab[N_idx][0]; @@ -128,20 +164,37 @@ mdct_info *faad_mdct_init(uint16_t N) sangle = const_tab[N_idx][2]; c = const_tab[N_idx][3]; s = const_tab[N_idx][4]; +#else + scale = (real_t)sqrt(2.0 / (real_t)N); +#endif + /* (co)sine table build using recurrence relations */ + /* this can also be done using static table lookup or */ + /* some form of interpolation */ for (k = 0; k < N/4; k++) { - RE(mdct->sincos[k]) = -1*MUL_C_C(c,scale); - IM(mdct->sincos[k]) = -1*MUL_C_C(s,scale); +#ifdef FIXED_POINT + RE(mdct->sincos[k]) = c; //MUL_C_C(c,scale); + IM(mdct->sincos[k]) = s; //MUL_C_C(s,scale); cold = c; - c = MUL_C_C(c,cangle) - MUL_C_C(s,sangle); - s = MUL_C_C(s,cangle) + MUL_C_C(cold,sangle); + c = MUL_F(c,cangle) - MUL_F(s,sangle); + s = MUL_F(s,cangle) + MUL_F(cold,sangle); +#else + /* no recurrence, just sines */ + RE(mdct->sincos[k]) = scale*(real_t)(cos(2.0*M_PI*(k+1./8.) / (real_t)N)); + IM(mdct->sincos[k]) = scale*(real_t)(sin(2.0*M_PI*(k+1./8.) / (real_t)N)); +#endif } /* initialise fft */ mdct->cfft = cffti(N/4); +#ifdef PROFILE + mdct->cycles = 0; + mdct->fft_cycles = 0; +#endif + return mdct; } @@ -149,12 +202,16 @@ void faad_mdct_end(mdct_info *mdct) { if (mdct != NULL) { +#ifdef PROFILE + printf("MDCT[%.4d]: %I64d cycles\n", mdct->N, mdct->cycles); + printf("CFFT[%.4d]: %I64d cycles\n", mdct->N/4, mdct->fft_cycles); +#endif + cfftu(mdct->cfft); - if (mdct->Z1) free(mdct->Z1); - if (mdct->sincos) free(mdct->sincos); + if (mdct->sincos) faad_free(mdct->sincos); - free(mdct); + faad_free(mdct); } } @@ -163,7 +220,7 @@ void faad_imdct(mdct_info *mdct, real_t *X_in, real_t *X_out) uint16_t k; complex_t x; - complex_t *Z1 = mdct->Z1; + ALIGN complex_t Z1[512]; complex_t *sincos = mdct->sincos; uint16_t N = mdct->N; @@ -171,44 +228,231 @@ void faad_imdct(mdct_info *mdct, real_t *X_in, real_t *X_out) uint16_t N4 = N >> 2; uint16_t N8 = N >> 3; +#ifdef PROFILE + int64_t count1, count2 = faad_get_ts(); +#endif + /* pre-IFFT complex multiplication */ for (k = 0; k < N4; k++) { - uint16_t n = k << 1; - RE(x) = X_in[ n]; - IM(x) = X_in[N2 - 1 - n]; - RE(Z1[k]) = MUL_R_C(IM(x), RE(sincos[k])) - MUL_R_C(RE(x), IM(sincos[k])); - IM(Z1[k]) = MUL_R_C(RE(x), RE(sincos[k])) + MUL_R_C(IM(x), IM(sincos[k])); + ComplexMult(&IM(Z1[k]), &RE(Z1[k]), + X_in[2*k], X_in[N2 - 1 - 2*k], RE(sincos[k]), IM(sincos[k])); } - /* complex IFFT */ +#ifdef PROFILE + count1 = faad_get_ts(); +#endif + + /* complex IFFT, any non-scaling FFT can be used here */ cfftb(mdct->cfft, Z1); +#ifdef PROFILE + count1 = faad_get_ts() - count1; +#endif + /* post-IFFT complex multiplication */ for (k = 0; k < N4; k++) { - uint16_t n = k << 1; RE(x) = RE(Z1[k]); IM(x) = IM(Z1[k]); + ComplexMult(&IM(Z1[k]), &RE(Z1[k]), + IM(x), RE(x), RE(sincos[k]), IM(sincos[k])); + } + + /* reordering */ + for (k = 0; k < N8; k+=2) + { + X_out[ 2*k] = IM(Z1[N8 + k]); + X_out[ 2 + 2*k] = IM(Z1[N8 + 1 + k]); + + X_out[ 1 + 2*k] = -RE(Z1[N8 - 1 - k]); + X_out[ 3 + 2*k] = -RE(Z1[N8 - 2 - k]); + + X_out[N4 + 2*k] = RE(Z1[ k]); + X_out[N4 + + 2 + 2*k] = RE(Z1[ 1 + k]); + + X_out[N4 + 1 + 2*k] = -IM(Z1[N4 - 1 - k]); + X_out[N4 + 3 + 2*k] = -IM(Z1[N4 - 2 - k]); + + X_out[N2 + 2*k] = RE(Z1[N8 + k]); + X_out[N2 + + 2 + 2*k] = RE(Z1[N8 + 1 + k]); - RE(Z1[k]) = MUL_R_C(RE(x), RE(sincos[k])) - MUL_R_C(IM(x), IM(sincos[k])); - IM(Z1[k]) = MUL_R_C(IM(x), RE(sincos[k])) + MUL_R_C(RE(x), IM(sincos[k])); + X_out[N2 + 1 + 2*k] = -IM(Z1[N8 - 1 - k]); + X_out[N2 + 3 + 2*k] = -IM(Z1[N8 - 2 - k]); + + X_out[N2 + N4 + 2*k] = -IM(Z1[ k]); + X_out[N2 + N4 + 2 + 2*k] = -IM(Z1[ 1 + k]); + + X_out[N2 + N4 + 1 + 2*k] = RE(Z1[N4 - 1 - k]); + X_out[N2 + N4 + 3 + 2*k] = RE(Z1[N4 - 2 - k]); + } + +#ifdef PROFILE + count2 = faad_get_ts() - count2; + mdct->fft_cycles += count1; + mdct->cycles += (count2 - count1); +#endif +} + +#ifdef USE_SSE +void faad_imdct_sse(mdct_info *mdct, real_t *X_in, real_t *X_out) +{ + uint16_t k; + + ALIGN complex_t Z1[512]; + complex_t *sincos = mdct->sincos; + + uint16_t N = mdct->N; + uint16_t N2 = N >> 1; + uint16_t N4 = N >> 2; + uint16_t N8 = N >> 3; + +#ifdef PROFILE + int64_t count1, count2 = faad_get_ts(); +#endif + + /* pre-IFFT complex multiplication */ + for (k = 0; k < N4; k+=4) + { + __m128 m12, m13, m14, m0, m1, m2, m3, m4, m5, m6, m7, m8, m9, m10, m11; + __m128 n12, n13, n14, n0, n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11; + n12 = _mm_load_ps(&X_in[N2 - 2*k - 8]); + m12 = _mm_load_ps(&X_in[N2 - 2*k - 4]); + m13 = _mm_load_ps(&X_in[2*k]); + n13 = _mm_load_ps(&X_in[2*k + 4]); + m1 = _mm_load_ps(&RE(sincos[k])); + n1 = _mm_load_ps(&RE(sincos[k+2])); + + m0 = _mm_shuffle_ps(m12, m13, _MM_SHUFFLE(2,0,1,3)); + m2 = _mm_shuffle_ps(m1, m1, _MM_SHUFFLE(2,3,0,1)); + m14 = _mm_shuffle_ps(m0, m0, _MM_SHUFFLE(3,1,2,0)); + n0 = _mm_shuffle_ps(n12, n13, _MM_SHUFFLE(2,0,1,3)); + n2 = _mm_shuffle_ps(n1, n1, _MM_SHUFFLE(2,3,0,1)); + n14 = _mm_shuffle_ps(n0, n0, _MM_SHUFFLE(3,1,2,0)); + + m3 = _mm_mul_ps(m14, m1); + n3 = _mm_mul_ps(n14, n1); + m4 = _mm_mul_ps(m14, m2); + n4 = _mm_mul_ps(n14, n2); + + m5 = _mm_shuffle_ps(m3, m4, _MM_SHUFFLE(2,0,2,0)); + n5 = _mm_shuffle_ps(n3, n4, _MM_SHUFFLE(2,0,2,0)); + m6 = _mm_shuffle_ps(m3, m4, _MM_SHUFFLE(3,1,3,1)); + n6 = _mm_shuffle_ps(n3, n4, _MM_SHUFFLE(3,1,3,1)); + + m7 = _mm_add_ps(m5, m6); + n7 = _mm_add_ps(n5, n6); + m8 = _mm_sub_ps(m5, m6); + n8 = _mm_sub_ps(n5, n6); + + m9 = _mm_shuffle_ps(m7, m7, _MM_SHUFFLE(3,2,3,2)); + n9 = _mm_shuffle_ps(n7, n7, _MM_SHUFFLE(3,2,3,2)); + m10 = _mm_shuffle_ps(m8, m8, _MM_SHUFFLE(1,0,1,0)); + n10 = _mm_shuffle_ps(n8, n8, _MM_SHUFFLE(1,0,1,0)); + + m11 = _mm_unpacklo_ps(m10, m9); + n11 = _mm_unpacklo_ps(n10, n9); + + _mm_store_ps(&RE(Z1[k]), m11); + _mm_store_ps(&RE(Z1[k+2]), n11); + } + +#ifdef PROFILE + count1 = faad_get_ts(); +#endif + + /* complex IFFT, any non-scaling FFT can be used here */ + cfftb_sse(mdct->cfft, Z1); + +#ifdef PROFILE + count1 = faad_get_ts() - count1; +#endif + + /* post-IFFT complex multiplication */ + for (k = 0; k < N4; k+=4) + { + __m128 m0, m1, m2, m3, m4, m5, m6, m7, m8, m9, m10, m11; + __m128 n0, n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11; + m0 = _mm_load_ps(&RE(Z1[k])); + n0 = _mm_load_ps(&RE(Z1[k+2])); + m1 = _mm_load_ps(&RE(sincos[k])); + n1 = _mm_load_ps(&RE(sincos[k+2])); + + m2 = _mm_shuffle_ps(m1, m1, _MM_SHUFFLE(2,3,0,1)); + n2 = _mm_shuffle_ps(n1, n1, _MM_SHUFFLE(2,3,0,1)); + + m3 = _mm_mul_ps(m0, m1); + n3 = _mm_mul_ps(n0, n1); + m4 = _mm_mul_ps(m0, m2); + n4 = _mm_mul_ps(n0, n2); + + m5 = _mm_shuffle_ps(m3, m4, _MM_SHUFFLE(2,0,2,0)); + n5 = _mm_shuffle_ps(n3, n4, _MM_SHUFFLE(2,0,2,0)); + m6 = _mm_shuffle_ps(m3, m4, _MM_SHUFFLE(3,1,3,1)); + n6 = _mm_shuffle_ps(n3, n4, _MM_SHUFFLE(3,1,3,1)); + + m7 = _mm_add_ps(m5, m6); + n7 = _mm_add_ps(n5, n6); + m8 = _mm_sub_ps(m5, m6); + n8 = _mm_sub_ps(n5, n6); + + m9 = _mm_shuffle_ps(m7, m7, _MM_SHUFFLE(3,2,3,2)); + n9 = _mm_shuffle_ps(n7, n7, _MM_SHUFFLE(3,2,3,2)); + m10 = _mm_shuffle_ps(m8, m8, _MM_SHUFFLE(1,0,1,0)); + n10 = _mm_shuffle_ps(n8, n8, _MM_SHUFFLE(1,0,1,0)); + + m11 = _mm_unpacklo_ps(m10, m9); + n11 = _mm_unpacklo_ps(n10, n9); + + _mm_store_ps(&RE(Z1[k]), m11); + _mm_store_ps(&RE(Z1[k+2]), n11); } /* reordering */ - for (k = 0; k < N8; k++) + for (k = 0; k < N8; k+=2) { - uint16_t n = k << 1; - X_out[ n] = IM(Z1[N8 + k]); - X_out[ 1 + n] = -RE(Z1[N8 - 1 - k]); - X_out[N4 + n] = RE(Z1[ k]); - X_out[N4 + 1 + n] = -IM(Z1[N4 - 1 - k]); - X_out[N2 + n] = RE(Z1[N8 + k]); - X_out[N2 + 1 + n] = -IM(Z1[N8 - 1 - k]); - X_out[N2 + N4 + n] = -IM(Z1[ k]); - X_out[N2 + N4 + 1 + n] = RE(Z1[N4 - 1 - k]); + __m128 m0, m1, m2, m3, m4, m5, m6, m7, m8, m9, m10, m11, m13; + __m128 n4, n5, n6, n7, n8, n9; + __m128 neg1 = _mm_set_ps(-1.0, 1.0, -1.0, 1.0); + __m128 neg2 = _mm_set_ps(-1.0, -1.0, -1.0, -1.0); + + m0 = _mm_load_ps(&RE(Z1[k])); + m1 = _mm_load_ps(&RE(Z1[N8 - 2 - k])); + m2 = _mm_load_ps(&RE(Z1[N8 + k])); + m3 = _mm_load_ps(&RE(Z1[N4 - 2 - k])); + + m10 = _mm_mul_ps(m0, neg1); + m11 = _mm_mul_ps(m1, neg2); + m13 = _mm_mul_ps(m3, neg1); + + m5 = _mm_shuffle_ps(m2, m2, _MM_SHUFFLE(3,1,2,0)); + n4 = _mm_shuffle_ps(m10, m10, _MM_SHUFFLE(3,1,2,0)); + m4 = _mm_shuffle_ps(m11, m11, _MM_SHUFFLE(3,1,2,0)); + n5 = _mm_shuffle_ps(m13, m13, _MM_SHUFFLE(3,1,2,0)); + + m6 = _mm_shuffle_ps(m4, m5, _MM_SHUFFLE(3,2,1,0)); + n6 = _mm_shuffle_ps(n4, n5, _MM_SHUFFLE(3,2,1,0)); + m7 = _mm_shuffle_ps(m5, m4, _MM_SHUFFLE(3,2,1,0)); + n7 = _mm_shuffle_ps(n5, n4, _MM_SHUFFLE(3,2,1,0)); + + m8 = _mm_shuffle_ps(m6, m6, _MM_SHUFFLE(0,3,1,2)); + n8 = _mm_shuffle_ps(n6, n6, _MM_SHUFFLE(2,1,3,0)); + m9 = _mm_shuffle_ps(m7, m7, _MM_SHUFFLE(2,1,3,0)); + n9 = _mm_shuffle_ps(n7, n7, _MM_SHUFFLE(0,3,1,2)); + + _mm_store_ps(&X_out[2*k], m8); + _mm_store_ps(&X_out[N4 + 2*k], n8); + _mm_store_ps(&X_out[N2 + 2*k], m9); + _mm_store_ps(&X_out[N2 + N4 + 2*k], n9); } + +#ifdef PROFILE + count2 = faad_get_ts() - count2; + mdct->fft_cycles += count1; + mdct->cycles += (count2 - count1); +#endif } +#endif #ifdef LTP_DEC void faad_mdct(mdct_info *mdct, real_t *X_in, real_t *X_out) @@ -216,7 +460,7 @@ void faad_mdct(mdct_info *mdct, real_t *X_in, real_t *X_out) uint16_t k; complex_t x; - complex_t *Z1 = mdct->Z1; + ALIGN complex_t Z1[512]; complex_t *sincos = mdct->sincos; uint16_t N = mdct->N; @@ -224,7 +468,11 @@ void faad_mdct(mdct_info *mdct, real_t *X_in, real_t *X_out) uint16_t N4 = N >> 2; uint16_t N8 = N >> 3; +#ifndef FIXED_POINT real_t scale = REAL_CONST(N); +#else + real_t scale = REAL_CONST(4.0/N); +#endif /* pre-FFT complex multiplication */ for (k = 0; k < N8; k++) @@ -233,30 +481,36 @@ void faad_mdct(mdct_info *mdct, real_t *X_in, real_t *X_out) RE(x) = X_in[N - N4 - 1 - n] + X_in[N - N4 + n]; IM(x) = X_in[ N4 + n] - X_in[ N4 - 1 - n]; - RE(Z1[k]) = -MUL_R_C(RE(x), RE(sincos[k])) - MUL_R_C(IM(x), IM(sincos[k])); - IM(Z1[k]) = -MUL_R_C(IM(x), RE(sincos[k])) + MUL_R_C(RE(x), IM(sincos[k])); + ComplexMult(&RE(Z1[k]), &IM(Z1[k]), + RE(x), IM(x), RE(sincos[k]), IM(sincos[k])); + + RE(Z1[k]) = MUL_R(RE(Z1[k]), scale); + IM(Z1[k]) = MUL_R(IM(Z1[k]), scale); RE(x) = X_in[N2 - 1 - n] - X_in[ n]; IM(x) = X_in[N2 + n] + X_in[N - 1 - n]; - RE(Z1[k + N8]) = -MUL_R_C(RE(x), RE(sincos[k + N8])) - MUL_R_C(IM(x), IM(sincos[k + N8])); - IM(Z1[k + N8]) = -MUL_R_C(IM(x), RE(sincos[k + N8])) + MUL_R_C(RE(x), IM(sincos[k + N8])); + ComplexMult(&RE(Z1[k + N8]), &IM(Z1[k + N8]), + RE(x), IM(x), RE(sincos[k + N8]), IM(sincos[k + N8])); + + RE(Z1[k + N8]) = MUL_R(RE(Z1[k + N8]), scale); + IM(Z1[k + N8]) = MUL_R(IM(Z1[k + N8]), scale); } - /* complex FFT */ + /* complex FFT, any non-scaling FFT can be used here */ cfftf(mdct->cfft, Z1); /* post-FFT complex multiplication */ for (k = 0; k < N4; k++) { uint16_t n = k << 1; - RE(x) = MUL(MUL_R_C(RE(Z1[k]), RE(sincos[k])) + MUL_R_C(IM(Z1[k]), IM(sincos[k])), scale); - IM(x) = MUL(MUL_R_C(IM(Z1[k]), RE(sincos[k])) - MUL_R_C(RE(Z1[k]), IM(sincos[k])), scale); + ComplexMult(&RE(x), &IM(x), + RE(Z1[k]), IM(Z1[k]), RE(sincos[k]), IM(sincos[k])); - X_out[ n] = RE(x); - X_out[N2 - 1 - n] = -IM(x); - X_out[N2 + n] = IM(x); - X_out[N - 1 - n] = -RE(x); + X_out[ n] = -RE(x); + X_out[N2 - 1 - n] = IM(x); + X_out[N2 + n] = -IM(x); + X_out[N - 1 - n] = RE(x); } } #endif diff --git a/src/libfaad/mdct.h b/src/libfaad/mdct.h index e06d1e5db..4aa2cdd25 100644 --- a/src/libfaad/mdct.h +++ b/src/libfaad/mdct.h @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: mdct.h,v 1.3 2002/12/16 19:00:40 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: mdct.h,v 1.4 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #ifndef __MDCT_H__ @@ -26,11 +32,13 @@ extern "C" { #endif -#include "cfft.h" mdct_info *faad_mdct_init(uint16_t N); void faad_mdct_end(mdct_info *mdct); void faad_imdct(mdct_info *mdct, real_t *X_in, real_t *X_out); +#ifdef USE_SSE +void faad_imdct_sse(mdct_info *mdct, real_t *X_in, real_t *X_out); +#endif void faad_mdct(mdct_info *mdct, real_t *X_in, real_t *X_out); diff --git a/src/libfaad/mp4.c b/src/libfaad/mp4.c index 1dfeb82f6..b09495fb3 100644 --- a/src/libfaad/mp4.c +++ b/src/libfaad/mp4.c @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: mp4.c,v 1.4 2003/04/12 14:58:47 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: mp4.c,v 1.5 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #include "common.h" @@ -26,7 +32,6 @@ #include "bits.h" #include "mp4.h" -#include "data.h" #include "syntax.h" /* defines if an object type can be decoded by this library or not */ @@ -48,8 +53,16 @@ static uint8_t ObjectTypesTable[32] = { #else 0, /* 4 AAC LTP */ #endif - 0, /* 5 Reserved */ +#ifdef SBR_DEC + 1, /* 5 SBR */ +#else + 0, /* 5 SBR */ +#endif +#ifdef SCALABLE_DEC + 1, /* 6 AAC Scalable */ +#else 0, /* 6 AAC Scalable */ +#endif 0, /* 7 TwinVQ */ 0, /* 8 CELP */ 0, /* 9 HVXC */ @@ -70,7 +83,11 @@ static uint8_t ObjectTypesTable[32] = { #else 0, /* 19 ER AAC LTP */ #endif +#ifdef SCALABLE_DEC + 1, /* 20 ER AAC scalable */ +#else 0, /* 20 ER AAC scalable */ +#endif 0, /* 21 ER TwinVQ */ 0, /* 22 ER BSAC */ #ifdef LD_DEC @@ -106,8 +123,19 @@ int8_t FAADAPI AudioSpecificConfig(uint8_t *pBuffer, uint32_t buffer_size, mp4AudioSpecificConfig *mp4ASC) { + return AudioSpecificConfig2(pBuffer, buffer_size, mp4ASC, NULL); +} + +int8_t FAADAPI AudioSpecificConfig2(uint8_t *pBuffer, + uint32_t buffer_size, + mp4AudioSpecificConfig *mp4ASC, + program_config *pce) +{ bitfile ld; int8_t result = 0; +#ifdef SBR_DEC + int8_t bits_to_decode = 0; +#endif if (pBuffer == NULL) return -7; @@ -128,7 +156,7 @@ int8_t FAADAPI AudioSpecificConfig(uint8_t *pBuffer, mp4ASC->channelsConfiguration = (uint8_t)faad_getbits(&ld, 4 DEBUGVAR(1,3,"parse_audio_decoder_specific_info(): ChannelsConfiguration")); - mp4ASC->samplingFrequency = sample_rates[mp4ASC->samplingFrequencyIndex]; + mp4ASC->samplingFrequency = get_sample_rate(mp4ASC->samplingFrequencyIndex); if (ObjectTypesTable[mp4ASC->objectTypeIndex] != 1) { @@ -148,16 +176,35 @@ int8_t FAADAPI AudioSpecificConfig(uint8_t *pBuffer, return -3; } +#ifdef SBR_DEC + mp4ASC->sbr_present_flag = -1; + if (mp4ASC->objectTypeIndex == 5) + { + mp4ASC->sbr_present_flag = 1; + mp4ASC->samplingFrequencyIndex = (uint8_t)faad_getbits(&ld, 4 + DEBUGVAR(1,5,"parse_audio_decoder_specific_info(): extensionSamplingFrequencyIndex")); + if (mp4ASC->samplingFrequencyIndex == 15) + { + mp4ASC->samplingFrequency = (uint32_t)faad_getbits(&ld, 24 + DEBUGVAR(1,6,"parse_audio_decoder_specific_info(): extensionSamplingFrequencyIndex")); + } else { + mp4ASC->samplingFrequency = get_sample_rate(mp4ASC->samplingFrequencyIndex); + } + mp4ASC->objectTypeIndex = (uint8_t)faad_getbits(&ld, 5 + DEBUGVAR(1,7,"parse_audio_decoder_specific_info(): ObjectTypeIndex")); + } +#endif + /* get GASpecificConfig */ if (mp4ASC->objectTypeIndex == 1 || mp4ASC->objectTypeIndex == 2 || mp4ASC->objectTypeIndex == 3 || mp4ASC->objectTypeIndex == 4 || mp4ASC->objectTypeIndex == 6 || mp4ASC->objectTypeIndex == 7) { - result = GASpecificConfig(&ld, mp4ASC); + result = GASpecificConfig(&ld, mp4ASC, pce); #ifdef ERROR_RESILIENCE } else if (mp4ASC->objectTypeIndex >= ER_OBJECT_START) { /* ER */ - result = GASpecificConfig(&ld, mp4ASC); + result = GASpecificConfig(&ld, mp4ASC, pce); mp4ASC->epConfig = (uint8_t)faad_getbits(&ld, 2 DEBUGVAR(1,143,"parse_audio_decoder_specific_info(): epConfig")); @@ -175,6 +222,53 @@ int8_t FAADAPI AudioSpecificConfig(uint8_t *pBuffer, return -6; #endif + +#ifdef SBR_DEC + bits_to_decode = (int8_t)(buffer_size*8 - faad_get_processed_bits(&ld)); + + if ((mp4ASC->objectTypeIndex != 5) && (bits_to_decode >= 16)) + { + int16_t syncExtensionType = (int16_t)faad_getbits(&ld, 11 + DEBUGVAR(1,9,"parse_audio_decoder_specific_info(): syncExtensionType")); + + if (syncExtensionType == 0x2b7) + { + mp4ASC->objectTypeIndex = (uint8_t)faad_getbits(&ld, 5 + DEBUGVAR(1,10,"parse_audio_decoder_specific_info(): extensionAudioObjectType")); + + if (mp4ASC->objectTypeIndex == 5) + { + mp4ASC->sbr_present_flag = (uint8_t)faad_get1bit(&ld + DEBUGVAR(1,11,"parse_audio_decoder_specific_info(): sbr_present_flag")); + + if (mp4ASC->sbr_present_flag) + { + mp4ASC->samplingFrequencyIndex = (uint8_t)faad_getbits(&ld, 4 + DEBUGVAR(1,12,"parse_audio_decoder_specific_info(): extensionSamplingFrequencyIndex")); + if (mp4ASC->samplingFrequencyIndex == 15) + { + mp4ASC->samplingFrequency = (uint32_t)faad_getbits(&ld, 24 + DEBUGVAR(1,13,"parse_audio_decoder_specific_info(): extensionSamplingFrequencyIndex")); + } else { + mp4ASC->samplingFrequency = get_sample_rate(mp4ASC->samplingFrequencyIndex); + } + } + } + } + } + + /* no SBR signalled, this could mean either implicit signalling or no SBR in this file */ + /* MPEG specification states: assume SBR on files with samplerate <= 24000 Hz */ + if (mp4ASC->sbr_present_flag == -1) + { + if (mp4ASC->samplingFrequency <= 24000) + { + mp4ASC->samplingFrequency *= 2; + mp4ASC->forceUpSampling = 1; + } + } +#endif + faad_endbits(&ld); return result; diff --git a/src/libfaad/mp4.h b/src/libfaad/mp4.h index e3885dd1b..7ec94d81e 100644 --- a/src/libfaad/mp4.h +++ b/src/libfaad/mp4.h @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: mp4.h,v 1.3 2003/04/12 14:58:47 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: mp4.h,v 1.4 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #ifndef __MP4_H__ @@ -32,6 +38,11 @@ int8_t FAADAPI AudioSpecificConfig(uint8_t *pBuffer, uint32_t buffer_size, mp4AudioSpecificConfig *mp4ASC); +int8_t FAADAPI AudioSpecificConfig2(uint8_t *pBuffer, + uint32_t buffer_size, + mp4AudioSpecificConfig *mp4ASC, + program_config *pce); + #ifdef __cplusplus } #endif diff --git a/src/libfaad/ms.c b/src/libfaad/ms.c index cb4a64020..22d4de134 100644 --- a/src/libfaad/ms.c +++ b/src/libfaad/ms.c @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: ms.c,v 1.2 2002/12/16 19:00:47 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: ms.c,v 1.3 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #include "common.h" diff --git a/src/libfaad/ms.h b/src/libfaad/ms.h index 4acb4685f..5ece4efaf 100644 --- a/src/libfaad/ms.h +++ b/src/libfaad/ms.h @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: ms.h,v 1.2 2002/12/16 19:00:48 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: ms.h,v 1.3 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #ifndef __MS_H__ diff --git a/src/libfaad/output.c b/src/libfaad/output.c index ee68e1960..2af34a1d0 100644 --- a/src/libfaad/output.c +++ b/src/libfaad/output.c @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: output.c,v 1.3 2003/04/12 14:58:47 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: output.c,v 1.4 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #include "common.h" @@ -27,193 +33,417 @@ #ifndef FIXED_POINT -#include "dither.h" +#define FLOAT_SCALE (1.0f/(1<<15)) -#define ftol(A,B) {tmp = *(int32_t*) & A - 0x4B7F8000; \ - B = (int16_t)((tmp==(int16_t)tmp) ? tmp : (tmp>>31)^0x7FFF);} +#define DM_MUL REAL_CONST(0.4142135623730950488) // 1/(1+sqrt(2)) +#define RSQRT2 REAL_CONST(0.7071067811865475244) // 1/sqrt(2) -#define ROUND(x) ((x >= 0) ? (int32_t)floor((x) + 0.5) : (int32_t)ceil((x) + 0.5)) -#define ROUND32(x) ROUND(x) +static INLINE real_t get_sample(real_t **input, uint8_t channel, uint16_t sample, + uint8_t down_matrix, uint8_t *internal_channel) +{ + if (!down_matrix) + return input[internal_channel[channel]][sample]; -#define ROUND64(x) (doubletmp = (x) + Dither.Add + (int64_t)0x001FFFFD80000000L, *(int64_t*)(&doubletmp) - (int64_t)0x433FFFFD80000000L) + if (channel == 0) + { + return DM_MUL * (input[internal_channel[1]][sample] + + input[internal_channel[0]][sample] * RSQRT2 + + input[internal_channel[3]][sample] * RSQRT2); + } else { + return DM_MUL * (input[internal_channel[2]][sample] + + input[internal_channel[0]][sample] * RSQRT2 + + input[internal_channel[4]][sample] * RSQRT2); + } +} -#define FLOAT_SCALE (1.0f/(1<<15)) +#ifndef HAS_LRINTF +#define CLIP(sample, max, min) \ +if (sample >= 0.0f) \ +{ \ + sample += 0.5f; \ + if (sample >= max) \ + sample = max; \ +} else { \ + sample += -0.5f; \ + if (sample <= min) \ + sample = min; \ +} +#else +#define CLIP(sample, max, min) \ +if (sample >= 0.0f) \ +{ \ + if (sample >= max) \ + sample = max; \ +} else { \ + if (sample <= min) \ + sample = min; \ +} +#endif -dither_t Dither; -double doubletmp; +#define CONV(a,b) ((a<<1)|(b&0x1)) -void* output_to_PCM(real_t **input, void *sample_buffer, uint8_t channels, - uint16_t frame_len, uint8_t format) +static void to_PCM_16bit(faacDecHandle hDecoder, real_t **input, + uint8_t channels, uint16_t frame_len, + int16_t **sample_buffer) { - uint8_t ch; - uint16_t i, j = 0; - - int16_t *short_sample_buffer = (int16_t*)sample_buffer; - int32_t *int_sample_buffer = (int32_t*)sample_buffer; - float32_t *float_sample_buffer = (float32_t*)sample_buffer; - double *double_sample_buffer = (double*)sample_buffer; + uint8_t ch, ch1; + uint16_t i; - /* Copy output to a standard PCM buffer */ - switch (format) + switch (CONV(channels,hDecoder->downMatrix)) { - case FAAD_FMT_16BIT: + case CONV(1,0): + case CONV(1,1): + for(i = 0; i < frame_len; i++) + { + real_t inp = input[hDecoder->internal_channel[0]][i]; + + CLIP(inp, 32767.0f, -32768.0f); + + (*sample_buffer)[i] = (int16_t)lrintf(inp); + } + break; + case CONV(2,0): + ch = hDecoder->internal_channel[0]; + ch1 = hDecoder->internal_channel[1]; + for(i = 0; i < frame_len; i++) + { + real_t inp0 = input[ch ][i]; + real_t inp1 = input[ch1][i]; + + CLIP(inp0, 32767.0f, -32768.0f); + CLIP(inp1, 32767.0f, -32768.0f); + + (*sample_buffer)[(i*2)+0] = (int16_t)lrintf(inp0); + (*sample_buffer)[(i*2)+1] = (int16_t)lrintf(inp1); + } + break; + default: for (ch = 0; ch < channels; ch++) { for(i = 0; i < frame_len; i++) { - int32_t tmp; - real_t ftemp; + real_t inp = get_sample(input, ch, i, hDecoder->downMatrix, hDecoder->internal_channel); + + CLIP(inp, 32767.0f, -32768.0f); - ftemp = input[ch][i] + 0xff8000; - ftol(ftemp, short_sample_buffer[(i*channels)+ch]); + (*sample_buffer)[(i*channels)+ch] = (int16_t)lrintf(inp); } } break; - case FAAD_FMT_16BIT_DITHER: - for (ch = 0; ch < channels; ch++) + } +} + +static void to_PCM_24bit(faacDecHandle hDecoder, real_t **input, + uint8_t channels, uint16_t frame_len, + int32_t **sample_buffer) +{ + uint8_t ch, ch1; + uint16_t i; + + switch (CONV(channels,hDecoder->downMatrix)) + { + case CONV(1,0): + case CONV(1,1): + for(i = 0; i < frame_len; i++) { - for(i = 0; i < frame_len; i++, j++) - { - double Sum = input[ch][i] * 65535.f; - int64_t val; - if(j > 31) - j = 0; - val = dither_output(1, 0, j, Sum, ch) / 65536; - if (val > (1<<15)-1) - val = (1<<15)-1; - else if (val < -(1<<15)) - val = -(1<<15); - short_sample_buffer[(i*channels)+ch] = (int16_t)val; - } + real_t inp = input[hDecoder->internal_channel[0]][i]; + + inp *= 256.0f; + CLIP(inp, 8388607.0f, -8388608.0f); + + (*sample_buffer)[i] = (int32_t)lrintf(inp); } break; - case FAAD_FMT_16BIT_L_SHAPE: - case FAAD_FMT_16BIT_M_SHAPE: - case FAAD_FMT_16BIT_H_SHAPE: - for (ch = 0; ch < channels; ch++) + case CONV(2,0): + ch = hDecoder->internal_channel[0]; + ch1 = hDecoder->internal_channel[1]; + for(i = 0; i < frame_len; i++) { - for(i = 0; i < frame_len; i++, j++) - { - double Sum = input[ch][i] * 65535.f; - int64_t val; - if(j > 31) - j = 0; - val = dither_output(1, 1, j, Sum, ch) / 65536; - if (val > (1<<15)-1) - val = (1<<15)-1; - else if (val < -(1<<15)) - val = -(1<<15); - short_sample_buffer[(i*channels)+ch] = (int16_t)val; - } + real_t inp0 = input[ch ][i]; + real_t inp1 = input[ch1][i]; + + inp0 *= 256.0f; + inp1 *= 256.0f; + CLIP(inp0, 8388607.0f, -8388608.0f); + CLIP(inp1, 8388607.0f, -8388608.0f); + + (*sample_buffer)[(i*2)+0] = (int32_t)lrintf(inp0); + (*sample_buffer)[(i*2)+1] = (int32_t)lrintf(inp1); } break; - case FAAD_FMT_24BIT: + default: for (ch = 0; ch < channels; ch++) { for(i = 0; i < frame_len; i++) { - if (input[ch][i] > (1<<15)-1) - input[ch][i] = (1<<15)-1; - else if (input[ch][i] < -(1<<15)) - input[ch][i] = -(1<<15); - int_sample_buffer[(i*channels)+ch] = ROUND(input[ch][i]*(1<<8)); + real_t inp = get_sample(input, ch, i, hDecoder->downMatrix, hDecoder->internal_channel); + + inp *= 256.0f; + CLIP(inp, 8388607.0f, -8388608.0f); + + (*sample_buffer)[(i*channels)+ch] = (int32_t)lrintf(inp); } } break; - case FAAD_FMT_32BIT: + } +} + +static void to_PCM_32bit(faacDecHandle hDecoder, real_t **input, + uint8_t channels, uint16_t frame_len, + int32_t **sample_buffer) +{ + uint8_t ch, ch1; + uint16_t i; + + switch (CONV(channels,hDecoder->downMatrix)) + { + case CONV(1,0): + case CONV(1,1): + for(i = 0; i < frame_len; i++) + { + real_t inp = input[hDecoder->internal_channel[0]][i]; + + inp *= 65536.0f; + CLIP(inp, 2147483647.0f, -2147483648.0f); + + (*sample_buffer)[i] = (int32_t)lrintf(inp); + } + break; + case CONV(2,0): + ch = hDecoder->internal_channel[0]; + ch1 = hDecoder->internal_channel[1]; + for(i = 0; i < frame_len; i++) + { + real_t inp0 = input[ch ][i]; + real_t inp1 = input[ch1][i]; + + inp0 *= 65536.0f; + inp1 *= 65536.0f; + CLIP(inp0, 2147483647.0f, -2147483648.0f); + CLIP(inp1, 2147483647.0f, -2147483648.0f); + + (*sample_buffer)[(i*2)+0] = (int32_t)lrintf(inp0); + (*sample_buffer)[(i*2)+1] = (int32_t)lrintf(inp1); + } + break; + default: for (ch = 0; ch < channels; ch++) { for(i = 0; i < frame_len; i++) { - if (input[ch][i] > (1<<15)-1) - input[ch][i] = (1<<15)-1; - else if (input[ch][i] < -(1<<15)) - input[ch][i] = -(1<<15); - int_sample_buffer[(i*channels)+ch] = ROUND32(input[ch][i]*(1<<16)); + real_t inp = get_sample(input, ch, i, hDecoder->downMatrix, hDecoder->internal_channel); + + inp *= 65536.0f; + CLIP(inp, 2147483647.0f, -2147483648.0f); + + (*sample_buffer)[(i*channels)+ch] = (int32_t)lrintf(inp); } } break; - case FAAD_FMT_FLOAT: + } +} + +static void to_PCM_float(faacDecHandle hDecoder, real_t **input, + uint8_t channels, uint16_t frame_len, + float32_t **sample_buffer) +{ + uint8_t ch, ch1; + uint16_t i; + + switch (CONV(channels,hDecoder->downMatrix)) + { + case CONV(1,0): + case CONV(1,1): + for(i = 0; i < frame_len; i++) + { + real_t inp = input[hDecoder->internal_channel[0]][i]; + (*sample_buffer)[i] = inp*FLOAT_SCALE; + } + break; + case CONV(2,0): + ch = hDecoder->internal_channel[0]; + ch1 = hDecoder->internal_channel[1]; + for(i = 0; i < frame_len; i++) + { + real_t inp0 = input[ch ][i]; + real_t inp1 = input[ch1][i]; + (*sample_buffer)[(i*2)+0] = inp0*FLOAT_SCALE; + (*sample_buffer)[(i*2)+1] = inp1*FLOAT_SCALE; + } + break; + default: for (ch = 0; ch < channels; ch++) { for(i = 0; i < frame_len; i++) { - if (input[ch][i] > (1<<15)-1) - input[ch][i] = (1<<15)-1; - else if (input[ch][i] < -(1<<15)) - input[ch][i] = -(1<<15); - float_sample_buffer[(i*channels)+ch] = input[ch][i]*FLOAT_SCALE; + real_t inp = get_sample(input, ch, i, hDecoder->downMatrix, hDecoder->internal_channel); + (*sample_buffer)[(i*channels)+ch] = inp*FLOAT_SCALE; } } break; - case FAAD_FMT_DOUBLE: + } +} + +static void to_PCM_double(faacDecHandle hDecoder, real_t **input, + uint8_t channels, uint16_t frame_len, + double **sample_buffer) +{ + uint8_t ch, ch1; + uint16_t i; + + switch (CONV(channels,hDecoder->downMatrix)) + { + case CONV(1,0): + case CONV(1,1): + for(i = 0; i < frame_len; i++) + { + real_t inp = input[hDecoder->internal_channel[0]][i]; + (*sample_buffer)[i] = (double)inp*FLOAT_SCALE; + } + break; + case CONV(2,0): + ch = hDecoder->internal_channel[0]; + ch1 = hDecoder->internal_channel[1]; + for(i = 0; i < frame_len; i++) + { + real_t inp0 = input[ch ][i]; + real_t inp1 = input[ch1][i]; + (*sample_buffer)[(i*2)+0] = (double)inp0*FLOAT_SCALE; + (*sample_buffer)[(i*2)+1] = (double)inp1*FLOAT_SCALE; + } + break; + default: for (ch = 0; ch < channels; ch++) { for(i = 0; i < frame_len; i++) { - if (input[ch][i] > (1<<15)-1) - input[ch][i] = (1<<15)-1; - else if (input[ch][i] < -(1<<15)) - input[ch][i] = -(1<<15); - double_sample_buffer[(i*channels)+ch] = (double)input[ch][i]*FLOAT_SCALE; + real_t inp = get_sample(input, ch, i, hDecoder->downMatrix, hDecoder->internal_channel); + (*sample_buffer)[(i*channels)+ch] = (double)inp*FLOAT_SCALE; } } break; } - - return sample_buffer; } - -/* Dither output */ -static int64_t dither_output(uint8_t dithering, uint8_t shapingtype, uint16_t i, double Sum, uint8_t k) +void *output_to_PCM(faacDecHandle hDecoder, + real_t **input, void *sample_buffer, uint8_t channels, + uint16_t frame_len, uint8_t format) { - double Sum2; - int64_t val; - if(dithering) + int16_t *short_sample_buffer = (int16_t*)sample_buffer; + int32_t *int_sample_buffer = (int32_t*)sample_buffer; + float32_t *float_sample_buffer = (float32_t*)sample_buffer; + double *double_sample_buffer = (double*)sample_buffer; + +#ifdef PROFILE + int64_t count = faad_get_ts(); +#endif + + /* Copy output to a standard PCM buffer */ + switch (format) { - if(!shapingtype) - { - double tmp = Random_Equi(Dither.Dither); - Sum2 = tmp - Dither.LastRandomNumber[k]; - Dither.LastRandomNumber[k] = tmp; - Sum2 = Sum += Sum2; - val = ROUND64(Sum2)&Dither.Mask; - } else { - Sum2 = Random_Triangular(Dither.Dither) - scalar16(Dither.DitherHistory[k], Dither.FilterCoeff + i); - Sum += Dither.DitherHistory[k][(-1-i)&15] = Sum2; - Sum2 = Sum + scalar16(Dither.ErrorHistory[k], Dither.FilterCoeff + i ); - val = ROUND64(Sum2)&Dither.Mask; - Dither.ErrorHistory[k][(-1-i)&15] = (float)(Sum - val); - } - return val; + case FAAD_FMT_16BIT: + to_PCM_16bit(hDecoder, input, channels, frame_len, &short_sample_buffer); + break; + case FAAD_FMT_24BIT: + to_PCM_24bit(hDecoder, input, channels, frame_len, &int_sample_buffer); + break; + case FAAD_FMT_32BIT: + to_PCM_32bit(hDecoder, input, channels, frame_len, &int_sample_buffer); + break; + case FAAD_FMT_FLOAT: + to_PCM_float(hDecoder, input, channels, frame_len, &float_sample_buffer); + break; + case FAAD_FMT_DOUBLE: + to_PCM_double(hDecoder, input, channels, frame_len, &double_sample_buffer); + break; } - else - return ROUND64 (Sum); + +#ifdef PROFILE + count = faad_get_ts() - count; + hDecoder->output_cycles += count; +#endif + + return sample_buffer; } #else -void* output_to_PCM(real_t **input, void *sample_buffer, uint8_t channels, +void* output_to_PCM(faacDecHandle hDecoder, + real_t **input, void *sample_buffer, uint8_t channels, uint16_t frame_len, uint8_t format) { uint8_t ch; uint16_t i; int16_t *short_sample_buffer = (int16_t*)sample_buffer; + int32_t *int_sample_buffer = (int32_t*)sample_buffer; /* Copy output to a standard PCM buffer */ for (ch = 0; ch < channels; ch++) { - for(i = 0; i < frame_len; i++) + switch (format) { - int32_t tmp = input[ch][i]; - tmp += (1 << (REAL_BITS-1)); - tmp >>= REAL_BITS; - if (tmp > 0x7fff) tmp = 0x7fff; - else if (tmp <= -32768) tmp = -32768; - short_sample_buffer[(i*channels)+ch] = (int16_t)tmp; + case FAAD_FMT_16BIT: + for(i = 0; i < frame_len; i++) + { + int32_t tmp = input[ch][i]; + if (tmp >= 0) + { + tmp += (1 << (REAL_BITS-1)); + if (tmp >= REAL_CONST(32767)) + { + tmp = REAL_CONST(32767); + } + } else { + tmp += -(1 << (REAL_BITS-1)); + if (tmp <= REAL_CONST(-32768)) + { + tmp = REAL_CONST(-32768); + } + } + tmp >>= REAL_BITS; + short_sample_buffer[(i*channels)+ch] = (int16_t)tmp; + } + break; + case FAAD_FMT_24BIT: + for(i = 0; i < frame_len; i++) + { + int32_t tmp = input[ch][i]; + if (tmp >= 0) + { + tmp += (1 << (REAL_BITS-9)); + tmp >>= (REAL_BITS-8); + if (tmp >= 8388607) + { + tmp = 8388607; + } + } else { + tmp += -(1 << (REAL_BITS-9)); + tmp >>= (REAL_BITS-8); + if (tmp <= -8388608) + { + tmp = -8388608; + } + } + int_sample_buffer[(i*channels)+ch] = (int32_t)tmp; + } + break; + case FAAD_FMT_32BIT: + for(i = 0; i < frame_len; i++) + { + int32_t tmp = input[ch][i]; + if (tmp >= 0) + { + tmp += (1 << (16-REAL_BITS-1)); + tmp <<= (16-REAL_BITS); + } else { + tmp += -(1 << (16-REAL_BITS-1)); + tmp <<= (16-REAL_BITS); + } + int_sample_buffer[(i*channels)+ch] = (int32_t)tmp; + } + break; } } diff --git a/src/libfaad/output.h b/src/libfaad/output.h index e46547bbe..967ba5ade 100644 --- a/src/libfaad/output.h +++ b/src/libfaad/output.h @@ -1,22 +1,28 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker -** +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. -** +** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. -** +** ** You should have received a copy of the GNU General Public License -** along with this program; if not, write to the Free Software +** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: output.h,v 1.2 2002/12/16 19:00:51 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: output.h,v 1.3 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #ifndef __OUTPUT_H__ @@ -26,7 +32,8 @@ extern "C" { #endif -void* output_to_PCM(real_t **input, +void* output_to_PCM(faacDecHandle hDecoder, + real_t **input, void *samplebuffer, uint8_t channels, uint16_t frame_len, diff --git a/src/libfaad/pns.c b/src/libfaad/pns.c index e7a0168e4..911b9cdb0 100644 --- a/src/libfaad/pns.c +++ b/src/libfaad/pns.c @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: pns.c,v 1.3 2003/04/12 14:58:47 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: pns.c,v 1.4 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #include "common.h" @@ -27,7 +33,7 @@ #ifdef FIXED_POINT -#define DIV(A, B) (((int64_t)A << COEF_BITS)/B) +#define DIV(A, B) (((int64_t)A << REAL_BITS)/B) #define step(shift) \ if ((0x40000000l >> shift) + root <= value) \ @@ -39,6 +45,7 @@ } /* fixed point square root approximation */ +/* !!!! ONLY WORKS FOR EVEN %REAL_BITS% !!!! */ real_t fp_sqrt(real_t value) { real_t root = 0; @@ -51,7 +58,7 @@ real_t fp_sqrt(real_t value) if (root < value) ++root; - root <<= (COEF_BITS/2); + root <<= (REAL_BITS/2); return root; } @@ -73,13 +80,14 @@ static real_t pow2_table[] = value. A suitable random number generator can be realized using one multiplication/accumulation per random value. */ -static INLINE void gen_rand_vector(real_t *spec, int16_t scale_factor, uint16_t size) +static INLINE void gen_rand_vector(real_t *spec, int16_t scale_factor, uint16_t size, + uint8_t sub) { #ifndef FIXED_POINT uint16_t i; real_t energy = 0.0; - real_t scale = 1.0/(real_t)size * ISQRT_MEAN_NRG; + real_t scale = (real_t)1.0/(real_t)size; for (i = 0; i < size; i++) { @@ -88,7 +96,7 @@ static INLINE void gen_rand_vector(real_t *spec, int16_t scale_factor, uint16_t energy += tmp*tmp; } - scale = 1.0/(real_t)sqrt(energy); + scale = (real_t)1.0/(real_t)sqrt(energy); scale *= (real_t)pow(2.0, 0.25 * scale_factor); for (i = 0; i < size; i++) { @@ -101,36 +109,40 @@ static INLINE void gen_rand_vector(real_t *spec, int16_t scale_factor, uint16_t for (i = 0; i < size; i++) { - real_t tmp = ISQRT_MEAN_NRG * (int32_t)random_int(); - tmp = MUL_C_C(COEF_CONST(1)/size, tmp); + /* this can be replaced by a 16 bit random generator!!!! */ + real_t tmp = (int32_t)random_int(); + if (tmp < 0) + tmp = -(tmp & ((1<<(REAL_BITS-1))-1)); + else + tmp = (tmp & ((1<<(REAL_BITS-1))-1)); - energy += MUL_C_C(tmp,tmp); + energy += MUL_R(tmp,tmp); - /* convert COEF to REAL */ - spec[i] = (tmp >> -(REAL_BITS-COEF_BITS)); + spec[i] = tmp; } energy = fp_sqrt(energy); if (energy > 0) { - scale = DIV(COEF_CONST(1),energy); - - scale >>= -(REAL_BITS-COEF_BITS); + scale = DIV(REAL_CONST(1),energy); exp = scale_factor / 4; frac = scale_factor % 4; + /* IMDCT pre-scaling */ + exp -= sub; + if (exp < 0) scale >>= -exp; else scale <<= exp; if (frac) - scale = MUL_R_C(scale, pow2_table[frac + 3]); + scale = MUL_C(scale, pow2_table[frac + 3]); for (i = 0; i < size; i++) { - spec[i] = MUL(spec[i], scale); + spec[i] = MUL_R(spec[i], scale); } } #endif @@ -138,7 +150,7 @@ static INLINE void gen_rand_vector(real_t *spec, int16_t scale_factor, uint16_t void pns_decode(ic_stream *ics_left, ic_stream *ics_right, real_t *spec_left, real_t *spec_right, uint16_t frame_len, - uint8_t channel_pair) + uint8_t channel_pair, uint8_t object_type) { uint8_t g, sfb, b; uint16_t size, offs; @@ -146,6 +158,21 @@ void pns_decode(ic_stream *ics_left, ic_stream *ics_right, uint8_t group = 0; uint16_t nshort = frame_len >> 3; + uint8_t sub = 0; + +#ifdef FIXED_POINT + /* IMDCT scaling */ + if (object_type == LD) + { + sub = 9 /*9*/; + } else { + if (ics_left->window_sequence == EIGHT_SHORT_SEQUENCE) + sub = 7 /*7*/; + else + sub = 10 /*10*/; + } +#endif + for (g = 0; g < ics_left->num_window_groups; g++) { /* Do perceptual noise substitution decoding */ @@ -173,7 +200,7 @@ void pns_decode(ic_stream *ics_left, ic_stream *ics_right, /* Generate random vector */ gen_rand_vector(&spec_left[(group*nshort)+offs], - ics_left->scale_factors[g][sfb], size); + ics_left->scale_factors[g][sfb], size, sub); } /* From the spec: @@ -217,7 +244,7 @@ void pns_decode(ic_stream *ics_left, ic_stream *ics_right, /* Generate random vector */ gen_rand_vector(&spec_right[(group*nshort)+offs], - ics_right->scale_factors[g][sfb], size); + ics_right->scale_factors[g][sfb], size, sub); } } } diff --git a/src/libfaad/pns.h b/src/libfaad/pns.h index 1e381ec24..32a757ea7 100644 --- a/src/libfaad/pns.h +++ b/src/libfaad/pns.h @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: pns.h,v 1.2 2002/12/16 19:00:57 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: pns.h,v 1.3 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #ifndef __PNS_H__ @@ -31,20 +37,14 @@ extern "C" { #include "syntax.h" #define NOISE_OFFSET 90 -/* #define MEAN_NRG 1.537228e+18 */ /* (2^31)^2 / 3 */ -#ifdef FIXED_POINT -#define ISQRT_MEAN_NRG 0x1DC7 /* sqrt(1/sqrt(MEAN_NRG)) */ -#else -#define ISQRT_MEAN_NRG 8.0655e-10 /* 1/sqrt(MEAN_NRG) */ -#endif - void pns_decode(ic_stream *ics_left, ic_stream *ics_right, real_t *spec_left, real_t *spec_right, uint16_t frame_len, - uint8_t channel_pair); + uint8_t channel_pair, uint8_t object_type); static INLINE int32_t random2(); -static void gen_rand_vector(real_t *spec, int16_t scale_factor, uint16_t size); +static void gen_rand_vector(real_t *spec, int16_t scale_factor, uint16_t size, + uint8_t sub); static INLINE uint8_t is_noise(ic_stream *ics, uint8_t group, uint8_t sfb) { diff --git a/src/libfaad/pulse.c b/src/libfaad/pulse.c index d2a7c6ec2..3c33708eb 100644 --- a/src/libfaad/pulse.c +++ b/src/libfaad/pulse.c @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: pulse.c,v 1.3 2003/04/12 14:58:47 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: pulse.c,v 1.4 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #include "common.h" @@ -25,7 +31,7 @@ #include "syntax.h" #include "pulse.h" -void pulse_decode(ic_stream *ics, int16_t *spec_data, uint16_t framelen) +uint8_t pulse_decode(ic_stream *ics, int16_t *spec_data, uint16_t framelen) { uint8_t i; uint16_t k; @@ -37,11 +43,13 @@ void pulse_decode(ic_stream *ics, int16_t *spec_data, uint16_t framelen) k += pul->pulse_offset[i]; if (k >= framelen) - return; /* should not be possible */ + return 15; /* should not be possible */ if (spec_data[k] > 0) spec_data[k] += pul->pulse_amp[i]; else spec_data[k] -= pul->pulse_amp[i]; } + + return 0; } diff --git a/src/libfaad/pulse.h b/src/libfaad/pulse.h index 4ccd429b1..671a0e9b9 100644 --- a/src/libfaad/pulse.h +++ b/src/libfaad/pulse.h @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: pulse.h,v 1.3 2003/04/12 14:58:47 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: pulse.h,v 1.4 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #ifndef __PULSE_H__ @@ -26,7 +32,7 @@ extern "C" { #endif -void pulse_decode(ic_stream *ics, int16_t *spec_coef, uint16_t framelen); +uint8_t pulse_decode(ic_stream *ics, int16_t *spec_coef, uint16_t framelen); #ifdef __cplusplus } diff --git a/src/libfaad/rvlc.c b/src/libfaad/rvlc.c index 70dcf7c29..59034b6df 100644 --- a/src/libfaad/rvlc.c +++ b/src/libfaad/rvlc.c @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: rvlc.c,v 1.2 2003/04/12 14:58:47 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: rvlc.c,v 1.3 2003/12/30 02:00:10 miguelfreitas Exp $ **/ /* RVLC scalefactor decoding @@ -52,19 +58,19 @@ uint8_t rvlc_scale_factor_data(ic_stream *ics, bitfile *ld) ics->sf_concealment = faad_get1bit(ld DEBUGVAR(1,149,"rvlc_scale_factor_data(): sf_concealment")); - ics->rev_global_gain = faad_getbits(ld, 8 + ics->rev_global_gain = (uint8_t)faad_getbits(ld, 8 DEBUGVAR(1,150,"rvlc_scale_factor_data(): rev_global_gain")); if (ics->window_sequence == EIGHT_SHORT_SEQUENCE) bits = 11; /* the number of bits used for the huffman codewords */ - ics->length_of_rvlc_sf = faad_getbits(ld, bits + ics->length_of_rvlc_sf = (uint16_t)faad_getbits(ld, bits DEBUGVAR(1,151,"rvlc_scale_factor_data(): length_of_rvlc_sf")); if (ics->noise_used) { - ics->dpcm_noise_nrg = faad_getbits(ld, 9 + ics->dpcm_noise_nrg = (uint16_t)faad_getbits(ld, 9 DEBUGVAR(1,152,"rvlc_scale_factor_data(): dpcm_noise_nrg")); ics->length_of_rvlc_sf -= 9; @@ -75,13 +81,13 @@ uint8_t rvlc_scale_factor_data(ic_stream *ics, bitfile *ld) if (ics->sf_escapes_present) { - ics->length_of_rvlc_escapes = faad_getbits(ld, 8 + ics->length_of_rvlc_escapes = (uint8_t)faad_getbits(ld, 8 DEBUGVAR(1,154,"rvlc_scale_factor_data(): length_of_rvlc_escapes")); } if (ics->noise_used) { - ics->dpcm_noise_last_position = faad_getbits(ld, 9 + ics->dpcm_noise_last_position = (uint16_t)faad_getbits(ld, 9 DEBUGVAR(1,155,"rvlc_scale_factor_data(): dpcm_noise_last_position")); } @@ -130,8 +136,8 @@ uint8_t rvlc_decode_scale_factors(ic_stream *ics, bitfile *ld) // &ld_rvlc_esc_rev, intensity_used); - if (rvlc_esc_buffer) free(rvlc_esc_buffer); - if (rvlc_sf_buffer) free(rvlc_sf_buffer); + if (rvlc_esc_buffer) faad_free(rvlc_esc_buffer); + if (rvlc_sf_buffer) faad_free(rvlc_sf_buffer); if (ics->length_of_rvlc_sf > 0) faad_endbits(&ld_rvlc_sf); @@ -198,8 +204,6 @@ static uint8_t rvlc_decode_sf_forward(ic_stream *ics, bitfile *ld_sf, bitfile *l ics->scale_factors[g][sfb] = noise_energy; break; - case BOOKSCL: /* invalid books */ - return 3; default: /* spectral books */ /* decode scale factor */ @@ -279,9 +283,8 @@ static uint8_t rvlc_decode_sf_reverse(ic_stream *ics, bitfile *ld_sf, bitfile *l t = rvlc_huffman_sf(ld_sf, ld_esc, -1); is_position -= t; - ics->scale_factors[g][sfb] = is_position; + ics->scale_factors[g][sfb] = (uint8_t)is_position; } - break; case NOISE_HCB: /* noise books */ @@ -295,11 +298,8 @@ static uint8_t rvlc_decode_sf_reverse(ic_stream *ics, bitfile *ld_sf, bitfile *l noise_energy -= t; } - ics->scale_factors[g][sfb] = noise_energy; - + ics->scale_factors[g][sfb] = (uint8_t)noise_energy; break; - case BOOKSCL: /* invalid books */ - return 3; default: /* spectral books */ if (sf_pcm_flag || (sfb == 0)) @@ -313,11 +313,10 @@ static uint8_t rvlc_decode_sf_reverse(ic_stream *ics, bitfile *ld_sf, bitfile *l scale_factor -= t; } - ics->scale_factors[g][sfb] = scale_factor; - if (scale_factor < 0) return 4; + ics->scale_factors[g][sfb] = (uint8_t)scale_factor; break; } #ifdef PRINT_RVLC @@ -509,4 +508,4 @@ static int8_t rvlc_huffman_esc(bitfile *ld, return h->index; } -#endif +#endif
\ No newline at end of file diff --git a/src/libfaad/rvlc.h b/src/libfaad/rvlc.h index 6727f5caa..4720dd6c0 100644 --- a/src/libfaad/rvlc.h +++ b/src/libfaad/rvlc.h @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: rvlc.h,v 1.1 2002/12/16 19:01:06 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: rvlc.h,v 1.2 2003/12/30 02:00:10 miguelfreitas Exp $ **/ #ifndef __RVLC_SCF_H__ diff --git a/src/libfaad/sbr_dct.c b/src/libfaad/sbr_dct.c new file mode 100644 index 000000000..8e1559367 --- /dev/null +++ b/src/libfaad/sbr_dct.c @@ -0,0 +1,2811 @@ +/* +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** +** This program is free software; you can redistribute it and/or modify +** it under the terms of the GNU General Public License as published by +** the Free Software Foundation; either version 2 of the License, or +** (at your option) any later version. +** +** This program is distributed in the hope that it will be useful, +** but WITHOUT ANY WARRANTY; without even the implied warranty of +** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +** GNU General Public License for more details. +** +** You should have received a copy of the GNU General Public License +** along with this program; if not, write to the Free Software +** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +** +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: sbr_dct.c,v 1.1 2003/12/30 02:00:10 miguelfreitas Exp $ +**/ + +#include "common.h" + +#ifdef SBR_DEC + +#ifdef _MSC_VER +#pragma warning(disable:4305) +#pragma warning(disable:4244) +#endif + + +#include "sbr_dct.h" + +#ifdef SBR_LOW_POWER + +void DCT3_32_unscaled(real_t *y, real_t *x) +{ + real_t f0, f1, f2, f3, f4, f5, f6, f7, f8, f9, f10; + real_t f11, f12, f13, f14, f15, f16, f17, f18, f19, f20; + real_t f21, f22, f23, f24, f25, f26, f27, f28, f29, f30; + real_t f31, f32, f33, f34, f35, f36, f37, f38, f39, f40; + real_t f41, f42, f43, f44, f45, f46, f47, f48, f49, f50; + real_t f51, f52, f53, f54, f55, f56, f57, f58, f59, f60; + real_t f61, f62, f63, f64, f65, f66, f67, f68, f69, f70; + real_t f71, f72, f73, f74, f75, f76, f77, f78, f79, f80; + real_t f81, f82, f83, f84, f85, f86, f87, f88, f89, f90; + real_t f91, f92, f93, f94, f95, f96, f97, f98, f99, f100; + real_t f101, f102, f103, f104, f105, f106, f107, f108, f109, f110; + real_t f111, f112, f113, f114, f115, f116, f117, f118, f119, f120; + real_t f121, f122, f123, f124, f125, f126, f127, f128, f129, f130; + real_t f131, f132, f133, f134, f135, f136, f137, f138, f139, f140; + real_t f141, f142, f143, f144, f145, f146, f147, f148, f149, f150; + real_t f151, f152, f153, f154, f155, f156, f157, f158, f159, f160; + real_t f161, f162, f163, f164, f165, f166, f167, f168, f169, f170; + real_t f171, f172, f173, f174, f175, f176, f177, f178, f179, f180; + real_t f181, f182, f183, f184, f185, f186, f187, f188, f189, f190; + real_t f191, f192, f193, f194, f195, f196, f197, f198, f199, f200; + real_t f201, f202, f203, f204, f205, f206, f207, f208, f209, f210; + real_t f211, f212, f213, f214, f215, f216, f217, f218, f219, f220; + real_t f221, f222, f223, f224, f225, f226, f227, f228, f229, f230; + real_t f231, f232, f233, f234, f235, f236, f237, f238, f239, f240; + real_t f241, f242, f243, f244, f245, f246, f247, f248, f249, f250; + real_t f251, f252, f253, f254, f255, f256, f257, f258, f259, f260; + real_t f261, f262, f263, f264, f265, f266, f267, f268, f269, f270; + real_t f271, f272; + + f0 = MUL_C(COEF_CONST(0.7071067811865476), x[16]); + f1 = x[0] - f0; + f2 = x[0] + f0; + f3 = x[8] + x[24]; + f4 = MUL_C(COEF_CONST(1.3065629648763766), x[8]); + f5 = MUL_C(COEF_CONST((-0.9238795325112866)), f3); + f6 = MUL_C(COEF_CONST((-0.5411961001461967)), x[24]); + f7 = f4 + f5; + f8 = f6 - f5; + f9 = f2 - f8; + f10 = f2 + f8; + f11 = f1 - f7; + f12 = f1 + f7; + f13 = x[4] + x[28]; + f14 = MUL_C(COEF_CONST(1.1758756024193588), x[4]); + f15 = MUL_C(COEF_CONST((-0.9807852804032304)), f13); + f16 = MUL_C(COEF_CONST((-0.7856949583871021)), x[28]); + f17 = f14 + f15; + f18 = f16 - f15; + f19 = x[12] + x[20]; + f20 = MUL_C(COEF_CONST(1.3870398453221473), x[12]); + f21 = MUL_C(COEF_CONST((-0.8314696123025455)), f19); + f22 = MUL_C(COEF_CONST((-0.2758993792829436)), x[20]); + f23 = f20 + f21; + f24 = f22 - f21; + f25 = f18 - f24; + f26 = f18 + f24; + f27 = MUL_C(COEF_CONST(0.7071067811865476), f25); + f28 = f17 - f23; + f29 = f17 + f23; + f30 = MUL_C(COEF_CONST(0.7071067811865476), f29); + f31 = f27 - f30; + f32 = f27 + f30; + f33 = f10 - f26; + f34 = f10 + f26; + f35 = f12 - f32; + f36 = f12 + f32; + f37 = f11 - f31; + f38 = f11 + f31; + f39 = f9 - f28; + f40 = f9 + f28; + f41 = x[2] + x[30]; + f42 = MUL_C(COEF_CONST(1.0932018670017569), x[2]); + f43 = MUL_C(COEF_CONST((-0.9951847266721969)), f41); + f44 = MUL_C(COEF_CONST((-0.8971675863426368)), x[30]); + f45 = f42 + f43; + f46 = f44 - f43; + f47 = x[6] + x[26]; + f48 = MUL_C(COEF_CONST(1.2472250129866711), x[6]); + f49 = MUL_C(COEF_CONST((-0.9569403357322089)), f47); + f50 = MUL_C(COEF_CONST((-0.6666556584777469)), x[26]); + f51 = f48 + f49; + f52 = f50 - f49; + f53 = x[10] + x[22]; + f54 = MUL_C(COEF_CONST(1.3533180011743526), x[10]); + f55 = MUL_C(COEF_CONST((-0.8819212643483551)), f53); + f56 = MUL_C(COEF_CONST((-0.4105245275223575)), x[22]); + f57 = f54 + f55; + f58 = f56 - f55; + f59 = x[14] + x[18]; + f60 = MUL_C(COEF_CONST(1.4074037375263826), x[14]); + f61 = MUL_C(COEF_CONST((-0.7730104533627369)), f59); + f62 = MUL_C(COEF_CONST((-0.1386171691990913)), x[18]); + f63 = f60 + f61; + f64 = f62 - f61; + f65 = f46 - f64; + f66 = f46 + f64; + f67 = f52 - f58; + f68 = f52 + f58; + f69 = f66 - f68; + f70 = f66 + f68; + f71 = MUL_C(COEF_CONST(0.7071067811865476), f69); + f72 = f65 + f67; + f73 = MUL_C(COEF_CONST(1.3065629648763766), f65); + f74 = MUL_C(COEF_CONST((-0.9238795325112866)), f72); + f75 = MUL_C(COEF_CONST((-0.5411961001461967)), f67); + f76 = f73 + f74; + f77 = f75 - f74; + f78 = f45 - f63; + f79 = f45 + f63; + f80 = f51 - f57; + f81 = f51 + f57; + f82 = f79 + f81; + f83 = MUL_C(COEF_CONST(1.3065629648763770), f79); + f84 = MUL_C(COEF_CONST((-0.3826834323650904)), f82); + f85 = MUL_C(COEF_CONST(0.5411961001461961), f81); + f86 = f83 + f84; + f87 = f85 - f84; + f88 = f78 - f80; + f89 = f78 + f80; + f90 = MUL_C(COEF_CONST(0.7071067811865476), f89); + f91 = f77 - f87; + f92 = f77 + f87; + f93 = f71 - f90; + f94 = f71 + f90; + f95 = f76 - f86; + f96 = f76 + f86; + f97 = f34 - f70; + f98 = f34 + f70; + f99 = f36 - f92; + f100 = f36 + f92; + f101 = f38 - f91; + f102 = f38 + f91; + f103 = f40 - f94; + f104 = f40 + f94; + f105 = f39 - f93; + f106 = f39 + f93; + f107 = f37 - f96; + f108 = f37 + f96; + f109 = f35 - f95; + f110 = f35 + f95; + f111 = f33 - f88; + f112 = f33 + f88; + f113 = x[1] + x[31]; + f114 = MUL_C(COEF_CONST(1.0478631305325901), x[1]); + f115 = MUL_C(COEF_CONST((-0.9987954562051724)), f113); + f116 = MUL_C(COEF_CONST((-0.9497277818777548)), x[31]); + f117 = f114 + f115; + f118 = f116 - f115; + f119 = x[5] + x[27]; + f120 = MUL_C(COEF_CONST(1.2130114330978077), x[5]); + f121 = MUL_C(COEF_CONST((-0.9700312531945440)), f119); + f122 = MUL_C(COEF_CONST((-0.7270510732912803)), x[27]); + f123 = f120 + f121; + f124 = f122 - f121; + f125 = x[9] + x[23]; + f126 = MUL_C(COEF_CONST(1.3315443865537255), x[9]); + f127 = MUL_C(COEF_CONST((-0.9039892931234433)), f125); + f128 = MUL_C(COEF_CONST((-0.4764341996931612)), x[23]); + f129 = f126 + f127; + f130 = f128 - f127; + f131 = x[13] + x[19]; + f132 = MUL_C(COEF_CONST(1.3989068359730781), x[13]); + f133 = MUL_C(COEF_CONST((-0.8032075314806453)), f131); + f134 = MUL_C(COEF_CONST((-0.2075082269882124)), x[19]); + f135 = f132 + f133; + f136 = f134 - f133; + f137 = x[17] + x[15]; + f138 = MUL_C(COEF_CONST(1.4125100802019777), x[17]); + f139 = MUL_C(COEF_CONST((-0.6715589548470187)), f137); + f140 = MUL_C(COEF_CONST(0.0693921705079402), x[15]); + f141 = f138 + f139; + f142 = f140 - f139; + f143 = x[21] + x[11]; + f144 = MUL_C(COEF_CONST(1.3718313541934939), x[21]); + f145 = MUL_C(COEF_CONST((-0.5141027441932219)), f143); + f146 = MUL_C(COEF_CONST(0.3436258658070501), x[11]); + f147 = f144 + f145; + f148 = f146 - f145; + f149 = x[25] + x[7]; + f150 = MUL_C(COEF_CONST(1.2784339185752409), x[25]); + f151 = MUL_C(COEF_CONST((-0.3368898533922200)), f149); + f152 = MUL_C(COEF_CONST(0.6046542117908008), x[7]); + f153 = f150 + f151; + f154 = f152 - f151; + f155 = x[29] + x[3]; + f156 = MUL_C(COEF_CONST(1.1359069844201433), x[29]); + f157 = MUL_C(COEF_CONST((-0.1467304744553624)), f155); + f158 = MUL_C(COEF_CONST(0.8424460355094185), x[3]); + f159 = f156 + f157; + f160 = f158 - f157; + f161 = f118 - f142; + f162 = f118 + f142; + f163 = f117 - f141; + f164 = f117 + f141; + f165 = f124 - f148; + f166 = f124 + f148; + f167 = f123 - f147; + f168 = f123 + f147; + f169 = f130 - f154; + f170 = f130 + f154; + f171 = f129 - f153; + f172 = f129 + f153; + f173 = f136 - f160; + f174 = f136 + f160; + f175 = f135 - f159; + f176 = f135 + f159; + f177 = f161 + f163; + f178 = MUL_C(COEF_CONST(1.1758756024193588), f161); + f179 = MUL_C(COEF_CONST((-0.9807852804032304)), f177); + f180 = MUL_C(COEF_CONST((-0.7856949583871021)), f163); + f181 = f178 + f179; + f182 = f180 - f179; + f183 = f165 + f167; + f184 = MUL_C(COEF_CONST(1.3870398453221475), f165); + f185 = MUL_C(COEF_CONST((-0.5555702330196022)), f183); + f186 = MUL_C(COEF_CONST(0.2758993792829431), f167); + f187 = f184 + f185; + f188 = f186 - f185; + f189 = f169 + f171; + f190 = MUL_C(COEF_CONST(0.7856949583871022), f169); + f191 = MUL_C(COEF_CONST(0.1950903220161283), f189); + f192 = MUL_C(COEF_CONST(1.1758756024193586), f171); + f193 = f190 + f191; + f194 = f192 - f191; + f195 = f173 + f175; + f196 = MUL_C(COEF_CONST((-0.2758993792829430)), f173); + f197 = MUL_C(COEF_CONST(0.8314696123025452), f195); + f198 = MUL_C(COEF_CONST(1.3870398453221475), f175); + f199 = f196 + f197; + f200 = f198 - f197; + f201 = f162 - f170; + f202 = f162 + f170; + f203 = f164 - f172; + f204 = f164 + f172; + f205 = f166 - f174; + f206 = f166 + f174; + f207 = f168 - f176; + f208 = f168 + f176; + f209 = f182 - f194; + f210 = f182 + f194; + f211 = f181 - f193; + f212 = f181 + f193; + f213 = f188 - f200; + f214 = f188 + f200; + f215 = f187 - f199; + f216 = f187 + f199; + f217 = f201 + f203; + f218 = MUL_C(COEF_CONST(1.3065629648763766), f201); + f219 = MUL_C(COEF_CONST((-0.9238795325112866)), f217); + f220 = MUL_C(COEF_CONST((-0.5411961001461967)), f203); + f221 = f218 + f219; + f222 = f220 - f219; + f223 = f205 + f207; + f224 = MUL_C(COEF_CONST(0.5411961001461969), f205); + f225 = MUL_C(COEF_CONST(0.3826834323650898), f223); + f226 = MUL_C(COEF_CONST(1.3065629648763766), f207); + f227 = f224 + f225; + f228 = f226 - f225; + f229 = f209 + f211; + f230 = MUL_C(COEF_CONST(1.3065629648763766), f209); + f231 = MUL_C(COEF_CONST((-0.9238795325112866)), f229); + f232 = MUL_C(COEF_CONST((-0.5411961001461967)), f211); + f233 = f230 + f231; + f234 = f232 - f231; + f235 = f213 + f215; + f236 = MUL_C(COEF_CONST(0.5411961001461969), f213); + f237 = MUL_C(COEF_CONST(0.3826834323650898), f235); + f238 = MUL_C(COEF_CONST(1.3065629648763766), f215); + f239 = f236 + f237; + f240 = f238 - f237; + f241 = f202 - f206; + f242 = f202 + f206; + f243 = f204 - f208; + f244 = f204 + f208; + f245 = f222 - f228; + f246 = f222 + f228; + f247 = f221 - f227; + f248 = f221 + f227; + f249 = f210 - f214; + f250 = f210 + f214; + f251 = f212 - f216; + f252 = f212 + f216; + f253 = f234 - f240; + f254 = f234 + f240; + f255 = f233 - f239; + f256 = f233 + f239; + f257 = f241 - f243; + f258 = f241 + f243; + f259 = MUL_C(COEF_CONST(0.7071067811865474), f257); + f260 = MUL_C(COEF_CONST(0.7071067811865474), f258); + f261 = f245 - f247; + f262 = f245 + f247; + f263 = MUL_C(COEF_CONST(0.7071067811865474), f261); + f264 = MUL_C(COEF_CONST(0.7071067811865474), f262); + f265 = f249 - f251; + f266 = f249 + f251; + f267 = MUL_C(COEF_CONST(0.7071067811865474), f265); + f268 = MUL_C(COEF_CONST(0.7071067811865474), f266); + f269 = f253 - f255; + f270 = f253 + f255; + f271 = MUL_C(COEF_CONST(0.7071067811865474), f269); + f272 = MUL_C(COEF_CONST(0.7071067811865474), f270); + y[31] = f98 - f242; + y[0] = f98 + f242; + y[30] = f100 - f250; + y[1] = f100 + f250; + y[29] = f102 - f254; + y[2] = f102 + f254; + y[28] = f104 - f246; + y[3] = f104 + f246; + y[27] = f106 - f264; + y[4] = f106 + f264; + y[26] = f108 - f272; + y[5] = f108 + f272; + y[25] = f110 - f268; + y[6] = f110 + f268; + y[24] = f112 - f260; + y[7] = f112 + f260; + y[23] = f111 - f259; + y[8] = f111 + f259; + y[22] = f109 - f267; + y[9] = f109 + f267; + y[21] = f107 - f271; + y[10] = f107 + f271; + y[20] = f105 - f263; + y[11] = f105 + f263; + y[19] = f103 - f248; + y[12] = f103 + f248; + y[18] = f101 - f256; + y[13] = f101 + f256; + y[17] = f99 - f252; + y[14] = f99 + f252; + y[16] = f97 - f244; + y[15] = f97 + f244; +} + +void DCT2_64_unscaled(real_t *y, real_t *x) +{ + int16_t i0; + real_t f2, f3, f4, f5, f6, f7, f8, f9, f10; + real_t f11, f12, f13, f14, f15, f16, f17, f18, f19, f20; + real_t f21, f22, f23, f24, f25, f26, f27, f28, f29, f30; + real_t f31, f32, f33, f34, f35, f36, f37, f38, f39, f40; + real_t f41, f42, f43, f44, f45, f46, f47, f48, f49, f50; + real_t f51, f52, f53, f54, f55, f56, f57, f58, f59, f60; + real_t f61, f62, f65, f66, f67, f68, f71, f72, f73, f74; + real_t f75, f76, f77, f78, f79, f80, f81, f82, f83, f85; + real_t f87, f88, f91, f92, f93, f94, f95, f96, f97, f98; + real_t f99, f100, f101, f102, f103, f104, f105, f106, f107, f108; + real_t f109, f110, f111, f112, f113, f114, f115, f116, f117, f118; + real_t f119, f120, f121, f122, f123, f124, f125, f126, f129, f130; + real_t f131, f132, f135, f136, f137, f138, f141, f142, f143, f144; + real_t f147, f148, f149, f150, f151, f152, f153, f154, f155, f156; + real_t f157, f158, f159, f160, f161, f162, f163, f164, f165, f166; + real_t f167, f168, f169, f170, f171, f172, f173, f174, f175, f176; + real_t f177, f178, f179, f180, f181, f182, f183, f184, f185, f186; + real_t f187, f188, f189, f190, f191, f192, f193, f194, f195, f196; + real_t f197, f198, f199, f200, f201, f202, f203, f204, f205, f206; + real_t f207, f208, f209, f210, f211, f212, f213, f214, f215, f216; + real_t f217, f218, f219, f220, f221, f222, f223, f224, f225, f226; + real_t f227, f228, f229, f230, f231, f232, f233, f234, f235, f236; + real_t f237, f238, f239, f240, f241, f242, f243, f244, f245, f246; + real_t f247, f248, f249, f250, f251, f252, f253, f254, f255, f256; + real_t f257, f258, f259, f260, f261, f262, f265, f266, f267, f268; + real_t f271, f272, f273, f274, f277, f278, f279, f280, f283, f284; + real_t f285, f286, f289, f290, f291, f292, f295, f296, f297, f298; + real_t f301, f302, f303, f304, f307, f308, f309, f310, f311, f312; + real_t f313, f314, f315, f316, f317, f318, f319, f320, f321, f322; + real_t f323, f324, f325, f326, f327, f328, f329, f330, f331, f332; + real_t f333, f334, f335, f336, f337, f338, f339, f340, f341, f342; + real_t f343, f344, f345, f346, f347, f348, f349, f350, f351, f352; + real_t f353, f354, f355, f356, f357, f358, f359, f360, f361, f362; + real_t f363, f364, f365, f366, f367, f368, f369, f370, f371, f372; + real_t f373, f374, f375, f376, f377, f378, f379, f380, f381, f382; + real_t f383, f384, f385, f386, f387, f388, f389, f390, f391, f392; + real_t f393, f394, f395, f396, f397, f398, f399, f400, f401, f402; + real_t f403, f404, f405, f406, f407, f408, f409, f410, f411, f412; + real_t f413, f414, f415, f416, f417, f418, f419, f420, f421, f422; + real_t f423, f424, f425, f426, f427, f428, f429, f430, f431, f433; + real_t f434, f435, f436, f437, f438, f439, f440, f441, f442, f443; + real_t f444, f445, f446, f447, f448, f449, f450, f451, f452, f453; + real_t f454, f455, f456, f457, f458, f459, f460, f461, f462, f463; + real_t f464, f465, f466, f467, f468, f469, f470, f471, f472, f473; + real_t f474, f475, f476, f477, f478, f479, f480, f481, f482, f483; + real_t f484, f485, f486, f487, f488, f489, f490, f491, f492, f493; + real_t f494, f495, f496, f497, f498, f499, f500, f501, f502, f503; + real_t f504, f505, f506, f507, f508, f509, f510, f511, f512, f513; + real_t f514, f515, f516, f517, f518, f519, f520, f521, f522, f523; + real_t f524, f525, f526, f527, f528, f529, f530, f531, f532, f533; + real_t f534, f535, f536, f537, f538, f539, f540, f541, f542, f543; + real_t f544, f546, f547, f548, f549, f550, f551, f552, f553, f554; + real_t f555, f556, f557, f558, f559, f560, f561, f562, f563, f564; + real_t f565, f566, f567, f568, f569, f570, f571, f572, f573, f574; + real_t f575, f576, f577, f578, f579, f580, f581, f582, f583, f584; + real_t f585, f586, f587, f588, f589, f590, f591, f592, f593, f594; + real_t f595, f596, f597, f598, f599, f600, f601, f602, f603, f604; + real_t f605, f606, f607, f608, f609, f610, f611, f612, f613, f614; + real_t f615, f616, f617, f618, f619, f620, f621, f622, f623, f624; + real_t f625, f626, f627, f628; + ALIGN static real_t t2[64]; + + for (i0=0; i0<32; i0++) + { + t2[2*i0+1] = x[i0] - x[-i0+63]; + t2[2*i0] = x[i0] + x[-i0+63]; + } + f2 = t2[0] - t2[62]; + f3 = t2[0] + t2[62]; + f4 = t2[2] - t2[60]; + f5 = t2[2] + t2[60]; + f6 = t2[4] - t2[58]; + f7 = t2[4] + t2[58]; + f8 = t2[6] - t2[56]; + f9 = t2[6] + t2[56]; + f10 = t2[8] - t2[54]; + f11 = t2[8] + t2[54]; + f12 = t2[10] - t2[52]; + f13 = t2[10] + t2[52]; + f14 = t2[12] - t2[50]; + f15 = t2[12] + t2[50]; + f16 = t2[14] - t2[48]; + f17 = t2[14] + t2[48]; + f18 = t2[16] - t2[46]; + f19 = t2[16] + t2[46]; + f20 = t2[18] - t2[44]; + f21 = t2[18] + t2[44]; + f22 = t2[20] - t2[42]; + f23 = t2[20] + t2[42]; + f24 = t2[22] - t2[40]; + f25 = t2[22] + t2[40]; + f26 = t2[24] - t2[38]; + f27 = t2[24] + t2[38]; + f28 = t2[26] - t2[36]; + f29 = t2[26] + t2[36]; + f30 = t2[28] - t2[34]; + f31 = t2[28] + t2[34]; + f32 = t2[30] - t2[32]; + f33 = t2[30] + t2[32]; + f34 = f3 - f33; + f35 = f3 + f33; + f36 = f5 - f31; + f37 = f5 + f31; + f38 = f7 - f29; + f39 = f7 + f29; + f40 = f9 - f27; + f41 = f9 + f27; + f42 = f11 - f25; + f43 = f11 + f25; + f44 = f13 - f23; + f45 = f13 + f23; + f46 = f15 - f21; + f47 = f15 + f21; + f48 = f17 - f19; + f49 = f17 + f19; + f50 = f35 - f49; + f51 = f35 + f49; + f52 = f37 - f47; + f53 = f37 + f47; + f54 = f39 - f45; + f55 = f39 + f45; + f56 = f41 - f43; + f57 = f41 + f43; + f58 = f51 - f57; + f59 = f51 + f57; + f60 = f53 - f55; + f61 = f53 + f55; + f62 = f59 - f61; + y[0] = f59 + f61; + y[32] = MUL_C(COEF_CONST(0.7071067811865476), f62); + f65 = f58 + f60; + f66 = MUL_C(COEF_CONST(1.3065629648763766), f58); + f67 = MUL_C(COEF_CONST((-0.9238795325112866)), f65); + f68 = MUL_C(COEF_CONST((-0.5411961001461967)), f60); + y[48] = f66 + f67; + y[16] = f68 - f67; + f71 = f50 + f56; + f72 = MUL_C(COEF_CONST(1.1758756024193588), f50); + f73 = MUL_C(COEF_CONST((-0.9807852804032304)), f71); + f74 = MUL_C(COEF_CONST((-0.7856949583871021)), f56); + f75 = f72 + f73; + f76 = f74 - f73; + f77 = f52 + f54; + f78 = MUL_C(COEF_CONST(1.3870398453221473), f52); + f79 = MUL_C(COEF_CONST((-0.8314696123025455)), f77); + f80 = MUL_C(COEF_CONST((-0.2758993792829436)), f54); + f81 = f78 + f79; + f82 = f80 - f79; + f83 = f76 - f82; + y[8] = f76 + f82; + f85 = MUL_C(COEF_CONST(0.7071067811865476), f83); + y[56] = f75 - f81; + f87 = f75 + f81; + f88 = MUL_C(COEF_CONST(0.7071067811865476), f87); + y[40] = f85 - f88; + y[24] = f85 + f88; + f91 = f36 - f38; + f92 = f36 + f38; + f93 = f40 - f42; + f94 = f40 + f42; + f95 = f44 - f46; + f96 = f44 + f46; + f97 = MUL_C(COEF_CONST(0.7071067811865476), f94); + f98 = f34 - f97; + f99 = f34 + f97; + f100 = f92 + f96; + f101 = MUL_C(COEF_CONST(1.3065629648763766), f92); + f102 = MUL_C(COEF_CONST((-0.9238795325112866)), f100); + f103 = MUL_C(COEF_CONST((-0.5411961001461967)), f96); + f104 = f101 + f102; + f105 = f103 - f102; + f106 = f99 - f105; + f107 = f99 + f105; + f108 = f98 - f104; + f109 = f98 + f104; + f110 = f91 + f95; + f111 = MUL_C(COEF_CONST(1.3065629648763770), f91); + f112 = MUL_C(COEF_CONST((-0.3826834323650904)), f110); + f113 = MUL_C(COEF_CONST(0.5411961001461961), f95); + f114 = f111 + f112; + f115 = f113 - f112; + f116 = MUL_C(COEF_CONST(0.7071067811865476), f93); + f117 = f116 - f48; + f118 = f116 + f48; + f119 = f115 - f118; + f120 = f115 + f118; + f121 = f114 - f117; + f122 = f114 + f117; + f123 = f120 + f107; + f124 = MUL_C(COEF_CONST((-0.8971675863426361)), f120); + f125 = MUL_C(COEF_CONST(0.9951847266721968), f123); + f126 = MUL_C(COEF_CONST(1.0932018670017576), f107); + y[4] = f124 + f125; + y[60] = f126 - f125; + f129 = f122 + f109; + f130 = MUL_C(COEF_CONST((-0.6666556584777466)), f122); + f131 = MUL_C(COEF_CONST(0.9569403357322089), f129); + f132 = MUL_C(COEF_CONST(1.2472250129866713), f109); + y[12] = f130 + f131; + y[52] = f132 - f131; + f135 = f121 + f108; + f136 = MUL_C(COEF_CONST((-0.4105245275223571)), f121); + f137 = MUL_C(COEF_CONST(0.8819212643483549), f135); + f138 = MUL_C(COEF_CONST(1.3533180011743529), f108); + y[20] = f136 + f137; + y[44] = f138 - f137; + f141 = f119 + f106; + f142 = MUL_C(COEF_CONST((-0.1386171691990915)), f119); + f143 = MUL_C(COEF_CONST(0.7730104533627370), f141); + f144 = MUL_C(COEF_CONST(1.4074037375263826), f106); + y[28] = f142 + f143; + y[36] = f144 - f143; + f147 = f16 - f18; + f148 = f16 + f18; + f149 = MUL_C(COEF_CONST(0.7071067811865476), f148); + f150 = MUL_C(COEF_CONST(0.7071067811865476), f147); + f151 = f10 - f24; + f152 = f10 + f24; + f153 = MUL_C(COEF_CONST(0.7071067811865476), f152); + f154 = MUL_C(COEF_CONST(0.7071067811865476), f151); + f155 = f14 - f20; + f156 = f14 + f20; + f157 = MUL_C(COEF_CONST(0.7071067811865476), f156); + f158 = MUL_C(COEF_CONST(0.7071067811865476), f155); + f159 = f12 - f22; + f160 = f12 + f22; + f161 = MUL_C(COEF_CONST(0.7071067811865476), f160); + f162 = MUL_C(COEF_CONST(0.7071067811865476), f159); + f163 = f2 - f149; + f164 = f2 + f149; + f165 = f32 - f150; + f166 = f32 + f150; + f167 = f8 - f153; + f168 = f8 + f153; + f169 = f26 - f154; + f170 = f26 + f154; + f171 = f4 - f157; + f172 = f4 + f157; + f173 = f30 - f158; + f174 = f30 + f158; + f175 = f6 - f161; + f176 = f6 + f161; + f177 = f28 - f162; + f178 = f28 + f162; + f179 = f170 + f168; + f180 = MUL_C(COEF_CONST((-0.5411961001461969)), f170); + f181 = MUL_C(COEF_CONST(0.9238795325112867), f179); + f182 = MUL_C(COEF_CONST(1.3065629648763766), f168); + f183 = f180 + f181; + f184 = f182 - f181; + f185 = f169 + f167; + f186 = MUL_C(COEF_CONST(1.3065629648763770), f169); + f187 = MUL_C(COEF_CONST((-0.3826834323650904)), f185); + f188 = MUL_C(COEF_CONST(0.5411961001461961), f167); + f189 = f186 + f187; + f190 = f188 - f187; + f191 = f178 + f176; + f192 = MUL_C(COEF_CONST((-0.5411961001461969)), f178); + f193 = MUL_C(COEF_CONST(0.9238795325112867), f191); + f194 = MUL_C(COEF_CONST(1.3065629648763766), f176); + f195 = f192 + f193; + f196 = f194 - f193; + f197 = f177 + f175; + f198 = MUL_C(COEF_CONST(1.3065629648763770), f177); + f199 = MUL_C(COEF_CONST((-0.3826834323650904)), f197); + f200 = MUL_C(COEF_CONST(0.5411961001461961), f175); + f201 = f198 + f199; + f202 = f200 - f199; + f203 = f164 - f183; + f204 = f164 + f183; + f205 = f166 - f184; + f206 = f166 + f184; + f207 = f163 - f189; + f208 = f163 + f189; + f209 = f165 - f190; + f210 = f165 + f190; + f211 = f172 - f195; + f212 = f172 + f195; + f213 = f174 - f196; + f214 = f174 + f196; + f215 = f171 - f201; + f216 = f171 + f201; + f217 = f173 - f202; + f218 = f173 + f202; + f219 = f214 + f212; + f220 = MUL_C(COEF_CONST((-0.7856949583871021)), f214); + f221 = MUL_C(COEF_CONST(0.9807852804032304), f219); + f222 = MUL_C(COEF_CONST(1.1758756024193588), f212); + f223 = f220 + f221; + f224 = f222 - f221; + f225 = f218 + f216; + f226 = MUL_C(COEF_CONST(0.2758993792829431), f218); + f227 = MUL_C(COEF_CONST(0.5555702330196022), f225); + f228 = MUL_C(COEF_CONST(1.3870398453221475), f216); + f229 = f226 + f227; + f230 = f228 - f227; + f231 = f213 + f211; + f232 = MUL_C(COEF_CONST(1.1758756024193591), f213); + f233 = MUL_C(COEF_CONST((-0.1950903220161287)), f231); + f234 = MUL_C(COEF_CONST(0.7856949583871016), f211); + f235 = f232 + f233; + f236 = f234 - f233; + f237 = f217 + f215; + f238 = MUL_C(COEF_CONST(1.3870398453221473), f217); + f239 = MUL_C(COEF_CONST((-0.8314696123025455)), f237); + f240 = MUL_C(COEF_CONST((-0.2758993792829436)), f215); + f241 = f238 + f239; + f242 = f240 - f239; + f243 = f204 - f223; + f244 = f204 + f223; + f245 = f206 - f224; + f246 = f206 + f224; + f247 = f208 - f229; + f248 = f208 + f229; + f249 = f210 - f230; + f250 = f210 + f230; + f251 = f203 - f235; + f252 = f203 + f235; + f253 = f205 - f236; + f254 = f205 + f236; + f255 = f207 - f241; + f256 = f207 + f241; + f257 = f209 - f242; + f258 = f209 + f242; + f259 = f246 + f244; + f260 = MUL_C(COEF_CONST((-0.9497277818777543)), f246); + f261 = MUL_C(COEF_CONST(0.9987954562051724), f259); + f262 = MUL_C(COEF_CONST(1.0478631305325905), f244); + y[2] = f260 + f261; + y[62] = f262 - f261; + f265 = f250 + f248; + f266 = MUL_C(COEF_CONST((-0.7270510732912801)), f250); + f267 = MUL_C(COEF_CONST(0.9700312531945440), f265); + f268 = MUL_C(COEF_CONST(1.2130114330978079), f248); + y[10] = f266 + f267; + y[54] = f268 - f267; + f271 = f254 + f252; + f272 = MUL_C(COEF_CONST((-0.4764341996931611)), f254); + f273 = MUL_C(COEF_CONST(0.9039892931234433), f271); + f274 = MUL_C(COEF_CONST(1.3315443865537255), f252); + y[18] = f272 + f273; + y[46] = f274 - f273; + f277 = f258 + f256; + f278 = MUL_C(COEF_CONST((-0.2075082269882114)), f258); + f279 = MUL_C(COEF_CONST(0.8032075314806448), f277); + f280 = MUL_C(COEF_CONST(1.3989068359730783), f256); + y[26] = f278 + f279; + y[38] = f280 - f279; + f283 = f245 + f243; + f284 = MUL_C(COEF_CONST(0.0693921705079408), f245); + f285 = MUL_C(COEF_CONST(0.6715589548470183), f283); + f286 = MUL_C(COEF_CONST(1.4125100802019774), f243); + y[34] = f284 + f285; + y[30] = f286 - f285; + f289 = f249 + f247; + f290 = MUL_C(COEF_CONST(0.3436258658070505), f249); + f291 = MUL_C(COEF_CONST(0.5141027441932217), f289); + f292 = MUL_C(COEF_CONST(1.3718313541934939), f247); + y[42] = f290 + f291; + y[22] = f292 - f291; + f295 = f253 + f251; + f296 = MUL_C(COEF_CONST(0.6046542117908007), f253); + f297 = MUL_C(COEF_CONST(0.3368898533922201), f295); + f298 = MUL_C(COEF_CONST(1.2784339185752409), f251); + y[50] = f296 + f297; + y[14] = f298 - f297; + f301 = f257 + f255; + f302 = MUL_C(COEF_CONST(0.8424460355094192), f257); + f303 = MUL_C(COEF_CONST(0.1467304744553618), f301); + f304 = MUL_C(COEF_CONST(1.1359069844201428), f255); + y[58] = f302 + f303; + y[6] = f304 - f303; + f307 = t2[1] + t2[63]; + f308 = MUL_C(COEF_CONST(1.0242400472191162), t2[1]); + f309 = MUL_C(COEF_CONST((-0.9996988186962043)), f307); + f310 = MUL_C(COEF_CONST((-0.9751575901732922)), t2[63]); + f311 = f308 + f309; + f312 = f310 - f309; + f313 = t2[3] + t2[61]; + f314 = MUL_C(COEF_CONST(1.0708550202783571),t2[3]); + f315 = MUL_C(COEF_CONST((-0.9972904566786902)), f313); + f316 = MUL_C(COEF_CONST((-0.9237258930790232)), t2[61]); + f317 = f314 + f315; + f318 = f316 - f315; + f319 = t2[5] + t2[59]; + f320 = MUL_C(COEF_CONST(1.1148902097979256), t2[5]); + f321 = MUL_C(COEF_CONST((-0.9924795345987101)), f319); + f322 = MUL_C(COEF_CONST((-0.8700688593994945)), t2[59]); + f323 = f320 + f321; + f324 = f322 - f321; + f325 = t2[7] + t2[57]; + f326 = MUL_C(COEF_CONST(1.1562395311492426), t2[7]); + f327 = MUL_C(COEF_CONST((-0.9852776423889412)), f325); + f328 = MUL_C(COEF_CONST((-0.8143157536286398)), t2[57]); + f329 = f326 + f327; + f330 = f328 - f327; + f331 = t2[9] + t2[55]; + f332 = MUL_C(COEF_CONST(1.1948033701953984), t2[9]); + f333 = MUL_C(COEF_CONST((-0.9757021300385286)), f331); + f334 = MUL_C(COEF_CONST((-0.7566008898816589)), t2[55]); + f335 = f332 + f333; + f336 = f334 - f333; + f337 = t2[11] + t2[53]; + f338 = MUL_C(COEF_CONST(1.2304888232703382), t2[11]); + f339 = MUL_C(COEF_CONST((-0.9637760657954400)), f337); + f340 = MUL_C(COEF_CONST((-0.6970633083205418)), t2[53]); + f341 = f338 + f339; + f342 = f340 - f339; + f343 = t2[13] + t2[51]; + f344 = MUL_C(COEF_CONST(1.2632099209919279), t2[13]); + f345 = MUL_C(COEF_CONST((-0.9495281805930368)), f343); + f346 = MUL_C(COEF_CONST((-0.6358464401941457)), t2[51]); + f347 = f344 + f345; + f348 = f346 - f345; + f349 = t2[15] + t2[49]; + f350 = MUL_C(COEF_CONST(1.2928878353697266), t2[15]); + f351 = MUL_C(COEF_CONST((-0.9329927988347391)), f349); + f352 = MUL_C(COEF_CONST((-0.5730977622997515)), t2[49]); + f353 = f350 + f351; + f354 = f352 - f351; + f355 = t2[17] + t2[47]; + f356 = MUL_C(COEF_CONST(1.3194510697085207), t2[17]); + f357 = MUL_C(COEF_CONST((-0.9142097557035306)), f355); + f358 = MUL_C(COEF_CONST((-0.5089684416985405)), t2[47]); + f359 = f356 + f357; + f360 = f358 - f357; + f361 = t2[19] + t2[45]; + f362 = MUL_C(COEF_CONST(1.3428356308501219), t2[19]); + f363 = MUL_C(COEF_CONST((-0.8932243011955153)), f361); + f364 = MUL_C(COEF_CONST((-0.4436129715409087)), t2[45]); + f365 = f362 + f363; + f366 = f364 - f363; + f367 = t2[21] + t2[43]; + f368 = MUL_C(COEF_CONST(1.3629851833384954), t2[21]); + f369 = MUL_C(COEF_CONST((-0.8700869911087115)), f367); + f370 = MUL_C(COEF_CONST((-0.3771887988789276)), t2[43]); + f371 = f368 + f369; + f372 = f370 - f369; + f373 = t2[23] + t2[41]; + f374 = MUL_C(COEF_CONST(1.3798511851368040), t2[23]); + f375 = MUL_C(COEF_CONST((-0.8448535652497072)), f373); + f376 = MUL_C(COEF_CONST((-0.3098559453626103)), t2[41]); + f377 = f374 + f375; + f378 = f376 - f375; + f379 = t2[25] + t2[39]; + f380 = MUL_C(COEF_CONST(1.3933930045694289), t2[25]); + f381 = MUL_C(COEF_CONST((-0.8175848131515840)), f379); + f382 = MUL_C(COEF_CONST((-0.2417766217337392)), t2[39]); + f383 = f380 + f381; + f384 = f382 - f381; + f385 = t2[27] + t2[37]; + f386 = MUL_C(COEF_CONST(1.4035780182072330), t2[27]); + f387 = MUL_C(COEF_CONST((-0.7883464276266061)), f385); + f388 = MUL_C(COEF_CONST((-0.1731148370459791)), t2[37]); + f389 = f386 + f387; + f390 = f388 - f387; + f391 = t2[29] + t2[35]; + f392 = MUL_C(COEF_CONST(1.4103816894602614), t2[29]); + f393 = MUL_C(COEF_CONST((-0.7572088465064846)), f391); + f394 = MUL_C(COEF_CONST((-0.1040360035527078)), t2[35]); + f395 = f392 + f393; + f396 = f394 - f393; + f397 = t2[31] + t2[33]; + f398 = MUL_C(COEF_CONST(1.4137876276885337), t2[31]); + f399 = MUL_C(COEF_CONST((-0.7242470829514670)), f397); + f400 = MUL_C(COEF_CONST((-0.0347065382144002)), t2[33]); + f401 = f398 + f399; + f402 = f400 - f399; + f403 = f312 - f402; + f404 = f312 + f402; + f405 = f318 - f396; + f406 = f318 + f396; + f407 = f324 - f390; + f408 = f324 + f390; + f409 = f330 - f384; + f410 = f330 + f384; + f411 = f336 - f378; + f412 = f336 + f378; + f413 = f342 - f372; + f414 = f342 + f372; + f415 = f348 - f366; + f416 = f348 + f366; + f417 = f354 - f360; + f418 = f354 + f360; + f419 = f404 - f418; + f420 = f404 + f418; + f421 = f406 - f416; + f422 = f406 + f416; + f423 = f408 - f414; + f424 = f408 + f414; + f425 = f410 - f412; + f426 = f410 + f412; + f427 = f420 - f426; + f428 = f420 + f426; + f429 = f422 - f424; + f430 = f422 + f424; + f431 = f428 - f430; + y[1] = f428 + f430; + f433 = MUL_C(COEF_CONST(0.7071067811865476), f431); + f434 = f427 + f429; + f435 = MUL_C(COEF_CONST(1.3065629648763766), f427); + f436 = MUL_C(COEF_CONST((-0.9238795325112866)), f434); + f437 = MUL_C(COEF_CONST((-0.5411961001461967)), f429); + f438 = f435 + f436; + f439 = f437 - f436; + f440 = f419 + f425; + f441 = MUL_C(COEF_CONST(1.1758756024193588), f419); + f442 = MUL_C(COEF_CONST((-0.9807852804032304)), f440); + f443 = MUL_C(COEF_CONST((-0.7856949583871021)), f425); + f444 = f441 + f442; + f445 = f443 - f442; + f446 = f421 + f423; + f447 = MUL_C(COEF_CONST(1.3870398453221473), f421); + f448 = MUL_C(COEF_CONST((-0.8314696123025455)), f446); + f449 = MUL_C(COEF_CONST((-0.2758993792829436)), f423); + f450 = f447 + f448; + f451 = f449 - f448; + f452 = f445 - f451; + f453 = f445 + f451; + f454 = MUL_C(COEF_CONST(0.7071067811865476), f452); + f455 = f444 - f450; + f456 = f444 + f450; + f457 = MUL_C(COEF_CONST(0.7071067811865476), f456); + f458 = f454 - f457; + f459 = f454 + f457; + f460 = f405 - f407; + f461 = f405 + f407; + f462 = f409 - f411; + f463 = f409 + f411; + f464 = f413 - f415; + f465 = f413 + f415; + f466 = MUL_C(COEF_CONST(0.7071067811865476), f463); + f467 = f403 - f466; + f468 = f403 + f466; + f469 = f461 + f465; + f470 = MUL_C(COEF_CONST(1.3065629648763766), f461); + f471 = MUL_C(COEF_CONST((-0.9238795325112866)), f469); + f472 = MUL_C(COEF_CONST((-0.5411961001461967)), f465); + f473 = f470 + f471; + f474 = f472 - f471; + f475 = f468 - f474; + f476 = f468 + f474; + f477 = f467 - f473; + f478 = f467 + f473; + f479 = f460 + f464; + f480 = MUL_C(COEF_CONST(1.3065629648763770), f460); + f481 = MUL_C(COEF_CONST((-0.3826834323650904)), f479); + f482 = MUL_C(COEF_CONST(0.5411961001461961), f464); + f483 = f480 + f481; + f484 = f482 - f481; + f485 = MUL_C(COEF_CONST(0.7071067811865476), f462); + f486 = f485 - f417; + f487 = f485 + f417; + f488 = f484 - f487; + f489 = f484 + f487; + f490 = f483 - f486; + f491 = f483 + f486; + f492 = f489 + f476; + f493 = MUL_C(COEF_CONST((-0.8971675863426361)), f489); + f494 = MUL_C(COEF_CONST(0.9951847266721968), f492); + f495 = MUL_C(COEF_CONST(1.0932018670017576), f476); + f496 = f493 + f494; + f497 = f495 - f494; + f498 = f491 + f478; + f499 = MUL_C(COEF_CONST((-0.6666556584777466)), f491); + f500 = MUL_C(COEF_CONST(0.9569403357322089), f498); + f501 = MUL_C(COEF_CONST(1.2472250129866713), f478); + f502 = f499 + f500; + f503 = f501 - f500; + f504 = f490 + f477; + f505 = MUL_C(COEF_CONST((-0.4105245275223571)), f490); + f506 = MUL_C(COEF_CONST(0.8819212643483549), f504); + f507 = MUL_C(COEF_CONST(1.3533180011743529), f477); + f508 = f505 + f506; + f509 = f507 - f506; + f510 = f488 + f475; + f511 = MUL_C(COEF_CONST((-0.1386171691990915)), f488); + f512 = MUL_C(COEF_CONST(0.7730104533627370), f510); + f513 = MUL_C(COEF_CONST(1.4074037375263826), f475); + f514 = f511 + f512; + f515 = f513 - f512; + f516 = f311 + f401; + f517 = f311 - f401; + f518 = f317 + f395; + f519 = f395 - f317; + f520 = f323 + f389; + f521 = f323 - f389; + f522 = f329 + f383; + f523 = f383 - f329; + f524 = f335 + f377; + f525 = f335 - f377; + f526 = f341 + f371; + f527 = f371 - f341; + f528 = f347 + f365; + f529 = f347 - f365; + f530 = f353 + f359; + f531 = f359 - f353; + f532 = f517 - f531; + f533 = f517 + f531; + f534 = f519 - f529; + f535 = f519 + f529; + f536 = f521 - f527; + f537 = f521 + f527; + f538 = f523 - f525; + f539 = f523 + f525; + f540 = f533 - f539; + f541 = f533 + f539; + f542 = f535 - f537; + f543 = f535 + f537; + f544 = f541 - f543; + y[63] = f541 + f543; + f546 = MUL_C(COEF_CONST(0.7071067811865476), f544); + f547 = f540 + f542; + f548 = MUL_C(COEF_CONST(1.3065629648763766), f540); + f549 = MUL_C(COEF_CONST((-0.9238795325112866)), f547); + f550 = MUL_C(COEF_CONST((-0.5411961001461967)), f542); + f551 = f548 + f549; + f552 = f550 - f549; + f553 = f532 + f538; + f554 = MUL_C(COEF_CONST(1.1758756024193588), f532); + f555 = MUL_C(COEF_CONST((-0.9807852804032304)), f553); + f556 = MUL_C(COEF_CONST((-0.7856949583871021)), f538); + f557 = f554 + f555; + f558 = f556 - f555; + f559 = f534 + f536; + f560 = MUL_C(COEF_CONST(1.3870398453221473), f534); + f561 = MUL_C(COEF_CONST((-0.8314696123025455)), f559); + f562 = MUL_C(COEF_CONST((-0.2758993792829436)), f536); + f563 = f560 + f561; + f564 = f562 - f561; + f565 = f558 - f564; + f566 = f558 + f564; + f567 = MUL_C(COEF_CONST(0.7071067811865476), f565); + f568 = f557 - f563; + f569 = f557 + f563; + f570 = MUL_C(COEF_CONST(0.7071067811865476), f569); + f571 = f567 - f570; + f572 = f567 + f570; + f573 = MUL_C(COEF_CONST(0.5024192861881557), f516); + f574 = MUL_C(COEF_CONST(0.5224986149396889), f518); + f575 = MUL_C(COEF_CONST(0.5669440348163577), f520); + f576 = MUL_C(COEF_CONST(0.6468217833599901), f522); + f577 = MUL_C(COEF_CONST(0.7881546234512502), f524); + f578 = MUL_C(COEF_CONST(1.0606776859903471), f526); + f579 = MUL_C(COEF_CONST(1.7224470982383342), f528); + f580 = MUL_C(COEF_CONST(5.1011486186891553), f530); + f581 = f573 + f580; + f582 = f573 - f580; + f583 = f574 + f579; + f584 = f579 - f574; + f585 = f575 + f578; + f586 = f575 - f578; + f587 = f576 + f577; + f588 = f577 - f576; + f589 = f582 - f588; + f590 = f582 + f588; + f591 = f584 - f586; + f592 = f584 + f586; + f593 = f590 - f592; + f594 = f590 + f592; + f595 = MUL_C(COEF_CONST(0.7071067811865476), f593); + f596 = f589 + f591; + f597 = MUL_C(COEF_CONST(1.3065629648763766), f589); + f598 = MUL_C(COEF_CONST((-0.9238795325112866)), f596); + f599 = MUL_C(COEF_CONST((-0.5411961001461967)), f591); + f600 = f597 + f598; + f601 = f599 - f598; + f602 = f583 + f585; + f603 = f585 - f583; + f604 = MUL_C(COEF_CONST(0.7071067811865476), f603); + f605 = MUL_C(COEF_CONST(0.7071067811865476), f602); + f606 = f581 - f604; + f607 = f581 + f604; + f608 = f605 - f587; + f609 = f587 + f605; + f610 = f607 - f609; + f611 = MUL_C(COEF_CONST((-0.7856949583871021)), f609); + f612 = MUL_C(COEF_CONST(0.9807852804032304), f610); + f613 = MUL_C(COEF_CONST(1.1758756024193588), f607); + f614 = f612 - f611; + f615 = f613 - f612; + f616 = f608 + f606; + f617 = MUL_C(COEF_CONST(0.2758993792829431), f608); + f618 = MUL_C(COEF_CONST(0.5555702330196022), f616); + f619 = MUL_C(COEF_CONST(1.3870398453221475), f606); + f620 = f617 + f618; + f621 = f619 - f618; + f622 = f594 + f614; + f623 = f614 + f601; + f624 = f601 + f621; + f625 = f621 + f595; + f626 = f595 + f620; + f627 = f620 + f600; + f628 = f600 + f615; + y[5] = f496 - f615; + y[3] = f496 + f615; + y[9] = f453 - f568; + y[7] = f453 + f568; + y[13] = f502 - f628; + y[11] = f502 + f628; + y[17] = f439 - f551; + y[15] = f439 + f551; + y[21] = f508 - f627; + y[19] = f508 + f627; + y[25] = f459 - f571; + y[23] = f459 + f571; + y[29] = f514 - f626; + y[27] = f514 + f626; + y[33] = f433 - f546; + y[31] = f433 + f546; + y[37] = f515 - f625; + y[35] = f515 + f625; + y[41] = f458 - f572; + y[39] = f458 + f572; + y[45] = f509 - f624; + y[43] = f509 + f624; + y[49] = f438 - f552; + y[47] = f438 + f552; + y[53] = f503 - f623; + y[51] = f503 + f623; + y[57] = f455 - f566; + y[55] = f455 + f566; + y[61] = f497 - f622; + y[59] = f497 + f622; +} + +void DST2_64_unscaled(real_t *y, real_t *x) +{ + int16_t i0; + real_t f2, f3, f4, f5, f6, f7; + real_t f8, f9, f10, f11, f12, f13; + real_t f14, f15, f16, f17, f18, f19; + real_t f20, f21, f22, f23, f24, f25; + real_t f26, f27, f28, f29, f30, f31; + real_t f32, f33, f34, f35, f36, f37; + real_t f38, f39, f40, f41, f42, f43; + real_t f44, f45, f46, f47, f48, f49; + real_t f50, f51, f52, f53, f54, f55; + real_t f56, f57, f58, f59, f60, f61; + real_t f62, f63, f64, f65, f66, f67; + real_t f68, f69, f70, f71, f72, f73; + real_t f74, f75, f76, f77, f78, f79; + real_t f80, f81, f82, f83, f84, f85; + real_t f86, f87, f88, f89, f90, f91; + real_t f92, f93, f94, f95, f96, f97; + real_t f98, f99, f100, f101, f102, f103; + real_t f104, f105, f106, f107, f108, f109; + real_t f110, f111, f112, f113, f114, f115; + real_t f116, f117, f118, f119, f120, f121; + real_t f122, f123, f124, f125, f126, f127; + real_t f128, f129, f130, f131, f132, f133; + real_t f134, f135, f136, f137, f138, f139; + real_t f140, f141, f142, f143, f144, f145; + real_t f146, f147, f148, f149, f150, f151; + real_t f152, f153, f154, f155, f156, f157; + real_t f158, f159, f160, f161, f162, f163; + real_t f164, f165, f166, f167, f168, f169; + real_t f170, f171, f172, f173, f174, f175; + real_t f176, f177, f178, f179, f180, f181; + real_t f182, f183, f184, f185, f186, f187; + real_t f188, f189, f190, f191, f192, f193; + real_t f194, f195, f196, f197, f198, f199; + real_t f200, f201, f202, f203, f204, f205; + real_t f206, f207, f208, f209, f210, f211; + real_t f212, f213, f214, f215, f216, f217; + real_t f218, f219, f220, f221, f222, f223; + real_t f224, f225, f226, f227, f228, f229; + real_t f230, f231, f232, f233, f234, f235; + real_t f236, f237, f238, f239, f240, f241; + real_t f242, f243, f244, f245, f246, f247; + real_t f248, f249, f250, f251, f252, f253; + real_t f254, f255, f256, f257, f258, f259; + real_t f260, f261, f264, f265, f266, f267; + real_t f270, f271, f272, f273, f276, f277; + real_t f278, f279, f282, f283, f284, f285; + real_t f288, f289, f290, f291, f294, f295; + real_t f296, f297, f300, f301, f302, f303; + real_t f306, f307, f308, f309, f312, f313; + real_t f314, f315, f318, f319, f320, f321; + real_t f324, f325, f326, f327, f330, f331; + real_t f332, f333, f336, f337, f338, f339; + real_t f342, f343, f344, f345, f348, f349; + real_t f350, f351, f354, f355, f356, f357; + real_t f358, f359, f360, f361, f362, f363; + real_t f364, f365, f366, f367, f368, f369; + real_t f370, f371, f372, f373, f374, f375; + real_t f376, f377, f378, f379, f380, f381; + real_t f382, f383, f384, f385, f386, f387; + real_t f388, f389, f390, f391, f392, f393; + real_t f394, f395, f396, f397, f398, f399; + real_t f400, f401, f402, f403, f404, f405; + real_t f406, f407, f408, f409, f410, f411; + real_t f412, f413, f414, f415, f416, f417; + real_t f418, f419, f420, f421, f422, f423; + real_t f424, f425, f426, f427, f428, f429; + real_t f430, f431, f432, f433, f434, f435; + real_t f436, f437, f438, f439, f440, f441; + real_t f442, f443, f444, f445, f446, f447; + real_t f448, f449, f450, f451, f452, f453; + real_t f454, f455, f456, f457, f458, f459; + real_t f460, f461, f462, f463, f464, f465; + real_t f466, f467, f468, f469, f470, f471; + real_t f472, f473, f474, f475, f476, f477; + real_t f478, f479, f480, f481, f482, f483; + real_t f484, f485, f486, f487, f488, f489; + real_t f490, f491, f492, f493, f494, f495; + real_t f496, f497, f498, f499, f500, f501; + real_t f504, f505, f506, f507, f510, f511; + real_t f512, f513, f516, f517, f518, f519; + real_t f522, f523, f524, f525, f528, f529; + real_t f530, f531, f534, f535, f536, f537; + real_t f540, f541, f542, f543, f546, f547; + real_t f548, f549, f550, f551, f552, f553; + real_t f554, f555, f556, f557, f558, f559; + real_t f560, f561, f562, f563, f564, f565; + real_t f566, f567, f568, f569, f570, f571; + real_t f572, f573, f574, f577, f578, f579; + real_t f580, f583, f584, f585, f586, f587; + real_t f588, f589, f590, f591, f592, f593; + real_t f594, f595, f596, f597, f598, f603; + real_t f604, f605, f606, f607, f608, f609; + real_t f610, f611, f612, f613, f614, f615; + real_t f616, f617, f618, f619, f620, f621; + real_t f622, f623, f624, f625, f626, f627; + real_t f628, f629, f630, f631, f632, f633; + real_t f634, f635, f636, f637, f638, f639; + real_t f640, f641, f642, f643, f644, f645; + real_t f646, f647, f648, f649, f650; + ALIGN static real_t t2[64]; + + for (i0=0; i0<32; i0++) + { + t2[2*i0+1] = x[i0] - x[-i0+63]; + t2[2*i0] = x[i0] + x[-i0+63]; + } + f2 = t2[2] + t2[4]; + f3 = t2[4] - t2[2]; + f4 = t2[6] + t2[8]; + f5 = t2[8] - t2[6]; + f6 = t2[10] + t2[12]; + f7 = t2[12] - t2[10]; + f8 = t2[14] + t2[16]; + f9 = t2[16] - t2[14]; + f10 = t2[18] + t2[20]; + f11 = t2[20] - t2[18]; + f12 = t2[22] + t2[24]; + f13 = t2[24] - t2[22]; + f14 = t2[26] + t2[28]; + f15 = t2[28] - t2[26]; + f16 = t2[30] + t2[32]; + f17 = t2[32] - t2[30]; + f18 = t2[34] + t2[36]; + f19 = t2[36] - t2[34]; + f20 = t2[38] + t2[40]; + f21 = t2[40] - t2[38]; + f22 = t2[42] + t2[44]; + f23 = t2[44] - t2[42]; + f24 = t2[46] + t2[48]; + f25 = t2[48] - t2[46]; + f26 = t2[50] + t2[52]; + f27 = t2[52] - t2[50]; + f28 = t2[54] + t2[56]; + f29 = t2[56] - t2[54]; + f30 = t2[58] + t2[60]; + f31 = t2[60] - t2[58]; + f32 = MUL_C(COEF_CONST(0.7071067811865476), f17); + f33 = t2[0] - f32; + f34 = t2[0] + f32; + f35 = f9 + f25; + f36 = MUL_C(COEF_CONST(1.3065629648763766), f9); + f37 = MUL_C(COEF_CONST((-0.9238795325112866)), f35); + f38 = MUL_C(COEF_CONST((-0.5411961001461967)), f25); + f39 = f36 + f37; + f40 = f38 - f37; + f41 = f34 - f40; + f42 = f34 + f40; + f43 = f33 - f39; + f44 = f33 + f39; + f45 = MUL_C(COEF_CONST(2.5629154477415064), f5); + f46 = MUL_C(COEF_CONST(0.8999762231364158), f13); + f47 = MUL_C(COEF_CONST(0.5097955791041592), f29); + f48 = MUL_C(COEF_CONST(0.6013448869350453), f21); + f49 = f45 - f47; + f50 = f45 + f47; + f51 = f46 - f48; + f52 = f46 + f48; + f53 = f50 + f52; + f54 = MUL_C(COEF_CONST(1.3065629648763770), f50); + f55 = MUL_C(COEF_CONST((-0.3826834323650904)), f53); + f56 = MUL_C(COEF_CONST(0.5411961001461961), f52); + f57 = f54 + f55; + f58 = f56 - f55; + f59 = f51 - f49; + f60 = f49 + f51; + f61 = MUL_C(COEF_CONST(0.7071067811865476), f60); + f62 = f58 - f61; + f63 = f57 - f61; + f64 = f59 + f57; + f65 = f42 - f58; + f66 = f42 + f58; + f67 = f44 + f62; + f68 = f44 - f62; + f69 = f43 - f63; + f70 = f43 + f63; + f71 = f41 + f64; + f72 = f41 - f64; + f73 = f7 - f11; + f74 = f7 + f11; + f75 = f15 - f19; + f76 = f15 + f19; + f77 = f23 - f27; + f78 = f23 + f27; + f79 = MUL_C(COEF_CONST(0.7071067811865476), f76); + f80 = f3 - f79; + f81 = f3 + f79; + f82 = f74 + f78; + f83 = MUL_C(COEF_CONST(1.3065629648763766), f74); + f84 = MUL_C(COEF_CONST((-0.9238795325112866)), f82); + f85 = MUL_C(COEF_CONST((-0.5411961001461967)), f78); + f86 = f83 + f84; + f87 = f85 - f84; + f88 = f81 - f87; + f89 = f81 + f87; + f90 = f80 - f86; + f91 = f80 + f86; + f92 = MUL_C(COEF_CONST(0.7071067811865476), f75); + f93 = f31 - f92; + f94 = f31 + f92; + f95 = f77 + f73; + f96 = MUL_C(COEF_CONST(1.3065629648763766), f77); + f97 = MUL_C(COEF_CONST((-0.9238795325112866)), f95); + f98 = MUL_C(COEF_CONST((-0.5411961001461967)), f73); + f99 = f96 + f97; + f100 = f98 - f97; + f101 = f94 - f100; + f102 = f94 + f100; + f103 = f93 - f99; + f104 = f93 + f99; + f105 = f102 + f89; + f106 = MUL_C(COEF_CONST((-0.8971675863426361)), f102); + f107 = MUL_C(COEF_CONST(0.9951847266721968), f105); + f108 = MUL_C(COEF_CONST(1.0932018670017576), f89); + f109 = f106 + f107; + f110 = f108 - f107; + f111 = f91 - f104; + f112 = MUL_C(COEF_CONST((-0.6666556584777466)), f104); + f113 = MUL_C(COEF_CONST(0.9569403357322089), f111); + f114 = MUL_C(COEF_CONST(1.2472250129866713), f91); + f115 = f113 - f112; + f116 = f114 - f113; + f117 = f103 + f90; + f118 = MUL_C(COEF_CONST((-0.4105245275223571)), f103); + f119 = MUL_C(COEF_CONST(0.8819212643483549), f117); + f120 = MUL_C(COEF_CONST(1.3533180011743529), f90); + f121 = f118 + f119; + f122 = f120 - f119; + f123 = f88 - f101; + f124 = MUL_C(COEF_CONST((-0.1386171691990915)), f101); + f125 = MUL_C(COEF_CONST(0.7730104533627370), f123); + f126 = MUL_C(COEF_CONST(1.4074037375263826), f88); + f127 = f125 - f124; + f128 = f126 - f125; + f129 = f66 - f109; + f130 = f66 + f109; + f131 = f68 - f115; + f132 = f68 + f115; + f133 = f70 - f121; + f134 = f70 + f121; + f135 = f72 - f127; + f136 = f72 + f127; + f137 = f71 - f128; + f138 = f71 + f128; + f139 = f69 - f122; + f140 = f69 + f122; + f141 = f67 - f116; + f142 = f67 + f116; + f143 = f65 - f110; + f144 = f65 + f110; + f145 = f26 + f30; + f146 = f22 + f26; + f147 = f18 + f22; + f148 = f14 + f18; + f149 = f10 + f14; + f150 = f6 + f10; + f151 = f2 + f6; + f152 = MUL_C(COEF_CONST(0.7071067811865476), f148); + f153 = f152 - f30; + f154 = f30 + f152; + f155 = f146 + f150; + f156 = MUL_C(COEF_CONST(1.3065629648763766), f146); + f157 = MUL_C(COEF_CONST((-0.9238795325112866)), f155); + f158 = MUL_C(COEF_CONST((-0.5411961001461967)), f150); + f159 = f156 + f157; + f160 = f157 - f158; + f161 = f154 + f160; + f162 = f160 - f154; + f163 = f153 + f159; + f164 = f153 - f159; + f165 = f147 + f145; + f166 = f149 + f147; + f167 = f151 + f149; + f168 = MUL_C(COEF_CONST(0.7071067811865476), f166); + f169 = f168 - f145; + f170 = f145 + f168; + f171 = f165 + f167; + f172 = MUL_C(COEF_CONST(1.3065629648763766), f165); + f173 = MUL_C(COEF_CONST((-0.9238795325112866)), f171); + f174 = MUL_C(COEF_CONST((-0.5411961001461967)), f167); + f175 = f172 + f173; + f176 = f173 - f174; + f177 = f170 + f176; + f178 = f176 - f170; + f179 = f169 + f175; + f180 = f169 - f175; + f181 = MUL_C(COEF_CONST(0.5097955791041592), f178); + f182 = MUL_C(COEF_CONST(0.6013448869350453), f180); + f183 = MUL_C(COEF_CONST(0.8999762231364156), f179); + f184 = MUL_C(COEF_CONST(2.5629154477415055), f177); + f185 = f162 - f181; + f186 = f162 + f181; + f187 = f164 - f182; + f188 = f164 + f182; + f189 = f163 - f183; + f190 = f163 + f183; + f191 = f184 - f161; + f192 = f161 + f184; + f193 = MUL_C(COEF_CONST(0.5024192861881557), f186); + f194 = MUL_C(COEF_CONST(0.5224986149396889), f188); + f195 = MUL_C(COEF_CONST(0.5669440348163577), f190); + f196 = MUL_C(COEF_CONST(0.6468217833599901), f192); + f197 = MUL_C(COEF_CONST(0.7881546234512502), f191); + f198 = MUL_C(COEF_CONST(1.0606776859903471), f189); + f199 = MUL_C(COEF_CONST(1.7224470982383342), f187); + f200 = MUL_C(COEF_CONST(5.1011486186891553), f185); + f201 = MUL_C(COEF_CONST(0.7071067811865476), f16); + f202 = f201 - t2[62]; + f203 = t2[62] + f201; + f204 = f24 + f8; + f205 = MUL_C(COEF_CONST(1.3065629648763766), f24); + f206 = MUL_C(COEF_CONST((-0.9238795325112866)), f204); + f207 = MUL_C(COEF_CONST((-0.5411961001461967)), f8); + f208 = f205 + f206; + f209 = f206 - f207; + f210 = f203 + f209; + f211 = f209 - f203; + f212 = f202 + f208; + f213 = f202 - f208; + f214 = f20 + f28; + f215 = f12 + f20; + f216 = f4 + f12; + f217 = MUL_C(COEF_CONST(0.7071067811865476), f215); + f218 = f217 - f28; + f219 = f28 + f217; + f220 = f214 + f216; + f221 = MUL_C(COEF_CONST(1.3065629648763766), f214); + f222 = MUL_C(COEF_CONST((-0.9238795325112866)), f220); + f223 = MUL_C(COEF_CONST((-0.5411961001461967)), f216); + f224 = f221 + f222; + f225 = f222 - f223; + f226 = f219 + f225; + f227 = f225 - f219; + f228 = f218 + f224; + f229 = f218 - f224; + f230 = MUL_C(COEF_CONST(0.5097955791041592), f227); + f231 = MUL_C(COEF_CONST(0.6013448869350453), f229); + f232 = MUL_C(COEF_CONST(0.8999762231364156), f228); + f233 = MUL_C(COEF_CONST(2.5629154477415055), f226); + f234 = f211 - f230; + f235 = f211 + f230; + f236 = f213 - f231; + f237 = f213 + f231; + f238 = f212 - f232; + f239 = f212 + f232; + f240 = f233 - f210; + f241 = f210 + f233; + f242 = f193 - f235; + f243 = f193 + f235; + f244 = f237 - f194; + f245 = f194 + f237; + f246 = f195 - f239; + f247 = f195 + f239; + f248 = f196 - f241; + f249 = f196 + f241; + f250 = f197 - f240; + f251 = f197 + f240; + f252 = f238 - f198; + f253 = f198 + f238; + f254 = f199 - f236; + f255 = f199 + f236; + f256 = f234 - f200; + f257 = f200 + f234; + f258 = f243 + f130; + f259 = MUL_C(COEF_CONST((-0.9751575901732920)), f243); + f260 = MUL_C(COEF_CONST(0.9996988186962043), f258); + f261 = MUL_C(COEF_CONST(1.0242400472191164), f130); + y[62] = f259 + f260; + y[0] = f261 - f260; + f264 = f132 - f245; + f265 = MUL_C(COEF_CONST((-0.9237258930790228)), f245); + f266 = MUL_C(COEF_CONST(0.9972904566786902), f264); + f267 = MUL_C(COEF_CONST(1.0708550202783576), f132); + y[60] = f266 - f265; + y[2] = f267 - f266; + f270 = f247 + f134; + f271 = MUL_C(COEF_CONST((-0.8700688593994936)), f247); + f272 = MUL_C(COEF_CONST(0.9924795345987100), f270); + f273 = MUL_C(COEF_CONST(1.1148902097979263), f134); + y[58] = f271 + f272; + y[4] = f273 - f272; + f276 = f249 + f136; + f277 = MUL_C(COEF_CONST((-0.8143157536286398)), f249); + f278 = MUL_C(COEF_CONST(0.9852776423889412), f276); + f279 = MUL_C(COEF_CONST(1.1562395311492426), f136); + y[56] = f277 + f278; + y[6] = f279 - f278; + f282 = f251 + f138; + f283 = MUL_C(COEF_CONST((-0.7566008898816587)), f251); + f284 = MUL_C(COEF_CONST(0.9757021300385286), f282); + f285 = MUL_C(COEF_CONST(1.1948033701953984), f138); + y[54] = f283 + f284; + y[8] = f285 - f284; + f288 = f140 - f253; + f289 = MUL_C(COEF_CONST((-0.6970633083205414)), f253); + f290 = MUL_C(COEF_CONST(0.9637760657954398), f288); + f291 = MUL_C(COEF_CONST(1.2304888232703384), f140); + y[52] = f290 - f289; + y[10] = f291 - f290; + f294 = f255 + f142; + f295 = MUL_C(COEF_CONST((-0.6358464401941451)), f255); + f296 = MUL_C(COEF_CONST(0.9495281805930367), f294); + f297 = MUL_C(COEF_CONST(1.2632099209919283), f142); + y[50] = f295 + f296; + y[12] = f297 - f296; + f300 = f144 - f257; + f301 = MUL_C(COEF_CONST((-0.5730977622997506)), f257); + f302 = MUL_C(COEF_CONST(0.9329927988347389), f300); + f303 = MUL_C(COEF_CONST(1.2928878353697271), f144); + y[48] = f302 - f301; + y[14] = f303 - f302; + f306 = f256 + f143; + f307 = MUL_C(COEF_CONST((-0.5089684416985408)), f256); + f308 = MUL_C(COEF_CONST(0.9142097557035307), f306); + f309 = MUL_C(COEF_CONST(1.3194510697085207), f143); + y[46] = f307 + f308; + y[16] = f309 - f308; + f312 = f254 + f141; + f313 = MUL_C(COEF_CONST((-0.4436129715409087)), f254); + f314 = MUL_C(COEF_CONST(0.8932243011955153), f312); + f315 = MUL_C(COEF_CONST(1.3428356308501219), f141); + y[44] = f313 + f314; + y[18] = f315 - f314; + f318 = f252 + f139; + f319 = MUL_C(COEF_CONST((-0.3771887988789273)), f252); + f320 = MUL_C(COEF_CONST(0.8700869911087114), f318); + f321 = MUL_C(COEF_CONST(1.3629851833384954), f139); + y[42] = f319 + f320; + y[20] = f321 - f320; + f324 = f250 + f137; + f325 = MUL_C(COEF_CONST((-0.3098559453626097)), f250); + f326 = MUL_C(COEF_CONST(0.8448535652497070), f324); + f327 = MUL_C(COEF_CONST(1.3798511851368043), f137); + y[40] = f325 + f326; + y[22] = f327 - f326; + f330 = f248 + f135; + f331 = MUL_C(COEF_CONST((-0.2417766217337384)), f248); + f332 = MUL_C(COEF_CONST(0.8175848131515837), f330); + f333 = MUL_C(COEF_CONST(1.3933930045694289), f135); + y[38] = f331 + f332; + y[24] = f333 - f332; + f336 = f246 + f133; + f337 = MUL_C(COEF_CONST((-0.1731148370459794)), f246); + f338 = MUL_C(COEF_CONST(0.7883464276266062), f336); + f339 = MUL_C(COEF_CONST(1.4035780182072330), f133); + y[36] = f337 + f338; + y[26] = f339 - f338; + f342 = f244 + f131; + f343 = MUL_C(COEF_CONST((-0.1040360035527077)), f244); + f344 = MUL_C(COEF_CONST(0.7572088465064845), f342); + f345 = MUL_C(COEF_CONST(1.4103816894602612), f131); + y[34] = f343 + f344; + y[28] = f345 - f344; + f348 = f242 + f129; + f349 = MUL_C(COEF_CONST((-0.0347065382144000)), f242); + f350 = MUL_C(COEF_CONST(0.7242470829514669), f348); + f351 = MUL_C(COEF_CONST(1.4137876276885337), f129); + y[32] = f349 + f350; + y[30] = f351 - f350; + f354 = t2[1] - t2[63]; + f355 = t2[1] + t2[63]; + f356 = t2[3] - t2[61]; + f357 = t2[3] + t2[61]; + f358 = t2[5] - t2[59]; + f359 = t2[5] + t2[59]; + f360 = t2[7] - t2[57]; + f361 = t2[7] + t2[57]; + f362 = t2[9] - t2[55]; + f363 = t2[9] + t2[55]; + f364 = t2[11] - t2[53]; + f365 = t2[11] + t2[53]; + f366 = t2[13] - t2[51]; + f367 = t2[13] + t2[51]; + f368 = t2[15] - t2[49]; + f369 = t2[15] + t2[49]; + f370 = t2[17] - t2[47]; + f371 = t2[17] + t2[47]; + f372 = t2[19] - t2[45]; + f373 = t2[19] + t2[45]; + f374 = t2[21] - t2[43]; + f375 = t2[21] + t2[43]; + f376 = t2[23] - t2[41]; + f377 = t2[23] + t2[41]; + f378 = t2[25] - t2[39]; + f379 = t2[25] + t2[39]; + f380 = t2[27] - t2[37]; + f381 = t2[27] + t2[37]; + f382 = t2[29] - t2[35]; + f383 = t2[29] + t2[35]; + f384 = t2[31] - t2[33]; + f385 = t2[31] + t2[33]; + f386 = f369 + f371; + f387 = f371 - f369; + f388 = MUL_C(COEF_CONST(0.7071067811865476), f387); + f389 = MUL_C(COEF_CONST(0.7071067811865476), f386); + f390 = f363 + f377; + f391 = f363 - f377; + f392 = MUL_C(COEF_CONST(0.7071067811865476), f391); + f393 = MUL_C(COEF_CONST(0.7071067811865476), f390); + f394 = f367 + f373; + f395 = f367 - f373; + f396 = MUL_C(COEF_CONST(0.7071067811865476), f395); + f397 = MUL_C(COEF_CONST(0.7071067811865476), f394); + f398 = f365 + f375; + f399 = f375 - f365; + f400 = MUL_C(COEF_CONST(0.7071067811865476), f399); + f401 = MUL_C(COEF_CONST(0.7071067811865476), f398); + f402 = f355 - f388; + f403 = f355 + f388; + f404 = f389 - f385; + f405 = f385 + f389; + f406 = f361 + f392; + f407 = f392 - f361; + f408 = f379 - f393; + f409 = f379 + f393; + f410 = f357 + f396; + f411 = f396 - f357; + f412 = f383 - f397; + f413 = f383 + f397; + f414 = f359 - f400; + f415 = f359 + f400; + f416 = f401 - f381; + f417 = f381 + f401; + f418 = f409 + f407; + f419 = MUL_C(COEF_CONST((-0.5411961001461969)), f409); + f420 = MUL_C(COEF_CONST(0.9238795325112867), f418); + f421 = MUL_C(COEF_CONST(1.3065629648763766), f407); + f422 = f419 + f420; + f423 = f421 - f420; + f424 = f408 - f406; + f425 = MUL_C(COEF_CONST(1.3065629648763770), f408); + f426 = MUL_C(COEF_CONST((-0.3826834323650904)), f424); + f427 = MUL_C(COEF_CONST(0.5411961001461961), f406); + f428 = f425 + f426; + f429 = f426 + f427; + f430 = f415 - f417; + f431 = MUL_C(COEF_CONST((-0.5411961001461969)), f417); + f432 = MUL_C(COEF_CONST(0.9238795325112867), f430); + f433 = MUL_C(COEF_CONST(1.3065629648763766), f415); + f434 = f432 - f431; + f435 = f433 - f432; + f436 = f416 + f414; + f437 = MUL_C(COEF_CONST(1.3065629648763770), f416); + f438 = MUL_C(COEF_CONST((-0.3826834323650904)), f436); + f439 = MUL_C(COEF_CONST(0.5411961001461961), f414); + f440 = f437 + f438; + f441 = f439 - f438; + f442 = f403 - f422; + f443 = f403 + f422; + f444 = f405 + f423; + f445 = f423 - f405; + f446 = f402 - f428; + f447 = f402 + f428; + f448 = f404 + f429; + f449 = f404 - f429; + f450 = f411 - f434; + f451 = f411 + f434; + f452 = f413 - f435; + f453 = f413 + f435; + f454 = f410 + f440; + f455 = f440 - f410; + f456 = f412 - f441; + f457 = f412 + f441; + f458 = f453 + f451; + f459 = MUL_C(COEF_CONST((-0.7856949583871021)), f453); + f460 = MUL_C(COEF_CONST(0.9807852804032304), f458); + f461 = MUL_C(COEF_CONST(1.1758756024193588), f451); + f462 = f459 + f460; + f463 = f461 - f460; + f464 = f457 + f455; + f465 = MUL_C(COEF_CONST(0.2758993792829431), f457); + f466 = MUL_C(COEF_CONST(0.5555702330196022), f464); + f467 = MUL_C(COEF_CONST(1.3870398453221475), f455); + f468 = f465 + f466; + f469 = f467 - f466; + f470 = f452 + f450; + f471 = MUL_C(COEF_CONST(1.1758756024193591), f452); + f472 = MUL_C(COEF_CONST((-0.1950903220161287)), f470); + f473 = MUL_C(COEF_CONST(0.7856949583871016), f450); + f474 = f471 + f472; + f475 = f473 - f472; + f476 = f456 - f454; + f477 = MUL_C(COEF_CONST(1.3870398453221473), f456); + f478 = MUL_C(COEF_CONST((-0.8314696123025455)), f476); + f479 = MUL_C(COEF_CONST((-0.2758993792829436)), f454); + f480 = f477 + f478; + f481 = f478 + f479; + f482 = f443 - f462; + f483 = f443 + f462; + f484 = f445 - f463; + f485 = f445 + f463; + f486 = f447 - f468; + f487 = f447 + f468; + f488 = f449 - f469; + f489 = f449 + f469; + f490 = f442 - f474; + f491 = f442 + f474; + f492 = f444 + f475; + f493 = f475 - f444; + f494 = f446 - f480; + f495 = f446 + f480; + f496 = f448 + f481; + f497 = f448 - f481; + f498 = f485 + f483; + f499 = MUL_C(COEF_CONST((-0.9497277818777543)), f485); + f500 = MUL_C(COEF_CONST(0.9987954562051724), f498); + f501 = MUL_C(COEF_CONST(1.0478631305325905), f483); + y[61] = f499 + f500; + y[1] = f501 - f500; + f504 = f489 + f487; + f505 = MUL_C(COEF_CONST((-0.7270510732912801)), f489); + f506 = MUL_C(COEF_CONST(0.9700312531945440), f504); + f507 = MUL_C(COEF_CONST(1.2130114330978079), f487); + y[53] = f505 + f506; + y[9] = f507 - f506; + f510 = f493 + f491; + f511 = MUL_C(COEF_CONST((-0.4764341996931611)), f493); + f512 = MUL_C(COEF_CONST(0.9039892931234433), f510); + f513 = MUL_C(COEF_CONST(1.3315443865537255), f491); + y[45] = f511 + f512; + y[17] = f513 - f512; + f516 = f497 + f495; + f517 = MUL_C(COEF_CONST((-0.2075082269882114)), f497); + f518 = MUL_C(COEF_CONST(0.8032075314806448), f516); + f519 = MUL_C(COEF_CONST(1.3989068359730783), f495); + y[37] = f517 + f518; + y[25] = f519 - f518; + f522 = f484 + f482; + f523 = MUL_C(COEF_CONST(0.0693921705079408), f484); + f524 = MUL_C(COEF_CONST(0.6715589548470183), f522); + f525 = MUL_C(COEF_CONST(1.4125100802019774), f482); + y[29] = f523 + f524; + y[33] = f525 - f524; + f528 = f488 + f486; + f529 = MUL_C(COEF_CONST(0.3436258658070505), f488); + f530 = MUL_C(COEF_CONST(0.5141027441932217), f528); + f531 = MUL_C(COEF_CONST(1.3718313541934939), f486); + y[21] = f529 + f530; + y[41] = f531 - f530; + f534 = f490 - f492; + f535 = MUL_C(COEF_CONST(0.6046542117908007), f492); + f536 = MUL_C(COEF_CONST(0.3368898533922201), f534); + f537 = MUL_C(COEF_CONST(1.2784339185752409), f490); + y[13] = f536 - f535; + y[49] = f537 - f536; + f540 = f496 + f494; + f541 = MUL_C(COEF_CONST(0.8424460355094192), f496); + f542 = MUL_C(COEF_CONST(0.1467304744553618), f540); + f543 = MUL_C(COEF_CONST(1.1359069844201428), f494); + y[5] = f541 + f542; + y[57] = f543 - f542; + f546 = f354 + f384; + f547 = f354 - f384; + f548 = f356 + f382; + f549 = f382 - f356; + f550 = f358 + f380; + f551 = f358 - f380; + f552 = f360 + f378; + f553 = f378 - f360; + f554 = f362 + f376; + f555 = f362 - f376; + f556 = f364 + f374; + f557 = f374 - f364; + f558 = f366 + f372; + f559 = f366 - f372; + f560 = f368 + f370; + f561 = f370 - f368; + f562 = f547 - f561; + f563 = f547 + f561; + f564 = f549 - f559; + f565 = f549 + f559; + f566 = f551 - f557; + f567 = f551 + f557; + f568 = f553 - f555; + f569 = f553 + f555; + f570 = f563 - f569; + f571 = f563 + f569; + f572 = f565 - f567; + f573 = f565 + f567; + f574 = f571 - f573; + y[63] = f571 + f573; + y[31] = MUL_C(COEF_CONST(0.7071067811865476), f574); + f577 = f570 + f572; + f578 = MUL_C(COEF_CONST(1.3065629648763766), f570); + f579 = MUL_C(COEF_CONST((-0.9238795325112866)), f577); + f580 = MUL_C(COEF_CONST((-0.5411961001461967)), f572); + y[15] = f578 + f579; + y[47] = f580 - f579; + f583 = f564 + f562; + f584 = f566 + f564; + f585 = f568 + f566; + f586 = MUL_C(COEF_CONST(0.7071067811865476), f584); + f587 = f562 - f586; + f588 = f562 + f586; + f589 = f583 + f585; + f590 = MUL_C(COEF_CONST(1.3065629648763766), f583); + f591 = MUL_C(COEF_CONST((-0.9238795325112866)), f589); + f592 = MUL_C(COEF_CONST((-0.5411961001461967)), f585); + f593 = f590 + f591; + f594 = f592 - f591; + f595 = f588 - f594; + f596 = f588 + f594; + f597 = f587 - f593; + f598 = f587 + f593; + y[55] = MUL_C(COEF_CONST(0.5097955791041592), f596); + y[39] = MUL_C(COEF_CONST(0.6013448869350453), f598); + y[23] = MUL_C(COEF_CONST(0.8999762231364156), f597); + y[7] = MUL_C(COEF_CONST(2.5629154477415055), f595); + f603 = MUL_C(COEF_CONST(0.5024192861881557), f546); + f604 = MUL_C(COEF_CONST(0.5224986149396889), f548); + f605 = MUL_C(COEF_CONST(0.5669440348163577), f550); + f606 = MUL_C(COEF_CONST(0.6468217833599901), f552); + f607 = MUL_C(COEF_CONST(0.7881546234512502), f554); + f608 = MUL_C(COEF_CONST(1.0606776859903471), f556); + f609 = MUL_C(COEF_CONST(1.7224470982383342), f558); + f610 = MUL_C(COEF_CONST(5.1011486186891553), f560); + f611 = f603 + f610; + f612 = f603 - f610; + f613 = f604 + f609; + f614 = f609 - f604; + f615 = f605 + f608; + f616 = f605 - f608; + f617 = f606 + f607; + f618 = f607 - f606; + f619 = f612 - f618; + f620 = f612 + f618; + f621 = f614 - f616; + f622 = f614 + f616; + f623 = f620 - f622; + f624 = f620 + f622; + f625 = MUL_C(COEF_CONST(0.7071067811865476), f623); + f626 = f619 + f621; + f627 = MUL_C(COEF_CONST(1.3065629648763766), f619); + f628 = MUL_C(COEF_CONST((-0.9238795325112866)), f626); + f629 = MUL_C(COEF_CONST((-0.5411961001461967)), f621); + f630 = f627 + f628; + f631 = f629 - f628; + f632 = f611 - f613; + f633 = f615 - f613; + f634 = f615 - f617; + f635 = MUL_C(COEF_CONST(0.7071067811865476), f633); + f636 = f611 - f635; + f637 = f611 + f635; + f638 = f632 + f634; + f639 = MUL_C(COEF_CONST(1.3065629648763766), f632); + f640 = MUL_C(COEF_CONST((-0.9238795325112866)), f638); + f641 = MUL_C(COEF_CONST((-0.5411961001461967)), f634); + f642 = f639 + f640; + f643 = f641 - f640; + f644 = f637 - f643; + f645 = f637 + f643; + f646 = f636 - f642; + f647 = f636 + f642; + f648 = MUL_C(COEF_CONST(0.5097955791041592), f645); + f649 = MUL_C(COEF_CONST(0.6013448869350453), f647); + f650 = MUL_C(COEF_CONST(0.8999762231364156), f646); + y[3] = MUL_C(COEF_CONST(2.5629154477415055), f644); + y[59] = f624 + f648; + y[51] = f648 + f631; + y[43] = f631 + f649; + y[35] = f649 + f625; + y[27] = f625 + f650; + y[19] = f650 + f630; + y[11] = f630 + y[3]; +} + +#else + +void DCT4_64(real_t *y, real_t *x) +{ + int16_t i0; + ALIGN static real_t t2[64]; + + t2[0] = x[0]; + for (i0=0; i0<31; i0++) + { + t2[2*i0+1] = x[2*i0+1] - x[2*i0+2]; + t2[2*i0+2] = x[2*i0+1] + x[2*i0+2]; + } + t2[63] = x[63]; + + DCT4_64_kernel(y, t2); +} + +void DCT4_64_kernel(real_t *y, real_t *t2) +{ + real_t f2, f3, f4, f5, f6, f7, f8; + real_t f9, f10, f11, f12, f13, f14, f15; + real_t f16, f17, f18, f19, f20, f21, f22; + real_t f23, f24, f25, f26, f27, f28, f29; + real_t f30, f31, f32, f33, f34, f35, f36; + real_t f37, f38, f39, f40, f41, f42, f43; + real_t f44, f45, f46, f47, f48, f49, f50; + real_t f51, f52, f53, f54, f55, f56, f57; + real_t f58, f59, f60, f61, f62, f63, f64; + real_t f65, f66, f67, f68, f69, f70, f71; + real_t f72, f73, f74, f75, f76, f77, f78; + real_t f79, f80, f81, f82, f83, f84, f85; + real_t f86, f87, f88, f89, f90, f91, f92; + real_t f93, f94, f95, f96, f97, f98, f99; + real_t f100, f101, f102, f103, f104, f105, f106; + real_t f107, f108, f109, f110, f111, f112, f113; + real_t f114, f115, f116, f117, f118, f119, f120; + real_t f121, f122, f123, f124, f125, f126, f127; + real_t f128, f129, f130, f131, f132, f133, f134; + real_t f135, f136, f137, f138, f139, f140, f141; + real_t f142, f143, f144, f145, f146, f147, f148; + real_t f149, f150, f151, f152, f153, f154, f155; + real_t f156, f157, f158, f159, f160, f161, f162; + real_t f163, f164, f165, f166, f167, f168, f169; + real_t f170, f171, f172, f173, f174, f175, f176; + real_t f177, f178, f179, f180, f181, f182, f183; + real_t f184, f185, f186, f187, f188, f189, f190; + real_t f191, f192, f193, f194, f195, f196, f197; + real_t f198, f199, f200, f201, f202, f203, f204; + real_t f205, f206, f207, f208, f209, f210, f211; + real_t f212, f213, f214, f215, f216, f217, f218; + real_t f219, f220, f221, f222, f223, f224, f225; + real_t f226, f227, f228, f229, f230, f231, f232; + real_t f233, f234, f235, f236, f237, f238, f239; + real_t f240, f241, f242, f243, f244, f245, f246; + real_t f247, f248, f249, f250, f251, f252, f253; + real_t f254, f255, f256, f257, f258, f259, f260; + real_t f261, f262, f263, f264, f265, f266, f267; + real_t f268, f269, f270, f271, f272, f273, f274; + real_t f275, f276, f277, f278, f279, f280, f281; + real_t f282, f283, f284, f285, f286, f287, f288; + real_t f289, f290, f291, f292, f293, f294, f295; + real_t f296, f297, f298, f299, f300, f301, f302; + real_t f303, f304, f305, f306, f307, f308, f309; + real_t f310, f311, f312, f313, f314, f315, f316; + real_t f317, f318, f319, f320, f321, f322, f323; + real_t f324, f325, f326, f327, f328, f329, f330; + real_t f331, f332, f333, f334, f335, f336, f337; + real_t f338, f339, f340, f341, f342, f343, f344; + real_t f345, f346, f347, f348, f349, f350, f351; + real_t f352, f353, f354, f355, f356, f357, f358; + real_t f359, f360, f361, f362, f363, f364, f365; + real_t f366, f367, f368, f369, f370, f371, f372; + real_t f373, f374, f375, f376, f377, f378, f379; + real_t f380, f381, f382, f383, f384, f385, f386; + real_t f387, f388, f389, f390, f391, f392, f393; + real_t f394, f395, f396, f397, f398, f399, f400; + real_t f401, f402, f403, f404, f405, f406, f407; + real_t f408, f409, f410, f411, f412, f413, f414; + real_t f415, f416, f417, f418, f419, f420, f421; + real_t f422, f423, f424, f425, f426, f427, f428; + real_t f429, f430, f431, f432, f433, f434, f435; + real_t f436, f437, f438, f439, f440, f441, f442; + real_t f443, f444, f445, f446, f447, f448, f449; + real_t f450, f451, f452, f453, f454, f455, f456; + real_t f457, f458, f459, f460, f461, f462, f463; + real_t f464, f465, f466, f467, f468, f469, f470; + real_t f471, f472, f473, f474, f475, f476, f477; + real_t f478, f479, f480, f481, f482, f483, f484; + real_t f485, f486, f487, f488, f489, f490, f491; + real_t f492, f493, f494, f495, f496, f497, f498; + real_t f499, f500, f501, f502, f503, f504, f505; + real_t f506, f507, f508, f509, f510, f511, f512; + real_t f513, f514, f515, f516, f517, f518, f519; + real_t f520, f521, f522, f523, f524, f525, f526; + real_t f527, f528, f529, f530, f531, f532, f533; + real_t f534, f535, f536, f537, f538, f539, f540; + real_t f541, f542, f543, f544, f545, f546, f547; + real_t f548, f549, f550, f551, f552, f553, f554; + real_t f555, f556, f557, f558, f559, f560, f561; + real_t f562, f563, f564, f565, f566, f567, f568; + real_t f569, f570, f571, f572, f573, f574, f575; + real_t f576, f577, f578, f579, f580, f581, f582; + real_t f583, f584, f585, f586, f587, f588, f589; + real_t f590, f591, f592, f593, f594, f595, f596; + real_t f597, f598, f599, f600, f601, f602, f603; + real_t f604, f605, f606, f607, f608, f609, f610; + real_t f611, f612, f613, f614, f615, f618, f619; + real_t f620, f621, f624, f625, f626, f627, f630; + real_t f631, f632, f633, f636, f637, f638, f639; + real_t f642, f643, f644, f645, f648, f649, f650; + real_t f651, f654, f655, f656, f657, f660, f661; + real_t f662, f663, f666, f667, f668, f669, f672; + real_t f673, f674, f675, f678, f679, f680, f681; + real_t f684, f685, f686, f687, f690, f691, f692; + real_t f693, f696, f697, f698, f699, f702, f703; + real_t f704, f705, f708, f709, f710, f711, f714; + real_t f715, f716, f717, f720, f721, f722, f723; + real_t f726, f727, f728, f729, f732, f733, f734; + real_t f735, f738, f739, f740, f741, f744, f745; + real_t f746, f747, f750, f751, f752, f753, f756; + real_t f757, f758, f759, f762, f763, f764, f765; + real_t f768, f769, f770, f771, f774, f775, f776; + real_t f777, f780, f781, f782, f783, f786, f787; + real_t f788, f789, f792, f793, f794, f795, f798; + real_t f799, f800, f801; + + f2 = 0.7071067811865476 * t2[32]; + f3 = t2[0] - f2; + f4 = t2[0] + f2; + f5 = t2[16] + t2[48]; + f6 = 1.3065629648763766 * t2[16]; + f7 = (-0.9238795325112866) * f5; + f8 = (-0.5411961001461967) * t2[48]; + f9 = f6 + f7; + f10 = f8 - f7; + f11 = f4 - f10; + f12 = f4 + f10; + f13 = f3 - f9; + f14 = f3 + f9; + f15 = t2[8] + t2[56]; + f16 = 1.1758756024193588 * t2[8]; + f17 = (-0.9807852804032304) * f15; + f18 = (-0.7856949583871021) * t2[56]; + f19 = f16 + f17; + f20 = f18 - f17; + f21 = t2[24] + t2[40]; + f22 = 1.3870398453221473 * t2[24]; + f23 = (-0.8314696123025455) * f21; + f24 = (-0.2758993792829436) * t2[40]; + f25 = f22 + f23; + f26 = f24 - f23; + f27 = f20 - f26; + f28 = f20 + f26; + f29 = 0.7071067811865476 * f27; + f30 = f19 - f25; + f31 = f19 + f25; + f32 = 0.7071067811865476 * f31; + f33 = f29 - f32; + f34 = f29 + f32; + f35 = f12 - f28; + f36 = f12 + f28; + f37 = f14 - f34; + f38 = f14 + f34; + f39 = f13 - f33; + f40 = f13 + f33; + f41 = f11 - f30; + f42 = f11 + f30; + f43 = t2[4] + t2[60]; + f44 = 1.0932018670017569 * t2[4]; + f45 = (-0.9951847266721969) * f43; + f46 = (-0.8971675863426368) * t2[60]; + f47 = f44 + f45; + f48 = f46 - f45; + f49 = t2[12] + t2[52]; + f50 = 1.2472250129866711 * t2[12]; + f51 = (-0.9569403357322089) * f49; + f52 = (-0.6666556584777469) * t2[52]; + f53 = f50 + f51; + f54 = f52 - f51; + f55 = t2[20] + t2[44]; + f56 = 1.3533180011743526 * t2[20]; + f57 = (-0.8819212643483551) * f55; + f58 = (-0.4105245275223575) * t2[44]; + f59 = f56 + f57; + f60 = f58 - f57; + f61 = t2[28] + t2[36]; + f62 = 1.4074037375263826 * t2[28]; + f63 = (-0.7730104533627369) * f61; + f64 = (-0.1386171691990913) * t2[36]; + f65 = f62 + f63; + f66 = f64 - f63; + f67 = f48 - f66; + f68 = f48 + f66; + f69 = f54 - f60; + f70 = f54 + f60; + f71 = f68 - f70; + f72 = f68 + f70; + f73 = 0.7071067811865476 * f71; + f74 = f67 + f69; + f75 = 1.3065629648763766 * f67; + f76 = (-0.9238795325112866) * f74; + f77 = (-0.5411961001461967) * f69; + f78 = f75 + f76; + f79 = f77 - f76; + f80 = f47 - f65; + f81 = f47 + f65; + f82 = f53 - f59; + f83 = f53 + f59; + f84 = f81 + f83; + f85 = 1.3065629648763770 * f81; + f86 = (-0.3826834323650904) * f84; + f87 = 0.5411961001461961 * f83; + f88 = f85 + f86; + f89 = f87 - f86; + f90 = f80 - f82; + f91 = f80 + f82; + f92 = 0.7071067811865476 * f91; + f93 = f79 - f89; + f94 = f79 + f89; + f95 = f73 - f92; + f96 = f73 + f92; + f97 = f78 - f88; + f98 = f78 + f88; + f99 = f36 - f72; + f100 = f36 + f72; + f101 = f38 - f94; + f102 = f38 + f94; + f103 = f40 - f93; + f104 = f40 + f93; + f105 = f42 - f96; + f106 = f42 + f96; + f107 = f41 - f95; + f108 = f41 + f95; + f109 = f39 - f98; + f110 = f39 + f98; + f111 = f37 - f97; + f112 = f37 + f97; + f113 = f35 - f90; + f114 = f35 + f90; + f115 = t2[2] + t2[62]; + f116 = 1.0478631305325901 * t2[2]; + f117 = (-0.9987954562051724) * f115; + f118 = (-0.9497277818777548) * t2[62]; + f119 = f116 + f117; + f120 = f118 - f117; + f121 = t2[10] + t2[54]; + f122 = 1.2130114330978077 * t2[10]; + f123 = (-0.9700312531945440) * f121; + f124 = (-0.7270510732912803) * t2[54]; + f125 = f122 + f123; + f126 = f124 - f123; + f127 = t2[18] + t2[46]; + f128 = 1.3315443865537255 * t2[18]; + f129 = (-0.9039892931234433) * f127; + f130 = (-0.4764341996931612) * t2[46]; + f131 = f128 + f129; + f132 = f130 - f129; + f133 = t2[26] + t2[38]; + f134 = 1.3989068359730781 * t2[26]; + f135 = (-0.8032075314806453) * f133; + f136 = (-0.2075082269882124) * t2[38]; + f137 = f134 + f135; + f138 = f136 - f135; + f139 = t2[34] + t2[30]; + f140 = 1.4125100802019777 * t2[34]; + f141 = (-0.6715589548470187) * f139; + f142 = 0.0693921705079402 * t2[30]; + f143 = f140 + f141; + f144 = f142 - f141; + f145 = t2[42] + t2[22]; + f146 = 1.3718313541934939 * t2[42]; + f147 = (-0.5141027441932219) * f145; + f148 = 0.3436258658070501 * t2[22]; + f149 = f146 + f147; + f150 = f148 - f147; + f151 = t2[50] + t2[14]; + f152 = 1.2784339185752409 * t2[50]; + f153 = (-0.3368898533922200) * f151; + f154 = 0.6046542117908008 * t2[14]; + f155 = f152 + f153; + f156 = f154 - f153; + f157 = t2[58] + t2[6]; + f158 = 1.1359069844201433 * t2[58]; + f159 = (-0.1467304744553624) * f157; + f160 = 0.8424460355094185 * t2[6]; + f161 = f158 + f159; + f162 = f160 - f159; + f163 = f120 - f144; + f164 = f120 + f144; + f165 = f119 - f143; + f166 = f119 + f143; + f167 = f126 - f150; + f168 = f126 + f150; + f169 = f125 - f149; + f170 = f125 + f149; + f171 = f132 - f156; + f172 = f132 + f156; + f173 = f131 - f155; + f174 = f131 + f155; + f175 = f138 - f162; + f176 = f138 + f162; + f177 = f137 - f161; + f178 = f137 + f161; + f179 = f163 + f165; + f180 = 1.1758756024193588 * f163; + f181 = (-0.9807852804032304) * f179; + f182 = (-0.7856949583871021) * f165; + f183 = f180 + f181; + f184 = f182 - f181; + f185 = f167 + f169; + f186 = 1.3870398453221475 * f167; + f187 = (-0.5555702330196022) * f185; + f188 = 0.2758993792829431 * f169; + f189 = f186 + f187; + f190 = f188 - f187; + f191 = f171 + f173; + f192 = 0.7856949583871022 * f171; + f193 = 0.1950903220161283 * f191; + f194 = 1.1758756024193586 * f173; + f195 = f192 + f193; + f196 = f194 - f193; + f197 = f175 + f177; + f198 = (-0.2758993792829430) * f175; + f199 = 0.8314696123025452 * f197; + f200 = 1.3870398453221475 * f177; + f201 = f198 + f199; + f202 = f200 - f199; + f203 = f164 - f172; + f204 = f164 + f172; + f205 = f166 - f174; + f206 = f166 + f174; + f207 = f168 - f176; + f208 = f168 + f176; + f209 = f170 - f178; + f210 = f170 + f178; + f211 = f184 - f196; + f212 = f184 + f196; + f213 = f183 - f195; + f214 = f183 + f195; + f215 = f190 - f202; + f216 = f190 + f202; + f217 = f189 - f201; + f218 = f189 + f201; + f219 = f203 + f205; + f220 = 1.3065629648763766 * f203; + f221 = (-0.9238795325112866) * f219; + f222 = (-0.5411961001461967) * f205; + f223 = f220 + f221; + f224 = f222 - f221; + f225 = f207 + f209; + f226 = 0.5411961001461969 * f207; + f227 = 0.3826834323650898 * f225; + f228 = 1.3065629648763766 * f209; + f229 = f226 + f227; + f230 = f228 - f227; + f231 = f211 + f213; + f232 = 1.3065629648763766 * f211; + f233 = (-0.9238795325112866) * f231; + f234 = (-0.5411961001461967) * f213; + f235 = f232 + f233; + f236 = f234 - f233; + f237 = f215 + f217; + f238 = 0.5411961001461969 * f215; + f239 = 0.3826834323650898 * f237; + f240 = 1.3065629648763766 * f217; + f241 = f238 + f239; + f242 = f240 - f239; + f243 = f204 - f208; + f244 = f204 + f208; + f245 = f206 - f210; + f246 = f206 + f210; + f247 = f224 - f230; + f248 = f224 + f230; + f249 = f223 - f229; + f250 = f223 + f229; + f251 = f212 - f216; + f252 = f212 + f216; + f253 = f214 - f218; + f254 = f214 + f218; + f255 = f236 - f242; + f256 = f236 + f242; + f257 = f235 - f241; + f258 = f235 + f241; + f259 = f243 - f245; + f260 = f243 + f245; + f261 = 0.7071067811865474 * f259; + f262 = 0.7071067811865474 * f260; + f263 = f247 - f249; + f264 = f247 + f249; + f265 = 0.7071067811865474 * f263; + f266 = 0.7071067811865474 * f264; + f267 = f251 - f253; + f268 = f251 + f253; + f269 = 0.7071067811865474 * f267; + f270 = 0.7071067811865474 * f268; + f271 = f255 - f257; + f272 = f255 + f257; + f273 = 0.7071067811865474 * f271; + f274 = 0.7071067811865474 * f272; + f275 = f100 - f244; + f276 = f100 + f244; + f277 = f102 - f252; + f278 = f102 + f252; + f279 = f104 - f256; + f280 = f104 + f256; + f281 = f106 - f248; + f282 = f106 + f248; + f283 = f108 - f266; + f284 = f108 + f266; + f285 = f110 - f274; + f286 = f110 + f274; + f287 = f112 - f270; + f288 = f112 + f270; + f289 = f114 - f262; + f290 = f114 + f262; + f291 = f113 - f261; + f292 = f113 + f261; + f293 = f111 - f269; + f294 = f111 + f269; + f295 = f109 - f273; + f296 = f109 + f273; + f297 = f107 - f265; + f298 = f107 + f265; + f299 = f105 - f250; + f300 = f105 + f250; + f301 = f103 - f258; + f302 = f103 + f258; + f303 = f101 - f254; + f304 = f101 + f254; + f305 = f99 - f246; + f306 = f99 + f246; + f307 = t2[1] - t2[61]; + f308 = 1.0478631305325901 * t2[1]; + f309 = (-0.9987954562051724) * f307; + f310 = (-0.9497277818777548) * t2[61]; + f311 = f308 + f309; + f312 = f309 + f310; + f313 = t2[9] - t2[53]; + f314 = 1.2130114330978077 * t2[9]; + f315 = (-0.9700312531945440) * f313; + f316 = (-0.7270510732912803) * t2[53]; + f317 = f314 + f315; + f318 = f315 + f316; + f319 = t2[17] - t2[45]; + f320 = 1.3315443865537255 * t2[17]; + f321 = (-0.9039892931234433) * f319; + f322 = (-0.4764341996931612) * t2[45]; + f323 = f320 + f321; + f324 = f321 + f322; + f325 = t2[25] - t2[37]; + f326 = 1.3989068359730781 * t2[25]; + f327 = (-0.8032075314806453) * f325; + f328 = (-0.2075082269882124) * t2[37]; + f329 = f326 + f327; + f330 = f327 + f328; + f331 = t2[33] - t2[29]; + f332 = 1.4125100802019777 * t2[33]; + f333 = (-0.6715589548470187) * f331; + f334 = 0.0693921705079402 * t2[29]; + f335 = f332 + f333; + f336 = f333 + f334; + f337 = t2[41] - t2[21]; + f338 = 1.3718313541934939 * t2[41]; + f339 = (-0.5141027441932219) * f337; + f340 = 0.3436258658070501 * t2[21]; + f341 = f338 + f339; + f342 = f339 + f340; + f343 = t2[49] - t2[13]; + f344 = 1.2784339185752409 * t2[49]; + f345 = (-0.3368898533922200) * f343; + f346 = 0.6046542117908008 * t2[13]; + f347 = f344 + f345; + f348 = f345 + f346; + f349 = t2[57] - t2[5]; + f350 = 1.1359069844201433 * t2[57]; + f351 = (-0.1467304744553624) * f349; + f352 = 0.8424460355094185 * t2[5]; + f353 = f350 + f351; + f354 = f351 + f352; + f355 = f336 - f312; + f356 = f312 + f336; + f357 = f311 - f335; + f358 = f311 + f335; + f359 = f342 - f318; + f360 = f318 + f342; + f361 = f317 - f341; + f362 = f317 + f341; + f363 = f348 - f324; + f364 = f324 + f348; + f365 = f323 - f347; + f366 = f323 + f347; + f367 = f354 - f330; + f368 = f330 + f354; + f369 = f329 - f353; + f370 = f329 + f353; + f371 = f355 + f357; + f372 = 1.1758756024193588 * f355; + f373 = (-0.9807852804032304) * f371; + f374 = (-0.7856949583871021) * f357; + f375 = f372 + f373; + f376 = f374 - f373; + f377 = f359 + f361; + f378 = 1.3870398453221475 * f359; + f379 = (-0.5555702330196022) * f377; + f380 = 0.2758993792829431 * f361; + f381 = f378 + f379; + f382 = f380 - f379; + f383 = f363 + f365; + f384 = 0.7856949583871022 * f363; + f385 = 0.1950903220161283 * f383; + f386 = 1.1758756024193586 * f365; + f387 = f384 + f385; + f388 = f386 - f385; + f389 = f367 + f369; + f390 = (-0.2758993792829430) * f367; + f391 = 0.8314696123025452 * f389; + f392 = 1.3870398453221475 * f369; + f393 = f390 + f391; + f394 = f392 - f391; + f395 = f364 - f356; + f396 = f356 + f364; + f397 = f358 - f366; + f398 = f358 + f366; + f399 = f368 - f360; + f400 = f360 + f368; + f401 = f362 - f370; + f402 = f362 + f370; + f403 = f376 - f388; + f404 = f376 + f388; + f405 = f375 - f387; + f406 = f375 + f387; + f407 = f382 - f394; + f408 = f382 + f394; + f409 = f381 - f393; + f410 = f381 + f393; + f411 = f395 + f397; + f412 = 1.3065629648763766 * f395; + f413 = (-0.9238795325112866) * f411; + f414 = (-0.5411961001461967) * f397; + f415 = f412 + f413; + f416 = f414 - f413; + f417 = f399 + f401; + f418 = 0.5411961001461969 * f399; + f419 = 0.3826834323650898 * f417; + f420 = 1.3065629648763766 * f401; + f421 = f418 + f419; + f422 = f420 - f419; + f423 = f403 + f405; + f424 = 1.3065629648763766 * f403; + f425 = (-0.9238795325112866) * f423; + f426 = (-0.5411961001461967) * f405; + f427 = f424 + f425; + f428 = f426 - f425; + f429 = f407 + f409; + f430 = 0.5411961001461969 * f407; + f431 = 0.3826834323650898 * f429; + f432 = 1.3065629648763766 * f409; + f433 = f430 + f431; + f434 = f432 - f431; + f435 = f400 - f396; + f436 = f396 + f400; + f437 = f398 - f402; + f438 = f398 + f402; + f439 = f416 - f422; + f440 = f416 + f422; + f441 = f415 - f421; + f442 = f415 + f421; + f443 = f404 - f408; + f444 = f404 + f408; + f445 = f406 - f410; + f446 = f406 + f410; + f447 = f428 - f434; + f448 = f428 + f434; + f449 = f427 - f433; + f450 = f427 + f433; + f451 = f435 - f437; + f452 = f435 + f437; + f453 = 0.7071067811865474 * f451; + f454 = 0.7071067811865474 * f452; + f455 = f439 - f441; + f456 = f439 + f441; + f457 = 0.7071067811865474 * f455; + f458 = 0.7071067811865474 * f456; + f459 = f443 - f445; + f460 = f443 + f445; + f461 = 0.7071067811865474 * f459; + f462 = 0.7071067811865474 * f460; + f463 = f447 - f449; + f464 = f447 + f449; + f465 = 0.7071067811865474 * f463; + f466 = 0.7071067811865474 * f464; + f467 = 0.7071067811865476 * t2[31]; + f468 = t2[63] - f467; + f469 = t2[63] + f467; + f470 = t2[47] + t2[15]; + f471 = 1.3065629648763766 * t2[47]; + f472 = (-0.9238795325112866) * f470; + f473 = (-0.5411961001461967) * t2[15]; + f474 = f471 + f472; + f475 = f473 - f472; + f476 = f469 - f475; + f477 = f469 + f475; + f478 = f468 - f474; + f479 = f468 + f474; + f480 = t2[55] + t2[7]; + f481 = 1.1758756024193588 * t2[55]; + f482 = (-0.9807852804032304) * f480; + f483 = (-0.7856949583871021) * t2[7]; + f484 = f481 + f482; + f485 = f483 - f482; + f486 = t2[39] + t2[23]; + f487 = 1.3870398453221473 * t2[39]; + f488 = (-0.8314696123025455) * f486; + f489 = (-0.2758993792829436) * t2[23]; + f490 = f487 + f488; + f491 = f489 - f488; + f492 = f485 - f491; + f493 = f485 + f491; + f494 = 0.7071067811865476 * f492; + f495 = f484 - f490; + f496 = f484 + f490; + f497 = 0.7071067811865476 * f496; + f498 = f494 - f497; + f499 = f494 + f497; + f500 = f477 - f493; + f501 = f477 + f493; + f502 = f479 - f499; + f503 = f479 + f499; + f504 = f478 - f498; + f505 = f478 + f498; + f506 = f476 - f495; + f507 = f476 + f495; + f508 = t2[59] + t2[3]; + f509 = 1.0932018670017569 * t2[59]; + f510 = (-0.9951847266721969) * f508; + f511 = (-0.8971675863426368) * t2[3]; + f512 = f509 + f510; + f513 = f511 - f510; + f514 = t2[51] + t2[11]; + f515 = 1.2472250129866711 * t2[51]; + f516 = (-0.9569403357322089) * f514; + f517 = (-0.6666556584777469) * t2[11]; + f518 = f515 + f516; + f519 = f517 - f516; + f520 = t2[43] + t2[19]; + f521 = 1.3533180011743526 * t2[43]; + f522 = (-0.8819212643483551) * f520; + f523 = (-0.4105245275223575) * t2[19]; + f524 = f521 + f522; + f525 = f523 - f522; + f526 = t2[35] + t2[27]; + f527 = 1.4074037375263826 * t2[35]; + f528 = (-0.7730104533627369) * f526; + f529 = (-0.1386171691990913) * t2[27]; + f530 = f527 + f528; + f531 = f529 - f528; + f532 = f513 - f531; + f533 = f513 + f531; + f534 = f519 - f525; + f535 = f519 + f525; + f536 = f533 - f535; + f537 = f533 + f535; + f538 = 0.7071067811865476 * f536; + f539 = f532 + f534; + f540 = 1.3065629648763766 * f532; + f541 = (-0.9238795325112866) * f539; + f542 = (-0.5411961001461967) * f534; + f543 = f540 + f541; + f544 = f542 - f541; + f545 = f512 - f530; + f546 = f512 + f530; + f547 = f518 - f524; + f548 = f518 + f524; + f549 = f546 + f548; + f550 = 1.3065629648763770 * f546; + f551 = (-0.3826834323650904) * f549; + f552 = 0.5411961001461961 * f548; + f553 = f550 + f551; + f554 = f552 - f551; + f555 = f545 - f547; + f556 = f545 + f547; + f557 = 0.7071067811865476 * f556; + f558 = f544 - f554; + f559 = f544 + f554; + f560 = f538 - f557; + f561 = f538 + f557; + f562 = f543 - f553; + f563 = f543 + f553; + f564 = f501 - f537; + f565 = f501 + f537; + f566 = f503 - f559; + f567 = f503 + f559; + f568 = f505 - f558; + f569 = f505 + f558; + f570 = f507 - f561; + f571 = f507 + f561; + f572 = f506 - f560; + f573 = f506 + f560; + f574 = f504 - f563; + f575 = f504 + f563; + f576 = f502 - f562; + f577 = f502 + f562; + f578 = f500 - f555; + f579 = f500 + f555; + f580 = f438 - f565; + f581 = f438 + f565; + f582 = f446 + f567; + f583 = f446 - f567; + f584 = f450 - f569; + f585 = f450 + f569; + f586 = f442 + f571; + f587 = f442 - f571; + f588 = f457 - f573; + f589 = f457 + f573; + f590 = f465 + f575; + f591 = f465 - f575; + f592 = f461 - f577; + f593 = f461 + f577; + f594 = f453 + f579; + f595 = f453 - f579; + f596 = f454 - f578; + f597 = f454 + f578; + f598 = f462 + f576; + f599 = f462 - f576; + f600 = f466 - f574; + f601 = f466 + f574; + f602 = f458 + f572; + f603 = f458 - f572; + f604 = f440 - f570; + f605 = f440 + f570; + f606 = f448 + f568; + f607 = f448 - f568; + f608 = f444 - f566; + f609 = f444 + f566; + f610 = f564 - f436; + f611 = f436 + f564; + f612 = f581 + f276; + f613 = (-0.9876531635534246) * f581; + f614 = 0.9999247018391445 * f612; + f615 = 1.0121962401248645 * f276; + y[0] = f613 + f614; + y[63] = f615 - f614; + f618 = f583 + f278; + f619 = (-0.9625151616469906) * f583; + f620 = 0.9993223845883495 * f618; + f621 = 1.0361296075297086 * f278; + y[1] = f619 + f620; + y[62] = f621 - f620; + f624 = f585 + f280; + f625 = (-0.9367973765979405) * f585; + f626 = 0.9981181129001492 * f624; + f627 = 1.0594388492023579 * f280; + y[2] = f625 + f626; + y[61] = f627 - f626; + f630 = f587 + f282; + f631 = (-0.9105152998383381) * f587; + f632 = 0.9963126121827780 * f630; + f633 = 1.0821099245272179 * f282; + y[3] = f631 + f632; + y[60] = f633 - f632; + f636 = f589 + f284; + f637 = (-0.8836847627084729) * f589; + f638 = 0.9939069700023561 * f636; + f639 = 1.1041291772962392 * f284; + y[4] = f637 + f638; + y[59] = f639 - f638; + f642 = f591 + f286; + f643 = (-0.8563219269206538) * f591; + f644 = 0.9909026354277800 * f642; + f645 = 1.1254833439349063 * f286; + y[5] = f643 + f644; + y[58] = f645 - f644; + f648 = f593 + f288; + f649 = (-0.8284432748239970) * f593; + f650 = 0.9873014181578584 * f648; + f651 = 1.1461595614917197 * f288; + y[6] = f649 + f650; + y[57] = f651 - f650; + f654 = f595 + f290; + f655 = (-0.8000655994760753) * f595; + f656 = 0.9831054874312163 * f654; + f657 = 1.1661453753863573 * f290; + y[7] = f655 + f656; + y[56] = f657 - f656; + f660 = f597 + f292; + f661 = (-0.7712059945274091) * f597; + f662 = 0.9783173707196277 * f660; + f663 = 1.1854287469118463 * f292; + y[8] = f661 + f662; + y[55] = f663 - f662; + f666 = f599 + f294; + f667 = (-0.7418818439248888) * f599; + f668 = 0.9729399522055601 * f666; + f669 = 1.2039980604862313 * f294; + y[9] = f667 + f668; + y[54] = f669 - f668; + f672 = f601 + f296; + f673 = (-0.7121108114403374) * f601; + f674 = 0.9669764710448521 * f672; + f675 = 1.2218421306493668 * f296; + y[10] = f673 + f674; + y[53] = f675 - f674; + f678 = f603 + f298; + f679 = (-0.6819108300305128) * f603; + f680 = 0.9604305194155658 * f678; + f681 = 1.2389502088006188 * f298; + y[11] = f679 + f680; + y[52] = f681 - f680; + f684 = f605 + f300; + f685 = (-0.6513000910349656) * f605; + f686 = 0.9533060403541938 * f684; + f687 = 1.2553119896734219 * f300; + y[12] = f685 + f686; + y[51] = f687 - f686; + f690 = f607 + f302; + f691 = (-0.6202970332182582) * f607; + f692 = 0.9456073253805213 * f690; + f693 = 1.2709176175427843 * f302; + y[13] = f691 + f692; + y[50] = f693 - f692; + f696 = f609 + f304; + f697 = (-0.5889203316631404) * f609; + f698 = 0.9373390119125750 * f696; + f699 = 1.2857576921620095 * f304; + y[14] = f697 + f698; + y[49] = f699 - f698; + f702 = f306 - f611; + f703 = (-0.5571888865213779) * f611; + f704 = 0.9285060804732155 * f702; + f705 = 1.2998232744250531 * f306; + y[15] = f704 - f703; + y[48] = f705 - f704; + f708 = f610 + f305; + f709 = (-0.5251218116290097) * f610; + f710 = 0.9191138516900578 * f708; + f711 = 1.3131058917511058 * f305; + y[16] = f709 + f710; + y[47] = f711 - f710; + f714 = f608 + f303; + f715 = (-0.4927384229928850) * f608; + f716 = 0.9091679830905223 * f714; + f717 = 1.3255975431881595 * f303; + y[17] = f715 + f716; + y[46] = f717 - f716; + f720 = f606 + f301; + f721 = (-0.4600582271554261) * f606; + f722 = 0.8986744656939538 * f720; + f723 = 1.3372907042324815 * f301; + y[18] = f721 + f722; + y[45] = f723 - f722; + f726 = f604 + f299; + f727 = (-0.4271009094446139) * f604; + f728 = 0.8876396204028539 * f726; + f729 = 1.3481783313610940 * f299; + y[19] = f727 + f728; + y[44] = f729 - f728; + f732 = f602 + f297; + f733 = (-0.3938863221162838) * f602; + f734 = 0.8760700941954066 * f732; + f735 = 1.3582538662745294 * f297; + y[20] = f733 + f734; + y[43] = f735 - f734; + f738 = f600 + f295; + f739 = (-0.3604344723958691) * f600; + f740 = 0.8639728561215867 * f738; + f741 = 1.3675112398473042 * f295; + y[21] = f739 + f740; + y[42] = f741 - f740; + f744 = f598 + f293; + f745 = (-0.3267655104267964) * f598; + f746 = 0.8513551931052652 * f744; + f747 = 1.3759448757837340 * f293; + y[22] = f745 + f746; + y[41] = f747 - f746; + f750 = f596 + f291; + f751 = (-0.2928997171327915) * f596; + f752 = 0.8382247055548380 * f750; + f753 = 1.3835496939768843 * f291; + y[23] = f751 + f752; + y[40] = f753 - f752; + f756 = f594 + f289; + f757 = (-0.2588574920014121) * f594; + f758 = 0.8245893027850253 * f756; + f759 = 1.3903211135686386 * f289; + y[24] = f757 + f758; + y[39] = f759 - f758; + f762 = f592 + f287; + f763 = (-0.2246593407961559) * f592; + f764 = 0.8104571982525948 * f762; + f765 = 1.3962550557090336 * f287; + y[25] = f763 + f764; + y[38] = f765 - f764; + f768 = f590 + f285; + f769 = (-0.1903258632045579) * f590; + f770 = 0.7958369046088835 * f768; + f771 = 1.4013479460132090 * f285; + y[26] = f769 + f770; + y[37] = f771 - f770; + f774 = f588 + f283; + f775 = (-0.1558777404297079) * f588; + f776 = 0.7807372285720944 * f774; + f777 = 1.4055967167144807 * f283; + y[27] = f775 + f776; + y[36] = f777 - f776; + f780 = f586 + f281; + f781 = (-0.1213357227326675) * f586; + f782 = 0.7651672656224590 * f780; + f783 = 1.4089988085122505 * f281; + y[28] = f781 + f782; + y[35] = f783 - f782; + f786 = f584 + f279; + f787 = (-0.0867206169332875) * f584; + f788 = 0.7491363945234593 * f786; + f789 = 1.4115521721136310 * f279; + y[29] = f787 + f788; + y[34] = f789 - f788; + f792 = f582 + f277; + f793 = (-0.0520532738769597) * f582; + f794 = 0.7326542716724128 * f792; + f795 = 1.4132552694678659 * f277; + y[30] = f793 + f794; + y[33] = f795 - f794; + f798 = f580 + f275; + f799 = (-0.0173545758748457) * f580; + f800 = 0.7157308252838186 * f798; + f801 = 1.4141070746927915 * f275; + y[31] = f799 + f800; + y[32] = f801 - f800; +} + +#endif + +#endif + diff --git a/src/libfaad/sbr_dct.h b/src/libfaad/sbr_dct.h new file mode 100644 index 000000000..5dcd5d5f2 --- /dev/null +++ b/src/libfaad/sbr_dct.h @@ -0,0 +1,46 @@ +/* +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** +** This program is free software; you can redistribute it and/or modify +** it under the terms of the GNU General Public License as published by +** the Free Software Foundation; either version 2 of the License, or +** (at your option) any later version. +** +** This program is distributed in the hope that it will be useful, +** but WITHOUT ANY WARRANTY; without even the implied warranty of +** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +** GNU General Public License for more details. +** +** You should have received a copy of the GNU General Public License +** along with this program; if not, write to the Free Software +** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +** +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: sbr_dct.h,v 1.1 2003/12/30 02:00:10 miguelfreitas Exp $ +**/ + +#ifndef __SBR_DCT_H__ +#define __SBR_DCT_H__ + +#ifdef __cplusplus +extern "C" { +#endif + +void DCT3_32_unscaled(real_t *y, real_t *x); +void DCT2_64_unscaled(real_t *y, real_t *x); +void DST2_64_unscaled(real_t *y, real_t *x); +void DCT4_64(real_t *y, real_t *x); +void DCT4_64_kernel(real_t *y, real_t *t2); + + +#ifdef __cplusplus +} +#endif +#endif + diff --git a/src/libfaad/sbr_dec.c b/src/libfaad/sbr_dec.c new file mode 100644 index 000000000..625ff857d --- /dev/null +++ b/src/libfaad/sbr_dec.c @@ -0,0 +1,347 @@ +/* +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** +** This program is free software; you can redistribute it and/or modify +** it under the terms of the GNU General Public License as published by +** the Free Software Foundation; either version 2 of the License, or +** (at your option) any later version. +** +** This program is distributed in the hope that it will be useful, +** but WITHOUT ANY WARRANTY; without even the implied warranty of +** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +** GNU General Public License for more details. +** +** You should have received a copy of the GNU General Public License +** along with this program; if not, write to the Free Software +** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +** +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: sbr_dec.c,v 1.3 2003/12/30 02:00:10 miguelfreitas Exp $ +**/ + + +#include "common.h" +#include "structs.h" + +#ifdef SBR_DEC + +#include <string.h> +#include <stdlib.h> + +#include "syntax.h" +#include "bits.h" +#include "sbr_syntax.h" +#include "sbr_qmf.h" +#include "sbr_hfgen.h" +#include "sbr_hfadj.h" + + +sbr_info *sbrDecodeInit(uint16_t framelength +#ifdef DRM + , uint8_t IsDRM +#endif + ) +{ + sbr_info *sbr = faad_malloc(sizeof(sbr_info)); + memset(sbr, 0, sizeof(sbr_info)); + + sbr->bs_freq_scale = 2; + sbr->bs_alter_scale = 1; + sbr->bs_noise_bands = 2; + sbr->bs_limiter_bands = 2; + sbr->bs_limiter_gains = 2; + sbr->bs_interpol_freq = 1; + sbr->bs_smoothing_mode = 1; + sbr->bs_start_freq = 5; + sbr->bs_amp_res = 1; + sbr->bs_samplerate_mode = 1; + sbr->prevEnvIsShort[0] = -1; + sbr->prevEnvIsShort[1] = -1; + sbr->header_count = 0; + +#ifdef DRM + sbr->Is_DRM_SBR = IsDRM; +#endif + sbr->bs_samplerate_mode = 1; + sbr->tHFGen = T_HFGEN; + sbr->tHFAdj = T_HFADJ; + + /* force sbr reset */ + sbr->bs_start_freq_prev = -1; + + if (framelength == 960) + { + sbr->numTimeSlotsRate = RATE * NO_TIME_SLOTS_960; + sbr->numTimeSlots = NO_TIME_SLOTS_960; + } else { + sbr->numTimeSlotsRate = RATE * NO_TIME_SLOTS; + sbr->numTimeSlots = NO_TIME_SLOTS; + } + + return sbr; +} + +void sbrDecodeEnd(sbr_info *sbr) +{ + uint8_t j; + + if (sbr) + { + qmfa_end(sbr->qmfa[0]); + qmfs_end(sbr->qmfs[0]); + if (sbr->id_aac == ID_CPE) + { + qmfa_end(sbr->qmfa[1]); + qmfs_end(sbr->qmfs[1]); + } + + for (j = 0; j < 5; j++) + { + if (sbr->G_temp_prev[0][j]) faad_free(sbr->G_temp_prev[0][j]); + if (sbr->Q_temp_prev[0][j]) faad_free(sbr->Q_temp_prev[0][j]); + if (sbr->G_temp_prev[1][j]) faad_free(sbr->G_temp_prev[1][j]); + if (sbr->Q_temp_prev[1][j]) faad_free(sbr->Q_temp_prev[1][j]); + } + + faad_free(sbr); + } +} + +void sbr_save_prev_data(sbr_info *sbr, uint8_t ch) +{ + uint8_t i; + + /* save data for next frame */ + sbr->kx_prev = sbr->kx; + + sbr->L_E_prev[ch] = sbr->L_E[ch]; + + sbr->f_prev[ch] = sbr->f[ch][sbr->L_E[ch] - 1]; + for (i = 0; i < 64; i++) + { + sbr->E_prev[ch][i] = sbr->E[ch][i][sbr->L_E[ch] - 1]; + sbr->Q_prev[ch][i] = sbr->Q[ch][i][sbr->L_Q[ch] - 1]; + } + + for (i = 0; i < 64; i++) + { + sbr->bs_add_harmonic_prev[ch][i] = sbr->bs_add_harmonic[ch][i]; + } + sbr->bs_add_harmonic_flag_prev[ch] = sbr->bs_add_harmonic_flag[ch]; + + if (sbr->l_A[ch] == sbr->L_E[ch]) + sbr->prevEnvIsShort[ch] = 0; + else + sbr->prevEnvIsShort[ch] = -1; +} + +void sbrDecodeFrame(sbr_info *sbr, real_t *left_channel, + real_t *right_channel, + const uint8_t just_seeked, const uint8_t upsample_only) +{ + int16_t i, k, l; + + uint8_t dont_process = 0; + uint8_t ch, channels, ret; + real_t *ch_buf; + + ALIGN qmf_t X[MAX_NTSR][64]; +#ifdef SBR_LOW_POWER + ALIGN real_t deg[64]; +#endif + + bitfile *ld = NULL; + + channels = (sbr->id_aac == ID_SCE) ? 1 : 2; + + if (sbr->data == NULL || sbr->data_size == 0) + { + ret = 1; + } else { + ld = (bitfile*)faad_malloc(sizeof(bitfile)); + + /* initialise and read the bitstream */ + faad_initbits(ld, sbr->data, sbr->data_size); + +#ifdef DRM + if (sbr->Is_DRM_SBR) + faad_getbits(ld, 8); /* Skip 8-bit CRC */ +#endif + + ret = sbr_extension_data(ld, sbr); + +#ifdef DRM + /* Check CRC */ + if (sbr->Is_DRM_SBR) + ld->error = faad_check_CRC(ld, faad_get_processed_bits(ld) - 8); +#endif + + ret = ld->error ? ld->error : ret; + faad_endbits(ld); + if (ld) faad_free(ld); + ld = NULL; + } + + if (sbr->data) faad_free(sbr->data); + sbr->data = NULL; + + if (ret || (sbr->header_count == 0)) + { + /* don't process just upsample */ + dont_process = 1; + + /* Re-activate reset for next frame */ + if (ret && sbr->Reset) + sbr->bs_start_freq_prev = -1; + } + + if (just_seeked) + { + sbr->just_seeked = 1; + } else { + sbr->just_seeked = 0; + } + + for (ch = 0; ch < channels; ch++) + { + if (sbr->frame == 0) + { + uint8_t j; + sbr->qmfa[ch] = qmfa_init(32); + sbr->qmfs[ch] = qmfs_init(64); + + for (j = 0; j < 5; j++) + { + sbr->G_temp_prev[ch][j] = faad_malloc(64*sizeof(real_t)); + sbr->Q_temp_prev[ch][j] = faad_malloc(64*sizeof(real_t)); + } + + memset(sbr->Xsbr[ch], 0, (sbr->numTimeSlotsRate+sbr->tHFGen)*64 * sizeof(qmf_t)); + memset(sbr->Xcodec[ch], 0, (sbr->numTimeSlotsRate+sbr->tHFGen)*32 * sizeof(qmf_t)); + } + + if (ch == 0) + ch_buf = left_channel; + else + ch_buf = right_channel; + + /* subband analysis */ + if (dont_process) + sbr_qmf_analysis_32(sbr, sbr->qmfa[ch], ch_buf, sbr->Xcodec[ch], sbr->tHFGen, 32); + else + sbr_qmf_analysis_32(sbr, sbr->qmfa[ch], ch_buf, sbr->Xcodec[ch], sbr->tHFGen, sbr->kx); + + if (!dont_process) + { +#if 1 + /* insert high frequencies here */ + /* hf generation using patching */ + hf_generation(sbr, sbr->Xcodec[ch], sbr->Xsbr[ch] +#ifdef SBR_LOW_POWER + ,deg +#endif + ,ch); +#endif + +#ifdef SBR_LOW_POWER + for (l = sbr->t_E[ch][0]; l < sbr->t_E[ch][sbr->L_E[ch]]; l++) + { + for (k = 0; k < sbr->kx; k++) + { + QMF_RE(sbr->Xsbr[ch][sbr->tHFAdj + l][k]) = 0; + } + } +#endif + +#if 1 + /* hf adjustment */ + hf_adjustment(sbr, sbr->Xsbr[ch] +#ifdef SBR_LOW_POWER + ,deg +#endif + ,ch); +#endif + } + + if ((sbr->just_seeked != 0) || dont_process) + { + for (l = 0; l < sbr->numTimeSlotsRate; l++) + { + for (k = 0; k < 32; k++) + { + QMF_RE(X[l][k]) = QMF_RE(sbr->Xcodec[ch][l + sbr->tHFAdj][k]); +#ifndef SBR_LOW_POWER + QMF_IM(X[l][k]) = QMF_IM(sbr->Xcodec[ch][l + sbr->tHFAdj][k]); +#endif + } + for (k = 32; k < 64; k++) + { + QMF_RE(X[l][k]) = 0; +#ifndef SBR_LOW_POWER + QMF_IM(X[l][k]) = 0; +#endif + } + } + } else { + for (l = 0; l < sbr->numTimeSlotsRate; l++) + { + uint8_t xover_band; + + if (l < sbr->t_E[ch][0]) + xover_band = sbr->kx_prev; + else + xover_band = sbr->kx; + + for (k = 0; k < xover_band; k++) + { + QMF_RE(X[l][k]) = QMF_RE(sbr->Xcodec[ch][l + sbr->tHFAdj][k]); +#ifndef SBR_LOW_POWER + QMF_IM(X[l][k]) = QMF_IM(sbr->Xcodec[ch][l + sbr->tHFAdj][k]); +#endif + } + for (k = xover_band; k < 64; k++) + { + QMF_RE(X[l][k]) = QMF_RE(sbr->Xsbr[ch][l + sbr->tHFAdj][k]); +#ifndef SBR_LOW_POWER + QMF_IM(X[l][k]) = QMF_IM(sbr->Xsbr[ch][l + sbr->tHFAdj][k]); +#endif + } +#ifdef SBR_LOW_POWER + QMF_RE(X[l][xover_band - 1]) += QMF_RE(sbr->Xsbr[ch][l + sbr->tHFAdj][xover_band - 1]); +#endif + } + } + + /* subband synthesis */ +#ifndef USE_SSE + sbr_qmf_synthesis_64(sbr, sbr->qmfs[ch], X, ch_buf); +#else + sbr->qmfs[ch]->qmf_func(sbr, sbr->qmfs[ch], X, ch_buf); +#endif + + for (i = 0; i < sbr->tHFGen; i++) + { + memmove(sbr->Xcodec[ch][i], sbr->Xcodec[ch][i+sbr->numTimeSlotsRate], 32 * sizeof(qmf_t)); + memmove(sbr->Xsbr[ch][i], sbr->Xsbr[ch][i+sbr->numTimeSlotsRate], 64 * sizeof(qmf_t)); + } + } + + if (sbr->bs_header_flag) + sbr->just_seeked = 0; + + if (sbr->header_count != 0) + { + for (ch = 0; ch < channels; ch++) + sbr_save_prev_data(sbr, ch); + } + + sbr->frame++; +} + +#endif diff --git a/src/libfaad/sbr_dec.h b/src/libfaad/sbr_dec.h new file mode 100644 index 000000000..db3ba0ecd --- /dev/null +++ b/src/libfaad/sbr_dec.h @@ -0,0 +1,220 @@ +/* +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** +** This program is free software; you can redistribute it and/or modify +** it under the terms of the GNU General Public License as published by +** the Free Software Foundation; either version 2 of the License, or +** (at your option) any later version. +** +** This program is distributed in the hope that it will be useful, +** but WITHOUT ANY WARRANTY; without even the implied warranty of +** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +** GNU General Public License for more details. +** +** You should have received a copy of the GNU General Public License +** along with this program; if not, write to the Free Software +** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +** +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: sbr_dec.h,v 1.3 2003/12/30 02:00:10 miguelfreitas Exp $ +**/ + +#ifndef __SBR_DEC_H__ +#define __SBR_DEC_H__ + +#ifdef __cplusplus +extern "C" { +#endif + + +/* MAX_NTSRHFG: maximum of number_time_slots * rate + HFGen. 16*2+8 */ +#define MAX_NTSRHFG 40 +#define MAX_NTSR 32 /* max number_time_slots * rate, ok for DRM and not DRM mode */ + + +typedef struct { + real_t *x; + uint8_t channels; +} qmfa_info; + +typedef struct { + real_t *v[2]; + uint8_t v_index; + uint8_t channels; +#ifdef USE_SSE + void (*qmf_func)(void *a, void *b, void *c, void *d); +#endif +} qmfs_info; + +typedef struct +{ + uint32_t sample_rate; + + uint8_t rate; + uint8_t just_seeked; + + uint8_t amp_res[2]; + + uint8_t k0; + uint8_t kx; + uint8_t M; + uint8_t N_master; + uint8_t N_high; + uint8_t N_low; + uint8_t N_Q; + uint8_t N_L[4]; + uint8_t n[2]; + + uint8_t f_master[64]; + uint8_t f_table_res[2][64]; + uint8_t f_table_noise[64]; + uint8_t f_table_lim[4][64]; +#ifdef SBR_LOW_POWER + uint8_t f_group[5][64]; + uint8_t N_G[5]; +#endif + + uint8_t table_map_k_to_g[64]; + + uint8_t abs_bord_lead[2]; + uint8_t abs_bord_trail[2]; + uint8_t n_rel_lead[2]; + uint8_t n_rel_trail[2]; + + uint8_t L_E[2]; + uint8_t L_E_prev[2]; + uint8_t L_Q[2]; + + uint8_t t_E[2][6]; + uint8_t t_Q[2][3]; + uint8_t f[2][6]; + uint8_t f_prev[2]; + + real_t *G_temp_prev[2][5]; + real_t *Q_temp_prev[2][5]; + + int16_t E[2][64][5]; + int16_t E_prev[2][64]; + real_t E_orig[2][64][5]; + real_t E_curr[2][64][5]; + int32_t Q[2][64][2]; + int32_t Q_prev[2][64]; + real_t Q_orig[2][64][2]; + + int8_t l_A[2]; + int8_t l_A_prev[2]; + + uint8_t bs_invf_mode[2][5]; + uint8_t bs_invf_mode_prev[2][5]; + real_t bwArray[2][64]; + real_t bwArray_prev[2][64]; + + uint8_t noPatches; + uint8_t patchNoSubbands[64]; + uint8_t patchStartSubband[64]; + + uint8_t bs_add_harmonic[2][64]; + uint8_t bs_add_harmonic_prev[2][64]; + + uint16_t index_noise_prev[2]; + uint8_t psi_is_prev[2]; + + uint8_t bs_start_freq_prev; + uint8_t bs_stop_freq_prev; + uint8_t bs_xover_band_prev; + uint8_t bs_freq_scale_prev; + uint8_t bs_alter_scale_prev; + uint8_t bs_noise_bands_prev; + + int8_t prevEnvIsShort[2]; + + int8_t kx_prev; + + uint8_t Reset; + uint32_t frame; + uint32_t header_count; + + uint8_t *data; + uint16_t data_size; + + uint8_t id_aac; + qmfa_info *qmfa[2]; + qmfs_info *qmfs[2]; + + qmf_t Xsbr[2][MAX_NTSRHFG][64]; + qmf_t Xcodec[2][MAX_NTSRHFG][32]; + +#ifdef DRM + int8_t lcstereo_flag; + uint8_t bs_dataextra; + uint16_t data_size_bits; + uint8_t Is_DRM_SBR; +#endif + + uint8_t numTimeSlotsRate; + uint8_t numTimeSlots; + uint8_t tHFGen; + uint8_t tHFAdj; + + /* to get it compiling */ + /* we'll see during the coding of all the tools, whether + these are all used or not. + */ + uint8_t bs_header_flag; + uint8_t bs_crc_flag; + uint16_t bs_sbr_crc_bits; + uint8_t bs_protocol_version; + uint8_t bs_amp_res; + uint8_t bs_start_freq; + uint8_t bs_stop_freq; + uint8_t bs_xover_band; + uint8_t bs_freq_scale; + uint8_t bs_alter_scale; + uint8_t bs_noise_bands; + uint8_t bs_limiter_bands; + uint8_t bs_limiter_gains; + uint8_t bs_interpol_freq; + uint8_t bs_smoothing_mode; + uint8_t bs_samplerate_mode; + uint8_t bs_add_harmonic_flag[2]; + uint8_t bs_add_harmonic_flag_prev[2]; + uint8_t bs_extended_data; + uint8_t bs_extension_id; + uint8_t bs_extension_data; + uint8_t bs_coupling; + uint8_t bs_frame_class[2]; + uint8_t bs_rel_bord[2][9]; + uint8_t bs_rel_bord_0[2][9]; + uint8_t bs_rel_bord_1[2][9]; + uint8_t bs_pointer[2]; + uint8_t bs_abs_bord_0[2]; + uint8_t bs_abs_bord_1[2]; + uint8_t bs_num_rel_0[2]; + uint8_t bs_num_rel_1[2]; + uint8_t bs_df_env[2][9]; + uint8_t bs_df_noise[2][3]; +} sbr_info; + +sbr_info *sbrDecodeInit(uint16_t framelength +#ifdef DRM + , uint8_t IsDRM +#endif + ); +void sbrDecodeEnd(sbr_info *sbr); + +void sbrDecodeFrame(sbr_info *sbr, real_t *left_channel, + real_t *right_channel, + const uint8_t just_seeked, const uint8_t upsample_only); + + +#ifdef __cplusplus +} +#endif +#endif + diff --git a/src/libfaad/sbr_e_nf.c b/src/libfaad/sbr_e_nf.c new file mode 100644 index 000000000..730eb258f --- /dev/null +++ b/src/libfaad/sbr_e_nf.c @@ -0,0 +1,370 @@ +/* +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** +** This program is free software; you can redistribute it and/or modify +** it under the terms of the GNU General Public License as published by +** the Free Software Foundation; either version 2 of the License, or +** (at your option) any later version. +** +** This program is distributed in the hope that it will be useful, +** but WITHOUT ANY WARRANTY; without even the implied warranty of +** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +** GNU General Public License for more details. +** +** You should have received a copy of the GNU General Public License +** along with this program; if not, write to the Free Software +** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +** +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: sbr_e_nf.c,v 1.1 2003/12/30 02:00:10 miguelfreitas Exp $ +**/ + +#include "common.h" +#include "structs.h" + +#ifdef SBR_DEC + +#include <stdlib.h> + +#include "sbr_syntax.h" +#include "sbr_e_nf.h" + +ALIGN static const real_t pow2deq[] = { + REAL_CONST(2.9103830456733704E-011), REAL_CONST(5.8207660913467407E-011), + REAL_CONST(1.1641532182693481E-010), REAL_CONST(2.3283064365386963E-010), + REAL_CONST(4.6566128730773926E-010), REAL_CONST(9.3132257461547852E-010), + REAL_CONST(1.862645149230957E-009), REAL_CONST(3.7252902984619141E-009), + REAL_CONST(7.4505805969238281E-009), REAL_CONST(1.4901161193847656E-008), + REAL_CONST(2.9802322387695313E-008), REAL_CONST(5.9604644775390625E-008), + REAL_CONST(1.1920928955078125E-007), REAL_CONST(2.384185791015625E-007), + REAL_CONST(4.76837158203125E-007), REAL_CONST(9.5367431640625E-007), + REAL_CONST(1.9073486328125E-006), REAL_CONST(3.814697265625E-006), + REAL_CONST(7.62939453125E-006), REAL_CONST(1.52587890625E-005), + REAL_CONST(3.0517578125E-005), REAL_CONST(6.103515625E-005), + REAL_CONST(0.0001220703125), REAL_CONST(0.000244140625), + REAL_CONST(0.00048828125), REAL_CONST(0.0009765625), + REAL_CONST(0.001953125), REAL_CONST(0.00390625), + REAL_CONST(0.0078125), REAL_CONST(0.015625), + REAL_CONST(0.03125), REAL_CONST(0.0625), + REAL_CONST(0.125), REAL_CONST(0.25), + REAL_CONST(0.5), REAL_CONST(1), + REAL_CONST(2), REAL_CONST(4), + REAL_CONST(8), REAL_CONST(16), + REAL_CONST(32), REAL_CONST(64), + REAL_CONST(128), REAL_CONST(256), + REAL_CONST(512), REAL_CONST(1024), + REAL_CONST(2048), REAL_CONST(4096), + REAL_CONST(8192), REAL_CONST(16384), + REAL_CONST(32768), REAL_CONST(65536), + REAL_CONST(131072), REAL_CONST(262144), + REAL_CONST(524288), REAL_CONST(1048576), + REAL_CONST(2097152), REAL_CONST(4194304), + REAL_CONST(8388608), REAL_CONST(16777216), + REAL_CONST(33554432), REAL_CONST(67108864), + REAL_CONST(134217728), REAL_CONST(268435456), + REAL_CONST(536870912), REAL_CONST(1073741824), + REAL_CONST(2147483648), REAL_CONST(4294967296), + REAL_CONST(8589934592), REAL_CONST(17179869184), + REAL_CONST(34359738368), REAL_CONST(68719476736), + REAL_CONST(137438953472), REAL_CONST(274877906944), + REAL_CONST(549755813888), REAL_CONST(1099511627776), + REAL_CONST(2199023255552), REAL_CONST(4398046511104), + REAL_CONST(8796093022208), REAL_CONST(17592186044416), + REAL_CONST(35184372088832), REAL_CONST(70368744177664), + REAL_CONST(140737488355328), REAL_CONST(281474976710656), + REAL_CONST(562949953421312), REAL_CONST(1125899906842624), + REAL_CONST(2251799813685248), REAL_CONST(4503599627370496), + REAL_CONST(9007199254740992), REAL_CONST(18014398509481984), + REAL_CONST(36028797018963968), REAL_CONST(72057594037927936), + REAL_CONST(144115188075855870), REAL_CONST(288230376151711740), + REAL_CONST(576460752303423490), REAL_CONST(1152921504606847000), + REAL_CONST(2305843009213694000), REAL_CONST(4611686018427387900), + REAL_CONST(9223372036854775800), REAL_CONST(1.8446744073709552E+019), + REAL_CONST(3.6893488147419103E+019), REAL_CONST(7.3786976294838206E+019), + REAL_CONST(1.4757395258967641E+020), REAL_CONST(2.9514790517935283E+020), + REAL_CONST(5.9029581035870565E+020), REAL_CONST(1.1805916207174113E+021), + REAL_CONST(2.3611832414348226E+021), REAL_CONST(4.7223664828696452E+021), + REAL_CONST(9.4447329657392904E+021), REAL_CONST(1.8889465931478581E+022), + REAL_CONST(3.7778931862957162E+022), REAL_CONST(7.5557863725914323E+022), + REAL_CONST(1.5111572745182865E+023), REAL_CONST(3.0223145490365729E+023), + REAL_CONST(6.0446290980731459E+023), REAL_CONST(1.2089258196146292E+024), + REAL_CONST(2.4178516392292583E+024), REAL_CONST(4.8357032784585167E+024), + REAL_CONST(9.6714065569170334E+024), REAL_CONST(1.9342813113834067E+025), + REAL_CONST(3.8685626227668134E+025), REAL_CONST(7.7371252455336267E+025), + REAL_CONST(1.5474250491067253E+026), REAL_CONST(3.0948500982134507E+026), + REAL_CONST(6.1897001964269014E+026), REAL_CONST(1.2379400392853803E+027), + REAL_CONST(2.4758800785707605E+027) +}; + +/* 1.0 / (1.0 + pow(2.0, x - 12) */ +ALIGN static const real_t pow2deq_rcp[] = { + FRAC_CONST(0.99975591896509641), + FRAC_CONST(0.99951195705222062), + FRAC_CONST(0.99902439024390244), + FRAC_CONST(0.99805068226120852), + FRAC_CONST(0.99610894941634243), + FRAC_CONST(0.99224806201550386), + FRAC_CONST(0.98461538461538467), + FRAC_CONST(0.96969696969696972), + FRAC_CONST(0.94117647058823528), + FRAC_CONST(0.88888888888888884), + FRAC_CONST(0.80000000000000004), + FRAC_CONST(0.66666666666666663), + FRAC_CONST(0.5), + FRAC_CONST(0.33333333333333331), + FRAC_CONST(0.20000000000000001), + FRAC_CONST(0.1111111111111111), + FRAC_CONST(0.058823529411764705), + FRAC_CONST(0.030303030303030304), + FRAC_CONST(0.015384615384615385), + FRAC_CONST(0.0077519379844961239), + FRAC_CONST(0.0038910505836575876), + FRAC_CONST(0.0019493177387914229), + FRAC_CONST(0.00097560975609756097), + FRAC_CONST(0.0004880429477794046), + FRAC_CONST(0.00024408103490358799), + FRAC_CONST(0.00012205541315757354), + FRAC_CONST(6.1031431187061336E-005), + FRAC_CONST(3.0516646830846227E-005), + FRAC_CONST(1.5258556235409006E-005), + FRAC_CONST(7.6293363240331724E-006), + FRAC_CONST(3.8146827137652828E-006), + FRAC_CONST(1.9073449948406318E-006), + FRAC_CONST(9.5367340691241559E-007) +}; + +void extract_envelope_data(sbr_info *sbr, uint8_t ch) +{ + uint8_t l, k; + + for (l = 0; l < sbr->L_E[ch]; l++) + { + if (sbr->bs_df_env[ch][l] == 0) + { + for (k = 1; k < sbr->n[sbr->f[ch][l]]; k++) + { + sbr->E[ch][k][l] = sbr->E[ch][k - 1][l] + sbr->E[ch][k][l]; + } + + } else { /* bs_df_env == 1 */ + + uint8_t g = (l == 0) ? sbr->f_prev[ch] : sbr->f[ch][l-1]; + int16_t E_prev; + + if (sbr->f[ch][l] == g) + { + for (k = 0; k < sbr->n[sbr->f[ch][l]]; k++) + { + if (l == 0) + E_prev = sbr->E_prev[ch][k]; + else + E_prev = sbr->E[ch][k][l - 1]; + + sbr->E[ch][k][l] = E_prev + sbr->E[ch][k][l]; + } + + } else if ((g == 1) && (sbr->f[ch][l] == 0)) { + uint8_t i; + + for (k = 0; k < sbr->n[sbr->f[ch][l]]; k++) + { + for (i = 0; i < sbr->N_high; i++) + { + if (sbr->f_table_res[HI_RES][i] == sbr->f_table_res[LO_RES][k]) + { + if (l == 0) + E_prev = sbr->E_prev[ch][i]; + else + E_prev = sbr->E[ch][i][l - 1]; + + sbr->E[ch][k][l] = E_prev + sbr->E[ch][k][l]; + } + } + } + + } else if ((g == 0) && (sbr->f[ch][l] == 1)) { + uint8_t i; + + for (k = 0; k < sbr->n[sbr->f[ch][l]]; k++) + { + for (i = 0; i < sbr->N_low; i++) + { + if ((sbr->f_table_res[LO_RES][i] <= sbr->f_table_res[HI_RES][k]) && + (sbr->f_table_res[HI_RES][k] < sbr->f_table_res[LO_RES][i + 1])) + { + if (l == 0) + E_prev = sbr->E_prev[ch][i]; + else + E_prev = sbr->E[ch][i][l - 1]; + + sbr->E[ch][k][l] = E_prev + sbr->E[ch][k][l]; + } + } + } + } + } + } +} + +void extract_noise_floor_data(sbr_info *sbr, uint8_t ch) +{ + uint8_t l, k; + + for (l = 0; l < sbr->L_Q[ch]; l++) + { + if (sbr->bs_df_noise[ch][l] == 0) + { + for (k = 1; k < sbr->N_Q; k++) + { + sbr->Q[ch][k][l] = sbr->Q[ch][k][l] + sbr->Q[ch][k-1][l]; + } + } else { + if (l == 0) + { + for (k = 0; k < sbr->N_Q; k++) + { + sbr->Q[ch][k][l] = sbr->Q_prev[ch][k] + sbr->Q[ch][k][0]; + } + } else { + for (k = 0; k < sbr->N_Q; k++) + { + sbr->Q[ch][k][l] = sbr->Q[ch][k][l - 1] + sbr->Q[ch][k][l]; + } + } + } + } +} + +void envelope_noise_dequantisation(sbr_info *sbr, uint8_t ch) +{ + if (sbr->bs_coupling == 0) + { + int16_t exp; + uint8_t l, k; + uint8_t amp = (sbr->amp_res[ch]) ? 0 : 1; + + for (l = 0; l < sbr->L_E[ch]; l++) + { + for (k = 0; k < sbr->n[sbr->f[ch][l]]; k++) + { + /* +6 for the *64 and -10 for the /32 in the synthesis QMF + * since this is a energy value: (x/32)^2 = (x^2)/1024 + */ + exp = (sbr->E[ch][k][l] >> amp) + 6 +#ifdef FIXED_POINT + - 10 +#endif + ; + + if ((exp < -P2_TABLE_OFFSET) || (exp > P2_TABLE_MAX)) + { + sbr->E_orig[ch][k][l] = 0; + } else { + /* FIXED POINT TODO: E_orig: INTEGER!! */ + sbr->E_orig[ch][k][l] = pow2deq[exp + P2_TABLE_OFFSET]; + + /* save half the table size at the cost of 1 multiply */ + if (amp && (sbr->E[ch][k][l] & 1)) + { + sbr->E_orig[ch][k][l] = MUL_R(sbr->E_orig[ch][k][l], REAL_CONST(1.414213562)); + } + } + } + } + + for (l = 0; l < sbr->L_Q[ch]; l++) + { + for (k = 0; k < sbr->N_Q; k++) + { + if (sbr->Q[ch][k][l] < 0 || sbr->Q[ch][k][l] > 30) + { + sbr->Q_orig[ch][k][l] = 0; + } else { + exp = NOISE_FLOOR_OFFSET - sbr->Q[ch][k][l]; +#ifdef FIXED_POINT + sbr->Q_orig[ch][k][l] = pow2deq_q[exp + P2Q_TABLE_OFFSET]; +#else + sbr->Q_orig[ch][k][l] = pow2deq[exp + P2_TABLE_OFFSET]; +#endif + } + } + } + } +} + +void unmap_envelope_noise(sbr_info *sbr) +{ + real_t tmp; + int16_t exp0, exp1; + uint8_t l, k; + uint8_t amp0 = (sbr->amp_res[0]) ? 0 : 1; + uint8_t amp1 = (sbr->amp_res[1]) ? 0 : 1; + + for (l = 0; l < sbr->L_E[0]; l++) + { + for (k = 0; k < sbr->n[sbr->f[0][l]]; k++) + { + /* +6: * 64 ; +1: * 2 ; -10: /1024 QMF */ + exp0 = (sbr->E[0][k][l] >> amp0) + 7 +#ifdef FIXED_POINT + - 10 +#endif + ; + /* UN_MAP removed: (x / 4096) same as (x >> 12) */ + /* E[1] is always even so no need for compensating the divide by 2 with + * an extra multiplication + */ + exp1 = (sbr->E[1][k][l] >> amp1) - 12; + + if ((exp0 < -P2_TABLE_OFFSET) || (exp0 > P2_TABLE_MAX) || + (exp1 < -P2_TABLE_RCP_OFFSET) || (exp1 > P2_TABLE_RCP_MAX)) + { + sbr->E_orig[1][k][l] = 0; + sbr->E_orig[0][k][l] = 0; + } else { + tmp = pow2deq[exp0 + P2_TABLE_OFFSET]; + if (amp0 && (sbr->E[0][k][l] & 1)) + tmp = MUL_R(tmp, REAL_CONST(1.414213562)); + + /* FIXED POINT TODO: E_orig: INTEGER!! */ + sbr->E_orig[1][k][l] = MUL_F(tmp, pow2deq_rcp[exp1 + P2_TABLE_RCP_OFFSET]); +#ifdef FIXED_POINT + sbr->E_orig[0][k][l] = MUL_R(sbr->E_orig[1][k][l], pow2deq[exp1 + P2_TABLE_OFFSET]); +#else + sbr->E_orig[0][k][l] = MUL_R(sbr->E_orig[1][k][l], pow2deq[exp1 + P2_TABLE_OFFSET]); +#endif + } + } + } + for (l = 0; l < sbr->L_Q[0]; l++) + { + for (k = 0; k < sbr->N_Q; k++) + { + if ((sbr->Q[0][k][l] < 0 || sbr->Q[0][k][l] > 30) || + (sbr->Q[1][k][l] < 0 || sbr->Q[1][k][l] > 24 /* 2*panOffset(1) */)) + { + sbr->Q_orig[0][k][l] = 0; + sbr->Q_orig[1][k][l] = 0; + } else { + exp0 = NOISE_FLOOR_OFFSET - sbr->Q[0][k][l] + 1; + exp1 = sbr->Q[1][k][l] - 12; + +#ifdef FIXED_POINT + sbr->Q_orig[1][k][l] = MUL_F(pow2deq_q[exp0 + P2Q_TABLE_OFFSET], pow2deq_rcp[exp1 + P2_TABLE_RCP_OFFSET]); + sbr->Q_orig[0][k][l] = MUL_R(sbr->Q_orig[1][k][l], pow2deq_q[exp1 + P2Q_TABLE_OFFSET]); +#else + sbr->Q_orig[1][k][l] = MUL_F(pow2deq[exp0 + P2_TABLE_OFFSET], pow2deq_rcp[exp1 + P2_TABLE_RCP_OFFSET]); + sbr->Q_orig[0][k][l] = MUL_R(sbr->Q_orig[1][k][l], pow2deq[exp1 + P2_TABLE_OFFSET]); +#endif + } + } + } +} + +#endif diff --git a/src/libfaad/sbr_e_nf.h b/src/libfaad/sbr_e_nf.h new file mode 100644 index 000000000..3e0ce399e --- /dev/null +++ b/src/libfaad/sbr_e_nf.h @@ -0,0 +1,58 @@ +/* +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** +** This program is free software; you can redistribute it and/or modify +** it under the terms of the GNU General Public License as published by +** the Free Software Foundation; either version 2 of the License, or +** (at your option) any later version. +** +** This program is distributed in the hope that it will be useful, +** but WITHOUT ANY WARRANTY; without even the implied warranty of +** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +** GNU General Public License for more details. +** +** You should have received a copy of the GNU General Public License +** along with this program; if not, write to the Free Software +** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +** +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: sbr_e_nf.h,v 1.1 2003/12/30 02:00:10 miguelfreitas Exp $ +**/ + +#ifndef __SBR_E_NF_H__ +#define __SBR_E_NF_H__ + +#ifdef __cplusplus +extern "C" { +#endif + + +#ifndef FIXED_POINT +#define P2_TABLE_OFFSET 35 +#define P2_TABLE_MAX 91 +#else +#define P2Q_TABLE_OFFSET 24 +#define P2Q_TABLE_MAX 7 +#define P2_TABLE_OFFSET 0 +#define P2_TABLE_MAX 31 +#endif +#define P2_TABLE_RCP_OFFSET 12 +#define P2_TABLE_RCP_MAX 21 + + +void extract_envelope_data(sbr_info *sbr, uint8_t ch); +void extract_noise_floor_data(sbr_info *sbr, uint8_t ch); +void envelope_noise_dequantisation(sbr_info *sbr, uint8_t ch); +void unmap_envelope_noise(sbr_info *sbr); + +#ifdef __cplusplus +} +#endif +#endif + diff --git a/src/libfaad/sbr_fbt.c b/src/libfaad/sbr_fbt.c new file mode 100644 index 000000000..88a2b29f2 --- /dev/null +++ b/src/libfaad/sbr_fbt.c @@ -0,0 +1,623 @@ +/* +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** +** This program is free software; you can redistribute it and/or modify +** it under the terms of the GNU General Public License as published by +** the Free Software Foundation; either version 2 of the License, or +** (at your option) any later version. +** +** This program is distributed in the hope that it will be useful, +** but WITHOUT ANY WARRANTY; without even the implied warranty of +** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +** GNU General Public License for more details. +** +** You should have received a copy of the GNU General Public License +** along with this program; if not, write to the Free Software +** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +** +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: sbr_fbt.c,v 1.1 2003/12/30 02:00:10 miguelfreitas Exp $ +**/ + +/* Calculate frequency band tables */ + +#include "common.h" +#include "structs.h" + +#ifdef SBR_DEC + +#include <stdlib.h> + +#include "sbr_syntax.h" +#include "sbr_fbt.h" + +/* calculate the start QMF channel for the master frequency band table */ +/* parameter is also called k0 */ +uint8_t qmf_start_channel(uint8_t bs_start_freq, uint8_t bs_samplerate_mode, + uint32_t sample_rate) +{ + static const uint8_t startMinTable[12] = { 7, 7, 10, 11, 12, 16, 16, + 17, 24, 32, 35, 48 }; + static const uint8_t offsetIndexTable[12] = { 5, 5, 4, 4, 4, 3, 2, 1, 0, + 6, 6, 6 }; + static const int8_t offset[7][16] = { + { -8, -7, -6, -5, -4, -3, -2, -1, 0, 1, 2, 3, 4, 5, 6, 7 }, + { -5, -4, -3, -2, -1, 0, 1, 2, 3, 4, 5, 6, 7, 9, 11, 13 }, + { -5, -3, -2, -1, 0, 1, 2, 3, 4, 5, 6, 7, 9, 11, 13, 16 }, + { -6, -4, -2, -1, 0, 1, 2, 3, 4, 5, 6, 7, 9, 11, 13, 16 }, + { -4, -2, -1, 0, 1, 2, 3, 4, 5, 6, 7, 9, 11, 13, 16, 20 }, + { -2, -1, 0, 1, 2, 3, 4, 5, 6, 7, 9, 11, 13, 16, 20, 24 }, + { 0, 1, 2, 3, 4, 5, 6, 7, 9, 11, 13, 16, 20, 24, 28, 33 } + }; + uint8_t startMin = startMinTable[get_sr_index(sample_rate)]; + uint8_t offsetIndex = offsetIndexTable[get_sr_index(sample_rate)]; + +#if 0 /* replaced with table (startMinTable) */ + if (sample_rate >= 64000) + { + startMin = (uint8_t)((5000.*128.)/(float)sample_rate + 0.5); + } else if (sample_rate < 32000) { + startMin = (uint8_t)((3000.*128.)/(float)sample_rate + 0.5); + } else { + startMin = (uint8_t)((4000.*128.)/(float)sample_rate + 0.5); + } +#endif + + if (bs_samplerate_mode) + { + return startMin + offset[offsetIndex][bs_start_freq]; + +#if 0 /* replaced by offsetIndexTable */ + switch (sample_rate) + { + case 16000: + return startMin + offset[0][bs_start_freq]; + case 22050: + return startMin + offset[1][bs_start_freq]; + case 24000: + return startMin + offset[2][bs_start_freq]; + case 32000: + return startMin + offset[3][bs_start_freq]; + default: + if (sample_rate > 64000) + { + return startMin + offset[5][bs_start_freq]; + } else { /* 44100 <= sample_rate <= 64000 */ + return startMin + offset[4][bs_start_freq]; + } + } +#endif + } else { + return startMin + offset[6][bs_start_freq]; + } +} + +static int longcmp(const void *a, const void *b) +{ + return ((int)(*(int32_t*)a - *(int32_t*)b)); +} + +/* calculate the stop QMF channel for the master frequency band table */ +/* parameter is also called k2 */ +uint8_t qmf_stop_channel(uint8_t bs_stop_freq, uint32_t sample_rate, + uint8_t k0) +{ + if (bs_stop_freq == 15) + { + return min(64, k0 * 3); + } else if (bs_stop_freq == 14) { + return min(64, k0 * 2); + } else { + static const uint8_t stopMinTable[12] = { 13, 15, 20, 21, 23, + 32, 32, 35, 48, 64, 70, 96 }; + static const int8_t offset[12][14] = { + { 0, 2, 4, 6, 8, 11, 14, 18, 22, 26, 31, 37, 44, 51 }, + { 0, 2, 4, 6, 8, 11, 14, 18, 22, 26, 31, 36, 42, 49 }, + { 0, 2, 4, 6, 8, 11, 14, 17, 21, 25, 29, 34, 39, 44 }, + { 0, 2, 4, 6, 8, 11, 14, 17, 20, 24, 28, 33, 38, 43 }, + { 0, 2, 4, 6, 8, 11, 14, 17, 20, 24, 28, 32, 36, 41 }, + { 0, 2, 4, 6, 8, 10, 12, 14, 17, 20, 23, 26, 29, 32 }, + { 0, 2, 4, 6, 8, 10, 12, 14, 17, 20, 23, 26, 29, 32 }, + { 0, 1, 3, 5, 7, 9, 11, 13, 15, 17, 20, 23, 26, 29 }, + { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 14, 16 }, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, -1, -2, -3, -4, -5, -6, -6, -6, -6, -6, -6, -6, -6 }, + { 0, -3, -6, -9, -12, -15, -18, -20, -22, -24, -26, -28, -30, -32 } + }; +#if 0 + uint8_t i; + int32_t stopDk[13], stopDk_t[14], k2; +#endif + uint8_t stopMin = stopMinTable[get_sr_index(sample_rate)]; + +#if 0 /* replaced by table lookup */ + if (sample_rate >= 64000) + { + stopMin = (uint8_t)((10000.*128.)/(float)sample_rate + 0.5); + } else if (sample_rate < 32000) { + stopMin = (uint8_t)((6000.*128.)/(float)sample_rate + 0.5); + } else { + stopMin = (uint8_t)((8000.*128.)/(float)sample_rate + 0.5); + } +#endif + +#if 0 /* replaced by table lookup */ + /* diverging power series */ + for (i = 0; i <= 13; i++) + { + stopDk_t[i] = (int32_t)(stopMin*pow(64.0/stopMin, i/13.0) + 0.5); + } + for (i = 0; i < 13; i++) + { + stopDk[i] = stopDk_t[i+1] - stopDk_t[i]; + } + + /* needed? */ + qsort(stopDk, 13, sizeof(stopDk[0]), longcmp); + + k2 = stopMin; + for (i = 0; i < bs_stop_freq; i++) + { + k2 += stopDk[i]; + } + return min(64, k2); +#endif + /* bs_stop_freq <= 13 */ + return min(64, stopMin + offset[get_sr_index(sample_rate)][min(bs_stop_freq, 13)]); + } + + return 0; +} + +/* calculate the master frequency table from k0, k2, bs_freq_scale + and bs_alter_scale + + version for bs_freq_scale = 0 +*/ +void master_frequency_table_fs0(sbr_info *sbr, uint8_t k0, uint8_t k2, + uint8_t bs_alter_scale) +{ + int8_t incr; + uint8_t k; + uint8_t dk; + uint32_t nrBands, k2Achieved; + int32_t k2Diff, vDk[64] = {0}; + + /* mft only defined for k2 > k0 */ + if (k2 <= k0) + { + sbr->N_master = 0; + return; + } + + dk = bs_alter_scale ? 2 : 1; + +#if 0 /* replaced by float-less design */ + nrBands = 2 * (int32_t)((float)(k2-k0)/(dk*2) + (-1+dk)/2.0f); +#else + if (bs_alter_scale) + { + nrBands = (((k2-k0+2)>>2)<<1); + } else { + nrBands = (((k2-k0)>>1)<<1); + } +#endif + nrBands = min(nrBands, 63); + + k2Achieved = k0 + nrBands * dk; + k2Diff = k2 - k2Achieved; + for (k = 0; k < nrBands; k++) + vDk[k] = dk; + + if (k2Diff) + { + incr = (k2Diff > 0) ? -1 : 1; + k = (k2Diff > 0) ? (nrBands-1) : 0; + + while (k2Diff != 0) + { + vDk[k] -= incr; + k += incr; + k2Diff += incr; + } + } + + sbr->f_master[0] = k0; + for (k = 1; k <= nrBands; k++) + sbr->f_master[k] = sbr->f_master[k-1] + vDk[k-1]; + + sbr->N_master = nrBands; + sbr->N_master = min(sbr->N_master, 64); + +#if 0 + printf("f_master[%d]: ", nrBands); + for (k = 0; k <= nrBands; k++) + { + printf("%d ", sbr->f_master[k]); + } + printf("\n"); +#endif +} + +/* + This function finds the number of bands using this formula: + bands * log(a1/a0)/log(2.0) + 0.5 +*/ +static int32_t find_bands(uint8_t warp, uint8_t bands, uint8_t a0, uint8_t a1) +{ + real_t div = (real_t)log(2.0); + if (warp) div *= (real_t)1.3; + + return (int32_t)(bands * log((float)a1/(float)a0)/div + 0.5); +} + +static real_t find_initial_power(uint8_t bands, uint8_t a0, uint8_t a1) +{ + return (real_t)pow((real_t)a1/(real_t)a0, 1.0/(real_t)bands); +} + +/* + version for bs_freq_scale > 0 +*/ +void master_frequency_table(sbr_info *sbr, uint8_t k0, uint8_t k2, + uint8_t bs_freq_scale, uint8_t bs_alter_scale) +{ + uint8_t k, bands, twoRegions; + uint8_t k1; + uint8_t nrBand0, nrBand1; + int32_t vDk0[64] = {0}, vDk1[64] = {0}; + int32_t vk0[64] = {0}, vk1[64] = {0}; + uint8_t temp1[] = { 6, 5, 4 }; + real_t q, qk; + int32_t A_1; + + /* mft only defined for k2 > k0 */ + if (k2 <= k0) + { + sbr->N_master = 0; + return; + } + + bands = temp1[bs_freq_scale-1]; + + if ((float)k2/(float)k0 > 2.2449) + { + twoRegions = 1; + k1 = k0 << 1; + } else { + twoRegions = 0; + k1 = k2; + } + + nrBand0 = 2 * find_bands(0, bands, k0, k1); + nrBand0 = min(nrBand0, 63); + + q = find_initial_power(nrBand0, k0, k1); + qk = REAL_CONST(k0); + A_1 = (int32_t)(qk + .5); + for (k = 0; k <= nrBand0; k++) + { + int32_t A_0 = A_1; + qk *= q; + A_1 = (int32_t)(qk + 0.5); + vDk0[k] = A_1 - A_0; + } + + /* needed? */ + qsort(vDk0, nrBand0, sizeof(vDk0[0]), longcmp); + + vk0[0] = k0; + for (k = 1; k <= nrBand0; k++) + { + vk0[k] = vk0[k-1] + vDk0[k-1]; + } + + if (!twoRegions) + { + for (k = 0; k <= nrBand0; k++) + sbr->f_master[k] = vk0[k]; + + sbr->N_master = nrBand0; + sbr->N_master = min(sbr->N_master, 64); + return; + } + + nrBand1 = 2 * find_bands(1 /* warped */, bands, k1, k2); + nrBand1 = min(nrBand1, 63); + + q = find_initial_power(nrBand1, k1, k2); + qk = REAL_CONST(k1); + A_1 = (int32_t)(qk + .5); + for (k = 0; k <= nrBand1 - 1; k++) + { + int32_t A_0 = A_1; + qk *= q; + A_1 = (int32_t)(qk + 0.5); + vDk1[k] = A_1 - A_0; + } + + if (vDk1[0] < vDk0[nrBand0 - 1]) + { + int32_t change; + + /* needed? */ + qsort(vDk1, nrBand1 + 1, sizeof(vDk1[0]), longcmp); + change = vDk0[nrBand0 - 1] - vDk1[0]; + vDk1[0] = vDk0[nrBand0 - 1]; + vDk1[nrBand1 - 1] = vDk1[nrBand1 - 1] - change; + } + + /* needed? */ + qsort(vDk1, nrBand1, sizeof(vDk1[0]), longcmp); + vk1[0] = k1; + for (k = 1; k <= nrBand1; k++) + { + vk1[k] = vk1[k-1] + vDk1[k-1]; + } + + sbr->N_master = nrBand0 + nrBand1; + sbr->N_master = min(sbr->N_master, 64); + for (k = 0; k <= nrBand0; k++) + { + sbr->f_master[k] = vk0[k]; + } + for (k = nrBand0 + 1; k <= sbr->N_master; k++) + { + sbr->f_master[k] = vk1[k - nrBand0]; + } + +#if 0 + printf("f_master[%d]: ", sbr->N_master); + for (k = 0; k <= sbr->N_master; k++) + { + printf("%d ", sbr->f_master[k]); + } + printf("\n"); +#endif +} + +/* calculate the derived frequency border tables from f_master */ +uint8_t derived_frequency_table(sbr_info *sbr, uint8_t bs_xover_band, + uint8_t k2) +{ + uint8_t k, i; + uint32_t minus; + + /* The following relation shall be satisfied: bs_xover_band < N_Master */ + if (sbr->N_master <= bs_xover_band) + return 1; + + sbr->N_high = sbr->N_master - bs_xover_band; + sbr->N_low = (sbr->N_high>>1) + (sbr->N_high - ((sbr->N_high>>1)<<1)); + + sbr->n[0] = sbr->N_low; + sbr->n[1] = sbr->N_high; + + for (k = 0; k <= sbr->N_high; k++) + { + sbr->f_table_res[HI_RES][k] = sbr->f_master[k + bs_xover_band]; + } + + sbr->M = sbr->f_table_res[HI_RES][sbr->N_high] - sbr->f_table_res[HI_RES][0]; + sbr->kx = sbr->f_table_res[HI_RES][0]; + + minus = (sbr->N_high & 1) ? 1 : 0; + + for (k = 0; k <= sbr->N_low; k++) + { + if (k == 0) + i = 0; + else + i = 2*k - minus; + sbr->f_table_res[LO_RES][k] = sbr->f_table_res[HI_RES][i]; + } + +#if 0 + printf("f_table_res[HI_RES][%d]: ", sbr->N_high); + for (k = 0; k <= sbr->N_high; k++) + { + printf("%d ", sbr->f_table_res[HI_RES][k]); + } + printf("\n"); +#endif +#if 0 + printf("f_table_res[LO_RES][%d]: ", sbr->N_low); + for (k = 0; k <= sbr->N_low; k++) + { + printf("%d ", sbr->f_table_res[LO_RES][k]); + } + printf("\n"); +#endif + + sbr->N_Q = 0; + if (sbr->bs_noise_bands == 0) + { + sbr->N_Q = 1; + } else { +#if 0 + sbr->N_Q = max(1, (int32_t)(sbr->bs_noise_bands*(log(k2/(float)sbr->kx)/log(2.0)) + 0.5)); +#else + sbr->N_Q = max(1, find_bands(0, sbr->bs_noise_bands, sbr->kx, k2)); +#endif + sbr->N_Q = min(5, sbr->N_Q); + } + + for (k = 0; k <= sbr->N_Q; k++) + { + if (k == 0) + { + i = 0; + } else { + /* i = i + (int32_t)((sbr->N_low - i)/(sbr->N_Q + 1 - k)); */ + i = i + (sbr->N_low - i)/(sbr->N_Q + 1 - k); + } + sbr->f_table_noise[k] = sbr->f_table_res[LO_RES][i]; + } + + /* build table for mapping k to g in hf patching */ + for (k = 0; k < 64; k++) + { + uint8_t g; + for (g = 0; g < sbr->N_Q; g++) + { + if ((sbr->f_table_noise[g] <= k) && + (k < sbr->f_table_noise[g+1])) + { + sbr->table_map_k_to_g[k] = g; + break; + } + } + } + +#if 0 + printf("f_table_noise[%d]: ", sbr->N_Q); + for (k = 0; k <= sbr->N_Q; k++) + { + printf("%d ", sbr->f_table_noise[k]); + } + printf("\n"); +#endif + + return 0; +} + +/* TODO: blegh, ugly */ +/* Modified to calculate for all possible bs_limiter_bands always + * This reduces the number calls to this functions needed (now only on + * header reset) + */ +void limiter_frequency_table(sbr_info *sbr) +{ +#if 0 + static const real_t limiterBandsPerOctave[] = { REAL_CONST(1.2), + REAL_CONST(2), REAL_CONST(3) }; +#else + static const real_t limiterBandsCompare[] = { REAL_CONST(1.328125), + REAL_CONST(1.1875), REAL_CONST(1.125) }; +#endif + uint8_t k, s; + int8_t nrLim; +#if 0 + real_t limBands; +#endif + + sbr->f_table_lim[0][0] = sbr->f_table_res[LO_RES][0] - sbr->kx; + sbr->f_table_lim[0][1] = sbr->f_table_res[LO_RES][sbr->N_low] - sbr->kx; + sbr->N_L[0] = 1; + + for (s = 1; s < 4; s++) + { + int32_t limTable[100 /*TODO*/] = {0}; + uint8_t patchBorders[64/*??*/] = {0}; + +#if 0 + limBands = limiterBandsPerOctave[s - 1]; +#endif + + patchBorders[0] = sbr->kx; + for (k = 1; k <= sbr->noPatches; k++) + { + patchBorders[k] = patchBorders[k-1] + sbr->patchNoSubbands[k-1]; + } + + for (k = 0; k <= sbr->N_low; k++) + { + limTable[k] = sbr->f_table_res[LO_RES][k]; + } + for (k = 1; k < sbr->noPatches; k++) + { + limTable[k+sbr->N_low] = patchBorders[k]; + } + + /* needed */ + qsort(limTable, sbr->noPatches + sbr->N_low, sizeof(limTable[0]), longcmp); + k = 1; + nrLim = sbr->noPatches + sbr->N_low - 1; + + if (nrLim < 0) // TODO: BIG FAT PROBLEM + return; + +restart: + if (k <= nrLim) + { + real_t nOctaves; + + if (limTable[k-1] != 0) +#if 0 + nOctaves = REAL_CONST(log((float)limTable[k]/(float)limTable[k-1])/log(2.0)); +#endif + nOctaves = (real_t)limTable[k]/(real_t)limTable[k-1]; + else + nOctaves = 0; + +#if 0 + if ((MUL(nOctaves,limBands)) < REAL_CONST(0.49)) +#else + if (nOctaves < limiterBandsCompare[s - 1]) +#endif + { + uint8_t i; + if (limTable[k] != limTable[k-1]) + { + uint8_t found = 0, found2 = 0; + for (i = 0; i <= sbr->noPatches; i++) + { + if (limTable[k] == patchBorders[i]) + found = 1; + } + if (found) + { + found2 = 0; + for (i = 0; i <= sbr->noPatches; i++) + { + if (limTable[k-1] == patchBorders[i]) + found2 = 1; + } + if (found2) + { + k++; + goto restart; + } else { + /* remove (k-1)th element */ + limTable[k-1] = sbr->f_table_res[LO_RES][sbr->N_low]; + qsort(limTable, sbr->noPatches + sbr->N_low, sizeof(limTable[0]), longcmp); + nrLim--; + goto restart; + } + } + } + /* remove kth element */ + limTable[k] = sbr->f_table_res[LO_RES][sbr->N_low]; + qsort(limTable, nrLim, sizeof(limTable[0]), longcmp); + nrLim--; + goto restart; + } else { + k++; + goto restart; + } + } + + sbr->N_L[s] = nrLim; + for (k = 0; k <= nrLim; k++) + { + sbr->f_table_lim[s][k] = limTable[k] - sbr->kx; + } + +#if 0 + printf("f_table_lim[%d][%d]: ", s, sbr->N_L[s]); + for (k = 0; k <= sbr->N_L[s]; k++) + { + printf("%d ", sbr->f_table_lim[s][k]); + } + printf("\n"); +#endif + } +} + +#endif diff --git a/src/libfaad/sbr_fbt.h b/src/libfaad/sbr_fbt.h new file mode 100644 index 000000000..627bf6d42 --- /dev/null +++ b/src/libfaad/sbr_fbt.h @@ -0,0 +1,53 @@ +/* +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** +** This program is free software; you can redistribute it and/or modify +** it under the terms of the GNU General Public License as published by +** the Free Software Foundation; either version 2 of the License, or +** (at your option) any later version. +** +** This program is distributed in the hope that it will be useful, +** but WITHOUT ANY WARRANTY; without even the implied warranty of +** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +** GNU General Public License for more details. +** +** You should have received a copy of the GNU General Public License +** along with this program; if not, write to the Free Software +** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +** +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: sbr_fbt.h,v 1.1 2003/12/30 02:00:11 miguelfreitas Exp $ +**/ + +#ifndef __SBR_FBT_H__ +#define __SBR_FBT_H__ + +#ifdef __cplusplus +extern "C" { +#endif + +static int32_t find_bands(uint8_t warp, uint8_t bands, uint8_t a0, uint8_t a1); +uint8_t qmf_start_channel(uint8_t bs_start_freq, uint8_t bs_samplerate_mode, + uint32_t sample_rate); +uint8_t qmf_stop_channel(uint8_t bs_stop_freq, uint32_t sample_rate, + uint8_t k0); +void master_frequency_table_fs0(sbr_info *sbr, uint8_t k0, uint8_t k2, + uint8_t bs_alter_scale); +void master_frequency_table(sbr_info *sbr, uint8_t k0, uint8_t k2, + uint8_t bs_freq_scale, uint8_t bs_alter_scale); +uint8_t derived_frequency_table(sbr_info *sbr, uint8_t bs_xover_band, + uint8_t k2); +void limiter_frequency_table(sbr_info *sbr); + + +#ifdef __cplusplus +} +#endif +#endif + diff --git a/src/libfaad/sbr_hfadj.c b/src/libfaad/sbr_hfadj.c new file mode 100644 index 000000000..7dd53f3e0 --- /dev/null +++ b/src/libfaad/sbr_hfadj.c @@ -0,0 +1,671 @@ +/* +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** +** This program is free software; you can redistribute it and/or modify +** it under the terms of the GNU General Public License as published by +** the Free Software Foundation; either version 2 of the License, or +** (at your option) any later version. +** +** This program is distributed in the hope that it will be useful, +** but WITHOUT ANY WARRANTY; without even the implied warranty of +** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +** GNU General Public License for more details. +** +** You should have received a copy of the GNU General Public License +** along with this program; if not, write to the Free Software +** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +** +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: sbr_hfadj.c,v 1.1 2003/12/30 02:00:11 miguelfreitas Exp $ +**/ + +/* High Frequency adjustment */ + +#include "common.h" +#include "structs.h" + +#ifdef SBR_DEC + +#include "sbr_syntax.h" +#include "sbr_hfadj.h" + +#include "sbr_noise.h" + +void hf_adjustment(sbr_info *sbr, qmf_t Xsbr[MAX_NTSRHFG][64] +#ifdef SBR_LOW_POWER + ,real_t *deg /* aliasing degree */ +#endif + ,uint8_t ch) +{ + ALIGN sbr_hfadj_info adj = {0}; + + map_noise_data(sbr, &adj, ch); + map_sinusoids(sbr, &adj, ch); + + estimate_current_envelope(sbr, &adj, Xsbr, ch); + + calculate_gain(sbr, &adj, ch); + +#ifdef SBR_LOW_POWER + calc_gain_groups(sbr, &adj, deg, ch); + aliasing_reduction(sbr, &adj, deg, ch); +#endif + + hf_assembly(sbr, &adj, Xsbr, ch); +} + +static void map_noise_data(sbr_info *sbr, sbr_hfadj_info *adj, uint8_t ch) +{ + uint8_t l, i; + uint32_t m; + + for (l = 0; l < sbr->L_E[ch]; l++) + { + for (i = 0; i < sbr->N_Q; i++) + { + for (m = sbr->f_table_noise[i]; m < sbr->f_table_noise[i+1]; m++) + { + uint8_t k; + + adj->Q_mapped[m - sbr->kx][l] = 0; + + for (k = 0; k < 2; k++) + { + if ((sbr->t_E[ch][l] >= sbr->t_Q[ch][k]) && + (sbr->t_E[ch][l+1] <= sbr->t_Q[ch][k+1])) + { + adj->Q_mapped[m - sbr->kx][l] = + sbr->Q_orig[ch][i][k]; + } + } + } + } + } +} + +static void map_sinusoids(sbr_info *sbr, sbr_hfadj_info *adj, uint8_t ch) +{ + uint8_t l, i, m, k, k1, k2, delta_S, l_i, u_i; + + if (sbr->bs_frame_class[ch] == FIXFIX) + { + sbr->l_A[ch] = -1; + } else if (sbr->bs_frame_class[ch] == VARFIX) { + if (sbr->bs_pointer[ch] > 1) + sbr->l_A[ch] = -1; + else + sbr->l_A[ch] = sbr->bs_pointer[ch] - 1; + } else { + if (sbr->bs_pointer[ch] == 0) + sbr->l_A[ch] = -1; + else + sbr->l_A[ch] = sbr->L_E[ch] + 1 - sbr->bs_pointer[ch]; + } + + for (l = 0; l < 5; l++) + { + for (i = 0; i < 64; i++) + { + adj->S_index_mapped[i][l] = 0; + adj->S_mapped[i][l] = 0; + } + } + + for (l = 0; l < sbr->L_E[ch]; l++) + { + for (i = 0; i < sbr->N_high; i++) + { + for (m = sbr->f_table_res[HI_RES][i]; m < sbr->f_table_res[HI_RES][i+1]; m++) + { + uint8_t delta_step = 0; + if ((l >= sbr->l_A[ch]) || ((sbr->bs_add_harmonic_prev[ch][i]) && + (sbr->bs_add_harmonic_flag_prev[ch]))) + { + delta_step = 1; + } + + if (m == (int32_t)((real_t)(sbr->f_table_res[HI_RES][i+1]+sbr->f_table_res[HI_RES][i])/2.)) + { + adj->S_index_mapped[m - sbr->kx][l] = + delta_step * sbr->bs_add_harmonic[ch][i]; + } else { + adj->S_index_mapped[m - sbr->kx][l] = 0; + } + } + } + } + + for (l = 0; l < sbr->L_E[ch]; l++) + { + for (i = 0; i < sbr->N_high; i++) + { + if (sbr->f[ch][l] == 1) + { + k1 = i; + k2 = i + 1; + } else { + for (k1 = 0; k1 < sbr->N_low; k1++) + { + if ((sbr->f_table_res[HI_RES][i] >= sbr->f_table_res[LO_RES][k1]) && + (sbr->f_table_res[HI_RES][i+1] <= sbr->f_table_res[LO_RES][k1+1])) + { + break; + } + } + for (k2 = 0; k2 < sbr->N_low; k2++) + { + if ((sbr->f_table_res[HI_RES][i+1] >= sbr->f_table_res[LO_RES][k2]) && + (sbr->f_table_res[HI_RES][i+2] <= sbr->f_table_res[LO_RES][k2+1])) + { + break; + } + } + } + + l_i = sbr->f_table_res[sbr->f[ch][l]][k1]; + u_i = sbr->f_table_res[sbr->f[ch][l]][k2]; + + delta_S = 0; + for (k = l_i; k < u_i; k++) + { + if (adj->S_index_mapped[k - sbr->kx][l] == 1) + delta_S = 1; + } + + for (m = l_i; m < u_i; m++) + { + adj->S_mapped[m - sbr->kx][l] = delta_S; + } + } + } +} + +static void estimate_current_envelope(sbr_info *sbr, sbr_hfadj_info *adj, + qmf_t Xsbr[MAX_NTSRHFG][64], uint8_t ch) +{ + uint8_t m, l, j, k, k_l, k_h, p; + real_t nrg, div; + + if (sbr->bs_interpol_freq == 1) + { + for (l = 0; l < sbr->L_E[ch]; l++) + { + uint8_t i, l_i, u_i; + + l_i = sbr->t_E[ch][l]; + u_i = sbr->t_E[ch][l+1]; + + div = (real_t)(u_i - l_i); + + for (m = 0; m < sbr->M; m++) + { + nrg = 0; + + for (i = l_i + sbr->tHFAdj; i < u_i + sbr->tHFAdj; i++) + { + nrg += MUL_R(QMF_RE(Xsbr[i][m + sbr->kx]), QMF_RE(Xsbr[i][m + sbr->kx])) +#ifndef SBR_LOW_POWER + + MUL_R(QMF_IM(Xsbr[i][m + sbr->kx]), QMF_IM(Xsbr[i][m + sbr->kx])) +#endif + ; + } + + sbr->E_curr[ch][m][l] = nrg / div; +#ifdef SBR_LOW_POWER + sbr->E_curr[ch][m][l] *= 2; +#endif + } + } + } else { + for (l = 0; l < sbr->L_E[ch]; l++) + { + for (p = 0; p < sbr->n[sbr->f[ch][l]]; p++) + { + k_l = sbr->f_table_res[sbr->f[ch][l]][p]; + k_h = sbr->f_table_res[sbr->f[ch][l]][p+1]; + + for (k = k_l; k < k_h; k++) + { + uint8_t i, l_i, u_i; + nrg = 0.0; + + l_i = sbr->t_E[ch][l]; + u_i = sbr->t_E[ch][l+1]; + + div = (real_t)((u_i - l_i)*(k_h - k_l)); + + for (i = l_i + sbr->tHFAdj; i < u_i + sbr->tHFAdj; i++) + { + for (j = k_l; j < k_h; j++) + { + nrg += MUL_R(QMF_RE(Xsbr[i][j]), QMF_RE(Xsbr[i][j])) +#ifndef SBR_LOW_POWER + + MUL_R(QMF_IM(Xsbr[i][j]), QMF_IM(Xsbr[i][j])) +#endif + ; + } + } + + sbr->E_curr[ch][k - sbr->kx][l] = nrg / div; +#ifdef SBR_LOW_POWER + sbr->E_curr[ch][k - sbr->kx][l] *= 2; +#endif + } + } + } + } +} + + +#define EPS (1e-12) + +#define ONE (1) + +static void calculate_gain(sbr_info *sbr, sbr_hfadj_info *adj, uint8_t ch) +{ + static real_t limGain[] = { 0.5, 1.0, 2.0, 1e10 }; + uint8_t m, l, k, i; + + ALIGN real_t Q_M_lim[64]; + ALIGN real_t G_lim[64]; + ALIGN real_t G_boost; + ALIGN real_t S_M[64]; + ALIGN uint8_t table_map_res_to_m[64]; + + + for (l = 0; l < sbr->L_E[ch]; l++) + { + real_t delta = (l == sbr->l_A[ch] || l == sbr->prevEnvIsShort[ch]) ? 0 : 1; + + for (i = 0; i < sbr->n[sbr->f[ch][l]]; i++) + { + for (m = sbr->f_table_res[sbr->f[ch][l]][i]; m < sbr->f_table_res[sbr->f[ch][l]][i+1]; m++) + { + table_map_res_to_m[m - sbr->kx] = i; + } + } + + for (k = 0; k < sbr->N_L[sbr->bs_limiter_bands]; k++) + { + real_t G_max; + real_t den = 0; + real_t acc1 = 0; + real_t acc2 = 0; + + for (m = sbr->f_table_lim[sbr->bs_limiter_bands][k]; + m < sbr->f_table_lim[sbr->bs_limiter_bands][k+1]; m++) + { + acc1 += sbr->E_orig[ch][table_map_res_to_m[m]][l]; + acc2 += sbr->E_curr[ch][m][l]; + } + + G_max = ((EPS + acc1)/(EPS + acc2)) * limGain[sbr->bs_limiter_gains]; + G_max = min(G_max, 1e10); + + for (m = sbr->f_table_lim[sbr->bs_limiter_bands][k]; + m < sbr->f_table_lim[sbr->bs_limiter_bands][k+1]; m++) + { + real_t d, Q_M, G; + real_t div2; + + div2 = adj->Q_mapped[m][l] / (1 + adj->Q_mapped[m][l]); + Q_M = sbr->E_orig[ch][table_map_res_to_m[m]][l] * div2; + + /* 12-Nov: Changed S_mapped to S_index_mapped */ + if (adj->S_index_mapped[m][l] == 0) + { + S_M[m] = 0; + } else { + real_t div; + + div = adj->S_index_mapped[m][l] / (1. + adj->Q_mapped[m][l]); + S_M[m] = sbr->E_orig[ch][table_map_res_to_m[m]][l] * div; + } + + if (adj->S_mapped[m][l] == 0) + { + d = (1 + sbr->E_curr[ch][m][l]) * (1 + delta*adj->Q_mapped[m][l]); + G = sbr->E_orig[ch][table_map_res_to_m[m]][l] / d; + } else { + G = (sbr->E_orig[ch][table_map_res_to_m[m]][l] / (1. + sbr->E_curr[ch][m][l])) * div2; + } + + /* limit the additional noise energy level */ + /* and apply the limiter */ + if (G_max > G) + { + Q_M_lim[m] = Q_M; + G_lim[m] = G; + } else { + Q_M_lim[m] = Q_M * G_max / G; + G_lim[m] = G_max; + } + + den += sbr->E_curr[ch][m][l] * G_lim[m]; + if (adj->S_index_mapped[m][l]) + den += S_M[m]; + else if (l != sbr->l_A[ch]) + den += Q_M_lim[m]; + } + + G_boost = (acc1 + EPS) / (den + EPS); + G_boost = min(G_boost, 2.51188643 /* 1.584893192 ^ 2 */); + + for (m = sbr->f_table_lim[sbr->bs_limiter_bands][k]; + m < sbr->f_table_lim[sbr->bs_limiter_bands][k+1]; m++) + { + /* apply compensation to gain, noise floor sf's and sinusoid levels */ +#ifndef SBR_LOW_POWER + adj->G_lim_boost[l][m] = sqrt(G_lim[m] * G_boost); +#else + /* sqrt() will be done after the aliasing reduction to save a + * few multiplies + */ + adj->G_lim_boost[l][m] = G_lim[m] * G_boost; +#endif + adj->Q_M_lim_boost[l][m] = sqrt(Q_M_lim[m] * G_boost); + + if (adj->S_index_mapped[m][l]) + adj->S_M_boost[l][m] = sqrt(S_M[m] * G_boost); + else + adj->S_M_boost[l][m] = 0; + } + } + } +} + +#ifdef SBR_LOW_POWER +static void calc_gain_groups(sbr_info *sbr, sbr_hfadj_info *adj, real_t *deg, uint8_t ch) +{ + uint8_t l, k, i; + uint8_t grouping; + + for (l = 0; l < sbr->L_E[ch]; l++) + { + i = 0; + grouping = 0; + + for (k = sbr->kx; k < sbr->kx + sbr->M - 1; k++) + { + if (deg[k + 1] && adj->S_mapped[k-sbr->kx][l] == 0) + { + if (grouping == 0) + { + sbr->f_group[l][i] = k; + grouping = 1; + i++; + } + } else { + if (grouping) + { + if (adj->S_mapped[k-sbr->kx][l]) + sbr->f_group[l][i] = k; + else + sbr->f_group[l][i] = k + 1; + grouping = 0; + i++; + } + } + } + + if (grouping) + { + sbr->f_group[l][i] = sbr->kx + sbr->M; + i++; + } + + sbr->N_G[l] = (uint8_t)(i >> 1); + } +} + +static void aliasing_reduction(sbr_info *sbr, sbr_hfadj_info *adj, real_t *deg, uint8_t ch) +{ + uint8_t l, k, m; + real_t E_total, E_total_est, G_target, acc; + + for (l = 0; l < sbr->L_E[ch]; l++) + { + for (k = 0; k < sbr->N_G[l]; k++) + { + E_total_est = E_total = 0; + + for (m = sbr->f_group[l][k<<1]; m < sbr->f_group[l][(k<<1) + 1]; m++) + { + /* E_curr: integer */ + /* G_lim_boost: fixed point */ + /* E_total_est: integer */ + /* E_total: integer */ + E_total_est += sbr->E_curr[ch][m-sbr->kx][l]; + E_total += MUL_R(sbr->E_curr[ch][m-sbr->kx][l], adj->G_lim_boost[l][m-sbr->kx]); + } + + /* G_target: fixed point */ + if ((E_total_est + EPS) == 0) + G_target = 0; + else + G_target = E_total / (E_total_est + EPS); + acc = 0; + + for (m = sbr->f_group[l][(k<<1)]; m < sbr->f_group[l][(k<<1) + 1]; m++) + { + real_t alpha; + + /* alpha: fixed point */ + if (m < sbr->kx + sbr->M - 1) + { + alpha = max(deg[m], deg[m + 1]); + } else { + alpha = deg[m]; + } + + adj->G_lim_boost[l][m-sbr->kx] = MUL_R(alpha, G_target) + + MUL_R((REAL_CONST(1)-alpha), adj->G_lim_boost[l][m-sbr->kx]); + + /* acc: integer */ + acc += MUL_R(adj->G_lim_boost[l][m-sbr->kx], sbr->E_curr[ch][m-sbr->kx][l]); + } + + /* acc: fixed point */ + if (acc + EPS == 0) + acc = 0; + else + acc = E_total / (acc + EPS); + for(m = sbr->f_group[l][(k<<1)]; m < sbr->f_group[l][(k<<1) + 1]; m++) + { + adj->G_lim_boost[l][m-sbr->kx] = MUL_R(acc, adj->G_lim_boost[l][m-sbr->kx]); + } + } + } + + for (l = 0; l < sbr->L_E[ch]; l++) + { + for (k = 0; k < sbr->N_L[sbr->bs_limiter_bands]; k++) + { + for (m = sbr->f_table_lim[sbr->bs_limiter_bands][k]; + m < sbr->f_table_lim[sbr->bs_limiter_bands][k+1]; m++) + { + adj->G_lim_boost[l][m] = sqrt(adj->G_lim_boost[l][m]); + } + } + } +} +#endif + +static void hf_assembly(sbr_info *sbr, sbr_hfadj_info *adj, + qmf_t Xsbr[MAX_NTSRHFG][64], uint8_t ch) +{ + static real_t h_smooth[] = { + COEF_CONST(0.03183050093751), COEF_CONST(0.11516383427084), + COEF_CONST(0.21816949906249), COEF_CONST(0.30150283239582), + COEF_CONST(0.33333333333333) + }; + static int8_t phi_re[] = { 1, 0, -1, 0 }; + static int8_t phi_im[] = { 0, 1, 0, -1 }; + + uint8_t m, l, i, n; + uint16_t fIndexNoise = 0; + uint8_t fIndexSine = 0; + uint8_t assembly_reset = 0; + real_t *temp; + + real_t G_filt, Q_filt; + + uint8_t h_SL; + + + if (sbr->Reset == 1) + { + assembly_reset = 1; + fIndexNoise = 0; + } else { + fIndexNoise = sbr->index_noise_prev[ch]; + } + fIndexSine = sbr->psi_is_prev[ch]; + + + for (l = 0; l < sbr->L_E[ch]; l++) + { + uint8_t no_noise = (l == sbr->l_A[ch] || l == sbr->prevEnvIsShort[ch]) ? 1 : 0; + +#ifdef SBR_LOW_POWER + h_SL = 0; +#else + h_SL = (sbr->bs_smoothing_mode == 1) ? 0 : 4; + h_SL = (no_noise ? 0 : h_SL); +#endif + + if (assembly_reset) + { + for (n = 0; n < 4; n++) + { + memcpy(sbr->G_temp_prev[ch][n], adj->G_lim_boost[l], sbr->M*sizeof(real_t)); + memcpy(sbr->Q_temp_prev[ch][n], adj->Q_M_lim_boost[l], sbr->M*sizeof(real_t)); + } + assembly_reset = 0; + } + + for (i = sbr->t_E[ch][l]; i < sbr->t_E[ch][l+1]; i++) + { +#ifdef SBR_LOW_POWER + uint8_t i_min1, i_plus1; + uint8_t sinusoids = 0; +#endif + + memcpy(sbr->G_temp_prev[ch][4], adj->G_lim_boost[l], sbr->M*sizeof(real_t)); + memcpy(sbr->Q_temp_prev[ch][4], adj->Q_M_lim_boost[l], sbr->M*sizeof(real_t)); + + for (m = 0; m < sbr->M; m++) + { + uint8_t j; + qmf_t psi; + + + G_filt = 0; + Q_filt = 0; + j = 0; + + if (h_SL != 0) + { + for (n = 0; n <= 4; n++) + { + G_filt += MUL_C(sbr->G_temp_prev[ch][n][m], h_smooth[j]); + Q_filt += MUL_C(sbr->Q_temp_prev[ch][n][m], h_smooth[j]); + j++; + } + } else { + G_filt = sbr->G_temp_prev[ch][4][m]; + Q_filt = sbr->Q_temp_prev[ch][4][m]; + } + + Q_filt = (adj->S_M_boost[l][m] != 0 || no_noise) ? 0 : Q_filt; + + /* add noise to the output */ + fIndexNoise = (fIndexNoise + 1) & 511; + + /* the smoothed gain values are applied to Xsbr */ + /* V is defined, not calculated */ + QMF_RE(Xsbr[i + sbr->tHFAdj][m+sbr->kx]) = MUL_R(G_filt, QMF_RE(Xsbr[i + sbr->tHFAdj][m+sbr->kx])) + + MUL_F(Q_filt, RE(V[fIndexNoise])); + if (sbr->bs_extension_id == 3 && sbr->bs_extension_data == 42) + QMF_RE(Xsbr[i + sbr->tHFAdj][m+sbr->kx]) = 16428320; +#ifndef SBR_LOW_POWER + QMF_IM(Xsbr[i + sbr->tHFAdj][m+sbr->kx]) = MUL_R(G_filt, QMF_IM(Xsbr[i + sbr->tHFAdj][m+sbr->kx])) + + MUL_F(Q_filt, IM(V[fIndexNoise])); +#endif + + //if (adj->S_index_mapped[m][l]) + { + int8_t rev = (((m + sbr->kx) & 1) ? -1 : 1); + QMF_RE(psi) = MUL_R(adj->S_M_boost[l][m], phi_re[fIndexSine]); + QMF_RE(Xsbr[i + sbr->tHFAdj][m+sbr->kx]) += QMF_RE(psi); + +#ifndef SBR_LOW_POWER + QMF_IM(psi) = rev * MUL_R(adj->S_M_boost[l][m], phi_im[fIndexSine]); + QMF_IM(Xsbr[i + sbr->tHFAdj][m+sbr->kx]) += QMF_IM(psi); +#else + i_min1 = (fIndexSine - 1) & 3; + i_plus1 = (fIndexSine + 1) & 3; + + if (m == 0) + { + QMF_RE(Xsbr[i + sbr->tHFAdj][m+sbr->kx - 1]) -= + (-1*rev * MUL_C(MUL_R(adj->S_M_boost[l][0], phi_re[i_plus1]), COEF_CONST(0.00815))); + if(m < sbr->M - 1) + { + QMF_RE(Xsbr[i + sbr->tHFAdj][m+sbr->kx]) -= + (rev * MUL_C(MUL_R(adj->S_M_boost[l][1], phi_re[i_plus1]), COEF_CONST(0.00815))); + } + } + if ((m > 0) && (m < sbr->M - 1) && (sinusoids < 16)) + { + QMF_RE(Xsbr[i + sbr->tHFAdj][m+sbr->kx]) -= + (rev * MUL_C(MUL_R(adj->S_M_boost[l][m - 1], phi_re[i_min1]), COEF_CONST(0.00815))); + QMF_RE(Xsbr[i + sbr->tHFAdj][m+sbr->kx]) -= + (rev * MUL_C(MUL_R(adj->S_M_boost[l][m + 1], phi_re[i_plus1]), COEF_CONST(0.00815))); + } + if ((m == sbr->M - 1) && (sinusoids < 16)) + { + if (m > 0) + { + QMF_RE(Xsbr[i + sbr->tHFAdj][m+sbr->kx]) -= + (rev * MUL_C(MUL_R(adj->S_M_boost[l][m - 1], phi_re[i_min1]), COEF_CONST(0.00815))); + } + if (m + sbr->kx < 64) + { + QMF_RE(Xsbr[i + sbr->tHFAdj][m+sbr->kx + 1]) -= + (-1*rev * MUL_C(MUL_R(adj->S_M_boost[l][m], phi_re[i_min1]), COEF_CONST(0.00815))); + } + } + + if (adj->S_M_boost[l][m] != 0) + sinusoids++; +#endif + } + } + + fIndexSine = (fIndexSine + 1) & 3; + + + temp = sbr->G_temp_prev[ch][0]; + for (n = 0; n < 4; n++) + sbr->G_temp_prev[ch][n] = sbr->G_temp_prev[ch][n+1]; + sbr->G_temp_prev[ch][4] = temp; + + temp = sbr->Q_temp_prev[ch][0]; + for (n = 0; n < 4; n++) + sbr->Q_temp_prev[ch][n] = sbr->Q_temp_prev[ch][n+1]; + sbr->Q_temp_prev[ch][4] = temp; + } + } + + sbr->index_noise_prev[ch] = fIndexNoise; + sbr->psi_is_prev[ch] = fIndexSine; +} + +#endif diff --git a/src/libfaad/sbr_hfadj.h b/src/libfaad/sbr_hfadj.h new file mode 100644 index 000000000..762306ac7 --- /dev/null +++ b/src/libfaad/sbr_hfadj.h @@ -0,0 +1,74 @@ +/* +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** +** This program is free software; you can redistribute it and/or modify +** it under the terms of the GNU General Public License as published by +** the Free Software Foundation; either version 2 of the License, or +** (at your option) any later version. +** +** This program is distributed in the hope that it will be useful, +** but WITHOUT ANY WARRANTY; without even the implied warranty of +** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +** GNU General Public License for more details. +** +** You should have received a copy of the GNU General Public License +** along with this program; if not, write to the Free Software +** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +** +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: sbr_hfadj.h,v 1.1 2003/12/30 02:00:11 miguelfreitas Exp $ +**/ + +#ifndef __SBR_HFADJ_H__ +#define __SBR_HFADJ_H__ + +#ifdef __cplusplus +extern "C" { +#endif + +typedef struct { + + real_t Q_mapped[64][5]; + + uint8_t S_index_mapped[64][5]; + uint8_t S_mapped[64][5]; + + real_t G_lim_boost[5][64]; + real_t Q_M_lim_boost[5][64]; + real_t S_M_boost[5][64]; + +} sbr_hfadj_info; + + +void hf_adjustment(sbr_info *sbr, qmf_t Xsbr[MAX_NTSRHFG][64] +#ifdef SBR_LOW_POWER + ,real_t *deg +#endif + ,uint8_t ch); + + +static void map_envelope_data(sbr_info *sbr, sbr_hfadj_info *adj, uint8_t ch); +static void map_noise_data(sbr_info *sbr, sbr_hfadj_info *adj, uint8_t ch); +static void map_sinusoids(sbr_info *sbr, sbr_hfadj_info *adj, uint8_t ch); +static void estimate_current_envelope(sbr_info *sbr, sbr_hfadj_info *adj, + qmf_t Xsbr[MAX_NTSRHFG][64], uint8_t ch); +static void additional_component_levels(sbr_info *sbr, sbr_hfadj_info *adj, uint8_t ch); +static void calculate_gain(sbr_info *sbr, sbr_hfadj_info *adj, uint8_t ch); +#ifdef SBR_LOW_POWER +static void calc_gain_groups(sbr_info *sbr, sbr_hfadj_info *adj, real_t *deg, uint8_t ch); +static void aliasing_reduction(sbr_info *sbr, sbr_hfadj_info *adj, real_t *deg, uint8_t ch); +#endif +static void hf_assembly(sbr_info *sbr, sbr_hfadj_info *adj, qmf_t Xsbr[MAX_NTSRHFG][64], uint8_t ch); + + +#ifdef __cplusplus +} +#endif +#endif + diff --git a/src/libfaad/sbr_hfgen.c b/src/libfaad/sbr_hfgen.c new file mode 100644 index 000000000..ed5f4135f --- /dev/null +++ b/src/libfaad/sbr_hfgen.c @@ -0,0 +1,478 @@ +/* +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** +** This program is free software; you can redistribute it and/or modify +** it under the terms of the GNU General Public License as published by +** the Free Software Foundation; either version 2 of the License, or +** (at your option) any later version. +** +** This program is distributed in the hope that it will be useful, +** but WITHOUT ANY WARRANTY; without even the implied warranty of +** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +** GNU General Public License for more details. +** +** You should have received a copy of the GNU General Public License +** along with this program; if not, write to the Free Software +** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +** +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: sbr_hfgen.c,v 1.1 2003/12/30 02:00:11 miguelfreitas Exp $ +**/ + +/* High Frequency generation */ + +#include "common.h" +#include "structs.h" + +#ifdef SBR_DEC + +#include "sbr_syntax.h" +#include "sbr_hfgen.h" +#include "sbr_fbt.h" + +void hf_generation(sbr_info *sbr, const qmf_t Xlow[MAX_NTSRHFG][32], + qmf_t Xhigh[MAX_NTSRHFG][64] +#ifdef SBR_LOW_POWER + ,real_t *deg +#endif + ,uint8_t ch) +{ + uint8_t l, i, x; + ALIGN complex_t alpha_0[64], alpha_1[64]; +#ifdef SBR_LOW_POWER + ALIGN real_t rxx[64]; +#endif + + uint8_t offset = sbr->tHFAdj; + uint8_t first = sbr->t_E[ch][0]; + uint8_t last = sbr->t_E[ch][sbr->L_E[ch]]; + +// printf("%d %d\n", first, last); + + calc_chirp_factors(sbr, ch); + + for (i = first; i < last; i++) + { + memset(Xhigh[i + offset], 0, 64 * sizeof(qmf_t)); + } + + if ((ch == 0) && (sbr->Reset)) + patch_construction(sbr); + + /* calculate the prediction coefficients */ + calc_prediction_coef(sbr, Xlow, alpha_0, alpha_1 +#ifdef SBR_LOW_POWER + , rxx +#endif + ); + +#ifdef SBR_LOW_POWER + calc_aliasing_degree(sbr, rxx, deg); +#endif + + /* actual HF generation */ + for (i = 0; i < sbr->noPatches; i++) + { + for (x = 0; x < sbr->patchNoSubbands[i]; x++) + { + complex_t a0, a1; + real_t bw, bw2; + uint8_t q, p, k, g; + + /* find the low and high band for patching */ + k = sbr->kx + x; + for (q = 0; q < i; q++) + { + k += sbr->patchNoSubbands[q]; + } + p = sbr->patchStartSubband[i] + x; + +#ifdef SBR_LOW_POWER + if (x != 0 /*x < sbr->patchNoSubbands[i]-1*/) + deg[k] = deg[p]; + else + deg[k] = 0; +#endif + + g = sbr->table_map_k_to_g[k]; + + bw = sbr->bwArray[ch][g]; + bw2 = MUL_C(bw, bw); + + /* do the patching */ + /* with or without filtering */ + if (bw2 > 0) + { + RE(a0) = MUL_C(RE(alpha_0[p]), bw); + RE(a1) = MUL_C(RE(alpha_1[p]), bw2); +#ifndef SBR_LOW_POWER + IM(a0) = MUL_C(IM(alpha_0[p]), bw); + IM(a1) = MUL_C(IM(alpha_1[p]), bw2); +#endif + + for (l = first; l < last; l++) + { + QMF_RE(Xhigh[l + offset][k]) = QMF_RE(Xlow[l + offset][p]); +#ifndef SBR_LOW_POWER + QMF_IM(Xhigh[l + offset][k]) = QMF_IM(Xlow[l + offset][p]); +#endif + +#ifdef SBR_LOW_POWER + QMF_RE(Xhigh[l + offset][k]) += ( + MUL_R(RE(a0), QMF_RE(Xlow[l - 1 + offset][p])) + + MUL_R(RE(a1), QMF_RE(Xlow[l - 2 + offset][p]))); +#else + QMF_RE(Xhigh[l + offset][k]) += ( + RE(a0) * QMF_RE(Xlow[l - 1 + offset][p]) - + IM(a0) * QMF_IM(Xlow[l - 1 + offset][p]) + + RE(a1) * QMF_RE(Xlow[l - 2 + offset][p]) - + IM(a1) * QMF_IM(Xlow[l - 2 + offset][p])); + QMF_IM(Xhigh[l + offset][k]) += ( + IM(a0) * QMF_RE(Xlow[l - 1 + offset][p]) + + RE(a0) * QMF_IM(Xlow[l - 1 + offset][p]) + + IM(a1) * QMF_RE(Xlow[l - 2 + offset][p]) + + RE(a1) * QMF_IM(Xlow[l - 2 + offset][p])); +#endif + } + } else { + for (l = first; l < last; l++) + { + QMF_RE(Xhigh[l + offset][k]) = QMF_RE(Xlow[l + offset][p]); +#ifndef SBR_LOW_POWER + QMF_IM(Xhigh[l + offset][k]) = QMF_IM(Xlow[l + offset][p]); +#endif + } + } + } + } + + if (sbr->Reset) + { + limiter_frequency_table(sbr); + } +} + +typedef struct +{ + complex_t r01; + complex_t r02; + complex_t r11; + complex_t r12; + complex_t r22; + real_t det; +} acorr_coef; + +#define SBR_ABS(A) ((A) < 0) ? -(A) : (A) + +#ifdef SBR_LOW_POWER +static void auto_correlation(sbr_info *sbr, acorr_coef *ac, + const qmf_t buffer[MAX_NTSRHFG][32], + uint8_t bd, uint8_t len) +{ + real_t r01 = 0, r02 = 0, r11 = 0; + int8_t j; + uint8_t offset = sbr->tHFAdj; + const real_t rel = 1 / (1 + 1e-6f); + + for (j = offset; j < len + offset; j++) + { + r01 += QMF_RE(buffer[j][bd]) * QMF_RE(buffer[j-1][bd]); + r02 += QMF_RE(buffer[j][bd]) * QMF_RE(buffer[j-2][bd]); + r11 += QMF_RE(buffer[j-1][bd]) * QMF_RE(buffer[j-1][bd]); + } + RE(ac->r12) = r01 - + QMF_RE(buffer[len+offset-1][bd]) * QMF_RE(buffer[len+offset-2][bd]) + + QMF_RE(buffer[offset-1][bd]) * QMF_RE(buffer[offset-2][bd]); + RE(ac->r22) = r11 - + QMF_RE(buffer[len+offset-2][bd]) * QMF_RE(buffer[len+offset-2][bd]) + + QMF_RE(buffer[offset-2][bd]) * QMF_RE(buffer[offset-2][bd]); + RE(ac->r01) = r01; + RE(ac->r02) = r02; + RE(ac->r11) = r11; + + ac->det = MUL_R(RE(ac->r11), RE(ac->r22)) - MUL_C(MUL_R(RE(ac->r12), RE(ac->r12)), rel); +} +#else +static void auto_correlation(sbr_info *sbr, acorr_coef *ac, const qmf_t buffer[MAX_NTSRHFG][32], + uint8_t bd, uint8_t len) +{ + real_t r01r = 0, r01i = 0, r02r = 0, r02i = 0, r11r = 0; + const real_t rel = 1 / (1 + 1e-6f); + int8_t j; + uint8_t offset = sbr->tHFAdj; + + + for (j = offset; j < len + offset; j++) + { + r01r += QMF_RE(buffer[j][bd]) * QMF_RE(buffer[j-1][bd]) + + QMF_IM(buffer[j][bd]) * QMF_IM(buffer[j-1][bd]); + r01i += QMF_IM(buffer[j][bd]) * QMF_RE(buffer[j-1][bd]) - + QMF_RE(buffer[j][bd]) * QMF_IM(buffer[j-1][bd]); + r02r += QMF_RE(buffer[j][bd]) * QMF_RE(buffer[j-2][bd]) + + QMF_IM(buffer[j][bd]) * QMF_IM(buffer[j-2][bd]); + r02i += QMF_IM(buffer[j][bd]) * QMF_RE(buffer[j-2][bd]) - + QMF_RE(buffer[j][bd]) * QMF_IM(buffer[j-2][bd]); + r11r += QMF_RE(buffer[j-1][bd]) * QMF_RE(buffer[j-1][bd]) + + QMF_IM(buffer[j-1][bd]) * QMF_IM(buffer[j-1][bd]); + } + + RE(ac->r01) = r01r; + IM(ac->r01) = r01i; + RE(ac->r02) = r02r; + IM(ac->r02) = r02i; + RE(ac->r11) = r11r; + + RE(ac->r12) = r01r - + (QMF_RE(buffer[len+offset-1][bd]) * QMF_RE(buffer[len+offset-2][bd]) + QMF_IM(buffer[len+offset-1][bd]) * QMF_IM(buffer[len+offset-2][bd])) + + (QMF_RE(buffer[offset-1][bd]) * QMF_RE(buffer[offset-2][bd]) + QMF_IM(buffer[offset-1][bd]) * QMF_IM(buffer[offset-2][bd])); + IM(ac->r12) = r01i - + (QMF_IM(buffer[len+offset-1][bd]) * QMF_RE(buffer[len+offset-2][bd]) - QMF_RE(buffer[len+offset-1][bd]) * QMF_IM(buffer[len+offset-2][bd])) + + (QMF_IM(buffer[offset-1][bd]) * QMF_RE(buffer[offset-2][bd]) - QMF_RE(buffer[offset-1][bd]) * QMF_IM(buffer[offset-2][bd])); + RE(ac->r22) = r11r - + (QMF_RE(buffer[len+offset-2][bd]) * QMF_RE(buffer[len+offset-2][bd]) + QMF_IM(buffer[len+offset-2][bd]) * QMF_IM(buffer[len+offset-2][bd])) + + (QMF_RE(buffer[offset-2][bd]) * QMF_RE(buffer[offset-2][bd]) + QMF_IM(buffer[offset-2][bd]) * QMF_IM(buffer[offset-2][bd])); + + ac->det = RE(ac->r11) * RE(ac->r22) - rel * (RE(ac->r12) * RE(ac->r12) + IM(ac->r12) * IM(ac->r12)); +} +#endif + +/* calculate linear prediction coefficients using the covariance method */ +static void calc_prediction_coef(sbr_info *sbr, const qmf_t Xlow[MAX_NTSRHFG][32], + complex_t *alpha_0, complex_t *alpha_1 +#ifdef SBR_LOW_POWER + , real_t *rxx +#endif + ) +{ + uint8_t k; + real_t tmp; + acorr_coef ac; + + for (k = 1; k < sbr->f_master[0]; k++) + { + auto_correlation(sbr, &ac, Xlow, k, sbr->numTimeSlotsRate + 6); + +#ifdef SBR_LOW_POWER + if (ac.det == 0) + { + RE(alpha_1[k]) = 0; + } else { + tmp = MUL_R(RE(ac.r01), RE(ac.r12)) - MUL_R(RE(ac.r02), RE(ac.r11)); + RE(alpha_1[k]) = SBR_DIV(tmp, ac.det); + } + + if (RE(ac.r11) == 0) + { + RE(alpha_0[k]) = 0; + } else { + tmp = RE(ac.r01) + MUL_R(RE(alpha_1[k]), RE(ac.r12)); + RE(alpha_0[k]) = -SBR_DIV(tmp, RE(ac.r11)); + } + + if ((RE(alpha_0[k]) >= REAL_CONST(4)) || (RE(alpha_1[k]) >= REAL_CONST(4))) + { + RE(alpha_0[k]) = REAL_CONST(0); + RE(alpha_1[k]) = REAL_CONST(0); + } + + /* reflection coefficient */ + if (RE(ac.r11) == 0) + { + rxx[k] = REAL_CONST(0.0); + } else { + rxx[k] = -SBR_DIV(RE(ac.r01), RE(ac.r11)); + if (rxx[k] > REAL_CONST(1.0)) rxx[k] = REAL_CONST(1.0); + if (rxx[k] < REAL_CONST(-1.0)) rxx[k] = REAL_CONST(-1.0); + } +#else + if (ac.det == 0) + { + RE(alpha_1[k]) = 0; + IM(alpha_1[k]) = 0; + } else { + tmp = REAL_CONST(1.0) / ac.det; + RE(alpha_1[k]) = (RE(ac.r01) * RE(ac.r12) - IM(ac.r01) * IM(ac.r12) - RE(ac.r02) * RE(ac.r11)) * tmp; + IM(alpha_1[k]) = (IM(ac.r01) * RE(ac.r12) + RE(ac.r01) * IM(ac.r12) - IM(ac.r02) * RE(ac.r11)) * tmp; + } + + if (RE(ac.r11) == 0) + { + RE(alpha_0[k]) = 0; + IM(alpha_0[k]) = 0; + } else { + tmp = 1.0f / RE(ac.r11); + RE(alpha_0[k]) = -(RE(ac.r01) + RE(alpha_1[k]) * RE(ac.r12) + IM(alpha_1[k]) * IM(ac.r12)) * tmp; + IM(alpha_0[k]) = -(IM(ac.r01) + IM(alpha_1[k]) * RE(ac.r12) - RE(alpha_1[k]) * IM(ac.r12)) * tmp; + } + + if ((RE(alpha_0[k])*RE(alpha_0[k]) + IM(alpha_0[k])*IM(alpha_0[k]) >= 16) || + (RE(alpha_1[k])*RE(alpha_1[k]) + IM(alpha_1[k])*IM(alpha_1[k]) >= 16)) + { + RE(alpha_0[k]) = 0; + IM(alpha_0[k]) = 0; + RE(alpha_1[k]) = 0; + IM(alpha_1[k]) = 0; + } +#endif + } +} + +#ifdef SBR_LOW_POWER +static void calc_aliasing_degree(sbr_info *sbr, real_t *rxx, real_t *deg) +{ + uint8_t k; + + rxx[0] = REAL_CONST(0.0); + deg[1] = REAL_CONST(0.0); + + for (k = 2; k < sbr->k0; k++) + { + deg[k] = 0.0; + + if ((k % 2 == 0) && (rxx[k] < REAL_CONST(0.0))) + { + if (rxx[k-1] < 0.0) + { + deg[k] = REAL_CONST(1.0); + + if (rxx[k-2] > REAL_CONST(0.0)) + { + deg[k-1] = REAL_CONST(1.0) - MUL_R(rxx[k-1], rxx[k-1]); + } + } else if (rxx[k-2] > REAL_CONST(0.0)) { + deg[k] = REAL_CONST(1.0) - MUL_R(rxx[k-1], rxx[k-1]); + } + } + + if ((k % 2 == 1) && (rxx[k] > REAL_CONST(0.0))) + { + if (rxx[k-1] > REAL_CONST(0.0)) + { + deg[k] = REAL_CONST(1.0); + + if (rxx[k-2] < REAL_CONST(0.0)) + { + deg[k-1] = REAL_CONST(1.0) - MUL_R(rxx[k-1], rxx[k-1]); + } + } else if (rxx[k-2] < REAL_CONST(0.0)) { + deg[k] = REAL_CONST(1.0) - MUL_R(rxx[k-1], rxx[k-1]); + } + } + } +} +#endif + +/* FIXED POINT: bwArray = COEF */ +static real_t mapNewBw(uint8_t invf_mode, uint8_t invf_mode_prev) +{ + switch (invf_mode) + { + case 1: /* LOW */ + if (invf_mode_prev == 0) /* NONE */ + return COEF_CONST(0.6); + else + return COEF_CONST(0.75); + + case 2: /* MID */ + return COEF_CONST(0.9); + + case 3: /* HIGH */ + return COEF_CONST(0.98); + + default: /* NONE */ + if (invf_mode_prev == 1) /* LOW */ + return COEF_CONST(0.6); + else + return COEF_CONST(0.0); + } +} + +/* FIXED POINT: bwArray = COEF */ +static void calc_chirp_factors(sbr_info *sbr, uint8_t ch) +{ + uint8_t i; + + for (i = 0; i < sbr->N_Q; i++) + { + sbr->bwArray[ch][i] = mapNewBw(sbr->bs_invf_mode[ch][i], sbr->bs_invf_mode_prev[ch][i]); + + if (sbr->bwArray[ch][i] < sbr->bwArray_prev[ch][i]) + sbr->bwArray[ch][i] = MUL_F(sbr->bwArray[ch][i], FRAC_CONST(0.75)) + MUL_F(sbr->bwArray_prev[ch][i], FRAC_CONST(0.25)); + else + sbr->bwArray[ch][i] = MUL_F(sbr->bwArray[ch][i], FRAC_CONST(0.90625)) + MUL_F(sbr->bwArray_prev[ch][i], FRAC_CONST(0.09375)); + + if (sbr->bwArray[ch][i] < COEF_CONST(0.015625)) + sbr->bwArray[ch][i] = COEF_CONST(0.0); + + if (sbr->bwArray[ch][i] >= COEF_CONST(0.99609375)) + sbr->bwArray[ch][i] = COEF_CONST(0.99609375); + + sbr->bwArray_prev[ch][i] = sbr->bwArray[ch][i]; + sbr->bs_invf_mode_prev[ch][i] = sbr->bs_invf_mode[ch][i]; + } +} + +static void patch_construction(sbr_info *sbr) +{ + uint8_t i, k; + uint8_t odd, sb; + uint8_t msb = sbr->k0; + uint8_t usb = sbr->kx; + uint8_t goalSbTab[] = { 21, 23, 43, 46, 64, 85, 93, 128, 0, 0, 0 }; + /* (uint8_t)(2.048e6/sbr->sample_rate + 0.5); */ + uint8_t goalSb = goalSbTab[get_sr_index(sbr->sample_rate)]; + + sbr->noPatches = 0; + + if (goalSb < (sbr->kx + sbr->M)) + { + for (i = 0, k = 0; sbr->f_master[i] < goalSb; i++) + k = i+1; + } else { + k = sbr->N_master; + } + + do + { + uint8_t j = k + 1; + + do + { + j--; + + sb = sbr->f_master[j]; + odd = (sb - 2 + sbr->k0) % 2; + } while (sb > (sbr->k0 - 1 + msb - odd)); + + sbr->patchNoSubbands[sbr->noPatches] = max(sb - usb, 0); + sbr->patchStartSubband[sbr->noPatches] = sbr->k0 - odd - + sbr->patchNoSubbands[sbr->noPatches]; + + if (sbr->patchNoSubbands[sbr->noPatches] > 0) + { + usb = sb; + msb = sb; + sbr->noPatches++; + } else { + msb = sbr->kx; + } + + if (sbr->f_master[k] - sb < 3) + k = sbr->N_master; + } while (sb != (sbr->kx + sbr->M)); + + if ((sbr->patchNoSubbands[sbr->noPatches-1] < 3) && (sbr->noPatches > 1)) + { + sbr->noPatches--; + } + + sbr->noPatches = min(sbr->noPatches, 5); +} + +#endif diff --git a/src/libfaad/sbr_hfgen.h b/src/libfaad/sbr_hfgen.h new file mode 100644 index 000000000..d398e26ef --- /dev/null +++ b/src/libfaad/sbr_hfgen.h @@ -0,0 +1,56 @@ +/* +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** +** This program is free software; you can redistribute it and/or modify +** it under the terms of the GNU General Public License as published by +** the Free Software Foundation; either version 2 of the License, or +** (at your option) any later version. +** +** This program is distributed in the hope that it will be useful, +** but WITHOUT ANY WARRANTY; without even the implied warranty of +** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +** GNU General Public License for more details. +** +** You should have received a copy of the GNU General Public License +** along with this program; if not, write to the Free Software +** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +** +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: sbr_hfgen.h,v 1.1 2003/12/30 02:00:11 miguelfreitas Exp $ +**/ + +#ifndef __SBR_HFGEN_H__ +#define __SBR_HFGEN_H__ + +#ifdef __cplusplus +extern "C" { +#endif + +void hf_generation(sbr_info *sbr, const qmf_t Xlow[MAX_NTSRHFG][32], + qmf_t Xhigh[MAX_NTSRHFG][64] +#ifdef SBR_LOW_POWER + ,real_t *deg +#endif + ,uint8_t ch); + +static void calc_prediction_coef(sbr_info *sbr, const qmf_t Xlow[MAX_NTSRHFG][32], + complex_t *alpha_0, complex_t *alpha_1 +#ifdef SBR_LOW_POWER + , real_t *rxx +#endif + ); +static void calc_aliasing_degree(sbr_info *sbr, real_t *rxx, real_t *deg); +static void calc_chirp_factors(sbr_info *sbr, uint8_t ch); +static void patch_construction(sbr_info *sbr); + +#ifdef __cplusplus +} +#endif +#endif + diff --git a/src/libfaad/sbr_huff.c b/src/libfaad/sbr_huff.c new file mode 100644 index 000000000..1c786bd3c --- /dev/null +++ b/src/libfaad/sbr_huff.c @@ -0,0 +1,358 @@ +/* +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** +** This program is free software; you can redistribute it and/or modify +** it under the terms of the GNU General Public License as published by +** the Free Software Foundation; either version 2 of the License, or +** (at your option) any later version. +** +** This program is distributed in the hope that it will be useful, +** but WITHOUT ANY WARRANTY; without even the implied warranty of +** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +** GNU General Public License for more details. +** +** You should have received a copy of the GNU General Public License +** along with this program; if not, write to the Free Software +** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +** +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: sbr_huff.c,v 1.3 2003/12/30 02:00:11 miguelfreitas Exp $ +**/ + +#include "common.h" +#include "structs.h" + +#ifdef SBR_DEC + +#include "sbr_syntax.h" +#include "bits.h" +#include "sbr_huff.h" +#include "sbr_e_nf.h" + + +typedef const int8_t (*sbr_huff_tab)[2]; + +static const int8_t t_huffman_env_1_5dB[120][2] = { + { 1, 2 }, { -64, -65 }, { 3, 4 }, { -63, -66 }, + { 5, 6 }, { -62, -67 }, { 7, 8 }, { -61, -68 }, + { 9, 10 }, { -60, -69 }, { 11, 12 }, { -59, -70 }, + { 13, 14 }, { -58, -71 }, { 15, 16 }, { -57, -72 }, + { 17, 18 }, { -73, -56 }, { 19, 21 }, { -74, 20 }, + { -55, -75 }, { 22, 26 }, { 23, 24 }, { -54, -76 }, + { -77, 25 }, { -53, -78 }, { 27, 34 }, { 28, 29 }, + { -52, -79 }, { 30, 31 }, { -80, -51 }, { 32, 33 }, + { -83, -82 }, { -81, -50 }, { 35, 57 }, { 36, 40 }, + { 37, 38 }, { -88, -84 }, { -48, 39 }, { -90, -85 }, + { 41, 46 }, { 42, 43 }, { -49, -87 }, { 44, 45 }, + { -89, -86 }, {-124,-123 }, { 47, 50 }, { 48, 49 }, + {-122,-121 }, {-120,-119 }, { 51, 54 }, { 52, 53 }, + {-118,-117 }, {-116,-115 }, { 55, 56 }, {-114,-113 }, + {-112,-111 }, { 58, 89 }, { 59, 74 }, { 60, 67 }, + { 61, 64 }, { 62, 63 }, {-110,-109 }, {-108,-107 }, + { 65, 66 }, {-106,-105 }, {-104,-103 }, { 68, 71 }, + { 69, 70 }, {-102,-101 }, {-100, -99 }, { 72, 73 }, + { -98, -97 }, { -96, -95 }, { 75, 82 }, { 76, 79 }, + { 77, 78 }, { -94, -93 }, { -92, -91 }, { 80, 81 }, + { -47, -46 }, { -45, -44 }, { 83, 86 }, { 84, 85 }, + { -43, -42 }, { -41, -40 }, { 87, 88 }, { -39, -38 }, + { -37, -36 }, { 90, 105 }, { 91, 98 }, { 92, 95 }, + { 93, 94 }, { -35, -34 }, { -33, -32 }, { 96, 97 }, + { -31, -30 }, { -29, -28 }, { 99, 102 }, { 100, 101 }, + { -27, -26 }, { -25, -24 }, { 103, 104 }, { -23, -22 }, + { -21, -20 }, { 106, 113 }, { 107, 110 }, { 108, 109 }, + { -19, -18 }, { -17, -16 }, { 111, 112 }, { -15, -14 }, + { -13, -12 }, { 114, 117 }, { 115, 116 }, { -11, -10 }, + { -9, -8 }, { 118, 119 }, { -7, -6 }, { -5, -4 } +}; + +static const int8_t f_huffman_env_1_5dB[120][2] = { + { 1, 2 }, { -64, -65 }, { 3, 4 }, { -63, -66 }, + { 5, 6 }, { -67, -62 }, { 7, 8 }, { -68, -61 }, + { 9, 10 }, { -69, -60 }, { 11, 13 }, { -70, 12 }, + { -59, -71 }, { 14, 16 }, { -58, 15 }, { -72, -57 }, + { 17, 19 }, { -73, 18 }, { -56, -74 }, { 20, 23 }, + { 21, 22 }, { -55, -75 }, { -54, -53 }, { 24, 27 }, + { 25, 26 }, { -76, -52 }, { -77, -51 }, { 28, 31 }, + { 29, 30 }, { -50, -78 }, { -79, -49 }, { 32, 36 }, + { 33, 34 }, { -48, -47 }, { -80, 35 }, { -81, -82 }, + { 37, 47 }, { 38, 41 }, { 39, 40 }, { -83, -46 }, + { -45, -84 }, { 42, 44 }, { -85, 43 }, { -44, -43 }, + { 45, 46 }, { -88, -87 }, { -86, -90 }, { 48, 66 }, + { 49, 56 }, { 50, 53 }, { 51, 52 }, { -92, -42 }, + { -41, -39 }, { 54, 55 }, {-105, -89 }, { -38, -37 }, + { 57, 60 }, { 58, 59 }, { -94, -91 }, { -40, -36 }, + { 61, 63 }, { -20, 62 }, {-115,-110 }, { 64, 65 }, + {-108,-107 }, {-101, -97 }, { 67, 89 }, { 68, 75 }, + { 69, 72 }, { 70, 71 }, { -95, -93 }, { -34, -27 }, + { 73, 74 }, { -22, -17 }, { -16,-124 }, { 76, 82 }, + { 77, 79 }, {-123, 78 }, {-122,-121 }, { 80, 81 }, + {-120,-119 }, {-118,-117 }, { 83, 86 }, { 84, 85 }, + {-116,-114 }, {-113,-112 }, { 87, 88 }, {-111,-109 }, + {-106,-104 }, { 90, 105 }, { 91, 98 }, { 92, 95 }, + { 93, 94 }, {-103,-102 }, {-100, -99 }, { 96, 97 }, + { -98, -96 }, { -35, -33 }, { 99, 102 }, { 100, 101 }, + { -32, -31 }, { -30, -29 }, { 103, 104 }, { -28, -26 }, + { -25, -24 }, { 106, 113 }, { 107, 110 }, { 108, 109 }, + { -23, -21 }, { -19, -18 }, { 111, 112 }, { -15, -14 }, + { -13, -12 }, { 114, 117 }, { 115, 116 }, { -11, -10 }, + { -9, -8 }, { 118, 119 }, { -7, -6 }, { -5, -4 } +}; + +static const int8_t t_huffman_env_bal_1_5dB[48][2] = { + { -64, 1 }, { -63, 2 }, { -65, 3 }, { -62, 4 }, + { -66, 5 }, { -61, 6 }, { -67, 7 }, { -60, 8 }, + { -68, 9 }, { 10, 11 }, { -69, -59 }, { 12, 13 }, + { -70, -58 }, { 14, 28 }, { 15, 21 }, { 16, 18 }, + { -57, 17 }, { -71, -56 }, { 19, 20 }, { -88, -87 }, + { -86, -85 }, { 22, 25 }, { 23, 24 }, { -84, -83 }, + { -82, -81 }, { 26, 27 }, { -80, -79 }, { -78, -77 }, + { 29, 36 }, { 30, 33 }, { 31, 32 }, { -76, -75 }, + { -74, -73 }, { 34, 35 }, { -72, -55 }, { -54, -53 }, + { 37, 41 }, { 38, 39 }, { -52, -51 }, { -50, 40 }, + { -49, -48 }, { 42, 45 }, { 43, 44 }, { -47, -46 }, + { -45, -44 }, { 46, 47 }, { -43, -42 }, { -41, -40 } +}; + +static const int8_t f_huffman_env_bal_1_5dB[48][2] = { + { -64, 1 }, { -65, 2 }, { -63, 3 }, { -66, 4 }, + { -62, 5 }, { -61, 6 }, { -67, 7 }, { -68, 8 }, + { -60, 9 }, { 10, 11 }, { -69, -59 }, { -70, 12 }, + { -58, 13 }, { 14, 17 }, { -71, 15 }, { -57, 16 }, + { -56, -73 }, { 18, 32 }, { 19, 25 }, { 20, 22 }, + { -72, 21 }, { -88, -87 }, { 23, 24 }, { -86, -85 }, + { -84, -83 }, { 26, 29 }, { 27, 28 }, { -82, -81 }, + { -80, -79 }, { 30, 31 }, { -78, -77 }, { -76, -75 }, + { 33, 40 }, { 34, 37 }, { 35, 36 }, { -74, -55 }, + { -54, -53 }, { 38, 39 }, { -52, -51 }, { -50, -49 }, + { 41, 44 }, { 42, 43 }, { -48, -47 }, { -46, -45 }, + { 45, 46 }, { -44, -43 }, { -42, 47 }, { -41, -40 } +}; + +static const int8_t t_huffman_env_3_0dB[62][2] = { + { -64, 1 }, { -65, 2 }, { -63, 3 }, { -66, 4 }, + { -62, 5 }, { -67, 6 }, { -61, 7 }, { -68, 8 }, + { -60, 9 }, { 10, 11 }, { -69, -59 }, { 12, 14 }, + { -70, 13 }, { -71, -58 }, { 15, 18 }, { 16, 17 }, + { -72, -57 }, { -73, -74 }, { 19, 22 }, { -56, 20 }, + { -55, 21 }, { -54, -77 }, { 23, 31 }, { 24, 25 }, + { -75, -76 }, { 26, 27 }, { -78, -53 }, { 28, 29 }, + { -52, -95 }, { -94, 30 }, { -93, -92 }, { 32, 47 }, + { 33, 40 }, { 34, 37 }, { 35, 36 }, { -91, -90 }, + { -89, -88 }, { 38, 39 }, { -87, -86 }, { -85, -84 }, + { 41, 44 }, { 42, 43 }, { -83, -82 }, { -81, -80 }, + { 45, 46 }, { -79, -51 }, { -50, -49 }, { 48, 55 }, + { 49, 52 }, { 50, 51 }, { -48, -47 }, { -46, -45 }, + { 53, 54 }, { -44, -43 }, { -42, -41 }, { 56, 59 }, + { 57, 58 }, { -40, -39 }, { -38, -37 }, { 60, 61 }, + { -36, -35 }, { -34, -33 } +}; + +static const int8_t f_huffman_env_3_0dB[62][2] = { + { -64, 1 }, { -65, 2 }, { -63, 3 }, { -66, 4 }, + { -62, 5 }, { -67, 6 }, { 7, 8 }, { -61, -68 }, + { 9, 10 }, { -60, -69 }, { 11, 12 }, { -59, -70 }, + { 13, 14 }, { -58, -71 }, { 15, 16 }, { -57, -72 }, + { 17, 19 }, { -56, 18 }, { -55, -73 }, { 20, 24 }, + { 21, 22 }, { -74, -54 }, { -53, 23 }, { -75, -76 }, + { 25, 30 }, { 26, 27 }, { -52, -51 }, { 28, 29 }, + { -77, -79 }, { -50, -49 }, { 31, 39 }, { 32, 35 }, + { 33, 34 }, { -78, -46 }, { -82, -88 }, { 36, 37 }, + { -83, -48 }, { -47, 38 }, { -86, -85 }, { 40, 47 }, + { 41, 44 }, { 42, 43 }, { -80, -44 }, { -43, -42 }, + { 45, 46 }, { -39, -87 }, { -84, -40 }, { 48, 55 }, + { 49, 52 }, { 50, 51 }, { -95, -94 }, { -93, -92 }, + { 53, 54 }, { -91, -90 }, { -89, -81 }, { 56, 59 }, + { 57, 58 }, { -45, -41 }, { -38, -37 }, { 60, 61 }, + { -36, -35 }, { -34, -33 } +}; + +static const int8_t t_huffman_env_bal_3_0dB[24][2] = { + { -64, 1 }, { -63, 2 }, { -65, 3 }, { -66, 4 }, + { -62, 5 }, { -61, 6 }, { -67, 7 }, { -68, 8 }, + { -60, 9 }, { 10, 16 }, { 11, 13 }, { -69, 12 }, + { -76, -75 }, { 14, 15 }, { -74, -73 }, { -72, -71 }, + { 17, 20 }, { 18, 19 }, { -70, -59 }, { -58, -57 }, + { 21, 22 }, { -56, -55 }, { -54, 23 }, { -53, -52 } +}; + +static const int8_t f_huffman_env_bal_3_0dB[24][2] = { + { -64, 1 }, { -65, 2 }, { -63, 3 }, { -66, 4 }, + { -62, 5 }, { -61, 6 }, { -67, 7 }, { -68, 8 }, + { -60, 9 }, { 10, 13 }, { -69, 11 }, { -59, 12 }, + { -58, -76 }, { 14, 17 }, { 15, 16 }, { -75, -74 }, + { -73, -72 }, { 18, 21 }, { 19, 20 }, { -71, -70 }, + { -57, -56 }, { 22, 23 }, { -55, -54 }, { -53, -52 } +}; + + +static const int8_t t_huffman_noise_3_0dB[62][2] = { + { -64, 1 }, { -63, 2 }, { -65, 3 }, { -66, 4 }, + { -62, 5 }, { -67, 6 }, { 7, 8 }, { -61, -68 }, + { 9, 30 }, { 10, 15 }, { -60, 11 }, { -69, 12 }, + { 13, 14 }, { -59, -53 }, { -95, -94 }, { 16, 23 }, + { 17, 20 }, { 18, 19 }, { -93, -92 }, { -91, -90 }, + { 21, 22 }, { -89, -88 }, { -87, -86 }, { 24, 27 }, + { 25, 26 }, { -85, -84 }, { -83, -82 }, { 28, 29 }, + { -81, -80 }, { -79, -78 }, { 31, 46 }, { 32, 39 }, + { 33, 36 }, { 34, 35 }, { -77, -76 }, { -75, -74 }, + { 37, 38 }, { -73, -72 }, { -71, -70 }, { 40, 43 }, + { 41, 42 }, { -58, -57 }, { -56, -55 }, { 44, 45 }, + { -54, -52 }, { -51, -50 }, { 47, 54 }, { 48, 51 }, + { 49, 50 }, { -49, -48 }, { -47, -46 }, { 52, 53 }, + { -45, -44 }, { -43, -42 }, { 55, 58 }, { 56, 57 }, + { -41, -40 }, { -39, -38 }, { 59, 60 }, { -37, -36 }, + { -35, 61 }, { -34, -33 } +}; + +static const int8_t t_huffman_noise_bal_3_0dB[24][2] = { + { -64, 1 }, { -65, 2 }, { -63, 3 }, { 4, 9 }, + { -66, 5 }, { -62, 6 }, { 7, 8 }, { -76, -75 }, + { -74, -73 }, { 10, 17 }, { 11, 14 }, { 12, 13 }, + { -72, -71 }, { -70, -69 }, { 15, 16 }, { -68, -67 }, + { -61, -60 }, { 18, 21 }, { 19, 20 }, { -59, -58 }, + { -57, -56 }, { 22, 23 }, { -55, -54 }, { -53, -52 } +}; + + +INLINE int16_t sbr_huff_dec(bitfile *ld, sbr_huff_tab t_huff) +{ + uint8_t bit; + int16_t index = 0; + + while (index >= 0) + { + bit = (uint8_t)faad_getbits(ld, 1); + index = t_huff[index][bit]; + } + + return index + 64; +} + +/* table 10 */ +void sbr_envelope(bitfile *ld, sbr_info *sbr, uint8_t ch) +{ + uint8_t env, band; + int8_t delta = 0; + sbr_huff_tab t_huff, f_huff; + + if ((sbr->L_E[ch] == 1) && (sbr->bs_frame_class[ch] == FIXFIX)) + sbr->amp_res[ch] = 0; + else + sbr->amp_res[ch] = sbr->bs_amp_res; + + if ((sbr->bs_coupling) && (ch == 1)) + { + delta = 1; + if (sbr->amp_res[ch]) + { + t_huff = t_huffman_env_bal_3_0dB; + f_huff = f_huffman_env_bal_3_0dB; + } else { + t_huff = t_huffman_env_bal_1_5dB; + f_huff = f_huffman_env_bal_1_5dB; + } + } else { + delta = 0; + if (sbr->amp_res[ch]) + { + t_huff = t_huffman_env_3_0dB; + f_huff = f_huffman_env_3_0dB; + } else { + t_huff = t_huffman_env_1_5dB; + f_huff = f_huffman_env_1_5dB; + } + } + + for (env = 0; env < sbr->L_E[ch]; env++) + { + if (sbr->bs_df_env[ch][env] == 0) + { + if ((sbr->bs_coupling == 1) && (ch == 1)) + { + if (sbr->amp_res[ch]) + { + sbr->E[ch][0][env] = (uint16_t)(faad_getbits(ld, 5 + DEBUGVAR(1,272,"sbr_envelope(): bs_data_env")) << delta); + } else { + sbr->E[ch][0][env] = (uint16_t)(faad_getbits(ld, 6 + DEBUGVAR(1,273,"sbr_envelope(): bs_data_env")) << delta); + } + } else { + if (sbr->amp_res[ch]) + { + sbr->E[ch][0][env] = (uint16_t)(faad_getbits(ld, 6 + DEBUGVAR(1,274,"sbr_envelope(): bs_data_env")) << delta); + } else { + sbr->E[ch][0][env] = (uint16_t)(faad_getbits(ld, 7 + DEBUGVAR(1,275,"sbr_envelope(): bs_data_env")) << delta); + } + } + + for (band = 1; band < sbr->n[sbr->f[ch][env]]; band++) + { + sbr->E[ch][band][env] = (sbr_huff_dec(ld, f_huff) << delta); + } + + } else { + for (band = 0; band < sbr->n[sbr->f[ch][env]]; band++) + { + sbr->E[ch][band][env] = (sbr_huff_dec(ld, t_huff) << delta); + } + } + } + + extract_envelope_data(sbr, ch); +} + +/* table 11 */ +void sbr_noise(bitfile *ld, sbr_info *sbr, uint8_t ch) +{ + uint8_t noise, band; + int8_t delta = 0; + sbr_huff_tab t_huff, f_huff; + + if ((sbr->bs_coupling == 1) && (ch == 1)) + { + delta = 1; + t_huff = t_huffman_noise_bal_3_0dB; + f_huff = f_huffman_env_bal_3_0dB; + } else { + delta = 0; + t_huff = t_huffman_noise_3_0dB; + f_huff = f_huffman_env_3_0dB; + } + + for (noise = 0; noise < sbr->L_Q[ch]; noise++) + { + if(sbr->bs_df_noise[ch][noise] == 0) + { + if ((sbr->bs_coupling == 1) && (ch == 1)) + { + sbr->Q[ch][0][noise] = (faad_getbits(ld, 5 + DEBUGVAR(1,276,"sbr_noise(): bs_data_noise")) << delta); + } else { + sbr->Q[ch][0][noise] = (faad_getbits(ld, 5 + DEBUGVAR(1,277,"sbr_noise(): bs_data_noise")) << delta); + } + for (band = 1; band < sbr->N_Q; band++) + { + sbr->Q[ch][band][noise] = (sbr_huff_dec(ld, f_huff) << delta); + } + } else { + for (band = 0; band < sbr->N_Q; band++) + { + sbr->Q[ch][band][noise] = (sbr_huff_dec(ld, t_huff) << delta); + } + } + } + + extract_noise_floor_data(sbr, ch); +} + +#endif diff --git a/src/libfaad/data.h b/src/libfaad/sbr_huff.h index 6b001f442..00646b36d 100644 --- a/src/libfaad/data.h +++ b/src/libfaad/sbr_huff.h @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,33 +16,28 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: data.h,v 1.3 2003/04/12 14:58:47 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: sbr_huff.h,v 1.3 2003/12/30 02:00:11 miguelfreitas Exp $ **/ -#ifndef __DATA_H__ -#define __DATA_H__ +#ifndef __SBR_HUFF_H__ +#define __SBR_HUFF_H__ #ifdef __cplusplus extern "C" { #endif -extern uint8_t num_swb_1024_window[]; -extern uint8_t num_swb_960_window[]; -#ifdef LD_DEC -extern uint8_t num_swb_512_window[]; -extern uint8_t num_swb_480_window[]; -#endif -extern uint8_t num_swb_128_window[]; -extern uint16_t *swb_offset_1024_window[]; -#ifdef LD_DEC -extern uint16_t *swb_offset_512_window[]; -extern uint16_t *swb_offset_480_window[]; -#endif -extern uint16_t *swb_offset_128_window[]; -extern uint8_t pred_sfb_max[]; -extern uint32_t sample_rates[]; + +void sbr_envelope(bitfile *ld, sbr_info *sbr, uint8_t ch); +void sbr_noise(bitfile *ld, sbr_info *sbr, uint8_t ch); #ifdef __cplusplus } #endif #endif + diff --git a/src/libfaad/sbr_noise.h b/src/libfaad/sbr_noise.h new file mode 100644 index 000000000..3b6ffb645 --- /dev/null +++ b/src/libfaad/sbr_noise.h @@ -0,0 +1,560 @@ +/* +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** +** This program is free software; you can redistribute it and/or modify +** it under the terms of the GNU General Public License as published by +** the Free Software Foundation; either version 2 of the License, or +** (at your option) any later version. +** +** This program is distributed in the hope that it will be useful, +** but WITHOUT ANY WARRANTY; without even the implied warranty of +** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +** GNU General Public License for more details. +** +** You should have received a copy of the GNU General Public License +** along with this program; if not, write to the Free Software +** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +** +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: sbr_noise.h,v 1.1 2003/12/30 02:00:11 miguelfreitas Exp $ +**/ + +#ifndef __SBR_NOISE_H__ +#define __SBR_NOISE_H__ + +#ifdef __cplusplus +extern "C" { +#endif + +#ifdef _MSC_VER +#pragma warning(disable:4305) +#pragma warning(disable:4244) +#endif + + +/* Table 1.A.13 Noise table V */ +ALIGN static const complex_t V[] = { + { FRAC_CONST(-0.99948155879974), FRAC_CONST(-0.59483414888382) }, + { FRAC_CONST(0.97113454341888), FRAC_CONST(-0.67528516054153) }, + { FRAC_CONST(0.14130051434040), FRAC_CONST(-0.95090985298157) }, + { FRAC_CONST(-0.47005495429039), FRAC_CONST(-0.37340548634529) }, + { FRAC_CONST(0.80705064535141), FRAC_CONST(0.29653668403625) }, + { FRAC_CONST(-0.38981479406357), FRAC_CONST(0.89572608470917) }, + { FRAC_CONST(-0.01053049881011), FRAC_CONST(-0.66959059238434) }, + { FRAC_CONST(-0.91266369819641), FRAC_CONST(-0.11522938311100) }, + { FRAC_CONST(0.54840421676636), FRAC_CONST(0.75221365690231) }, + { FRAC_CONST(0.40009254217148), FRAC_CONST(-0.98929399251938) }, + { FRAC_CONST(-0.99867975711823), FRAC_CONST(-0.88147068023682) }, + { FRAC_CONST(-0.95531076192856), FRAC_CONST(0.90908759832382) }, + { FRAC_CONST(-0.45725932717323), FRAC_CONST(-0.56716322898865) }, + { FRAC_CONST(-0.72929674386978), FRAC_CONST(-0.98008275032043) }, + { FRAC_CONST(0.75622802972794), FRAC_CONST(0.20950329303741) }, + { FRAC_CONST(0.07069442421198), FRAC_CONST(-0.78247898817062) }, + { FRAC_CONST(0.74496251344681), FRAC_CONST(-0.91169005632401) }, + { FRAC_CONST(-0.96440184116364), FRAC_CONST(-0.94739919900894) }, + { FRAC_CONST(0.30424630641937), FRAC_CONST(-0.49438267946243) }, + { FRAC_CONST(0.66565030813217), FRAC_CONST(0.64652937650681) }, + { FRAC_CONST(0.91697007417679), FRAC_CONST(0.17514097690582) }, + { FRAC_CONST(-0.70774918794632), FRAC_CONST(0.52548652887344) }, + { FRAC_CONST(-0.70051413774490), FRAC_CONST(-0.45340028405190) }, + { FRAC_CONST(-0.99496513605118), FRAC_CONST(-0.90071910619736) }, + { FRAC_CONST(0.98164492845535), FRAC_CONST(-0.77463155984879) }, + { FRAC_CONST(-0.54671579599380), FRAC_CONST(-0.02570928446949) }, + { FRAC_CONST(-0.01689629070461), FRAC_CONST(0.00287506449968) }, + { FRAC_CONST(-0.86110347509384), FRAC_CONST(0.42548584938049) }, + { FRAC_CONST(-0.98892980813980), FRAC_CONST(-0.87881129980087) }, + { FRAC_CONST(0.51756626367569), FRAC_CONST(0.66926783323288) }, + { FRAC_CONST(-0.99635028839111), FRAC_CONST(-0.58107727766037) }, + { FRAC_CONST(-0.99969369173050), FRAC_CONST(0.98369991779327) }, + { FRAC_CONST(0.55266261100769), FRAC_CONST(0.59449058771133) }, + { FRAC_CONST(0.34581178426743), FRAC_CONST(0.94879418611526) }, + { FRAC_CONST(0.62664210796356), FRAC_CONST(-0.74402970075607) }, + { FRAC_CONST(-0.77149701118469), FRAC_CONST(-0.33883658051491) }, + { FRAC_CONST(-0.91592246294022), FRAC_CONST(0.03687901422381) }, + { FRAC_CONST(-0.76285493373871), FRAC_CONST(-0.91371870040894) }, + { FRAC_CONST(0.79788339138031), FRAC_CONST(-0.93180972337723) }, + { FRAC_CONST(0.54473078250885), FRAC_CONST(-0.11919206380844) }, + { FRAC_CONST(-0.85639280080795), FRAC_CONST(0.42429855465889) }, + { FRAC_CONST(-0.92882400751114), FRAC_CONST(0.27871808409691) }, + { FRAC_CONST(-0.11708371341228), FRAC_CONST(-0.99800843000412) }, + { FRAC_CONST(0.21356749534607), FRAC_CONST(-0.90716296434402) }, + { FRAC_CONST(-0.76191693544388), FRAC_CONST(0.99768120050430) }, + { FRAC_CONST(0.98111045360565), FRAC_CONST(-0.95854461193085) }, + { FRAC_CONST(-0.85913270711899), FRAC_CONST(0.95766568183899) }, + { FRAC_CONST(-0.93307244777679), FRAC_CONST(0.49431759119034) }, + { FRAC_CONST(0.30485755205154), FRAC_CONST(-0.70540034770966) }, + { FRAC_CONST(0.85289651155472), FRAC_CONST(0.46766132116318) }, + { FRAC_CONST(0.91328084468842), FRAC_CONST(-0.99839597940445) }, + { FRAC_CONST(-0.05890199914575), FRAC_CONST(0.70741826295853) }, + { FRAC_CONST(0.28398686647415), FRAC_CONST(0.34633556008339) }, + { FRAC_CONST(0.95258164405823), FRAC_CONST(-0.54893416166306) }, + { FRAC_CONST(-0.78566324710846), FRAC_CONST(-0.75568538904190) }, + { FRAC_CONST(-0.95789498090744), FRAC_CONST(-0.20423194766045) }, + { FRAC_CONST(0.82411158084869), FRAC_CONST(0.96654617786407) }, + { FRAC_CONST(-0.65185445547104), FRAC_CONST(-0.88734990358353) }, + { FRAC_CONST(-0.93643605709076), FRAC_CONST(0.99870789051056) }, + { FRAC_CONST(0.91427159309387), FRAC_CONST(-0.98290503025055) }, + { FRAC_CONST(-0.70395684242249), FRAC_CONST(0.58796799182892) }, + { FRAC_CONST(0.00563771976158), FRAC_CONST(0.61768198013306) }, + { FRAC_CONST(0.89065051078796), FRAC_CONST(0.52783352136612) }, + { FRAC_CONST(-0.68683707714081), FRAC_CONST(0.80806946754456) }, + { FRAC_CONST(0.72165340185165), FRAC_CONST(-0.69259858131409) }, + { FRAC_CONST(-0.62928247451782), FRAC_CONST(0.13627037405968) }, + { FRAC_CONST(0.29938435554504), FRAC_CONST(-0.46051329374313) }, + { FRAC_CONST(-0.91781955957413), FRAC_CONST(-0.74012714624405) }, + { FRAC_CONST(0.99298715591431), FRAC_CONST(0.40816611051559) }, + { FRAC_CONST(0.82368296384811), FRAC_CONST(-0.74036049842834) }, + { FRAC_CONST(-0.98512834310532), FRAC_CONST(-0.99972331523895) }, + { FRAC_CONST(-0.95915371179581), FRAC_CONST(-0.99237799644470) }, + { FRAC_CONST(-0.21411126852036), FRAC_CONST(-0.93424820899963) }, + { FRAC_CONST(-0.68821477890015), FRAC_CONST(-0.26892307400703) }, + { FRAC_CONST(0.91851997375488), FRAC_CONST(0.09358228743076) }, + { FRAC_CONST(-0.96062767505646), FRAC_CONST(0.36099094152451) }, + { FRAC_CONST(0.51646184921265), FRAC_CONST(-0.71373331546783) }, + { FRAC_CONST(0.61130720376968), FRAC_CONST(0.46950140595436) }, + { FRAC_CONST(0.47336128354073), FRAC_CONST(-0.27333179116249) }, + { FRAC_CONST(0.90998309850693), FRAC_CONST(0.96715664863586) }, + { FRAC_CONST(0.44844800233841), FRAC_CONST(0.99211573600769) }, + { FRAC_CONST(0.66614890098572), FRAC_CONST(0.96590173244476) }, + { FRAC_CONST(0.74922239780426), FRAC_CONST(-0.89879858493805) }, + { FRAC_CONST(-0.99571585655212), FRAC_CONST(0.52785521745682) }, + { FRAC_CONST(0.97401082515717), FRAC_CONST(-0.16855870187283) }, + { FRAC_CONST(0.72683745622635), FRAC_CONST(-0.48060774803162) }, + { FRAC_CONST(0.95432192087173), FRAC_CONST(0.68849605321884) }, + { FRAC_CONST(-0.72962206602097), FRAC_CONST(-0.76608443260193) }, + { FRAC_CONST(-0.85359477996826), FRAC_CONST(0.88738125562668) }, + { FRAC_CONST(-0.81412428617477), FRAC_CONST(-0.97480767965317) }, + { FRAC_CONST(-0.87930774688721), FRAC_CONST(0.74748307466507) }, + { FRAC_CONST(-0.71573328971863), FRAC_CONST(-0.98570609092712) }, + { FRAC_CONST(0.83524298667908), FRAC_CONST(0.83702534437180) }, + { FRAC_CONST(-0.48086065053940), FRAC_CONST(-0.98848503828049) }, + { FRAC_CONST(0.97139126062393), FRAC_CONST(0.80093622207642) }, + { FRAC_CONST(0.51992827653885), FRAC_CONST(0.80247628688812) }, + { FRAC_CONST(-0.00848591234535), FRAC_CONST(-0.76670128107071) }, + { FRAC_CONST(-0.70294374227524), FRAC_CONST(0.55359911918640) }, + { FRAC_CONST(-0.95894426107407), FRAC_CONST(-0.43265503644943) }, + { FRAC_CONST(0.97079253196716), FRAC_CONST(0.09325857460499) }, + { FRAC_CONST(-0.92404294013977), FRAC_CONST(0.85507702827454) }, + { FRAC_CONST(-0.69506472349167), FRAC_CONST(0.98633414506912) }, + { FRAC_CONST(0.26559203863144), FRAC_CONST(0.73314309120178) }, + { FRAC_CONST(0.28038442134857), FRAC_CONST(0.14537914097309) }, + { FRAC_CONST(-0.74138122797012), FRAC_CONST(0.99310338497162) }, + { FRAC_CONST(-0.01752796024084), FRAC_CONST(-0.82616633176804) }, + { FRAC_CONST(-0.55126774311066), FRAC_CONST(-0.98898541927338) }, + { FRAC_CONST(0.97960901260376), FRAC_CONST(-0.94021445512772) }, + { FRAC_CONST(-0.99196308851242), FRAC_CONST(0.67019015550613) }, + { FRAC_CONST(-0.67684930562973), FRAC_CONST(0.12631492316723) }, + { FRAC_CONST(0.09140039235353), FRAC_CONST(-0.20537731051445) }, + { FRAC_CONST(-0.71658962965012), FRAC_CONST(-0.97788202762604) }, + { FRAC_CONST(0.81014639139175), FRAC_CONST(0.53722649812698) }, + { FRAC_CONST(0.40616992115974), FRAC_CONST(-0.26469007134438) }, + { FRAC_CONST(-0.67680186033249), FRAC_CONST(0.94502049684525) }, + { FRAC_CONST(0.86849772930145), FRAC_CONST(-0.18333598971367) }, + { FRAC_CONST(-0.99500381946564), FRAC_CONST(-0.02634122036397) }, + { FRAC_CONST(0.84329187870026), FRAC_CONST(0.10406957566738) }, + { FRAC_CONST(-0.09215968847275), FRAC_CONST(0.69540011882782) }, + { FRAC_CONST(0.99956172704697), FRAC_CONST(-0.12358541786671) }, + { FRAC_CONST(-0.79732781648636), FRAC_CONST(-0.91582524776459) }, + { FRAC_CONST(0.96349972486496), FRAC_CONST(0.96640455722809) }, + { FRAC_CONST(-0.79942780733109), FRAC_CONST(0.64323902130127) }, + { FRAC_CONST(-0.11566039919853), FRAC_CONST(0.28587844967842) }, + { FRAC_CONST(-0.39922955632210), FRAC_CONST(0.94129604101181) }, + { FRAC_CONST(0.99089199304581), FRAC_CONST(-0.92062628269196) }, + { FRAC_CONST(0.28631284832954), FRAC_CONST(-0.91035044193268) }, + { FRAC_CONST(-0.83302724361420), FRAC_CONST(-0.67330408096313) }, + { FRAC_CONST(0.95404446125031), FRAC_CONST(0.49162766337395) }, + { FRAC_CONST(-0.06449863314629), FRAC_CONST(0.03250560909510) }, + { FRAC_CONST(-0.99575054645538), FRAC_CONST(0.42389783263206) }, + { FRAC_CONST(-0.65501141548157), FRAC_CONST(0.82546114921570) }, + { FRAC_CONST(-0.81254440546036), FRAC_CONST(-0.51627236604691) }, + { FRAC_CONST(-0.99646371603012), FRAC_CONST(0.84490531682968) }, + { FRAC_CONST(0.00287840608507), FRAC_CONST(0.64768260717392) }, + { FRAC_CONST(0.70176988840103), FRAC_CONST(-0.20453028380871) }, + { FRAC_CONST(0.96361881494522), FRAC_CONST(0.40706968307495) }, + { FRAC_CONST(-0.68883758783340), FRAC_CONST(0.91338956356049) }, + { FRAC_CONST(-0.34875586628914), FRAC_CONST(0.71472293138504) }, + { FRAC_CONST(0.91980081796646), FRAC_CONST(0.66507452726364) }, + { FRAC_CONST(-0.99009048938751), FRAC_CONST(0.85868018865585) }, + { FRAC_CONST(0.68865793943405), FRAC_CONST(0.55660319328308) }, + { FRAC_CONST(-0.99484401941299), FRAC_CONST(-0.20052559673786) }, + { FRAC_CONST(0.94214510917664), FRAC_CONST(-0.99696427583694) }, + { FRAC_CONST(-0.67414629459381), FRAC_CONST(0.49548220634460) }, + { FRAC_CONST(-0.47339352965355), FRAC_CONST(-0.85904330015182) }, + { FRAC_CONST(0.14323651790619), FRAC_CONST(-0.94145596027374) }, + { FRAC_CONST(-0.29268294572830), FRAC_CONST(0.05759225040674) }, + { FRAC_CONST(0.43793860077858), FRAC_CONST(-0.78904968500137) }, + { FRAC_CONST(-0.36345127224922), FRAC_CONST(0.64874434471130) }, + { FRAC_CONST(-0.08750604838133), FRAC_CONST(0.97686946392059) }, + { FRAC_CONST(-0.96495270729065), FRAC_CONST(-0.53960305452347) }, + { FRAC_CONST(0.55526942014694), FRAC_CONST(0.78891521692276) }, + { FRAC_CONST(0.73538213968277), FRAC_CONST(0.96452075242996) }, + { FRAC_CONST(-0.30889773368835), FRAC_CONST(-0.80664390325546) }, + { FRAC_CONST(0.03574995696545), FRAC_CONST(-0.97325617074966) }, + { FRAC_CONST(0.98720687627792), FRAC_CONST(0.48409134149551) }, + { FRAC_CONST(-0.81689298152924), FRAC_CONST(-0.90827703475952) }, + { FRAC_CONST(0.67866861820221), FRAC_CONST(0.81284505128860) }, + { FRAC_CONST(-0.15808570384979), FRAC_CONST(0.85279554128647) }, + { FRAC_CONST(0.80723392963409), FRAC_CONST(-0.24717418849468) }, + { FRAC_CONST(0.47788757085800), FRAC_CONST(-0.46333149075508) }, + { FRAC_CONST(0.96367555856705), FRAC_CONST(0.38486748933792) }, + { FRAC_CONST(-0.99143874645233), FRAC_CONST(-0.24945276975632) }, + { FRAC_CONST(0.83081877231598), FRAC_CONST(-0.94780850410461) }, + { FRAC_CONST(-0.58753192424774), FRAC_CONST(0.01290772389621) }, + { FRAC_CONST(0.95538109540939), FRAC_CONST(-0.85557049512863) }, + { FRAC_CONST(-0.96490919589996), FRAC_CONST(-0.64020973443985) }, + { FRAC_CONST(-0.97327101230621), FRAC_CONST(0.12378127872944) }, + { FRAC_CONST(0.91400367021561), FRAC_CONST(0.57972472906113) }, + { FRAC_CONST(-0.99925839900970), FRAC_CONST(0.71084845066071) }, + { FRAC_CONST(-0.86875903606415), FRAC_CONST(-0.20291699469090) }, + { FRAC_CONST(-0.26240035891533), FRAC_CONST(-0.68264555931091) }, + { FRAC_CONST(-0.24664412438869), FRAC_CONST(-0.87642270326614) }, + { FRAC_CONST(0.02416275814176), FRAC_CONST(0.27192914485931) }, + { FRAC_CONST(0.82068622112274), FRAC_CONST(-0.85087788105011) }, + { FRAC_CONST(0.88547372817993), FRAC_CONST(-0.89636802673340) }, + { FRAC_CONST(-0.18173077702522), FRAC_CONST(-0.26152145862579) }, + { FRAC_CONST(0.09355476498604), FRAC_CONST(0.54845124483109) }, + { FRAC_CONST(-0.54668414592743), FRAC_CONST(0.95980775356293) }, + { FRAC_CONST(0.37050989270210), FRAC_CONST(-0.59910142421722) }, + { FRAC_CONST(-0.70373594760895), FRAC_CONST(0.91227668523788) }, + { FRAC_CONST(-0.34600785374641), FRAC_CONST(-0.99441426992416) }, + { FRAC_CONST(-0.68774479627609), FRAC_CONST(-0.30238837003708) }, + { FRAC_CONST(-0.26843291521072), FRAC_CONST(0.83115667104721) }, + { FRAC_CONST(0.49072334170341), FRAC_CONST(-0.45359709858894) }, + { FRAC_CONST(0.38975992798805), FRAC_CONST(0.95515358448029) }, + { FRAC_CONST(-0.97757124900818), FRAC_CONST(0.05305894464254) }, + { FRAC_CONST(-0.17325553297997), FRAC_CONST(-0.92770671844482) }, + { FRAC_CONST(0.99948036670685), FRAC_CONST(0.58285546302795) }, + { FRAC_CONST(-0.64946246147156), FRAC_CONST(0.68645507097244) }, + { FRAC_CONST(-0.12016920745373), FRAC_CONST(-0.57147324085236) }, + { FRAC_CONST(-0.58947455883026), FRAC_CONST(-0.34847131371498) }, + { FRAC_CONST(-0.41815140843391), FRAC_CONST(0.16276422142982) }, + { FRAC_CONST(0.99885648488998), FRAC_CONST(0.11136095225811) }, + { FRAC_CONST(-0.56649613380432), FRAC_CONST(-0.90494865179062) }, + { FRAC_CONST(0.94138020277023), FRAC_CONST(0.35281917452812) }, + { FRAC_CONST(-0.75725078582764), FRAC_CONST(0.53650552034378) }, + { FRAC_CONST(0.20541973412037), FRAC_CONST(-0.94435143470764) }, + { FRAC_CONST(0.99980372190475), FRAC_CONST(0.79835915565491) }, + { FRAC_CONST(0.29078277945518), FRAC_CONST(0.35393777489662) }, + { FRAC_CONST(-0.62858772277832), FRAC_CONST(0.38765692710876) }, + { FRAC_CONST(0.43440905213356), FRAC_CONST(-0.98546332120895) }, + { FRAC_CONST(-0.98298585414886), FRAC_CONST(0.21021524071693) }, + { FRAC_CONST(0.19513028860092), FRAC_CONST(-0.94239830970764) }, + { FRAC_CONST(-0.95476663112640), FRAC_CONST(0.98364555835724) }, + { FRAC_CONST(0.93379634618759), FRAC_CONST(-0.70881992578506) }, + { FRAC_CONST(-0.85235410928726), FRAC_CONST(-0.08342348039150) }, + { FRAC_CONST(-0.86425095796585), FRAC_CONST(-0.45795026421547) }, + { FRAC_CONST(0.38879778981209), FRAC_CONST(0.97274428606033) }, + { FRAC_CONST(0.92045122385025), FRAC_CONST(-0.62433654069901) }, + { FRAC_CONST(0.89162534475327), FRAC_CONST(0.54950958490372) }, + { FRAC_CONST(-0.36834338307381), FRAC_CONST(0.96458297967911) }, + { FRAC_CONST(0.93891763687134), FRAC_CONST(-0.89968353509903) }, + { FRAC_CONST(0.99267655611038), FRAC_CONST(-0.03757034242153) }, + { FRAC_CONST(-0.94063472747803), FRAC_CONST(0.41332337260246) }, + { FRAC_CONST(0.99740225076675), FRAC_CONST(-0.16830494999886) }, + { FRAC_CONST(-0.35899412631989), FRAC_CONST(-0.46633225679398) }, + { FRAC_CONST(0.05237237364054), FRAC_CONST(-0.25640362501144) }, + { FRAC_CONST(0.36703583598137), FRAC_CONST(-0.38653266429901) }, + { FRAC_CONST(0.91653180122375), FRAC_CONST(-0.30587628483772) }, + { FRAC_CONST(0.69000804424286), FRAC_CONST(0.90952169895172) }, + { FRAC_CONST(-0.38658750057220), FRAC_CONST(0.99501574039459) }, + { FRAC_CONST(-0.29250815510750), FRAC_CONST(0.37444993853569) }, + { FRAC_CONST(-0.60182201862335), FRAC_CONST(0.86779648065567) }, + { FRAC_CONST(-0.97418588399887), FRAC_CONST(0.96468526124954) }, + { FRAC_CONST(0.88461571931839), FRAC_CONST(0.57508403062820) }, + { FRAC_CONST(0.05198933184147), FRAC_CONST(0.21269661188126) }, + { FRAC_CONST(-0.53499621152878), FRAC_CONST(0.97241556644440) }, + { FRAC_CONST(-0.49429559707642), FRAC_CONST(0.98183864355087) }, + { FRAC_CONST(-0.98935145139694), FRAC_CONST(-0.40249159932137) }, + { FRAC_CONST(-0.98081380128860), FRAC_CONST(-0.72856897115707) }, + { FRAC_CONST(-0.27338150143623), FRAC_CONST(0.99950921535492) }, + { FRAC_CONST(0.06310802698135), FRAC_CONST(-0.54539585113525) }, + { FRAC_CONST(-0.20461677014828), FRAC_CONST(-0.14209978282452) }, + { FRAC_CONST(0.66223841905594), FRAC_CONST(0.72528582811356) }, + { FRAC_CONST(-0.84764343500137), FRAC_CONST(0.02372316829860) }, + { FRAC_CONST(-0.89039862155914), FRAC_CONST(0.88866579532623) }, + { FRAC_CONST(0.95903307199478), FRAC_CONST(0.76744925975800) }, + { FRAC_CONST(0.73504126071930), FRAC_CONST(-0.03747203201056) }, + { FRAC_CONST(-0.31744435429573), FRAC_CONST(-0.36834111809731) }, + { FRAC_CONST(-0.34110826253891), FRAC_CONST(0.40211221575737) }, + { FRAC_CONST(0.47803884744644), FRAC_CONST(-0.39423218369484) }, + { FRAC_CONST(0.98299193382263), FRAC_CONST(0.01989791356027) }, + { FRAC_CONST(-0.30963072180748), FRAC_CONST(-0.18076720833778) }, + { FRAC_CONST(0.99992591142654), FRAC_CONST(-0.26281872391701) }, + { FRAC_CONST(-0.93149733543396), FRAC_CONST(-0.98313164710999) }, + { FRAC_CONST(0.99923473596573), FRAC_CONST(-0.80142992734909) }, + { FRAC_CONST(-0.26024168729782), FRAC_CONST(-0.75999760627747) }, + { FRAC_CONST(-0.35712513327599), FRAC_CONST(0.19298963248730) }, + { FRAC_CONST(-0.99899083375931), FRAC_CONST(0.74645155668259) }, + { FRAC_CONST(0.86557173728943), FRAC_CONST(0.55593866109848) }, + { FRAC_CONST(0.33408042788506), FRAC_CONST(0.86185956001282) }, + { FRAC_CONST(0.99010735750198), FRAC_CONST(0.04602397605777) }, + { FRAC_CONST(-0.66694271564484), FRAC_CONST(-0.91643613576889) }, + { FRAC_CONST(0.64016789197922), FRAC_CONST(0.15649530291557) }, + { FRAC_CONST(0.99570536613464), FRAC_CONST(0.45844584703445) }, + { FRAC_CONST(-0.63431465625763), FRAC_CONST(0.21079117059708) }, + { FRAC_CONST(-0.07706847041845), FRAC_CONST(-0.89581435918808) }, + { FRAC_CONST(0.98590087890625), FRAC_CONST(0.88241720199585) }, + { FRAC_CONST(0.80099332332611), FRAC_CONST(-0.36851897835732) }, + { FRAC_CONST(0.78368133306503), FRAC_CONST(0.45506998896599) }, + { FRAC_CONST(0.08707806468010), FRAC_CONST(0.80938994884491) }, + { FRAC_CONST(-0.86811882257462), FRAC_CONST(0.39347308874130) }, + { FRAC_CONST(-0.39466530084610), FRAC_CONST(-0.66809433698654) }, + { FRAC_CONST(0.97875326871872), FRAC_CONST(-0.72467839717865) }, + { FRAC_CONST(-0.95038563013077), FRAC_CONST(0.89563220739365) }, + { FRAC_CONST(0.17005239427090), FRAC_CONST(0.54683053493500) }, + { FRAC_CONST(-0.76910793781281), FRAC_CONST(-0.96226614713669) }, + { FRAC_CONST(0.99743282794952), FRAC_CONST(0.42697158455849) }, + { FRAC_CONST(0.95437383651733), FRAC_CONST(0.97002321481705) }, + { FRAC_CONST(0.99578905105591), FRAC_CONST(-0.54106825590134) }, + { FRAC_CONST(0.28058260679245), FRAC_CONST(-0.85361421108246) }, + { FRAC_CONST(0.85256522893906), FRAC_CONST(-0.64567607641220) }, + { FRAC_CONST(-0.50608539581299), FRAC_CONST(-0.65846014022827) }, + { FRAC_CONST(-0.97210735082626), FRAC_CONST(-0.23095212876797) }, + { FRAC_CONST(0.95424050092697), FRAC_CONST(-0.99240148067474) }, + { FRAC_CONST(-0.96926569938660), FRAC_CONST(0.73775655031204) }, + { FRAC_CONST(0.30872163176537), FRAC_CONST(0.41514959931374) }, + { FRAC_CONST(-0.24523839354515), FRAC_CONST(0.63206630945206) }, + { FRAC_CONST(-0.33813264966011), FRAC_CONST(-0.38661777973175) }, + { FRAC_CONST(-0.05826828256249), FRAC_CONST(-0.06940773874521) }, + { FRAC_CONST(-0.22898460924625), FRAC_CONST(0.97054851055145) }, + { FRAC_CONST(-0.18509915471077), FRAC_CONST(0.47565764188766) }, + { FRAC_CONST(-0.10488238185644), FRAC_CONST(-0.87769949436188) }, + { FRAC_CONST(-0.71886587142944), FRAC_CONST(0.78030979633331) }, + { FRAC_CONST(0.99793875217438), FRAC_CONST(0.90041309595108) }, + { FRAC_CONST(0.57563304901123), FRAC_CONST(-0.91034334897995) }, + { FRAC_CONST(0.28909647464752), FRAC_CONST(0.96307784318924) }, + { FRAC_CONST(0.42188999056816), FRAC_CONST(0.48148649930954) }, + { FRAC_CONST(0.93335050344467), FRAC_CONST(-0.43537023663521) }, + { FRAC_CONST(-0.97087377309799), FRAC_CONST(0.86636447906494) }, + { FRAC_CONST(0.36722871661186), FRAC_CONST(0.65291655063629) }, + { FRAC_CONST(-0.81093025207520), FRAC_CONST(0.08778370171785) }, + { FRAC_CONST(-0.26240602135658), FRAC_CONST(-0.92774093151093) }, + { FRAC_CONST(0.83996498584747), FRAC_CONST(0.55839848518372) }, + { FRAC_CONST(-0.99909615516663), FRAC_CONST(-0.96024608612061) }, + { FRAC_CONST(0.74649465084076), FRAC_CONST(0.12144893407822) }, + { FRAC_CONST(-0.74774593114853), FRAC_CONST(-0.26898062229156) }, + { FRAC_CONST(0.95781666040421), FRAC_CONST(-0.79047924280167) }, + { FRAC_CONST(0.95472306013107), FRAC_CONST(-0.08588775992393) }, + { FRAC_CONST(0.48708331584930), FRAC_CONST(0.99999040365219) }, + { FRAC_CONST(0.46332037448883), FRAC_CONST(0.10964126139879) }, + { FRAC_CONST(-0.76497006416321), FRAC_CONST(0.89210927486420) }, + { FRAC_CONST(0.57397389411926), FRAC_CONST(0.35289704799652) }, + { FRAC_CONST(0.75374317169189), FRAC_CONST(0.96705216169357) }, + { FRAC_CONST(-0.59174400568008), FRAC_CONST(-0.89405369758606) }, + { FRAC_CONST(0.75087904930115), FRAC_CONST(-0.29612672328949) }, + { FRAC_CONST(-0.98607856035233), FRAC_CONST(0.25034910440445) }, + { FRAC_CONST(-0.40761056542397), FRAC_CONST(-0.90045571327209) }, + { FRAC_CONST(0.66929268836975), FRAC_CONST(0.98629492521286) }, + { FRAC_CONST(-0.97463697195053), FRAC_CONST(-0.00190223299433) }, + { FRAC_CONST(0.90145510435104), FRAC_CONST(0.99781388044357) }, + { FRAC_CONST(-0.87259286642075), FRAC_CONST(0.99233585596085) }, + { FRAC_CONST(-0.91529458761215), FRAC_CONST(-0.15698707103729) }, + { FRAC_CONST(-0.03305738791823), FRAC_CONST(-0.37205263972282) }, + { FRAC_CONST(0.07223051041365), FRAC_CONST(-0.88805001974106) }, + { FRAC_CONST(0.99498009681702), FRAC_CONST(0.97094357013702) }, + { FRAC_CONST(-0.74904936552048), FRAC_CONST(0.99985486268997) }, + { FRAC_CONST(0.04585228487849), FRAC_CONST(0.99812334775925) }, + { FRAC_CONST(-0.89054954051971), FRAC_CONST(-0.31791913509369) }, + { FRAC_CONST(-0.83782142400742), FRAC_CONST(0.97637635469437) }, + { FRAC_CONST(0.33454805612564), FRAC_CONST(-0.86231517791748) }, + { FRAC_CONST(-0.99707579612732), FRAC_CONST(0.93237990140915) }, + { FRAC_CONST(-0.22827528417110), FRAC_CONST(0.18874759972095) }, + { FRAC_CONST(0.67248046398163), FRAC_CONST(-0.03646211326122) }, + { FRAC_CONST(-0.05146538093686), FRAC_CONST(-0.92599701881409) }, + { FRAC_CONST(0.99947297573090), FRAC_CONST(0.93625229597092) }, + { FRAC_CONST(0.66951125860214), FRAC_CONST(0.98905825614929) }, + { FRAC_CONST(-0.99602955579758), FRAC_CONST(-0.44654715061188) }, + { FRAC_CONST(0.82104903459549), FRAC_CONST(0.99540740251541) }, + { FRAC_CONST(0.99186509847641), FRAC_CONST(0.72022998332977) }, + { FRAC_CONST(-0.65284591913223), FRAC_CONST(0.52186721563339) }, + { FRAC_CONST(0.93885445594788), FRAC_CONST(-0.74895310401917) }, + { FRAC_CONST(0.96735250949860), FRAC_CONST(0.90891814231873) }, + { FRAC_CONST(-0.22225968539715), FRAC_CONST(0.57124030590057) }, + { FRAC_CONST(-0.44132784008980), FRAC_CONST(-0.92688840627670) }, + { FRAC_CONST(-0.85694974660873), FRAC_CONST(0.88844531774521) }, + { FRAC_CONST(0.91783040761948), FRAC_CONST(-0.46356892585754) }, + { FRAC_CONST(0.72556972503662), FRAC_CONST(-0.99899554252625) }, + { FRAC_CONST(-0.99711579084396), FRAC_CONST(0.58211559057236) }, + { FRAC_CONST(0.77638977766037), FRAC_CONST(0.94321835041046) }, + { FRAC_CONST(0.07717324048281), FRAC_CONST(0.58638399839401) }, + { FRAC_CONST(-0.56049829721451), FRAC_CONST(0.82522302865982) }, + { FRAC_CONST(0.98398894071579), FRAC_CONST(0.39467439055443) }, + { FRAC_CONST(0.47546947002411), FRAC_CONST(0.68613046407700) }, + { FRAC_CONST(0.65675091743469), FRAC_CONST(0.18331636488438) }, + { FRAC_CONST(0.03273375332355), FRAC_CONST(-0.74933111667633) }, + { FRAC_CONST(-0.38684144616127), FRAC_CONST(0.51337349414825) }, + { FRAC_CONST(-0.97346270084381), FRAC_CONST(-0.96549361944199) }, + { FRAC_CONST(-0.53282153606415), FRAC_CONST(-0.91423267126083) }, + { FRAC_CONST(0.99817311763763), FRAC_CONST(0.61133575439453) }, + { FRAC_CONST(-0.50254499912262), FRAC_CONST(-0.88829338550568) }, + { FRAC_CONST(0.01995873264968), FRAC_CONST(0.85223513841629) }, + { FRAC_CONST(0.99930381774902), FRAC_CONST(0.94578897953033) }, + { FRAC_CONST(0.82907766103745), FRAC_CONST(-0.06323442608118) }, + { FRAC_CONST(-0.58660709857941), FRAC_CONST(0.96840775012970) }, + { FRAC_CONST(-0.17573736608028), FRAC_CONST(-0.48166921734810) }, + { FRAC_CONST(0.83434289693832), FRAC_CONST(-0.13023450970650) }, + { FRAC_CONST(0.05946491286159), FRAC_CONST(0.20511047542095) }, + { FRAC_CONST(0.81505483388901), FRAC_CONST(-0.94685947895050) }, + { FRAC_CONST(-0.44976380467415), FRAC_CONST(0.40894573926926) }, + { FRAC_CONST(-0.89746475219727), FRAC_CONST(0.99846577644348) }, + { FRAC_CONST(0.39677256345749), FRAC_CONST(-0.74854665994644) }, + { FRAC_CONST(-0.07588948309422), FRAC_CONST(0.74096214771271) }, + { FRAC_CONST(0.76343196630478), FRAC_CONST(0.41746628284454) }, + { FRAC_CONST(-0.74490106105804), FRAC_CONST(0.94725912809372) }, + { FRAC_CONST(0.64880120754242), FRAC_CONST(0.41336661577225) }, + { FRAC_CONST(0.62319535017014), FRAC_CONST(-0.93098312616348) }, + { FRAC_CONST(0.42215818166733), FRAC_CONST(-0.07712787389755) }, + { FRAC_CONST(0.02704554051161), FRAC_CONST(-0.05417517945170) }, + { FRAC_CONST(0.80001771450043), FRAC_CONST(0.91542196273804) }, + { FRAC_CONST(-0.79351830482483), FRAC_CONST(-0.36208897829056) }, + { FRAC_CONST(0.63872361183167), FRAC_CONST(0.08128252625465) }, + { FRAC_CONST(0.52890521287918), FRAC_CONST(0.60048872232437) }, + { FRAC_CONST(0.74238550662994), FRAC_CONST(0.04491915181279) }, + { FRAC_CONST(0.99096131324768), FRAC_CONST(-0.19451183080673) }, + { FRAC_CONST(-0.80412328243256), FRAC_CONST(-0.88513815402985) }, + { FRAC_CONST(-0.64612615108490), FRAC_CONST(0.72198677062988) }, + { FRAC_CONST(0.11657770723104), FRAC_CONST(-0.83662831783295) }, + { FRAC_CONST(-0.95053184032440), FRAC_CONST(-0.96939903497696) }, + { FRAC_CONST(-0.62228870391846), FRAC_CONST(0.82767260074615) }, + { FRAC_CONST(0.03004475869238), FRAC_CONST(-0.99738895893097) }, + { FRAC_CONST(-0.97987216711044), FRAC_CONST(0.36526128649712) }, + { FRAC_CONST(-0.99986982345581), FRAC_CONST(-0.36021611094475) }, + { FRAC_CONST(0.89110648632050), FRAC_CONST(-0.97894251346588) }, + { FRAC_CONST(0.10407960414886), FRAC_CONST(0.77357792854309) }, + { FRAC_CONST(0.95964735746384), FRAC_CONST(-0.35435819625854) }, + { FRAC_CONST(0.50843232870102), FRAC_CONST(0.96107691526413) }, + { FRAC_CONST(0.17006334662437), FRAC_CONST(-0.76854026317596) }, + { FRAC_CONST(0.25872674584389), FRAC_CONST(0.99893301725388) }, + { FRAC_CONST(-0.01115998718888), FRAC_CONST(0.98496019840240) }, + { FRAC_CONST(-0.79598701000214), FRAC_CONST(0.97138410806656) }, + { FRAC_CONST(-0.99264711141586), FRAC_CONST(-0.99542820453644) }, + { FRAC_CONST(-0.99829661846161), FRAC_CONST(0.01877138763666) }, + { FRAC_CONST(-0.70801013708115), FRAC_CONST(0.33680686354637) }, + { FRAC_CONST(-0.70467054843903), FRAC_CONST(0.93272775411606) }, + { FRAC_CONST(0.99846023321152), FRAC_CONST(-0.98725748062134) }, + { FRAC_CONST(-0.63364970684052), FRAC_CONST(-0.16473594307899) }, + { FRAC_CONST(-0.16258217394352), FRAC_CONST(-0.95939123630524) }, + { FRAC_CONST(-0.43645593523979), FRAC_CONST(-0.94805032014847) }, + { FRAC_CONST(-0.99848473072052), FRAC_CONST(0.96245169639587) }, + { FRAC_CONST(-0.16796459257603), FRAC_CONST(-0.98987513780594) }, + { FRAC_CONST(-0.87979227304459), FRAC_CONST(-0.71725726127625) }, + { FRAC_CONST(0.44183099269867), FRAC_CONST(-0.93568974733353) }, + { FRAC_CONST(0.93310177326202), FRAC_CONST(-0.99913311004639) }, + { FRAC_CONST(-0.93941932916641), FRAC_CONST(-0.56409376859665) }, + { FRAC_CONST(-0.88590002059937), FRAC_CONST(0.47624599933624) }, + { FRAC_CONST(0.99971461296082), FRAC_CONST(-0.83889955282211) }, + { FRAC_CONST(-0.75376385450363), FRAC_CONST(0.00814643409103) }, + { FRAC_CONST(0.93887686729431), FRAC_CONST(-0.11284527927637) }, + { FRAC_CONST(0.85126435756683), FRAC_CONST(0.52349251508713) }, + { FRAC_CONST(0.39701420068741), FRAC_CONST(0.81779634952545) }, + { FRAC_CONST(-0.37024465203285), FRAC_CONST(-0.87071657180786) }, + { FRAC_CONST(-0.36024826765060), FRAC_CONST(0.34655734896660) }, + { FRAC_CONST(-0.93388813734055), FRAC_CONST(-0.84476542472839) }, + { FRAC_CONST(-0.65298801660538), FRAC_CONST(-0.18439576029778) }, + { FRAC_CONST(0.11960318684578), FRAC_CONST(0.99899345636368) }, + { FRAC_CONST(0.94292563199997), FRAC_CONST(0.83163905143738) }, + { FRAC_CONST(0.75081145763397), FRAC_CONST(-0.35533222556114) }, + { FRAC_CONST(0.56721979379654), FRAC_CONST(-0.24076835811138) }, + { FRAC_CONST(0.46857765316963), FRAC_CONST(-0.30140233039856) }, + { FRAC_CONST(0.97312313318253), FRAC_CONST(-0.99548190832138) }, + { FRAC_CONST(-0.38299977779388), FRAC_CONST(0.98516911268234) }, + { FRAC_CONST(0.41025799512863), FRAC_CONST(0.02116736955941) }, + { FRAC_CONST(0.09638062119484), FRAC_CONST(0.04411984235048) }, + { FRAC_CONST(-0.85283249616623), FRAC_CONST(0.91475564241409) }, + { FRAC_CONST(0.88866806030273), FRAC_CONST(-0.99735265970230) }, + { FRAC_CONST(-0.48202428221703), FRAC_CONST(-0.96805608272552) }, + { FRAC_CONST(0.27572581171989), FRAC_CONST(0.58634752035141) }, + { FRAC_CONST(-0.65889132022858), FRAC_CONST(0.58835631608963) }, + { FRAC_CONST(0.98838084936142), FRAC_CONST(0.99994349479675) }, + { FRAC_CONST(-0.20651349425316), FRAC_CONST(0.54593044519424) }, + { FRAC_CONST(-0.62126415967941), FRAC_CONST(-0.59893679618835) }, + { FRAC_CONST(0.20320105552673), FRAC_CONST(-0.86879181861877) }, + { FRAC_CONST(-0.97790551185608), FRAC_CONST(0.96290808916092) }, + { FRAC_CONST(0.11112534999847), FRAC_CONST(0.21484763920307) }, + { FRAC_CONST(-0.41368338465691), FRAC_CONST(0.28216838836670) }, + { FRAC_CONST(0.24133038520813), FRAC_CONST(0.51294362545013) }, + { FRAC_CONST(-0.66393411159515), FRAC_CONST(-0.08249679952860) }, + { FRAC_CONST(-0.53697830438614), FRAC_CONST(-0.97649902105331) }, + { FRAC_CONST(-0.97224736213684), FRAC_CONST(0.22081333398819) }, + { FRAC_CONST(0.87392479181290), FRAC_CONST(-0.12796173989773) }, + { FRAC_CONST(0.19050361216068), FRAC_CONST(0.01602615416050) }, + { FRAC_CONST(-0.46353441476822), FRAC_CONST(-0.95249038934708) }, + { FRAC_CONST(-0.07064096629620), FRAC_CONST(-0.94479805231094) }, + { FRAC_CONST(-0.92444086074829), FRAC_CONST(-0.10457590222359) }, + { FRAC_CONST(-0.83822596073151), FRAC_CONST(-0.01695043221116) }, + { FRAC_CONST(0.75214684009552), FRAC_CONST(-0.99955683946609) }, + { FRAC_CONST(-0.42102998495102), FRAC_CONST(0.99720942974091) }, + { FRAC_CONST(-0.72094786167145), FRAC_CONST(-0.35008960962296) }, + { FRAC_CONST(0.78843313455582), FRAC_CONST(0.52851396799088) }, + { FRAC_CONST(0.97394025325775), FRAC_CONST(-0.26695942878723) }, + { FRAC_CONST(0.99206465482712), FRAC_CONST(-0.57010120153427) }, + { FRAC_CONST(0.76789611577988), FRAC_CONST(-0.76519358158112) }, + { FRAC_CONST(-0.82002419233322), FRAC_CONST(-0.73530179262161) }, + { FRAC_CONST(0.81924992799759), FRAC_CONST(0.99698424339294) }, + { FRAC_CONST(-0.26719850301743), FRAC_CONST(0.68903368711472) }, + { FRAC_CONST(-0.43311259150505), FRAC_CONST(0.85321813821793) }, + { FRAC_CONST(0.99194979667664), FRAC_CONST(0.91876250505447) }, + { FRAC_CONST(-0.80691999197006), FRAC_CONST(-0.32627540826797) }, + { FRAC_CONST(0.43080005049706), FRAC_CONST(-0.21919095516205) }, + { FRAC_CONST(0.67709493637085), FRAC_CONST(-0.95478075742722) }, + { FRAC_CONST(0.56151771545410), FRAC_CONST(-0.70693808794022) }, + { FRAC_CONST(0.10831862688065), FRAC_CONST(-0.08628837019205) }, + { FRAC_CONST(0.91229414939880), FRAC_CONST(-0.65987348556519) }, + { FRAC_CONST(-0.48972892761230), FRAC_CONST(0.56289243698120) }, + { FRAC_CONST(-0.89033657312393), FRAC_CONST(-0.71656566858292) }, + { FRAC_CONST(0.65269446372986), FRAC_CONST(0.65916007757187) }, + { FRAC_CONST(0.67439478635788), FRAC_CONST(-0.81684380769730) }, + { FRAC_CONST(-0.47770830988884), FRAC_CONST(-0.16789555549622) }, + { FRAC_CONST(-0.99715977907181), FRAC_CONST(-0.93565785884857) }, + { FRAC_CONST(-0.90889590978622), FRAC_CONST(0.62034398317337) }, + { FRAC_CONST(-0.06618622690439), FRAC_CONST(-0.23812216520309) }, + { FRAC_CONST(0.99430269002914), FRAC_CONST(0.18812555074692) }, + { FRAC_CONST(0.97686403989792), FRAC_CONST(-0.28664535284042) }, + { FRAC_CONST(0.94813650846481), FRAC_CONST(-0.97506642341614) }, + { FRAC_CONST(-0.95434498786926), FRAC_CONST(-0.79607981443405) }, + { FRAC_CONST(-0.49104782938957), FRAC_CONST(0.32895213365555) }, + { FRAC_CONST(0.99881172180176), FRAC_CONST(0.88993984460831) }, + { FRAC_CONST(0.50449168682098), FRAC_CONST(-0.85995072126389) }, + { FRAC_CONST(0.47162890434265), FRAC_CONST(-0.18680204451084) }, + { FRAC_CONST(-0.62081581354141), FRAC_CONST(0.75000673532486) }, + { FRAC_CONST(-0.43867015838623), FRAC_CONST(0.99998068809509) }, + { FRAC_CONST(0.98630565404892), FRAC_CONST(-0.53578901290894) }, + { FRAC_CONST(-0.61510360240936), FRAC_CONST(-0.89515018463135) }, + { FRAC_CONST(-0.03841517493129), FRAC_CONST(-0.69888818264008) }, + { FRAC_CONST(-0.30102157592773), FRAC_CONST(-0.07667808979750) }, + { FRAC_CONST(0.41881284117699), FRAC_CONST(0.02188098989427) }, + { FRAC_CONST(-0.86135452985764), FRAC_CONST(0.98947483301163) }, + { FRAC_CONST(0.67226862907410), FRAC_CONST(-0.13494388759136) }, + { FRAC_CONST(-0.70737397670746), FRAC_CONST(-0.76547348499298) }, + { FRAC_CONST(0.94044947624207), FRAC_CONST(0.09026201069355) }, + { FRAC_CONST(-0.82386350631714), FRAC_CONST(0.08924768865108) }, + { FRAC_CONST(-0.32070666551590), FRAC_CONST(0.50143420696259) }, + { FRAC_CONST(0.57593160867691), FRAC_CONST(-0.98966425657272) }, + { FRAC_CONST(-0.36326017975807), FRAC_CONST(0.07440242916346) }, + { FRAC_CONST(0.99979043006897), FRAC_CONST(-0.14130286872387) }, + { FRAC_CONST(-0.92366021871567), FRAC_CONST(-0.97979295253754) }, + { FRAC_CONST(-0.44607177376747), FRAC_CONST(-0.54233253002167) }, + { FRAC_CONST(0.44226801395416), FRAC_CONST(0.71326756477356) }, + { FRAC_CONST(0.03671907261014), FRAC_CONST(0.63606387376785) }, + { FRAC_CONST(0.52175426483154), FRAC_CONST(-0.85396826267242) }, + { FRAC_CONST(-0.94701141119003), FRAC_CONST(-0.01826348155737) }, + { FRAC_CONST(-0.98759609460831), FRAC_CONST(0.82288712263107) }, + { FRAC_CONST(0.87434792518616), FRAC_CONST(0.89399492740631) }, + { FRAC_CONST(-0.93412041664124), FRAC_CONST(0.41374051570892) }, + { FRAC_CONST(0.96063941717148), FRAC_CONST(0.93116706609726) }, + { FRAC_CONST(0.97534251213074), FRAC_CONST(0.86150932312012) }, + { FRAC_CONST(0.99642467498779), FRAC_CONST(0.70190042257309) }, + { FRAC_CONST(-0.94705086946487), FRAC_CONST(-0.29580041766167) }, + { FRAC_CONST(0.91599804162979), FRAC_CONST(-0.98147833347321) } +}; + +#ifdef __cplusplus + +#endif +#endif
\ No newline at end of file diff --git a/src/libfaad/sbr_qmf.c b/src/libfaad/sbr_qmf.c new file mode 100644 index 000000000..fb7623b3f --- /dev/null +++ b/src/libfaad/sbr_qmf.c @@ -0,0 +1,569 @@ +/* +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** +** This program is free software; you can redistribute it and/or modify +** it under the terms of the GNU General Public License as published by +** the Free Software Foundation; either version 2 of the License, or +** (at your option) any later version. +** +** This program is distributed in the hope that it will be useful, +** but WITHOUT ANY WARRANTY; without even the implied warranty of +** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +** GNU General Public License for more details. +** +** You should have received a copy of the GNU General Public License +** along with this program; if not, write to the Free Software +** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +** +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: sbr_qmf.c,v 1.3 2003/12/30 02:00:11 miguelfreitas Exp $ +**/ + +#include "common.h" +#include "structs.h" + +#ifdef SBR_DEC + + +#include <stdlib.h> +#include <string.h> +#include "sbr_dct.h" +#include "sbr_qmf.h" +#include "sbr_qmf_c.h" +#include "sbr_syntax.h" + + +qmfa_info *qmfa_init(uint8_t channels) +{ + qmfa_info *qmfa = (qmfa_info*)faad_malloc(sizeof(qmfa_info)); + qmfa->x = (real_t*)faad_malloc(channels * 10 * sizeof(real_t)); + memset(qmfa->x, 0, channels * 10 * sizeof(real_t)); + + qmfa->channels = channels; + + return qmfa; +} + +void qmfa_end(qmfa_info *qmfa) +{ + if (qmfa) + { + if (qmfa->x) faad_free(qmfa->x); + faad_free(qmfa); + } +} + +void sbr_qmf_analysis_32(sbr_info *sbr, qmfa_info *qmfa, const real_t *input, + qmf_t X[MAX_NTSRHFG][32], uint8_t offset, uint8_t kx) +{ + ALIGN real_t u[64]; +#ifndef SBR_LOW_POWER + ALIGN real_t x[64], y[64]; +#else + ALIGN real_t y[32]; +#endif + uint16_t in = 0; + uint8_t l; + + /* qmf subsample l */ + for (l = 0; l < sbr->numTimeSlotsRate; l++) + { + int16_t n; + + /* shift input buffer x */ + memmove(qmfa->x + 32, qmfa->x, (320-32)*sizeof(real_t)); + + /* add new samples to input buffer x */ + for (n = 32 - 1; n >= 0; n--) + { + qmfa->x[n] = input[in++]; + } + + /* window and summation to create array u */ + for (n = 0; n < 64; n++) + { + u[n] = MUL_F(qmfa->x[n], qmf_c[2*n]) + + MUL_F(qmfa->x[n + 64], qmf_c[2*(n + 64)]) + + MUL_F(qmfa->x[n + 128], qmf_c[2*(n + 128)]) + + MUL_F(qmfa->x[n + 192], qmf_c[2*(n + 192)]) + + MUL_F(qmfa->x[n + 256], qmf_c[2*(n + 256)]); + } + + /* calculate 32 subband samples by introducing X */ +#ifdef SBR_LOW_POWER + y[0] = u[48]; + for (n = 1; n < 16; n++) + y[n] = u[n+48] + u[48-n]; + for (n = 16; n < 32; n++) + y[n] = -u[n-16] + u[48-n]; + + DCT3_32_unscaled(u, y); + + for (n = 0; n < 32; n++) + { + if (n < kx) + { + QMF_RE(X[l + offset][n]) = 2. * u[n]; + } else { + QMF_RE(X[l + offset][n]) = 0; + } + } +#else + x[0] = u[0]; + for (n = 0; n < 31; n++) + { + x[2*n+1] = u[n+1] + u[63-n]; + x[2*n+2] = u[n+1] - u[63-n]; + } + x[63] = u[32]; + + DCT4_64_kernel(y, x); + + for (n = 0; n < 32; n++) + { + if (n < kx) + { + QMF_RE(X[l + offset][n]) = 2. * y[n]; + QMF_IM(X[l + offset][n]) = -2. * y[63-n]; + } else { + QMF_RE(X[l + offset][n]) = 0; + QMF_IM(X[l + offset][n]) = 0; + } + } +#endif + } +} + +qmfs_info *qmfs_init(uint8_t channels) +{ + qmfs_info *qmfs = (qmfs_info*)faad_malloc(sizeof(qmfs_info)); + +#ifndef SBR_LOW_POWER + qmfs->v[0] = (real_t*)faad_malloc(channels * 10 * sizeof(real_t)); + memset(qmfs->v[0], 0, channels * 10 * sizeof(real_t)); + qmfs->v[1] = (real_t*)faad_malloc(channels * 10 * sizeof(real_t)); + memset(qmfs->v[1], 0, channels * 10 * sizeof(real_t)); +#else + qmfs->v[0] = (real_t*)faad_malloc(channels * 20 * sizeof(real_t)); + memset(qmfs->v[0], 0, channels * 20 * sizeof(real_t)); + qmfs->v[1] = NULL; +#endif + + qmfs->v_index = 0; + + qmfs->channels = channels; + +#ifdef USE_SSE + if (cpu_has_sse()) + { + qmfs->qmf_func = sbr_qmf_synthesis_64_sse; + } else { + qmfs->qmf_func = sbr_qmf_synthesis_64; + } +#endif + + return qmfs; +} + +void qmfs_end(qmfs_info *qmfs) +{ + if (qmfs) + { + if (qmfs->v[0]) faad_free(qmfs->v[0]); +#ifndef SBR_LOW_POWER + if (qmfs->v[1]) faad_free(qmfs->v[1]); +#endif + faad_free(qmfs); + } +} + +#ifdef SBR_LOW_POWER +void sbr_qmf_synthesis_64(sbr_info *sbr, qmfs_info *qmfs, const qmf_t X[MAX_NTSRHFG][64], + real_t *output) +{ + ALIGN real_t x[64]; + ALIGN real_t y[64]; + int16_t n, k, out = 0; + uint8_t l; + + + /* qmf subsample l */ + for (l = 0; l < sbr->numTimeSlotsRate; l++) + { + //real_t *v0, *v1; + + /* shift buffers */ + //memmove(qmfs->v[0] + 64, qmfs->v[0], (640-64)*sizeof(real_t)); + //memmove(qmfs->v[1] + 64, qmfs->v[1], (640-64)*sizeof(real_t)); + memmove(qmfs->v[0] + 128, qmfs->v[0], (1280-128)*sizeof(real_t)); + + //v0 = qmfs->v[qmfs->v_index]; + //v1 = qmfs->v[(qmfs->v_index + 1) & 0x1]; + //qmfs->v_index = (qmfs->v_index + 1) & 0x1; + + /* calculate 128 samples */ + for (k = 0; k < 64; k++) + { + x[k] = QMF_RE(X[l][k]) / 32.; + } + + for (n = 0; n < 32; n++) + { + y[2*n] = -x[2*n]; + y[2*n+1] = x[2*n+1]; + } + + DCT2_64_unscaled(x, x); + + for (n = 0; n < 64; n++) + { + qmfs->v[0][n+32] = x[n]; + } + for (n = 0; n < 32; n++) + { + qmfs->v[0][31 - n] = x[n + 1]; + } + DST2_64_unscaled(x, y); + qmfs->v[0][96] = 0; + for (n = 1; n < 32; n++) + { + qmfs->v[0][n + 96] = x[n-1]; + } + + /* calculate 64 output samples and window */ + for (k = 0; k < 64; k++) + { +#if 1 + output[out++] = MUL_F(qmfs->v[0][k], qmf_c[k]) + + MUL_F(qmfs->v[0][192 + k], qmf_c[64 + k]) + + MUL_F(qmfs->v[0][256 + k], qmf_c[128 + k]) + + MUL_F(qmfs->v[0][256 + 192 + k], qmf_c[128 + 64 + k]) + + MUL_F(qmfs->v[0][512 + k], qmf_c[256 + k]) + + MUL_F(qmfs->v[0][512 + 192 + k], qmf_c[256 + 64 + k]) + + MUL_F(qmfs->v[0][768 + k], qmf_c[384 + k]) + + MUL_F(qmfs->v[0][768 + 192 + k], qmf_c[384 + 64 + k]) + + MUL_F(qmfs->v[0][1024 + k], qmf_c[512 + k]) + + MUL_F(qmfs->v[0][1024 + 192 + k], qmf_c[512 + 64 + k]); +#else + output[out++] = MUL_F(v0[k], qmf_c[k]) + + MUL_F(v0[64 + k], qmf_c[64 + k]) + + MUL_F(v0[128 + k], qmf_c[128 + k]) + + MUL_F(v0[192 + k], qmf_c[192 + k]) + + MUL_F(v0[256 + k], qmf_c[256 + k]) + + MUL_F(v0[320 + k], qmf_c[320 + k]) + + MUL_F(v0[384 + k], qmf_c[384 + k]) + + MUL_F(v0[448 + k], qmf_c[448 + k]) + + MUL_F(v0[512 + k], qmf_c[512 + k]) + + MUL_F(v0[576 + k], qmf_c[576 + k]); +#endif + } + } +} + +void DST2(real_t *in, real_t *out, int32_t len) +{ + int r, i; + + for (r = 1; r <= len; r++) + { + double sum = 0; + for (i = 1; i <= len; i++) + { + sum += in[i-1] * sin(((real_t)r)*((real_t)i-0.5)*M_PI/(real_t)len); + } + out[r-1] = (real_t)sum; + } +} + +void DCT2(real_t *in, real_t *out, int32_t len) +{ + int r, i; + + for (r = 0; r < len; r++) + { + double sum = 0; + for (i = 0; i < len; i++) + { + sum += in[i] * cos(((real_t)r)*((real_t)i+0.5)*M_PI/(real_t)len); + } + out[r] = (real_t)sum; + } +} + +void sbr_qmf_synthesis_64_sse(sbr_info *sbr, qmfs_info *qmfs, const qmf_t X[MAX_NTSRHFG][64], + real_t *output) +{ + ALIGN real_t x[64]; + ALIGN real_t y[64]; + ALIGN real_t y2[64]; + int16_t n, k, out = 0; + uint8_t l; + + /* qmf subsample l */ + for (l = 0; l < sbr->numTimeSlotsRate; l++) + { + //real_t *v0, *v1; + + /* shift buffers */ + //memmove(qmfs->v[0] + 64, qmfs->v[0], (640-64)*sizeof(real_t)); + //memmove(qmfs->v[1] + 64, qmfs->v[1], (640-64)*sizeof(real_t)); + memmove(qmfs->v[0] + 128, qmfs->v[0], (1280-128)*sizeof(real_t)); + + //v0 = qmfs->v[qmfs->v_index]; + //v1 = qmfs->v[(qmfs->v_index + 1) & 0x1]; + //qmfs->v_index = (qmfs->v_index + 1) & 0x1; + + /* calculate 128 samples */ + for (k = 0; k < 64; k++) + { + x[k] = QMF_RE(X[l][k]) / 32.; + } + + for (n = 0; n < 32; n++) + { + y[2*n] = -x[2*n]; + y[2*n+1] = x[2*n+1]; + } + + DCT2_64_unscaled(x, x); + + for (n = 0; n < 64; n++) + { + qmfs->v[0][n+32] = x[n]; + } + for (n = 0; n < 32; n++) + { + qmfs->v[0][31 - n] = x[n + 1]; + } + + DST2_64_unscaled(x, y); + qmfs->v[0][96] = 0; + for (n = 1; n < 32; n++) + { + qmfs->v[0][n + 96] = x[n-1]; + } + + /* calculate 64 output samples and window */ + for (k = 0; k < 64; k++) + { +#if 1 + output[out++] = MUL_F(qmfs->v[0][k], qmf_c[k]) + + MUL_F(qmfs->v[0][192 + k], qmf_c[64 + k]) + + MUL_F(qmfs->v[0][256 + k], qmf_c[128 + k]) + + MUL_F(qmfs->v[0][256 + 192 + k], qmf_c[128 + 64 + k]) + + MUL_F(qmfs->v[0][512 + k], qmf_c[256 + k]) + + MUL_F(qmfs->v[0][512 + 192 + k], qmf_c[256 + 64 + k]) + + MUL_F(qmfs->v[0][768 + k], qmf_c[384 + k]) + + MUL_F(qmfs->v[0][768 + 192 + k], qmf_c[384 + 64 + k]) + + MUL_F(qmfs->v[0][1024 + k], qmf_c[512 + k]) + + MUL_F(qmfs->v[0][1024 + 192 + k], qmf_c[512 + 64 + k]); +#else + output[out++] = MUL_F(v0[k], qmf_c[k]) + + MUL_F(v0[64 + k], qmf_c[64 + k]) + + MUL_F(v0[128 + k], qmf_c[128 + k]) + + MUL_F(v0[192 + k], qmf_c[192 + k]) + + MUL_F(v0[256 + k], qmf_c[256 + k]) + + MUL_F(v0[320 + k], qmf_c[320 + k]) + + MUL_F(v0[384 + k], qmf_c[384 + k]) + + MUL_F(v0[448 + k], qmf_c[448 + k]) + + MUL_F(v0[512 + k], qmf_c[512 + k]) + + MUL_F(v0[576 + k], qmf_c[576 + k]); +#endif + } + } +} +#else +void sbr_qmf_synthesis_64(sbr_info *sbr, qmfs_info *qmfs, const qmf_t X[MAX_NTSRHFG][64], + real_t *output) +{ + ALIGN real_t x1[64], x2[64]; + real_t scale = 1.f/64.f; + int16_t n, k, out = 0; + uint8_t l; + + + /* qmf subsample l */ + for (l = 0; l < sbr->numTimeSlotsRate; l++) + { + real_t *v0, *v1; + + /* shift buffers */ + memmove(qmfs->v[0] + 64, qmfs->v[0], (640-64)*sizeof(real_t)); + memmove(qmfs->v[1] + 64, qmfs->v[1], (640-64)*sizeof(real_t)); + + v0 = qmfs->v[qmfs->v_index]; + v1 = qmfs->v[(qmfs->v_index + 1) & 0x1]; + qmfs->v_index = (qmfs->v_index + 1) & 0x1; + + /* calculate 128 samples */ + x1[0] = scale*QMF_RE(X[l][0]); + x2[63] = scale*QMF_IM(X[l][0]); + for (k = 0; k < 31; k++) + { + x1[2*k+1] = scale*(QMF_RE(X[l][2*k+1]) - QMF_RE(X[l][2*k+2])); + x1[2*k+2] = scale*(QMF_RE(X[l][2*k+1]) + QMF_RE(X[l][2*k+2])); + + x2[61 - 2*k] = scale*(QMF_IM(X[l][2*k+2]) - QMF_IM(X[l][2*k+1])); + x2[62 - 2*k] = scale*(QMF_IM(X[l][2*k+2]) + QMF_IM(X[l][2*k+1])); + } + x1[63] = scale*QMF_RE(X[l][63]); + x2[0] = scale*QMF_IM(X[l][63]); + + DCT4_64_kernel(x1, x1); + DCT4_64_kernel(x2, x2); + + for (n = 0; n < 32; n++) + { + v0[ 2*n] = x2[2*n] - x1[2*n]; + v1[63-2*n] = x2[2*n] + x1[2*n]; + v0[ 2*n+1] = -x2[2*n+1] - x1[2*n+1]; + v1[62-2*n] = -x2[2*n+1] + x1[2*n+1]; + } + + /* calculate 64 output samples and window */ + for (k = 0; k < 64; k++) + { + output[out++] = MUL_F(v0[k], qmf_c[k]) + + MUL_F(v0[64 + k], qmf_c[64 + k]) + + MUL_F(v0[128 + k], qmf_c[128 + k]) + + MUL_F(v0[192 + k], qmf_c[192 + k]) + + MUL_F(v0[256 + k], qmf_c[256 + k]) + + MUL_F(v0[320 + k], qmf_c[320 + k]) + + MUL_F(v0[384 + k], qmf_c[384 + k]) + + MUL_F(v0[448 + k], qmf_c[448 + k]) + + MUL_F(v0[512 + k], qmf_c[512 + k]) + + MUL_F(v0[576 + k], qmf_c[576 + k]); + } + } +} + +#ifdef USE_SSE +void memmove_sse_576(real_t *out, const real_t *in) +{ + __m128 m[144]; + uint16_t i; + + for (i = 0; i < 144; i++) + { + m[i] = _mm_load_ps(&in[i*4]); + } + for (i = 0; i < 144; i++) + { + _mm_store_ps(&out[i*4], m[i]); + } +} + +void sbr_qmf_synthesis_64_sse(sbr_info *sbr, qmfs_info *qmfs, const qmf_t X[MAX_NTSRHFG][64], + real_t *output) +{ + ALIGN real_t x1[64], x2[64]; + real_t scale = 1.f/64.f; + int16_t n, k, out = 0; + uint8_t l; + + + /* qmf subsample l */ + for (l = 0; l < sbr->numTimeSlotsRate; l++) + { + real_t *v0, *v1; + + /* shift buffers */ + memmove_sse_576(qmfs->v[0] + 64, qmfs->v[0]); + memmove_sse_576(qmfs->v[1] + 64, qmfs->v[1]); + + v0 = qmfs->v[qmfs->v_index]; + v1 = qmfs->v[(qmfs->v_index + 1) & 0x1]; + qmfs->v_index = (qmfs->v_index + 1) & 0x1; + + /* calculate 128 samples */ + x1[0] = scale*QMF_RE(X[l][0]); + x2[63] = scale*QMF_IM(X[l][0]); + for (k = 0; k < 31; k++) + { + x1[2*k+1] = scale*(QMF_RE(X[l][2*k+1]) - QMF_RE(X[l][2*k+2])); + x1[2*k+2] = scale*(QMF_RE(X[l][2*k+1]) + QMF_RE(X[l][2*k+2])); + + x2[61 - 2*k] = scale*(QMF_IM(X[l][2*k+2]) - QMF_IM(X[l][2*k+1])); + x2[62 - 2*k] = scale*(QMF_IM(X[l][2*k+2]) + QMF_IM(X[l][2*k+1])); + } + x1[63] = scale*QMF_RE(X[l][63]); + x2[0] = scale*QMF_IM(X[l][63]); + + DCT4_64_kernel(x1, x1); + DCT4_64_kernel(x2, x2); + + for (n = 0; n < 32; n++) + { + v0[ 2*n ] = x2[2*n] - x1[2*n]; + v1[63- 2*n ] = x2[2*n] + x1[2*n]; + v0[ 2*n+1 ] = -x2[2*n+1] - x1[2*n+1]; + v1[63-(2*n+1)] = -x2[2*n+1] + x1[2*n+1]; + } + + /* calculate 64 output samples and window */ + for (k = 0; k < 64; k+=4) + { + __m128 m0, m1, m2, m3, m4, m5, m6, m7, m8, m9; + __m128 c0, c1, c2, c3, c4, c5, c6, c7, c8, c9; + __m128 s1, s2, s3, s4, s5, s6, s7, s8, s9; + + m0 = _mm_load_ps(&v0[k]); + m1 = _mm_load_ps(&v0[k + 64]); + m2 = _mm_load_ps(&v0[k + 128]); + m3 = _mm_load_ps(&v0[k + 192]); + m4 = _mm_load_ps(&v0[k + 256]); + c0 = _mm_load_ps(&qmf_c[k]); + c1 = _mm_load_ps(&qmf_c[k + 64]); + c2 = _mm_load_ps(&qmf_c[k + 128]); + c3 = _mm_load_ps(&qmf_c[k + 192]); + c4 = _mm_load_ps(&qmf_c[k + 256]); + + m0 = _mm_mul_ps(m0, c0); + m1 = _mm_mul_ps(m1, c1); + m2 = _mm_mul_ps(m2, c2); + m3 = _mm_mul_ps(m3, c3); + m4 = _mm_mul_ps(m4, c4); + + s1 = _mm_add_ps(m0, m1); + s2 = _mm_add_ps(m2, m3); + s6 = _mm_add_ps(s1, s2); + + m5 = _mm_load_ps(&v0[k + 320]); + m6 = _mm_load_ps(&v0[k + 384]); + m7 = _mm_load_ps(&v0[k + 448]); + m8 = _mm_load_ps(&v0[k + 512]); + m9 = _mm_load_ps(&v0[k + 576]); + c5 = _mm_load_ps(&qmf_c[k + 320]); + c6 = _mm_load_ps(&qmf_c[k + 384]); + c7 = _mm_load_ps(&qmf_c[k + 448]); + c8 = _mm_load_ps(&qmf_c[k + 512]); + c9 = _mm_load_ps(&qmf_c[k + 576]); + + m5 = _mm_mul_ps(m5, c5); + m6 = _mm_mul_ps(m6, c6); + m7 = _mm_mul_ps(m7, c7); + m8 = _mm_mul_ps(m8, c8); + m9 = _mm_mul_ps(m9, c9); + + s3 = _mm_add_ps(m4, m5); + s4 = _mm_add_ps(m6, m7); + s5 = _mm_add_ps(m8, m9); + s7 = _mm_add_ps(s3, s4); + s8 = _mm_add_ps(s5, s6); + s9 = _mm_add_ps(s7, s8); + + _mm_store_ps(&output[out], s9); + out += 4; + } + } +} +#endif +#endif + +#endif diff --git a/src/libfaad/sbr_qmf.h b/src/libfaad/sbr_qmf.h new file mode 100644 index 000000000..9835d6139 --- /dev/null +++ b/src/libfaad/sbr_qmf.h @@ -0,0 +1,56 @@ +/* +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** +** This program is free software; you can redistribute it and/or modify +** it under the terms of the GNU General Public License as published by +** the Free Software Foundation; either version 2 of the License, or +** (at your option) any later version. +** +** This program is distributed in the hope that it will be useful, +** but WITHOUT ANY WARRANTY; without even the implied warranty of +** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +** GNU General Public License for more details. +** +** You should have received a copy of the GNU General Public License +** along with this program; if not, write to the Free Software +** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +** +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: sbr_qmf.h,v 1.3 2003/12/30 02:00:11 miguelfreitas Exp $ +**/ + +#ifndef __SBR_QMF_H__ +#define __SBR_QMF_H__ + +#ifdef __cplusplus +extern "C" { +#endif + +qmfa_info *qmfa_init(uint8_t channels); +void qmfa_end(qmfa_info *qmfa); +qmfs_info *qmfs_init(uint8_t channels); +void qmfs_end(qmfs_info *qmfs); + +void sbr_qmf_analysis_32(sbr_info *sbr, qmfa_info *qmfa, const real_t *input, + qmf_t X[MAX_NTSRHFG][32], uint8_t offset, uint8_t kx); +void sbr_qmf_synthesis_32(qmfs_info *qmfs, const qmf_t *X, + real_t *output); +void sbr_qmf_synthesis_64(sbr_info *sbr, qmfs_info *qmfs, const qmf_t X[MAX_NTSRHFG][64], + real_t *output); +#ifdef USE_SSE +void sbr_qmf_synthesis_64_sse(sbr_info *sbr, qmfs_info *qmfs, const qmf_t X[MAX_NTSRHFG][64], + real_t *output); +#endif + + +#ifdef __cplusplus +} +#endif +#endif + diff --git a/src/libfaad/sbr_qmf_c.h b/src/libfaad/sbr_qmf_c.h new file mode 100644 index 000000000..b02cbcd37 --- /dev/null +++ b/src/libfaad/sbr_qmf_c.h @@ -0,0 +1,364 @@ +/* +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** +** This program is free software; you can redistribute it and/or modify +** it under the terms of the GNU General Public License as published by +** the Free Software Foundation; either version 2 of the License, or +** (at your option) any later version. +** +** This program is distributed in the hope that it will be useful, +** but WITHOUT ANY WARRANTY; without even the implied warranty of +** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +** GNU General Public License for more details. +** +** You should have received a copy of the GNU General Public License +** along with this program; if not, write to the Free Software +** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +** +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: sbr_qmf_c.h,v 1.1 2003/12/30 02:00:11 miguelfreitas Exp $ +**/ + +#ifndef __SBR_QMF_C_H__ +#define __SBR_QMF_C_H__ + +#ifdef __cplusplus +extern "C" { +#endif + + +#ifdef _MSC_VER +#pragma warning(disable:4305) +#pragma warning(disable:4244) +#endif + +ALIGN static const real_t qmf_c[640] = { + FRAC_CONST(0), FRAC_CONST(-0.00055252865047), + FRAC_CONST(-0.00056176925738), FRAC_CONST(-0.00049475180896), + FRAC_CONST(-0.00048752279712), FRAC_CONST(-0.00048937912498), + FRAC_CONST(-0.00050407143497), FRAC_CONST(-0.00052265642972), + FRAC_CONST(-0.00054665656337), FRAC_CONST(-0.00056778025613), + FRAC_CONST(-0.00058709304852), FRAC_CONST(-0.00061327473938), + FRAC_CONST(-0.00063124935319), FRAC_CONST(-0.00065403333621), + FRAC_CONST(-0.00067776907764), FRAC_CONST(-0.00069416146273), + FRAC_CONST(-0.00071577364744), FRAC_CONST(-0.00072550431222), + FRAC_CONST(-0.00074409418541), FRAC_CONST(-0.00074905980532), + FRAC_CONST(-0.0007681371927), FRAC_CONST(-0.00077248485949), + FRAC_CONST(-0.00078343322877), FRAC_CONST(-0.00077798694927), + FRAC_CONST(-0.000780366471), FRAC_CONST(-0.00078014496257), + FRAC_CONST(-0.0007757977331), FRAC_CONST(-0.00076307935757), + FRAC_CONST(-0.00075300014201), FRAC_CONST(-0.00073193571525), + FRAC_CONST(-0.00072153919876), FRAC_CONST(-0.00069179375372), + FRAC_CONST(-0.00066504150893), FRAC_CONST(-0.00063415949025), + FRAC_CONST(-0.0005946118933), FRAC_CONST(-0.00055645763906), + FRAC_CONST(-0.00051455722108), FRAC_CONST(-0.00046063254803), + FRAC_CONST(-0.00040951214522), FRAC_CONST(-0.00035011758756), + FRAC_CONST(-0.00028969811748), FRAC_CONST(-0.0002098337344), + FRAC_CONST(-0.00014463809349), FRAC_CONST(-6.173344072E-005), + FRAC_CONST(1.349497418E-005), FRAC_CONST(0.00010943831274), + FRAC_CONST(0.00020430170688), FRAC_CONST(0.00029495311041), + FRAC_CONST(0.0004026540216), FRAC_CONST(0.00051073884952), + FRAC_CONST(0.00062393761391), FRAC_CONST(0.00074580258865), + FRAC_CONST(0.00086084433262), FRAC_CONST(0.00098859883015), + FRAC_CONST(0.00112501551307), FRAC_CONST(0.00125778846475), + FRAC_CONST(0.00139024948272), FRAC_CONST(0.00154432198471), + FRAC_CONST(0.00168680832531), FRAC_CONST(0.00183482654224), + FRAC_CONST(0.00198411407369), FRAC_CONST(0.00214615835557), + FRAC_CONST(0.00230172547746), FRAC_CONST(0.00246256169126), + FRAC_CONST(0.00262017586902), FRAC_CONST(0.00278704643465), + FRAC_CONST(0.00294694477165), FRAC_CONST(0.00311254206525), + FRAC_CONST(0.00327396134847), FRAC_CONST(0.00344188741828), + FRAC_CONST(0.00360082681231), FRAC_CONST(0.00376039229104), + FRAC_CONST(0.00392074323703), FRAC_CONST(0.00408197531935), + FRAC_CONST(0.0042264269227), FRAC_CONST(0.00437307196781), + FRAC_CONST(0.00452098527825), FRAC_CONST(0.00466064606118), + FRAC_CONST(0.00479325608498), FRAC_CONST(0.00491376035745), + FRAC_CONST(0.00503930226013), FRAC_CONST(0.00514073539032), + FRAC_CONST(0.00524611661324), FRAC_CONST(0.00534716811982), + FRAC_CONST(0.00541967759307), FRAC_CONST(0.00548760401507), + FRAC_CONST(0.00554757145088), FRAC_CONST(0.00559380230045), + FRAC_CONST(0.00562206432097), FRAC_CONST(0.00564551969164), + FRAC_CONST(0.00563891995151), FRAC_CONST(0.00562661141932), + FRAC_CONST(0.0055917128663), FRAC_CONST(0.005540436394), + FRAC_CONST(0.0054753783077), FRAC_CONST(0.0053838975897), + FRAC_CONST(0.00527157587272), FRAC_CONST(0.00513822754514), + FRAC_CONST(0.00498396877629), FRAC_CONST(0.004810946906), + FRAC_CONST(0.00460395301471), FRAC_CONST(0.00438018617447), + FRAC_CONST(0.0041251642327), FRAC_CONST(0.00384564081246), + FRAC_CONST(0.00354012465507), FRAC_CONST(0.00320918858098), + FRAC_CONST(0.00284467578623), FRAC_CONST(0.00245085400321), + FRAC_CONST(0.0020274176185), FRAC_CONST(0.00157846825768), + FRAC_CONST(0.00109023290512), FRAC_CONST(0.0005832264248), + FRAC_CONST(2.760451905E-005), FRAC_CONST(-0.00054642808664), + FRAC_CONST(-0.00115681355227), FRAC_CONST(-0.00180394725893), + FRAC_CONST(-0.00248267236449), FRAC_CONST(-0.003193377839), + FRAC_CONST(-0.00394011240522), FRAC_CONST(-0.004722259624), + FRAC_CONST(-0.00553372111088), FRAC_CONST(-0.00637922932685), + FRAC_CONST(-0.00726158168517), FRAC_CONST(-0.00817982333726), + FRAC_CONST(-0.00913253296085), FRAC_CONST(-0.01011502154986), + FRAC_CONST(-0.01113155480321), FRAC_CONST(-0.01218499959508), + FRAC_CONST(0.01327182200351), FRAC_CONST(0.01439046660792), + FRAC_CONST(0.01554055533423), FRAC_CONST(0.01673247129989), + FRAC_CONST(0.01794333813443), FRAC_CONST(0.01918724313698), + FRAC_CONST(0.02045317933555), FRAC_CONST(0.02174675502535), + FRAC_CONST(0.02306801692862), FRAC_CONST(0.02441609920285), + FRAC_CONST(0.02578758475467), FRAC_CONST(0.02718594296329), + FRAC_CONST(0.02860721736385), FRAC_CONST(0.03005026574279), + FRAC_CONST(0.03150176087389), FRAC_CONST(0.03297540810337), + FRAC_CONST(0.03446209487686), FRAC_CONST(0.03596975605542), + FRAC_CONST(0.03748128504252), FRAC_CONST(0.03900536794745), + FRAC_CONST(0.04053491705584), FRAC_CONST(0.04206490946367), + FRAC_CONST(0.04360975421304), FRAC_CONST(0.04514884056413), + FRAC_CONST(0.04668430272642), FRAC_CONST(0.04821657200672), + FRAC_CONST(0.04973857556014), FRAC_CONST(0.05125561555216), + FRAC_CONST(0.05276307465207), FRAC_CONST(0.05424527683589), + FRAC_CONST(0.05571736482138), FRAC_CONST(0.05716164501299), + FRAC_CONST(0.0585915683626), FRAC_CONST(0.05998374801761), + FRAC_CONST(0.06134551717207), FRAC_CONST(0.06268578081172), + FRAC_CONST(0.06397158980681), FRAC_CONST(0.0652247106438), + FRAC_CONST(0.06643675122104), FRAC_CONST(0.06760759851228), + FRAC_CONST(0.06870438283512), FRAC_CONST(0.06976302447127), + FRAC_CONST(0.07076287107266), FRAC_CONST(0.07170026731102), + FRAC_CONST(0.07256825833083), FRAC_CONST(0.07336202550803), + FRAC_CONST(0.07410036424342), FRAC_CONST(0.07474525581194), + FRAC_CONST(0.07531373362019), FRAC_CONST(0.07580083586584), + FRAC_CONST(0.07619924793396), FRAC_CONST(0.07649921704119), + FRAC_CONST(0.07670934904245), FRAC_CONST(0.07681739756964), + FRAC_CONST(0.07682300113923), FRAC_CONST(0.07672049241746), + FRAC_CONST(0.07650507183194), FRAC_CONST(0.07617483218536), + FRAC_CONST(0.07573057565061), FRAC_CONST(0.0751576255287), + FRAC_CONST(0.07446643947564), FRAC_CONST(0.0736406005762), + FRAC_CONST(0.07267746427299), FRAC_CONST(0.07158263647903), + FRAC_CONST(0.07035330735093), FRAC_CONST(0.06896640131951), + FRAC_CONST(0.06745250215166), FRAC_CONST(0.06576906686508), + FRAC_CONST(0.06394448059633), FRAC_CONST(0.06196027790387), + FRAC_CONST(0.0598166570809), FRAC_CONST(0.05751526919867), + FRAC_CONST(0.05504600343009), FRAC_CONST(0.05240938217366), + FRAC_CONST(0.04959786763445), FRAC_CONST(0.04663033051701), + FRAC_CONST(0.04347687821958), FRAC_CONST(0.04014582784127), + FRAC_CONST(0.03664181168133), FRAC_CONST(0.03295839306691), + FRAC_CONST(0.02908240060125), FRAC_CONST(0.02503075618909), + FRAC_CONST(0.02079970728622), FRAC_CONST(0.01637012582228), + FRAC_CONST(0.01176238327857), FRAC_CONST(0.00696368621617), + FRAC_CONST(0.00197656014503), FRAC_CONST(-0.00320868968304), + FRAC_CONST(-0.00857117491366), FRAC_CONST(-0.01412888273558), + FRAC_CONST(-0.01988341292573), FRAC_CONST(-0.02582272888064), + FRAC_CONST(-0.03195312745332), FRAC_CONST(-0.03827765720822), + FRAC_CONST(-0.04478068215856), FRAC_CONST(-0.05148041767934), + FRAC_CONST(-0.05837053268336), FRAC_CONST(-0.06544098531359), + FRAC_CONST(-0.07269433008129), FRAC_CONST(-0.08013729344279), + FRAC_CONST(-0.08775475365593), FRAC_CONST(-0.09555333528914), + FRAC_CONST(-0.10353295311463), FRAC_CONST(-0.1116826931773), + FRAC_CONST(-0.120007798468), FRAC_CONST(-0.12850028503878), + FRAC_CONST(-0.13715517611934), FRAC_CONST(-0.1459766491187), + FRAC_CONST(-0.15496070710605), FRAC_CONST(-0.16409588556669), + FRAC_CONST(-0.17338081721706), FRAC_CONST(-0.18281725485142), + FRAC_CONST(-0.19239667457267), FRAC_CONST(-0.20212501768103), + FRAC_CONST(-0.21197358538056), FRAC_CONST(-0.22196526964149), + FRAC_CONST(-0.23206908706791), FRAC_CONST(-0.24230168845974), + FRAC_CONST(-0.25264803095722), FRAC_CONST(-0.26310532994603), + FRAC_CONST(-0.27366340405625), FRAC_CONST(-0.28432141891085), + FRAC_CONST(-0.29507167170646), FRAC_CONST(-0.30590985751916), + FRAC_CONST(-0.31682789136456), FRAC_CONST(-0.32781137272105), + FRAC_CONST(-0.33887226938665), FRAC_CONST(-0.3499914122931), + FRAC_CONST(0.36115899031355), FRAC_CONST(0.37237955463061), + FRAC_CONST(0.38363500139043), FRAC_CONST(0.39492117615675), + FRAC_CONST(0.40623176767625), FRAC_CONST(0.41756968968409), + FRAC_CONST(0.42891199207373), FRAC_CONST(0.44025537543665), + FRAC_CONST(0.45159965356824), FRAC_CONST(0.46293080852757), + FRAC_CONST(0.47424532146115), FRAC_CONST(0.48552530911099), + FRAC_CONST(0.49677082545707), FRAC_CONST(0.50798175000434), + FRAC_CONST(0.51912349702391), FRAC_CONST(0.53022408956855), + FRAC_CONST(0.54125534487322), FRAC_CONST(0.55220512585061), + FRAC_CONST(0.5630789140137), FRAC_CONST(0.57385241316923), + FRAC_CONST(0.58454032354679), FRAC_CONST(0.59511230862496), + FRAC_CONST(0.6055783538918), FRAC_CONST(0.61591099320291), + FRAC_CONST(0.62612426956055), FRAC_CONST(0.63619801077286), + FRAC_CONST(0.64612696959461), FRAC_CONST(0.65590163024671), + FRAC_CONST(0.66551398801627), FRAC_CONST(0.67496631901712), + FRAC_CONST(0.68423532934598), FRAC_CONST(0.69332823767032), + FRAC_CONST(0.70223887193539), FRAC_CONST(0.71094104263095), + FRAC_CONST(0.71944626349561), FRAC_CONST(0.72774489002994), + FRAC_CONST(0.73582117582769), FRAC_CONST(0.74368278636488), + FRAC_CONST(0.75131374561237), FRAC_CONST(0.75870807608242), + FRAC_CONST(0.76586748650939), FRAC_CONST(0.77277808813327), + FRAC_CONST(0.77942875190216), FRAC_CONST(0.7858353120392), + FRAC_CONST(0.79197358416424), FRAC_CONST(0.797846641377), + FRAC_CONST(0.80344857518505), FRAC_CONST(0.80876950044491), + FRAC_CONST(0.81381912706217), FRAC_CONST(0.81857760046468), + FRAC_CONST(0.82304198905409), FRAC_CONST(0.8272275347336), + FRAC_CONST(0.8311038457152), FRAC_CONST(0.83469373618402), + FRAC_CONST(0.83797173378865), FRAC_CONST(0.84095413924722), + FRAC_CONST(0.84362382812005), FRAC_CONST(0.84598184698206), + FRAC_CONST(0.84803157770763), FRAC_CONST(0.84978051984268), + FRAC_CONST(0.85119715249343), FRAC_CONST(0.85230470352147), + FRAC_CONST(0.85310209497017), FRAC_CONST(0.85357205739107), + FRAC_CONST(0.85373856005937), FRAC_CONST(0.85357205739107), + FRAC_CONST(0.85310209497017), FRAC_CONST(0.85230470352147), + FRAC_CONST(0.85119715249343), FRAC_CONST(0.84978051984268), + FRAC_CONST(0.84803157770763), FRAC_CONST(0.84598184698206), + FRAC_CONST(0.84362382812005), FRAC_CONST(0.84095413924722), + FRAC_CONST(0.83797173378865), FRAC_CONST(0.83469373618402), + FRAC_CONST(0.8311038457152), FRAC_CONST(0.8272275347336), + FRAC_CONST(0.82304198905409), FRAC_CONST(0.81857760046468), + FRAC_CONST(0.81381912706217), FRAC_CONST(0.80876950044491), + FRAC_CONST(0.80344857518505), FRAC_CONST(0.797846641377), + FRAC_CONST(0.79197358416424), FRAC_CONST(0.7858353120392), + FRAC_CONST(0.77942875190216), FRAC_CONST(0.77277808813327), + FRAC_CONST(0.76586748650939), FRAC_CONST(0.75870807608242), + FRAC_CONST(0.75131374561237), FRAC_CONST(0.74368278636488), + FRAC_CONST(0.73582117582769), FRAC_CONST(0.72774489002994), + FRAC_CONST(0.71944626349561), FRAC_CONST(0.71094104263095), + FRAC_CONST(0.70223887193539), FRAC_CONST(0.69332823767032), + FRAC_CONST(0.68423532934598), FRAC_CONST(0.67496631901712), + FRAC_CONST(0.66551398801627), FRAC_CONST(0.65590163024671), + FRAC_CONST(0.64612696959461), FRAC_CONST(0.63619801077286), + FRAC_CONST(0.62612426956055), FRAC_CONST(0.61591099320291), + FRAC_CONST(0.6055783538918), FRAC_CONST(0.59511230862496), + FRAC_CONST(0.58454032354679), FRAC_CONST(0.57385241316923), + FRAC_CONST(0.5630789140137), FRAC_CONST(0.55220512585061), + FRAC_CONST(0.54125534487322), FRAC_CONST(0.53022408956855), + FRAC_CONST(0.51912349702391), FRAC_CONST(0.50798175000434), + FRAC_CONST(0.49677082545707), FRAC_CONST(0.48552530911099), + FRAC_CONST(0.47424532146115), FRAC_CONST(0.46293080852757), + FRAC_CONST(0.45159965356824), FRAC_CONST(0.44025537543665), + FRAC_CONST(0.42891199207373), FRAC_CONST(0.41756968968409), + FRAC_CONST(0.40623176767625), FRAC_CONST(0.39492117615675), + FRAC_CONST(0.38363500139043), FRAC_CONST(0.37237955463061), + FRAC_CONST(-0.36115899031355), FRAC_CONST(-0.3499914122931), + FRAC_CONST(-0.33887226938665), FRAC_CONST(-0.32781137272105), + FRAC_CONST(-0.31682789136456), FRAC_CONST(-0.30590985751916), + FRAC_CONST(-0.29507167170646), FRAC_CONST(-0.28432141891085), + FRAC_CONST(-0.27366340405625), FRAC_CONST(-0.26310532994603), + FRAC_CONST(-0.25264803095722), FRAC_CONST(-0.24230168845974), + FRAC_CONST(-0.23206908706791), FRAC_CONST(-0.22196526964149), + FRAC_CONST(-0.21197358538056), FRAC_CONST(-0.20212501768103), + FRAC_CONST(-0.19239667457267), FRAC_CONST(-0.18281725485142), + FRAC_CONST(-0.17338081721706), FRAC_CONST(-0.16409588556669), + FRAC_CONST(-0.15496070710605), FRAC_CONST(-0.1459766491187), + FRAC_CONST(-0.13715517611934), FRAC_CONST(-0.12850028503878), + FRAC_CONST(-0.120007798468), FRAC_CONST(-0.1116826931773), + FRAC_CONST(-0.10353295311463), FRAC_CONST(-0.09555333528914), + FRAC_CONST(-0.08775475365593), FRAC_CONST(-0.08013729344279), + FRAC_CONST(-0.07269433008129), FRAC_CONST(-0.06544098531359), + FRAC_CONST(-0.05837053268336), FRAC_CONST(-0.05148041767934), + FRAC_CONST(-0.04478068215856), FRAC_CONST(-0.03827765720822), + FRAC_CONST(-0.03195312745332), FRAC_CONST(-0.02582272888064), + FRAC_CONST(-0.01988341292573), FRAC_CONST(-0.01412888273558), + FRAC_CONST(-0.00857117491366), FRAC_CONST(-0.00320868968304), + FRAC_CONST(0.00197656014503), FRAC_CONST(0.00696368621617), + FRAC_CONST(0.01176238327857), FRAC_CONST(0.01637012582228), + FRAC_CONST(0.02079970728622), FRAC_CONST(0.02503075618909), + FRAC_CONST(0.02908240060125), FRAC_CONST(0.03295839306691), + FRAC_CONST(0.03664181168133), FRAC_CONST(0.04014582784127), + FRAC_CONST(0.04347687821958), FRAC_CONST(0.04663033051701), + FRAC_CONST(0.04959786763445), FRAC_CONST(0.05240938217366), + FRAC_CONST(0.05504600343009), FRAC_CONST(0.05751526919867), + FRAC_CONST(0.0598166570809), FRAC_CONST(0.06196027790387), + FRAC_CONST(0.06394448059633), FRAC_CONST(0.06576906686508), + FRAC_CONST(0.06745250215166), FRAC_CONST(0.06896640131951), + FRAC_CONST(0.07035330735093), FRAC_CONST(0.07158263647903), + FRAC_CONST(0.07267746427299), FRAC_CONST(0.0736406005762), + FRAC_CONST(0.07446643947564), FRAC_CONST(0.0751576255287), + FRAC_CONST(0.07573057565061), FRAC_CONST(0.07617483218536), + FRAC_CONST(0.07650507183194), FRAC_CONST(0.07672049241746), + FRAC_CONST(0.07682300113923), FRAC_CONST(0.07681739756964), + FRAC_CONST(0.07670934904245), FRAC_CONST(0.07649921704119), + FRAC_CONST(0.07619924793396), FRAC_CONST(0.07580083586584), + FRAC_CONST(0.07531373362019), FRAC_CONST(0.07474525581194), + FRAC_CONST(0.07410036424342), FRAC_CONST(0.07336202550803), + FRAC_CONST(0.07256825833083), FRAC_CONST(0.07170026731102), + FRAC_CONST(0.07076287107266), FRAC_CONST(0.06976302447127), + FRAC_CONST(0.06870438283512), FRAC_CONST(0.06760759851228), + FRAC_CONST(0.06643675122104), FRAC_CONST(0.0652247106438), + FRAC_CONST(0.06397158980681), FRAC_CONST(0.06268578081172), + FRAC_CONST(0.06134551717207), FRAC_CONST(0.05998374801761), + FRAC_CONST(0.0585915683626), FRAC_CONST(0.05716164501299), + FRAC_CONST(0.05571736482138), FRAC_CONST(0.05424527683589), + FRAC_CONST(0.05276307465207), FRAC_CONST(0.05125561555216), + FRAC_CONST(0.04973857556014), FRAC_CONST(0.04821657200672), + FRAC_CONST(0.04668430272642), FRAC_CONST(0.04514884056413), + FRAC_CONST(0.04360975421304), FRAC_CONST(0.04206490946367), + FRAC_CONST(0.04053491705584), FRAC_CONST(0.03900536794745), + FRAC_CONST(0.03748128504252), FRAC_CONST(0.03596975605542), + FRAC_CONST(0.03446209487686), FRAC_CONST(0.03297540810337), + FRAC_CONST(0.03150176087389), FRAC_CONST(0.03005026574279), + FRAC_CONST(0.02860721736385), FRAC_CONST(0.02718594296329), + FRAC_CONST(0.02578758475467), FRAC_CONST(0.02441609920285), + FRAC_CONST(0.02306801692862), FRAC_CONST(0.02174675502535), + FRAC_CONST(0.02045317933555), FRAC_CONST(0.01918724313698), + FRAC_CONST(0.01794333813443), FRAC_CONST(0.01673247129989), + FRAC_CONST(0.01554055533423), FRAC_CONST(0.01439046660792), + FRAC_CONST(-0.01327182200351), FRAC_CONST(-0.01218499959508), + FRAC_CONST(-0.01113155480321), FRAC_CONST(-0.01011502154986), + FRAC_CONST(-0.00913253296085), FRAC_CONST(-0.00817982333726), + FRAC_CONST(-0.00726158168517), FRAC_CONST(-0.00637922932685), + FRAC_CONST(-0.00553372111088), FRAC_CONST(-0.004722259624), + FRAC_CONST(-0.00394011240522), FRAC_CONST(-0.003193377839), + FRAC_CONST(-0.00248267236449), FRAC_CONST(-0.00180394725893), + FRAC_CONST(-0.00115681355227), FRAC_CONST(-0.00054642808664), + FRAC_CONST(2.760451905E-005), FRAC_CONST(0.0005832264248), + FRAC_CONST(0.00109023290512), FRAC_CONST(0.00157846825768), + FRAC_CONST(0.0020274176185), FRAC_CONST(0.00245085400321), + FRAC_CONST(0.00284467578623), FRAC_CONST(0.00320918858098), + FRAC_CONST(0.00354012465507), FRAC_CONST(0.00384564081246), + FRAC_CONST(0.0041251642327), FRAC_CONST(0.00438018617447), + FRAC_CONST(0.00460395301471), FRAC_CONST(0.004810946906), + FRAC_CONST(0.00498396877629), FRAC_CONST(0.00513822754514), + FRAC_CONST(0.00527157587272), FRAC_CONST(0.0053838975897), + FRAC_CONST(0.0054753783077), FRAC_CONST(0.005540436394), + FRAC_CONST(0.0055917128663), FRAC_CONST(0.00562661141932), + FRAC_CONST(0.00563891995151), FRAC_CONST(0.00564551969164), + FRAC_CONST(0.00562206432097), FRAC_CONST(0.00559380230045), + FRAC_CONST(0.00554757145088), FRAC_CONST(0.00548760401507), + FRAC_CONST(0.00541967759307), FRAC_CONST(0.00534716811982), + FRAC_CONST(0.00524611661324), FRAC_CONST(0.00514073539032), + FRAC_CONST(0.00503930226013), FRAC_CONST(0.00491376035745), + FRAC_CONST(0.00479325608498), FRAC_CONST(0.00466064606118), + FRAC_CONST(0.00452098527825), FRAC_CONST(0.00437307196781), + FRAC_CONST(0.0042264269227), FRAC_CONST(0.00408197531935), + FRAC_CONST(0.00392074323703), FRAC_CONST(0.00376039229104), + FRAC_CONST(0.00360082681231), FRAC_CONST(0.00344188741828), + FRAC_CONST(0.00327396134847), FRAC_CONST(0.00311254206525), + FRAC_CONST(0.00294694477165), FRAC_CONST(0.00278704643465), + FRAC_CONST(0.00262017586902), FRAC_CONST(0.00246256169126), + FRAC_CONST(0.00230172547746), FRAC_CONST(0.00214615835557), + FRAC_CONST(0.00198411407369), FRAC_CONST(0.00183482654224), + FRAC_CONST(0.00168680832531), FRAC_CONST(0.00154432198471), + FRAC_CONST(0.00139024948272), FRAC_CONST(0.00125778846475), + FRAC_CONST(0.00112501551307), FRAC_CONST(0.00098859883015), + FRAC_CONST(0.00086084433262), FRAC_CONST(0.00074580258865), + FRAC_CONST(0.00062393761391), FRAC_CONST(0.00051073884952), + FRAC_CONST(0.0004026540216), FRAC_CONST(0.00029495311041), + FRAC_CONST(0.00020430170688), FRAC_CONST(0.00010943831274), + FRAC_CONST(1.349497418E-005), FRAC_CONST(-6.173344072E-005), + FRAC_CONST(-0.00014463809349), FRAC_CONST(-0.0002098337344), + FRAC_CONST(-0.00028969811748), FRAC_CONST(-0.00035011758756), + FRAC_CONST(-0.00040951214522), FRAC_CONST(-0.00046063254803), + FRAC_CONST(-0.00051455722108), FRAC_CONST(-0.00055645763906), + FRAC_CONST(-0.0005946118933), FRAC_CONST(-0.00063415949025), + FRAC_CONST(-0.00066504150893), FRAC_CONST(-0.00069179375372), + FRAC_CONST(-0.00072153919876), FRAC_CONST(-0.00073193571525), + FRAC_CONST(-0.00075300014201), FRAC_CONST(-0.00076307935757), + FRAC_CONST(-0.0007757977331), FRAC_CONST(-0.00078014496257), + FRAC_CONST(-0.000780366471), FRAC_CONST(-0.00077798694927), + FRAC_CONST(-0.00078343322877), FRAC_CONST(-0.00077248485949), + FRAC_CONST(-0.0007681371927), FRAC_CONST(-0.00074905980532), + FRAC_CONST(-0.00074409418541), FRAC_CONST(-0.00072550431222), + FRAC_CONST(-0.00071577364744), FRAC_CONST(-0.00069416146273), + FRAC_CONST(-0.00067776907764), FRAC_CONST(-0.00065403333621), + FRAC_CONST(-0.00063124935319), FRAC_CONST(-0.00061327473938), + FRAC_CONST(-0.00058709304852), FRAC_CONST(-0.00056778025613), + FRAC_CONST(-0.00054665656337), FRAC_CONST(-0.00052265642972), + FRAC_CONST(-0.00050407143497), FRAC_CONST(-0.00048937912498), + FRAC_CONST(-0.00048752279712), FRAC_CONST(-0.00049475180896), + FRAC_CONST(-0.00056176925738), FRAC_CONST(-0.00055252865047) +}; + +#endif
\ No newline at end of file diff --git a/src/libfaad/sbr_syntax.c b/src/libfaad/sbr_syntax.c new file mode 100644 index 000000000..f24aff986 --- /dev/null +++ b/src/libfaad/sbr_syntax.c @@ -0,0 +1,665 @@ +/* +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** +** This program is free software; you can redistribute it and/or modify +** it under the terms of the GNU General Public License as published by +** the Free Software Foundation; either version 2 of the License, or +** (at your option) any later version. +** +** This program is distributed in the hope that it will be useful, +** but WITHOUT ANY WARRANTY; without even the implied warranty of +** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +** GNU General Public License for more details. +** +** You should have received a copy of the GNU General Public License +** along with this program; if not, write to the Free Software +** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +** +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: sbr_syntax.c,v 1.3 2003/12/30 02:00:11 miguelfreitas Exp $ +**/ + +#include "common.h" +#include "structs.h" + +#ifdef SBR_DEC + +#include "sbr_syntax.h" +#include "syntax.h" +#include "sbr_huff.h" +#include "sbr_fbt.h" +#include "sbr_tf_grid.h" +#include "sbr_e_nf.h" +#include "bits.h" +#include "analysis.h" + +static void sbr_reset(sbr_info *sbr) +{ +#if 0 + printf("%d\n", sbr->bs_start_freq_prev); + printf("%d\n", sbr->bs_stop_freq_prev); + printf("%d\n", sbr->bs_freq_scale_prev); + printf("%d\n", sbr->bs_alter_scale_prev); + printf("%d\n", sbr->bs_xover_band_prev); + printf("%d\n\n", sbr->bs_noise_bands_prev); +#endif + + /* if these are different from the previous frame: Reset = 1 */ + if ((sbr->bs_start_freq != sbr->bs_start_freq_prev) || + (sbr->bs_stop_freq != sbr->bs_stop_freq_prev) || + (sbr->bs_freq_scale != sbr->bs_freq_scale_prev) || + (sbr->bs_alter_scale != sbr->bs_alter_scale_prev)) + { + sbr->Reset = 1; + } else { + sbr->Reset = 0; + } + + if ((sbr->bs_start_freq != sbr->bs_start_freq_prev) || + (sbr->bs_stop_freq != sbr->bs_stop_freq_prev) || + (sbr->bs_freq_scale != sbr->bs_freq_scale_prev) || + (sbr->bs_alter_scale != sbr->bs_alter_scale_prev) || + (sbr->bs_xover_band != sbr->bs_xover_band_prev) || + (sbr->bs_noise_bands != sbr->bs_noise_bands_prev)) + { + sbr->Reset = 1; + } else { + sbr->Reset = 0; + } + + sbr->bs_start_freq_prev = sbr->bs_start_freq; + sbr->bs_stop_freq_prev = sbr->bs_stop_freq; + sbr->bs_freq_scale_prev = sbr->bs_freq_scale; + sbr->bs_alter_scale_prev = sbr->bs_alter_scale; + sbr->bs_xover_band_prev = sbr->bs_xover_band; + sbr->bs_noise_bands_prev = sbr->bs_noise_bands; + + if (sbr->frame == 0) + { + sbr->Reset = 1; + } +} + +/* table 2 */ +uint8_t sbr_extension_data(bitfile *ld, sbr_info *sbr) +{ + uint8_t result; + +#ifdef DRM + if (!sbr->Is_DRM_SBR) +#endif + { + uint8_t bs_extension_type = (uint8_t)faad_getbits(ld, 4 + DEBUGVAR(1,198,"sbr_bitstream(): bs_extension_type")); + + if (bs_extension_type == EXT_SBR_DATA_CRC) + { + sbr->bs_sbr_crc_bits = (uint16_t)faad_getbits(ld, 10 + DEBUGVAR(1,199,"sbr_bitstream(): bs_sbr_crc_bits")); + } + } + + sbr->bs_header_flag = faad_get1bit(ld + DEBUGVAR(1,200,"sbr_bitstream(): bs_header_flag")); + + if (sbr->bs_header_flag) + sbr_header(ld, sbr); + + /* TODO: Reset? */ + sbr_reset(sbr); + + /* first frame should have a header */ + if (sbr->frame == 0 && sbr->bs_header_flag == 0) + return 1; + + + if (sbr->Reset || (sbr->bs_header_flag && sbr->just_seeked)) + { + uint8_t k2; + + /* calculate the Master Frequency Table */ + sbr->k0 = qmf_start_channel(sbr->bs_start_freq, sbr->bs_samplerate_mode, + sbr->sample_rate); + k2 = qmf_stop_channel(sbr->bs_stop_freq, sbr->sample_rate, sbr->k0); + + /* check k0 and k2 */ + if (sbr->sample_rate >= 48000) + { + if ((k2 - sbr->k0) > 32) + return 1; + } else if (sbr->sample_rate <= 32000) { + if ((k2 - sbr->k0) > 48) + return 1; + } else { /* (sbr->sample_rate == 44100) */ + if ((k2 - sbr->k0) > 45) + return 1; + } + + if (sbr->bs_freq_scale == 0) + { + master_frequency_table_fs0(sbr, sbr->k0, k2, sbr->bs_alter_scale); + } else { + master_frequency_table(sbr, sbr->k0, k2, sbr->bs_freq_scale, + sbr->bs_alter_scale); + } + if ((result = derived_frequency_table(sbr, sbr->bs_xover_band, k2)) > 0) + return result; + } + + if ((result = sbr_data(ld, sbr)) > 0) + return result; + + /* no error */ + return 0; +} + +/* table 3 */ +static void sbr_header(bitfile *ld, sbr_info *sbr) +{ + uint8_t bs_header_extra_1, bs_header_extra_2; + + sbr->header_count++; + + sbr->bs_amp_res = faad_get1bit(ld + DEBUGVAR(1,203,"sbr_header(): bs_amp_res")); + + /* bs_start_freq and bs_stop_freq must define a fequency band that does + not exceed 48 channels */ + sbr->bs_start_freq = (uint8_t)faad_getbits(ld, 4 + DEBUGVAR(1,204,"sbr_header(): bs_start_freq")); + sbr->bs_stop_freq = (uint8_t)faad_getbits(ld, 4 + DEBUGVAR(1,205,"sbr_header(): bs_stop_freq")); + sbr->bs_xover_band = (uint8_t)faad_getbits(ld, 3 + DEBUGVAR(1,206,"sbr_header(): bs_xover_band")); + faad_getbits(ld, 2 + DEBUGVAR(1,207,"sbr_header(): bs_reserved_bits_hdr")); + bs_header_extra_1 = (uint8_t)faad_get1bit(ld + DEBUGVAR(1,208,"sbr_header(): bs_header_extra_1")); + bs_header_extra_2 = (uint8_t)faad_get1bit(ld + DEBUGVAR(1,209,"sbr_header(): bs_header_extra_2")); + + if (bs_header_extra_1) + { + sbr->bs_freq_scale = (uint8_t)faad_getbits(ld, 2 + DEBUGVAR(1,211,"sbr_header(): bs_freq_scale")); + sbr->bs_alter_scale = (uint8_t)faad_get1bit(ld + DEBUGVAR(1,212,"sbr_header(): bs_alter_scale")); + sbr->bs_noise_bands = (uint8_t)faad_getbits(ld, 2 + DEBUGVAR(1,213,"sbr_header(): bs_noise_bands")); + } else { + /* Default values */ + sbr->bs_freq_scale = 2; + sbr->bs_alter_scale = 1; + sbr->bs_noise_bands = 2; + } + + if (bs_header_extra_2) + { + sbr->bs_limiter_bands = (uint8_t)faad_getbits(ld, 2 + DEBUGVAR(1,214,"sbr_header(): bs_limiter_bands")); + sbr->bs_limiter_gains = (uint8_t)faad_getbits(ld, 2 + DEBUGVAR(1,215,"sbr_header(): bs_limiter_gains")); + sbr->bs_interpol_freq = (uint8_t)faad_get1bit(ld + DEBUGVAR(1,216,"sbr_header(): bs_interpol_freq")); + sbr->bs_smoothing_mode = (uint8_t)faad_get1bit(ld + DEBUGVAR(1,217,"sbr_header(): bs_smoothing_mode")); + } else { + /* Default values */ + sbr->bs_limiter_bands = 2; + sbr->bs_limiter_gains = 2; + sbr->bs_interpol_freq = 1; + sbr->bs_smoothing_mode = 1; + } + +#if 0 + /* print the header to screen */ + printf("bs_amp_res: %d\n", sbr->bs_amp_res); + printf("bs_start_freq: %d\n", sbr->bs_start_freq); + printf("bs_stop_freq: %d\n", sbr->bs_stop_freq); + printf("bs_xover_band: %d\n", sbr->bs_xover_band); + if (bs_header_extra_1) + { + printf("bs_freq_scale: %d\n", sbr->bs_freq_scale); + printf("bs_alter_scale: %d\n", sbr->bs_alter_scale); + printf("bs_noise_bands: %d\n", sbr->bs_noise_bands); + } + if (bs_header_extra_2) + { + printf("bs_limiter_bands: %d\n", sbr->bs_limiter_bands); + printf("bs_limiter_gains: %d\n", sbr->bs_limiter_gains); + printf("bs_interpol_freq: %d\n", sbr->bs_interpol_freq); + printf("bs_smoothing_mode: %d\n", sbr->bs_smoothing_mode); + } + printf("\n"); +#endif +} + +/* table 4 */ +static uint8_t sbr_data(bitfile *ld, sbr_info *sbr) +{ + uint8_t result; +#if 0 + sbr->bs_samplerate_mode = faad_get1bit(ld + DEBUGVAR(1,219,"sbr_data(): bs_samplerate_mode")); +#endif + + sbr->rate = (sbr->bs_samplerate_mode) ? 2 : 1; + + switch (sbr->id_aac) + { + case ID_SCE: + if ((result = sbr_single_channel_element(ld, sbr)) > 0) + return result; + break; + case ID_CPE: + if ((result = sbr_channel_pair_element(ld, sbr)) > 0) + return result; + break; + } + + return 0; +} + +/* table 5 */ +static uint8_t sbr_single_channel_element(bitfile *ld, sbr_info *sbr) +{ + uint8_t result; + + if (faad_get1bit(ld + DEBUGVAR(1,220,"sbr_single_channel_element(): bs_data_extra"))) + { + faad_getbits(ld, 4 + DEBUGVAR(1,221,"sbr_single_channel_element(): bs_reserved_bits_data")); + } + +#ifdef DRM + /* bs_coupling, from sbr_channel_pair_base_element(bs_amp_res) */ + if (sbr->Is_DRM_SBR) + faad_get1bit(ld); +#endif + + if ((result = sbr_grid(ld, sbr, 0)) > 0) + return result; + sbr_dtdf(ld, sbr, 0); + invf_mode(ld, sbr, 0); + sbr_envelope(ld, sbr, 0); + sbr_noise(ld, sbr, 0); + + envelope_noise_dequantisation(sbr, 0); + + memset(sbr->bs_add_harmonic[0], 0, 64*sizeof(uint8_t)); + + sbr->bs_add_harmonic_flag[0] = faad_get1bit(ld + DEBUGVAR(1,223,"sbr_single_channel_element(): bs_add_harmonic_flag[0]")); + if (sbr->bs_add_harmonic_flag[0]) + sinusoidal_coding(ld, sbr, 0); + + sbr->bs_extended_data = faad_get1bit(ld + DEBUGVAR(1,224,"sbr_single_channel_element(): bs_extended_data[0]")); + if (sbr->bs_extended_data) + { + uint16_t nr_bits_left; + uint16_t cnt = (uint16_t)faad_getbits(ld, 4 + DEBUGVAR(1,225,"sbr_single_channel_element(): bs_extension_size")); + if (cnt == 15) + { + cnt += (uint16_t)faad_getbits(ld, 8 + DEBUGVAR(1,226,"sbr_single_channel_element(): bs_esc_count")); + } + + nr_bits_left = 8 * cnt; + while (nr_bits_left > 7) + { + sbr->bs_extension_id = (uint8_t)faad_getbits(ld, 2 + DEBUGVAR(1,227,"sbr_single_channel_element(): bs_extension_id")); + nr_bits_left -= 2; + /* sbr_extension(ld, sbr, 0, nr_bits_left); */ +#ifdef DRM + if (!sbr->Is_DRM_SBR) +#endif + { + sbr->bs_extension_data = (uint8_t)faad_getbits(ld, 6 + DEBUGVAR(1,279,"sbr_single_channel_element(): bs_extension_data")); + } + } + + /* Corrigendum */ + faad_getbits(ld, nr_bits_left + DEBUGVAR(1,280,"sbr_single_channel_element(): nr_bits_left")); + } + + return 0; +} + +/* table 6 */ +static uint8_t sbr_channel_pair_element(bitfile *ld, sbr_info *sbr) +{ + uint8_t n, result; + + if (faad_get1bit(ld + DEBUGVAR(1,228,"sbr_single_channel_element(): bs_data_extra"))) + { + faad_getbits(ld, 4 + DEBUGVAR(1,228,"sbr_channel_pair_element(): bs_reserved_bits_data")); + faad_getbits(ld, 4 + DEBUGVAR(1,228,"sbr_channel_pair_element(): bs_reserved_bits_data")); + } + + sbr->bs_coupling = faad_get1bit(ld + DEBUGVAR(1,228,"sbr_channel_pair_element(): bs_coupling")); + + if (sbr->bs_coupling) + { + if ((result = sbr_grid(ld, sbr, 0)) > 0) + return result; + + /* need to copy some data from left to right */ + sbr->bs_frame_class[1] = sbr->bs_frame_class[0]; + sbr->L_E[1] = sbr->L_E[0]; + sbr->L_Q[1] = sbr->L_Q[0]; + sbr->bs_pointer[1] = sbr->bs_pointer[0]; + + for (n = 0; n <= sbr->L_E[0]; n++) + { + sbr->t_E[1][n] = sbr->t_E[0][n]; + sbr->f[1][n] = sbr->f[0][n]; + } + for (n = 0; n <= sbr->L_Q[0]; n++) + sbr->t_Q[1][n] = sbr->t_Q[0][n]; + + sbr_dtdf(ld, sbr, 0); + sbr_dtdf(ld, sbr, 1); + invf_mode(ld, sbr, 0); + + /* more copying */ + for (n = 0; n < sbr->N_Q; n++) + sbr->bs_invf_mode[1][n] = sbr->bs_invf_mode[0][n]; + + sbr_envelope(ld, sbr, 0); + sbr_noise(ld, sbr, 0); + sbr_envelope(ld, sbr, 1); + sbr_noise(ld, sbr, 1); + + memset(sbr->bs_add_harmonic[0], 0, 64*sizeof(uint8_t)); + memset(sbr->bs_add_harmonic[1], 0, 64*sizeof(uint8_t)); + + sbr->bs_add_harmonic_flag[0] = faad_get1bit(ld + DEBUGVAR(1,231,"sbr_channel_pair_element(): bs_add_harmonic_flag[0]")); + if (sbr->bs_add_harmonic_flag[0]) + sinusoidal_coding(ld, sbr, 0); + + sbr->bs_add_harmonic_flag[1] = faad_get1bit(ld + DEBUGVAR(1,232,"sbr_channel_pair_element(): bs_add_harmonic_flag[1]")); + if (sbr->bs_add_harmonic_flag[1]) + sinusoidal_coding(ld, sbr, 1); + } else { + if ((result = sbr_grid(ld, sbr, 0)) > 0) + return result; + if ((result = sbr_grid(ld, sbr, 1)) > 0) + return result; + sbr_dtdf(ld, sbr, 0); + sbr_dtdf(ld, sbr, 1); + invf_mode(ld, sbr, 0); + invf_mode(ld, sbr, 1); + sbr_envelope(ld, sbr, 0); + sbr_envelope(ld, sbr, 1); + sbr_noise(ld, sbr, 0); + sbr_noise(ld, sbr, 1); + + memset(sbr->bs_add_harmonic[0], 0, 64*sizeof(uint8_t)); + memset(sbr->bs_add_harmonic[1], 0, 64*sizeof(uint8_t)); + + sbr->bs_add_harmonic_flag[0] = faad_get1bit(ld + DEBUGVAR(1,239,"sbr_channel_pair_element(): bs_add_harmonic_flag[0]")); + if (sbr->bs_add_harmonic_flag[0]) + sinusoidal_coding(ld, sbr, 0); + + sbr->bs_add_harmonic_flag[1] = faad_get1bit(ld + DEBUGVAR(1,240,"sbr_channel_pair_element(): bs_add_harmonic_flag[1]")); + if (sbr->bs_add_harmonic_flag[1]) + sinusoidal_coding(ld, sbr, 1); + } + envelope_noise_dequantisation(sbr, 0); + envelope_noise_dequantisation(sbr, 1); + + if (sbr->bs_coupling) + unmap_envelope_noise(sbr); + + sbr->bs_extended_data = faad_get1bit(ld + DEBUGVAR(1,233,"sbr_channel_pair_element(): bs_extended_data[0]")); + if (sbr->bs_extended_data) + { + uint16_t nr_bits_left; + uint16_t cnt = (uint16_t)faad_getbits(ld, 4 + DEBUGVAR(1,234,"sbr_channel_pair_element(): bs_extension_size")); + if (cnt == 15) + { + cnt += (uint16_t)faad_getbits(ld, 8 + DEBUGVAR(1,235,"sbr_channel_pair_element(): bs_esc_count")); + } + + nr_bits_left = 8 * cnt; + while (nr_bits_left > 7) + { + sbr->bs_extension_id = (uint8_t)faad_getbits(ld, 2 + DEBUGVAR(1,236,"sbr_channel_pair_element(): bs_extension_id")); + nr_bits_left -= 2; + /* sbr_extension(ld, sbr, 0, nr_bits_left); */ +#ifdef DRM + if (!sbr->Is_DRM_SBR) +#endif + { + sbr->bs_extension_data = (uint8_t)faad_getbits(ld, 6 + DEBUGVAR(1,280,"sbr_channel_pair_element(): bs_extension_data")); + } + } + + /* Corrigendum */ + faad_getbits(ld, nr_bits_left + DEBUGVAR(1,280,"sbr_channel_pair_element(): nr_bits_left")); + } + + return 0; +} + +/* integer log[2](x): input range [0,10) */ +static int8_t sbr_log2(const int8_t val) +{ + int8_t log2tab[] = { 0, 0, 1, 2, 2, 3, 3, 3, 3, 4 }; + if (val < 10 && val >= 0) + return log2tab[val]; + else + return 0; +} + + +/* table 7 */ +static uint8_t sbr_grid(bitfile *ld, sbr_info *sbr, uint8_t ch) +{ + uint8_t i, env, rel, result; + uint8_t bs_abs_bord, bs_abs_bord_1; + uint8_t bs_num_env; + + sbr->bs_frame_class[ch] = (uint8_t)faad_getbits(ld, 2 + DEBUGVAR(1,248,"sbr_grid(): bs_frame_class")); + + switch (sbr->bs_frame_class[ch]) + { + case FIXFIX: + i = (uint8_t)faad_getbits(ld, 2 + DEBUGVAR(1,249,"sbr_grid(): bs_num_env_raw")); + + bs_num_env = min(1 << i, 5); + + i = (uint8_t)faad_get1bit(ld + DEBUGVAR(1,250,"sbr_grid(): bs_freq_res_flag")); + for (env = 0; env < bs_num_env; env++) + sbr->f[ch][env] = i; + + sbr->abs_bord_lead[ch] = 0; + sbr->abs_bord_trail[ch] = sbr->numTimeSlots; + sbr->n_rel_lead[ch] = bs_num_env - 1; + sbr->n_rel_trail[ch] = 0; + break; + + case FIXVAR: + bs_abs_bord = (uint8_t)faad_getbits(ld, 2 + DEBUGVAR(1,251,"sbr_grid(): bs_abs_bord")) + sbr->numTimeSlots; + bs_num_env = (uint8_t)faad_getbits(ld, 2 + DEBUGVAR(1,252,"sbr_grid(): bs_num_env")) + 1; + + for (rel = 0; rel < bs_num_env-1; rel++) + { + sbr->bs_rel_bord[ch][rel] = 2 * (uint8_t)faad_getbits(ld, 2 + DEBUGVAR(1,253,"sbr_grid(): bs_rel_bord")) + 2; + } + i = sbr_log2(bs_num_env + 1); + sbr->bs_pointer[ch] = (uint8_t)faad_getbits(ld, i + DEBUGVAR(1,254,"sbr_grid(): bs_pointer")); + + for (env = 0; env < bs_num_env; env++) + { + sbr->f[ch][bs_num_env - env - 1] = (uint8_t)faad_get1bit(ld + DEBUGVAR(1,255,"sbr_grid(): bs_freq_res")); + } + + sbr->abs_bord_lead[ch] = 0; + sbr->abs_bord_trail[ch] = bs_abs_bord; + sbr->n_rel_lead[ch] = 0; + sbr->n_rel_trail[ch] = bs_num_env - 1; + break; + + case VARFIX: + bs_abs_bord = (uint8_t)faad_getbits(ld, 2 + DEBUGVAR(1,256,"sbr_grid(): bs_abs_bord")); + bs_num_env = (uint8_t)faad_getbits(ld, 2 + DEBUGVAR(1,257,"sbr_grid(): bs_num_env")) + 1; + + for (rel = 0; rel < bs_num_env-1; rel++) + { + sbr->bs_rel_bord[ch][rel] = 2 * (uint8_t)faad_getbits(ld, 2 + DEBUGVAR(1,258,"sbr_grid(): bs_rel_bord")) + 2; + } + i = sbr_log2(bs_num_env + 1); + sbr->bs_pointer[ch] = (uint8_t)faad_getbits(ld, i + DEBUGVAR(1,259,"sbr_grid(): bs_pointer")); + + for (env = 0; env < bs_num_env; env++) + { + sbr->f[ch][env] = (uint8_t)faad_get1bit(ld + DEBUGVAR(1,260,"sbr_grid(): bs_freq_res")); + } + + sbr->abs_bord_lead[ch] = bs_abs_bord; + sbr->abs_bord_trail[ch] = sbr->numTimeSlots; + sbr->n_rel_lead[ch] = bs_num_env - 1; + sbr->n_rel_trail[ch] = 0; + break; + + case VARVAR: + bs_abs_bord = (uint8_t)faad_getbits(ld, 2 + DEBUGVAR(1,261,"sbr_grid(): bs_abs_bord_0")); + bs_abs_bord_1 = (uint8_t)faad_getbits(ld, 2 + DEBUGVAR(1,262,"sbr_grid(): bs_abs_bord_1")) + sbr->numTimeSlots; + sbr->bs_num_rel_0[ch] = (uint8_t)faad_getbits(ld, 2 + DEBUGVAR(1,263,"sbr_grid(): bs_num_rel_0")); + sbr->bs_num_rel_1[ch] = (uint8_t)faad_getbits(ld, 2 + DEBUGVAR(1,264,"sbr_grid(): bs_num_rel_1")); + + bs_num_env = min(5, sbr->bs_num_rel_0[ch] + sbr->bs_num_rel_1[ch] + 1); + + for (rel = 0; rel < sbr->bs_num_rel_0[ch]; rel++) + { + sbr->bs_rel_bord_0[ch][rel] = 2 * (uint8_t)faad_getbits(ld, 2 + DEBUGVAR(1,265,"sbr_grid(): bs_rel_bord")) + 2; + } + for(rel = 0; rel < sbr->bs_num_rel_1[ch]; rel++) + { + sbr->bs_rel_bord_1[ch][rel] = 2 * (uint8_t)faad_getbits(ld, 2 + DEBUGVAR(1,266,"sbr_grid(): bs_rel_bord")) + 2; + } + i = sbr_log2(sbr->bs_num_rel_0[ch] + sbr->bs_num_rel_1[ch] + 2); + sbr->bs_pointer[ch] = (uint8_t)faad_getbits(ld, i + DEBUGVAR(1,267,"sbr_grid(): bs_pointer")); + + for (env = 0; env < bs_num_env; env++) + { + sbr->f[ch][env] = (uint8_t)faad_get1bit(ld + DEBUGVAR(1,268,"sbr_grid(): bs_freq_res")); + } + + sbr->abs_bord_lead[ch] = bs_abs_bord; + sbr->abs_bord_trail[ch] = bs_abs_bord_1; + sbr->n_rel_lead[ch] = sbr->bs_num_rel_0[ch]; + sbr->n_rel_trail[ch] = sbr->bs_num_rel_1[ch]; + break; + } + + if (sbr->bs_frame_class[ch] == VARVAR) + sbr->L_E[ch] = min(bs_num_env, 5); + else + sbr->L_E[ch] = min(bs_num_env, 4); + + if (sbr->L_E[ch] > 1) + sbr->L_Q[ch] = 2; + else + sbr->L_Q[ch] = 1; + + /* TODO: this code can probably be integrated into the code above! */ + if ((result = envelope_time_border_vector(sbr, ch)) > 0) + return result; + noise_floor_time_border_vector(sbr, ch); + + return 0; +} + +/* table 8 */ +static void sbr_dtdf(bitfile *ld, sbr_info *sbr, uint8_t ch) +{ + uint8_t i; + + for (i = 0; i < sbr->L_E[ch]; i++) + { + sbr->bs_df_env[ch][i] = faad_get1bit(ld + DEBUGVAR(1,269,"sbr_dtdf(): bs_df_env")); + } + + for (i = 0; i < sbr->L_Q[ch]; i++) + { + sbr->bs_df_noise[ch][i] = faad_get1bit(ld + DEBUGVAR(1,270,"sbr_dtdf(): bs_df_noise")); + } +} + +/* table 9 */ +static void invf_mode(bitfile *ld, sbr_info *sbr, uint8_t ch) +{ + uint8_t n; + + for (n = 0; n < sbr->N_Q; n++) + { + sbr->bs_invf_mode[ch][n] = (uint8_t)faad_getbits(ld, 2 + DEBUGVAR(1,271,"invf_mode(): bs_invf_mode")); + } +} + +/* table 12 */ +static void sinusoidal_coding(bitfile *ld, sbr_info *sbr, uint8_t ch) +{ + uint8_t n; + + for (n = 0; n < sbr->N_high; n++) + { + sbr->bs_add_harmonic[ch][n] = faad_get1bit(ld + DEBUGVAR(1,278,"sinusoidal_coding(): bs_add_harmonic")); + } +} + + +#endif /* SBR_DEC */ diff --git a/src/libfaad/sbr_syntax.h b/src/libfaad/sbr_syntax.h new file mode 100644 index 000000000..cf254ea0a --- /dev/null +++ b/src/libfaad/sbr_syntax.h @@ -0,0 +1,72 @@ +/* +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** +** This program is free software; you can redistribute it and/or modify +** it under the terms of the GNU General Public License as published by +** the Free Software Foundation; either version 2 of the License, or +** (at your option) any later version. +** +** This program is distributed in the hope that it will be useful, +** but WITHOUT ANY WARRANTY; without even the implied warranty of +** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +** GNU General Public License for more details. +** +** You should have received a copy of the GNU General Public License +** along with this program; if not, write to the Free Software +** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +** +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: sbr_syntax.h,v 1.3 2003/12/30 02:00:11 miguelfreitas Exp $ +**/ + +#ifndef __SBR_SYNTAX_H__ +#define __SBR_SYNTAX_H__ + +#ifdef __cplusplus +extern "C" { +#endif + +#include "bits.h" + +#define T_HFGEN 8 +#define T_HFADJ 2 + +#define EXT_SBR_DATA 13 +#define EXT_SBR_DATA_CRC 14 + +#define FIXFIX 0 +#define FIXVAR 1 +#define VARFIX 2 +#define VARVAR 3 + +#define LO_RES 0 +#define HI_RES 1 + +#define NO_TIME_SLOTS_960 15 +#define NO_TIME_SLOTS 16 +#define RATE 2 + +#define NOISE_FLOOR_OFFSET 6 + + +uint8_t sbr_extension_data(bitfile *ld, sbr_info *sbr); +static void sbr_header(bitfile *ld, sbr_info *sbr); +static uint8_t sbr_data(bitfile *ld, sbr_info *sbr); +static uint8_t sbr_single_channel_element(bitfile *ld, sbr_info *sbr); +static uint8_t sbr_channel_pair_element(bitfile *ld, sbr_info *sbr); +static uint8_t sbr_grid(bitfile *ld, sbr_info *sbr, uint8_t ch); +static void sbr_dtdf(bitfile *ld, sbr_info *sbr, uint8_t ch); +static void invf_mode(bitfile *ld, sbr_info *sbr, uint8_t ch); +static void sinusoidal_coding(bitfile *ld, sbr_info *sbr, uint8_t ch); + +#ifdef __cplusplus +} +#endif +#endif /* __SBR_SYNTAX_H__ */ + diff --git a/src/libfaad/sbr_tf_grid.c b/src/libfaad/sbr_tf_grid.c new file mode 100644 index 000000000..977c92cd2 --- /dev/null +++ b/src/libfaad/sbr_tf_grid.c @@ -0,0 +1,243 @@ +/* +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** +** This program is free software; you can redistribute it and/or modify +** it under the terms of the GNU General Public License as published by +** the Free Software Foundation; either version 2 of the License, or +** (at your option) any later version. +** +** This program is distributed in the hope that it will be useful, +** but WITHOUT ANY WARRANTY; without even the implied warranty of +** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +** GNU General Public License for more details. +** +** You should have received a copy of the GNU General Public License +** along with this program; if not, write to the Free Software +** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +** +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: sbr_tf_grid.c,v 1.1 2003/12/30 02:00:11 miguelfreitas Exp $ +**/ + +/* Time/Frequency grid */ + +#include "common.h" +#include "structs.h" + +#ifdef SBR_DEC + +#include <stdlib.h> + +#include "sbr_syntax.h" +#include "sbr_tf_grid.h" + +uint8_t envelope_time_border_vector(sbr_info *sbr, uint8_t ch) +{ + uint8_t l, border, temp; + + for (l = 0; l <= sbr->L_E[ch]; l++) + { + sbr->t_E[ch][l] = 0; + } + + sbr->t_E[ch][0] = sbr->rate * sbr->abs_bord_lead[ch]; + sbr->t_E[ch][sbr->L_E[ch]] = sbr->rate * sbr->abs_bord_trail[ch]; + + switch (sbr->bs_frame_class[ch]) + { + case FIXFIX: + switch (sbr->L_E[ch]) + { + case 4: + temp = (int) (sbr->numTimeSlots / 4); + sbr->t_E[ch][3] = sbr->rate * 3 * temp; + sbr->t_E[ch][2] = sbr->rate * 2 * temp; + sbr->t_E[ch][1] = sbr->rate * temp; + break; + case 2: + sbr->t_E[ch][1] = sbr->rate * (int) (sbr->numTimeSlots / 2); + break; + default: + break; + } + break; + + case FIXVAR: + if (sbr->L_E[ch] > 1) + { + int8_t i = sbr->L_E[ch]; + border = sbr->abs_bord_trail[ch]; + + for (l = 0; l < (sbr->L_E[ch] - 1); l++) + { + if (border < sbr->bs_rel_bord[ch][l]) + return 1; + + border -= sbr->bs_rel_bord[ch][l]; + sbr->t_E[ch][--i] = sbr->rate * border; + } + } + break; + + case VARFIX: + if (sbr->L_E[ch] > 1) + { + int8_t i = 1; + border = sbr->abs_bord_lead[ch]; + + for (l = 0; l < (sbr->L_E[ch] - 1); l++) + { + border += sbr->bs_rel_bord[ch][l]; + + if (sbr->rate * border + sbr->tHFAdj > sbr->numTimeSlotsRate+sbr->tHFGen) + return 1; + + sbr->t_E[ch][i++] = sbr->rate * border; + } + } + break; + + case VARVAR: + if (sbr->bs_num_rel_0[ch]) + { + int8_t i = 1; + border = sbr->abs_bord_lead[ch]; + + for (l = 0; l < sbr->bs_num_rel_0[ch]; l++) + { + border += sbr->bs_rel_bord_0[ch][l]; + + if (sbr->rate * border + sbr->tHFAdj > sbr->numTimeSlotsRate+sbr->tHFGen) + return 1; + + sbr->t_E[ch][i++] = sbr->rate * border; + } + } + + if (sbr->bs_num_rel_1[ch]) + { + int8_t i = sbr->L_E[ch]; + border = sbr->abs_bord_trail[ch]; + + for (l = 0; l < sbr->bs_num_rel_1[ch]; l++) + { + if (border < sbr->bs_rel_bord_1[ch][l]) + return 1; + + border -= sbr->bs_rel_bord_1[ch][l]; + sbr->t_E[ch][--i] = sbr->rate * border; + } + } + break; + } + + return 0; +} + +void noise_floor_time_border_vector(sbr_info *sbr, uint8_t ch) +{ + sbr->t_Q[ch][0] = sbr->t_E[ch][0]; + + if (sbr->L_E[ch] == 1) + { + sbr->t_Q[ch][1] = sbr->t_E[ch][1]; + sbr->t_Q[ch][2] = 0; + } else { + uint8_t index = middleBorder(sbr, ch); + sbr->t_Q[ch][1] = sbr->t_E[ch][index]; + sbr->t_Q[ch][2] = sbr->t_E[ch][sbr->L_E[ch]]; + } +} + +static int16_t rel_bord_lead(sbr_info *sbr, uint8_t ch, uint8_t l) +{ + uint8_t i; + int16_t acc = 0; + + switch (sbr->bs_frame_class[ch]) + { + case FIXFIX: + return sbr->numTimeSlots/sbr->L_E[ch]; + case FIXVAR: + return 0; + case VARFIX: + for (i = 0; i < l; i++) + { + acc += sbr->bs_rel_bord[ch][i]; + } + return acc; + case VARVAR: + for (i = 0; i < l; i++) + { + acc += sbr->bs_rel_bord_0[ch][i]; + } + return acc; + } + + return 0; +} + +static int16_t rel_bord_trail(sbr_info *sbr, uint8_t ch, uint8_t l) +{ + uint8_t i; + int16_t acc = 0; + + switch (sbr->bs_frame_class[ch]) + { + case FIXFIX: + case VARFIX: + return 0; + case FIXVAR: + for (i = 0; i < l; i++) + { + acc += sbr->bs_rel_bord[ch][i]; + } + return acc; + case VARVAR: + for (i = 0; i < l; i++) + { + acc += sbr->bs_rel_bord_1[ch][i]; + } + return acc; + } + + return 0; +} + +static uint8_t middleBorder(sbr_info *sbr, uint8_t ch) +{ + int8_t retval; + + switch (sbr->bs_frame_class[ch]) + { + case FIXFIX: + retval = sbr->L_E[ch]/2; + break; + case VARFIX: + if (sbr->bs_pointer[ch] == 0) + retval = 1; + else if (sbr->bs_pointer[ch] == 1) + retval = sbr->L_E[ch] - 1; + else + retval = sbr->bs_pointer[ch] - 1; + break; + case FIXVAR: + case VARVAR: + if (sbr->bs_pointer[ch] > 1) + retval = sbr->L_E[ch] + 1 - sbr->bs_pointer[ch]; + else + retval = sbr->L_E[ch] - 1; + break; + } + + return (retval > 0) ? retval : 0; +} + + +#endif diff --git a/src/libfaad/sbr_tf_grid.h b/src/libfaad/sbr_tf_grid.h new file mode 100644 index 000000000..f166a3edc --- /dev/null +++ b/src/libfaad/sbr_tf_grid.h @@ -0,0 +1,48 @@ +/* +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** +** This program is free software; you can redistribute it and/or modify +** it under the terms of the GNU General Public License as published by +** the Free Software Foundation; either version 2 of the License, or +** (at your option) any later version. +** +** This program is distributed in the hope that it will be useful, +** but WITHOUT ANY WARRANTY; without even the implied warranty of +** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +** GNU General Public License for more details. +** +** You should have received a copy of the GNU General Public License +** along with this program; if not, write to the Free Software +** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +** +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: sbr_tf_grid.h,v 1.1 2003/12/30 02:00:11 miguelfreitas Exp $ +**/ + +#ifndef __SBR_TF_GRID_H__ +#define __SBR_TF_GRID_H__ + +#ifdef __cplusplus +extern "C" { +#endif + + +uint8_t envelope_time_border_vector(sbr_info *sbr, uint8_t ch); +void noise_floor_time_border_vector(sbr_info *sbr, uint8_t ch); + +static int16_t rel_bord_lead(sbr_info *sbr, uint8_t ch, uint8_t l); +static int16_t rel_bord_trail(sbr_info *sbr, uint8_t ch, uint8_t l); +static uint8_t middleBorder(sbr_info *sbr, uint8_t ch); + + +#ifdef __cplusplus +} +#endif +#endif + diff --git a/src/libfaad/sine_win.h b/src/libfaad/sine_win.h index 9e6fd503b..807190633 100644 --- a/src/libfaad/sine_win.h +++ b/src/libfaad/sine_win.h @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: sine_win.h,v 1.1 2002/12/16 19:01:06 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: sine_win.h,v 1.2 2003/12/30 02:00:11 miguelfreitas Exp $ **/ #ifndef __SINE_WIN_H__ @@ -26,8514 +32,4267 @@ extern "C" { #endif -#ifndef FIXED_POINT - #ifdef _MSC_VER #pragma warning(disable:4305) #pragma warning(disable:4244) #endif -real_t sine_long_1024[] = -{ - 0.0007669903, - 0.0023009692, - 0.0038349427, - 0.0053689071, - 0.0069028589, - 0.0084367945, - 0.0099707102, - 0.0115046024, - 0.0130384676, - 0.0145723021, - 0.0161061023, - 0.0176398646, - 0.0191735854, - 0.0207072611, - 0.0222408880, - 0.0237744627, - 0.0253079813, - 0.0268414404, - 0.0283748364, - 0.0299081656, - 0.0314414244, - 0.0329746092, - 0.0345077165, - 0.0360407425, - 0.0375736838, - 0.0391065366, - 0.0406392974, - 0.0421719625, - 0.0437045285, - 0.0452369916, - 0.0467693482, - 0.0483015948, - 0.0498337277, - 0.0513657434, - 0.0528976382, - 0.0544294085, - 0.0559610508, - 0.0574925613, - 0.0590239366, - 0.0605551730, - 0.0620862669, - 0.0636172147, - 0.0651480128, - 0.0666786576, - 0.0682091456, - 0.0697394730, - 0.0712696363, - 0.0727996319, - 0.0743294562, - 0.0758591055, - 0.0773885764, - 0.0789178652, - 0.0804469683, - 0.0819758821, - 0.0835046030, - 0.0850331273, - 0.0865614516, - 0.0880895722, - 0.0896174856, - 0.0911451880, - 0.0926726760, - 0.0941999459, - 0.0957269942, - 0.0972538171, - 0.0987804113, - 0.1003067730, - 0.1018328987, - 0.1033587847, - 0.1048844276, - 0.1064098236, - 0.1079349692, - 0.1094598609, - 0.1109844950, - 0.1125088679, - 0.1140329761, - 0.1155568160, - 0.1170803839, - 0.1186036763, - 0.1201266897, - 0.1216494204, - 0.1231718648, - 0.1246940194, - 0.1262158806, - 0.1277374448, - 0.1292587084, - 0.1307796678, - 0.1323003195, - 0.1338206599, - 0.1353406854, - 0.1368603924, - 0.1383797774, - 0.1398988368, - 0.1414175669, - 0.1429359643, - 0.1444540254, - 0.1459717465, - 0.1474891242, - 0.1490061548, - 0.1505228347, - 0.1520391605, - 0.1535551285, - 0.1550707352, - 0.1565859770, - 0.1581008503, - 0.1596153516, - 0.1611294774, - 0.1626432239, - 0.1641565877, - 0.1656695653, - 0.1671821530, - 0.1686943474, - 0.1702061448, - 0.1717175416, - 0.1732285344, - 0.1747391196, - 0.1762492936, - 0.1777590529, - 0.1792683938, - 0.1807773130, - 0.1822858067, - 0.1837938716, - 0.1853015039, - 0.1868087002, - 0.1883154569, - 0.1898217705, - 0.1913276375, - 0.1928330542, - 0.1943380172, - 0.1958425228, - 0.1973465677, - 0.1988501481, - 0.2003532607, - 0.2018559018, - 0.2033580679, - 0.2048597554, - 0.2063609610, - 0.2078616809, - 0.2093619117, - 0.2108616499, - 0.2123608919, - 0.2138596342, - 0.2153578733, - 0.2168556056, - 0.2183528276, - 0.2198495358, - 0.2213457267, - 0.2228413967, - 0.2243365424, - 0.2258311602, - 0.2273252466, - 0.2288187981, - 0.2303118111, - 0.2318042822, - 0.2332962078, - 0.2347875845, - 0.2362784086, - 0.2377686768, - 0.2392583855, - 0.2407475313, - 0.2422361105, - 0.2437241197, - 0.2452115554, - 0.2466984140, - 0.2481846922, - 0.2496703864, - 0.2511554931, - 0.2526400088, - 0.2541239300, - 0.2556072532, - 0.2570899749, - 0.2585720917, - 0.2600536001, - 0.2615344965, - 0.2630147775, - 0.2644944396, - 0.2659734793, - 0.2674518932, - 0.2689296777, - 0.2704068294, - 0.2718833448, - 0.2733592205, - 0.2748344529, - 0.2763090386, - 0.2777829741, - 0.2792562559, - 0.2807288807, - 0.2822008448, - 0.2836721449, - 0.2851427776, - 0.2866127392, - 0.2880820264, - 0.2895506357, - 0.2910185637, - 0.2924858069, - 0.2939523618, - 0.2954182251, - 0.2968833932, - 0.2983478627, - 0.2998116301, - 0.3012746921, - 0.3027370451, - 0.3041986858, - 0.3056596107, - 0.3071198163, - 0.3085792992, - 0.3100380561, - 0.3114960833, - 0.3129533776, - 0.3144099355, - 0.3158657535, - 0.3173208283, - 0.3187751564, - 0.3202287344, - 0.3216815589, - 0.3231336264, - 0.3245849335, - 0.3260354769, - 0.3274852530, - 0.3289342586, - 0.3303824902, - 0.3318299443, - 0.3332766176, - 0.3347225067, - 0.3361676081, - 0.3376119185, - 0.3390554345, - 0.3404981526, - 0.3419400695, - 0.3433811818, - 0.3448214861, - 0.3462609790, - 0.3476996571, - 0.3491375170, - 0.3505745554, - 0.3520107688, - 0.3534461540, - 0.3548807074, - 0.3563144257, - 0.3577473057, - 0.3591793438, - 0.3606105367, - 0.3620408811, - 0.3634703735, - 0.3648990107, - 0.3663267892, - 0.3677537058, - 0.3691797569, - 0.3706049394, - 0.3720292498, - 0.3734526847, - 0.3748752409, - 0.3762969150, - 0.3777177036, - 0.3791376034, - 0.3805566111, - 0.3819747232, - 0.3833919366, - 0.3848082478, - 0.3862236535, - 0.3876381503, - 0.3890517351, - 0.3904644043, - 0.3918761548, - 0.3932869831, - 0.3946968860, - 0.3961058601, - 0.3975139021, - 0.3989210088, - 0.4003271768, - 0.4017324027, - 0.4031366834, - 0.4045400154, - 0.4059423955, - 0.4073438203, - 0.4087442867, - 0.4101437912, - 0.4115423307, - 0.4129399017, - 0.4143365010, - 0.4157321254, - 0.4171267715, - 0.4185204361, - 0.4199131159, - 0.4213048075, - 0.4226955078, - 0.4240852135, - 0.4254739212, - 0.4268616277, - 0.4282483298, - 0.4296340242, - 0.4310187077, - 0.4324023768, - 0.4337850286, - 0.4351666595, - 0.4365472665, - 0.4379268463, - 0.4393053955, - 0.4406829110, - 0.4420593896, - 0.4434348280, - 0.4448092229, - 0.4461825711, - 0.4475548694, - 0.4489261146, - 0.4502963034, - 0.4516654326, - 0.4530334990, - 0.4544004994, - 0.4557664305, - 0.4571312892, - 0.4584950722, - 0.4598577763, - 0.4612193983, - 0.4625799351, - 0.4639393833, - 0.4652977398, - 0.4666550015, - 0.4680111650, - 0.4693662273, - 0.4707201851, - 0.4720730353, - 0.4734247746, - 0.4747754000, - 0.4761249081, - 0.4774732959, - 0.4788205601, - 0.4801666976, - 0.4815117052, - 0.4828555798, - 0.4841983182, - 0.4855399172, - 0.4868803737, - 0.4882196845, - 0.4895578465, - 0.4908948565, - 0.4922307114, - 0.4935654080, - 0.4948989433, - 0.4962313139, - 0.4975625169, - 0.4988925491, - 0.5002214073, - 0.5015490885, - 0.5028755895, - 0.5042009071, - 0.5055250384, - 0.5068479800, - 0.5081697290, - 0.5094902823, - 0.5108096366, - 0.5121277890, - 0.5134447363, - 0.5147604754, - 0.5160750032, - 0.5173883167, - 0.5187004127, - 0.5200112881, - 0.5213209399, - 0.5226293650, - 0.5239365603, - 0.5252425227, - 0.5265472491, - 0.5278507366, - 0.5291529819, - 0.5304539821, - 0.5317537341, - 0.5330522349, - 0.5343494813, - 0.5356454703, - 0.5369401989, - 0.5382336641, - 0.5395258627, - 0.5408167917, - 0.5421064482, - 0.5433948291, - 0.5446819312, - 0.5459677517, - 0.5472522875, - 0.5485355355, - 0.5498174928, - 0.5510981563, - 0.5523775230, - 0.5536555900, - 0.5549323541, - 0.5562078124, - 0.5574819619, - 0.5587547996, - 0.5600263225, - 0.5612965275, - 0.5625654118, - 0.5638329724, - 0.5650992062, - 0.5663641102, - 0.5676276815, - 0.5688899172, - 0.5701508142, - 0.5714103696, - 0.5726685804, - 0.5739254436, - 0.5751809564, - 0.5764351157, - 0.5776879185, - 0.5789393621, - 0.5801894433, - 0.5814381593, - 0.5826855071, - 0.5839314838, - 0.5851760864, - 0.5864193121, - 0.5876611579, - 0.5889016208, - 0.5901406980, - 0.5913783866, - 0.5926146835, - 0.5938495860, - 0.5950830911, - 0.5963151959, - 0.5975458976, - 0.5987751931, - 0.6000030797, - 0.6012295544, - 0.6024546144, - 0.6036782567, - 0.6049004785, - 0.6061212769, - 0.6073406491, - 0.6085585921, - 0.6097751031, - 0.6109901793, - 0.6122038177, - 0.6134160156, - 0.6146267701, - 0.6158360782, - 0.6170439373, - 0.6182503444, - 0.6194552967, - 0.6206587913, - 0.6218608255, - 0.6230613964, - 0.6242605011, - 0.6254581369, - 0.6266543010, - 0.6278489904, - 0.6290422025, - 0.6302339344, - 0.6314241833, - 0.6326129463, - 0.6338002208, - 0.6349860039, - 0.6361702928, - 0.6373530847, - 0.6385343769, - 0.6397141665, - 0.6408924509, - 0.6420692271, - 0.6432444925, - 0.6444182443, - 0.6455904797, - 0.6467611960, - 0.6479303904, - 0.6490980601, - 0.6502642024, - 0.6514288146, - 0.6525918940, - 0.6537534377, - 0.6549134431, - 0.6560719074, - 0.6572288279, - 0.6583842018, - 0.6595380266, - 0.6606902994, - 0.6618410175, - 0.6629901782, - 0.6641377789, - 0.6652838167, - 0.6664282891, - 0.6675711934, - 0.6687125267, - 0.6698522866, - 0.6709904702, - 0.6721270748, - 0.6732620980, - 0.6743955368, - 0.6755273888, - 0.6766576511, - 0.6777863212, - 0.6789133965, - 0.6800388741, - 0.6811627516, - 0.6822850262, - 0.6834056954, - 0.6845247564, - 0.6856422067, - 0.6867580436, - 0.6878722645, - 0.6889848667, - 0.6900958478, - 0.6912052049, - 0.6923129356, - 0.6934190372, - 0.6945235071, - 0.6956263427, - 0.6967275415, - 0.6978271008, - 0.6989250180, - 0.7000212906, - 0.7011159160, - 0.7022088916, - 0.7033002148, - 0.7043898831, - 0.7054778939, - 0.7065642446, - 0.7076489327, - 0.7087319557, - 0.7098133109, - 0.7108929959, - 0.7119710081, - 0.7130473449, - 0.7141220039, - 0.7151949824, - 0.7162662781, - 0.7173358883, - 0.7184038105, - 0.7194700423, - 0.7205345811, - 0.7215974244, - 0.7226585697, - 0.7237180145, - 0.7247757564, - 0.7258317928, - 0.7268861212, - 0.7279387392, - 0.7289896443, - 0.7300388340, - 0.7310863058, - 0.7321320574, - 0.7331760861, - 0.7342183896, - 0.7352589655, - 0.7362978112, - 0.7373349243, - 0.7383703024, - 0.7394039430, - 0.7404358438, - 0.7414660022, - 0.7424944159, - 0.7435210825, - 0.7445459994, - 0.7455691644, - 0.7465905750, - 0.7476102287, - 0.7486281233, - 0.7496442563, - 0.7506586253, - 0.7516712279, - 0.7526820618, - 0.7536911245, - 0.7546984137, - 0.7557039270, - 0.7567076622, - 0.7577096166, - 0.7587097882, - 0.7597081744, - 0.7607047729, - 0.7616995815, - 0.7626925976, - 0.7636838191, - 0.7646732436, - 0.7656608687, - 0.7666466922, - 0.7676307116, - 0.7686129248, - 0.7695933293, - 0.7705719229, - 0.7715487032, - 0.7725236681, - 0.7734968151, - 0.7744681420, - 0.7754376465, - 0.7764053263, - 0.7773711792, - 0.7783352028, - 0.7792973950, - 0.7802577533, - 0.7812162757, - 0.7821729598, - 0.7831278033, - 0.7840808041, - 0.7850319598, - 0.7859812683, - 0.7869287273, - 0.7878743346, - 0.7888180880, - 0.7897599851, - 0.7907000239, - 0.7916382021, - 0.7925745175, - 0.7935089679, - 0.7944415511, - 0.7953722649, - 0.7963011071, - 0.7972280756, - 0.7981531680, - 0.7990763824, - 0.7999977164, - 0.8009171680, - 0.8018347350, - 0.8027504151, - 0.8036642063, - 0.8045761064, - 0.8054861132, - 0.8063942247, - 0.8073004386, - 0.8082047529, - 0.8091071654, - 0.8100076740, - 0.8109062766, - 0.8118029710, - 0.8126977551, - 0.8135906270, - 0.8144815843, - 0.8153706251, - 0.8162577473, - 0.8171429487, - 0.8180262273, - 0.8189075810, - 0.8197870078, - 0.8206645055, - 0.8215400721, - 0.8224137055, - 0.8232854037, - 0.8241551647, - 0.8250229863, - 0.8258888666, - 0.8267528035, - 0.8276147949, - 0.8284748389, - 0.8293329334, - 0.8301890764, - 0.8310432659, - 0.8318954999, - 0.8327457763, - 0.8335940932, - 0.8344404486, - 0.8352848405, - 0.8361272668, - 0.8369677257, - 0.8378062151, - 0.8386427331, - 0.8394772776, - 0.8403098468, - 0.8411404387, - 0.8419690512, - 0.8427956826, - 0.8436203307, - 0.8444429937, - 0.8452636697, - 0.8460823567, - 0.8468990528, - 0.8477137560, - 0.8485264645, - 0.8493371763, - 0.8501458896, - 0.8509526024, - 0.8517573128, - 0.8525600189, - 0.8533607189, - 0.8541594108, - 0.8549560928, - 0.8557507630, - 0.8565434196, - 0.8573340606, - 0.8581226843, - 0.8589092887, - 0.8596938720, - 0.8604764323, - 0.8612569679, - 0.8620354768, - 0.8628119573, - 0.8635864076, - 0.8643588257, - 0.8651292099, - 0.8658975583, - 0.8666638692, - 0.8674281408, - 0.8681903713, - 0.8689505588, - 0.8697087015, - 0.8704647978, - 0.8712188458, - 0.8719708437, - 0.8727207898, - 0.8734686823, - 0.8742145194, - 0.8749582994, - 0.8757000206, - 0.8764396811, - 0.8771772793, - 0.8779128134, - 0.8786462817, - 0.8793776825, - 0.8801070140, - 0.8808342745, - 0.8815594624, - 0.8822825758, - 0.8830036132, - 0.8837225727, - 0.8844394528, - 0.8851542517, - 0.8858669678, - 0.8865775993, - 0.8872861446, - 0.8879926020, - 0.8886969699, - 0.8893992467, - 0.8900994305, - 0.8907975199, - 0.8914935132, - 0.8921874087, - 0.8928792048, - 0.8935688998, - 0.8942564922, - 0.8949419803, - 0.8956253626, - 0.8963066373, - 0.8969858030, - 0.8976628579, - 0.8983378006, - 0.8990106294, - 0.8996813427, - 0.9003499390, - 0.9010164167, - 0.9016807742, - 0.9023430100, - 0.9030031224, - 0.9036611101, - 0.9043169713, - 0.9049707045, - 0.9056223083, - 0.9062717811, - 0.9069191213, - 0.9075643274, - 0.9082073980, - 0.9088483315, - 0.9094871263, - 0.9101237811, - 0.9107582942, - 0.9113906642, - 0.9120208897, - 0.9126489690, - 0.9132749009, - 0.9138986837, - 0.9145203160, - 0.9151397963, - 0.9157571232, - 0.9163722953, - 0.9169853111, - 0.9175961691, - 0.9182048679, - 0.9188114061, - 0.9194157822, - 0.9200179948, - 0.9206180426, - 0.9212159241, - 0.9218116378, - 0.9224051825, - 0.9229965566, - 0.9235857588, - 0.9241727878, - 0.9247576421, - 0.9253403203, - 0.9259208211, - 0.9264991431, - 0.9270752850, - 0.9276492454, - 0.9282210230, - 0.9287906163, - 0.9293580242, - 0.9299232451, - 0.9304862779, - 0.9310471211, - 0.9316057735, - 0.9321622337, - 0.9327165005, - 0.9332685724, - 0.9338184484, - 0.9343661269, - 0.9349116068, - 0.9354548868, - 0.9359959655, - 0.9365348418, - 0.9370715142, - 0.9376059817, - 0.9381382429, - 0.9386682966, - 0.9391961415, - 0.9397217764, - 0.9402452000, - 0.9407664111, - 0.9412854085, - 0.9418021910, - 0.9423167573, - 0.9428291063, - 0.9433392367, - 0.9438471473, - 0.9443528370, - 0.9448563045, - 0.9453575486, - 0.9458565683, - 0.9463533623, - 0.9468479294, - 0.9473402684, - 0.9478303783, - 0.9483182579, - 0.9488039059, - 0.9492873214, - 0.9497685031, - 0.9502474498, - 0.9507241606, - 0.9511986342, - 0.9516708696, - 0.9521408655, - 0.9526086210, - 0.9530741350, - 0.9535374062, - 0.9539984337, - 0.9544572163, - 0.9549137530, - 0.9553680427, - 0.9558200843, - 0.9562698768, - 0.9567174191, - 0.9571627101, - 0.9576057488, - 0.9580465342, - 0.9584850652, - 0.9589213409, - 0.9593553600, - 0.9597871218, - 0.9602166250, - 0.9606438688, - 0.9610688521, - 0.9614915739, - 0.9619120332, - 0.9623302290, - 0.9627461604, - 0.9631598263, - 0.9635712259, - 0.9639803580, - 0.9643872219, - 0.9647918164, - 0.9651941407, - 0.9655941938, - 0.9659919747, - 0.9663874826, - 0.9667807165, - 0.9671716754, - 0.9675603585, - 0.9679467648, - 0.9683308935, - 0.9687127436, - 0.9690923142, - 0.9694696044, - 0.9698446134, - 0.9702173403, - 0.9705877841, - 0.9709559440, - 0.9713218192, - 0.9716854088, - 0.9720467119, - 0.9724057277, - 0.9727624553, - 0.9731168939, - 0.9734690427, - 0.9738189008, - 0.9741664675, - 0.9745117418, - 0.9748547230, - 0.9751954102, - 0.9755338028, - 0.9758698998, - 0.9762037005, - 0.9765352041, - 0.9768644098, - 0.9771913168, - 0.9775159245, - 0.9778382319, - 0.9781582384, - 0.9784759432, - 0.9787913456, - 0.9791044447, - 0.9794152399, - 0.9797237305, - 0.9800299157, - 0.9803337948, - 0.9806353670, - 0.9809346317, - 0.9812315882, - 0.9815262358, - 0.9818185737, - 0.9821086014, - 0.9823963180, - 0.9826817229, - 0.9829648155, - 0.9832455951, - 0.9835240610, - 0.9838002126, - 0.9840740493, - 0.9843455703, - 0.9846147750, - 0.9848816628, - 0.9851462332, - 0.9854084853, - 0.9856684187, - 0.9859260328, - 0.9861813268, - 0.9864343003, - 0.9866849526, - 0.9869332832, - 0.9871792914, - 0.9874229766, - 0.9876643384, - 0.9879033761, - 0.9881400891, - 0.9883744770, - 0.9886065391, - 0.9888362750, - 0.9890636840, - 0.9892887657, - 0.9895115194, - 0.9897319448, - 0.9899500412, - 0.9901658081, - 0.9903792451, - 0.9905903517, - 0.9907991273, - 0.9910055714, - 0.9912096836, - 0.9914114634, - 0.9916109103, - 0.9918080239, - 0.9920028036, - 0.9921952491, - 0.9923853598, - 0.9925731354, - 0.9927585753, - 0.9929416792, - 0.9931224466, - 0.9933008770, - 0.9934769702, - 0.9936507256, - 0.9938221428, - 0.9939912215, - 0.9941579612, - 0.9943223616, - 0.9944844222, - 0.9946441427, - 0.9948015227, - 0.9949565619, - 0.9951092598, - 0.9952596161, - 0.9954076305, - 0.9955533026, - 0.9956966321, - 0.9958376186, - 0.9959762618, - 0.9961125614, - 0.9962465170, - 0.9963781284, - 0.9965073951, - 0.9966343170, - 0.9967588938, - 0.9968811250, - 0.9970010105, - 0.9971185500, - 0.9972337431, - 0.9973465897, - 0.9974570894, - 0.9975652420, - 0.9976710472, - 0.9977745048, - 0.9978756145, - 0.9979743762, - 0.9980707895, - 0.9981648543, - 0.9982565703, - 0.9983459372, - 0.9984329550, - 0.9985176234, - 0.9985999422, - 0.9986799111, - 0.9987575301, - 0.9988327989, - 0.9989057173, - 0.9989762853, - 0.9990445025, - 0.9991103689, - 0.9991738843, - 0.9992350485, - 0.9992938615, - 0.9993503230, - 0.9994044329, - 0.9994561911, - 0.9995055976, - 0.9995526521, - 0.9995973545, - 0.9996397048, - 0.9996797029, - 0.9997173486, - 0.9997526418, - 0.9997855826, - 0.9998161708, - 0.9998444063, - 0.9998702890, - 0.9998938190, - 0.9999149961, - 0.9999338204, - 0.9999502917, - 0.9999644100, - 0.9999761753, - 0.9999855875, - 0.9999926467, - 0.9999973529, - 0.9999997059 -}; - -real_t sine_long_960[] = -{ - 0.0008181230, - 0.0024543669, - 0.0040906041, - 0.0057268305, - 0.0073630415, - 0.0089992327, - 0.0106353999, - 0.0122715386, - 0.0139076445, - 0.0155437131, - 0.0171797401, - 0.0188157211, - 0.0204516518, - 0.0220875276, - 0.0237233444, - 0.0253590976, - 0.0269947829, - 0.0286303960, - 0.0302659324, - 0.0319013878, - 0.0335367578, - 0.0351720379, - 0.0368072240, - 0.0384423114, - 0.0400772960, - 0.0417121732, - 0.0433469388, - 0.0449815883, - 0.0466161174, - 0.0482505217, - 0.0498847968, - 0.0515189384, - 0.0531529420, - 0.0547868033, - 0.0564205179, - 0.0580540815, - 0.0596874897, - 0.0613207380, - 0.0629538222, - 0.0645867378, - 0.0662194805, - 0.0678520459, - 0.0694844297, - 0.0711166274, - 0.0727486347, - 0.0743804473, - 0.0760120607, - 0.0776434706, - 0.0792746727, - 0.0809056625, - 0.0825364356, - 0.0841669879, - 0.0857973147, - 0.0874274119, - 0.0890572750, - 0.0906868996, - 0.0923162815, - 0.0939454162, - 0.0955742994, - 0.0972029267, - 0.0988312938, - 0.1004593962, - 0.1020872297, - 0.1037147899, - 0.1053420724, - 0.1069690729, - 0.1085957870, - 0.1102222103, - 0.1118483386, - 0.1134741674, - 0.1150996924, - 0.1167249092, - 0.1183498135, - 0.1199744010, - 0.1215986673, - 0.1232226080, - 0.1248462188, - 0.1264694953, - 0.1280924333, - 0.1297150283, - 0.1313372760, - 0.1329591721, - 0.1345807122, - 0.1362018920, - 0.1378227072, - 0.1394431534, - 0.1410632262, - 0.1426829214, - 0.1443022345, - 0.1459211613, - 0.1475396975, - 0.1491578386, - 0.1507755804, - 0.1523929185, - 0.1540098486, - 0.1556263664, - 0.1572424676, - 0.1588581477, - 0.1604734026, - 0.1620882278, - 0.1637026190, - 0.1653165720, - 0.1669300823, - 0.1685431457, - 0.1701557579, - 0.1717679146, - 0.1733796113, - 0.1749908439, - 0.1766016080, - 0.1782118992, - 0.1798217134, - 0.1814310460, - 0.1830398930, - 0.1846482499, - 0.1862561124, - 0.1878634763, - 0.1894703372, - 0.1910766908, - 0.1926825329, - 0.1942878591, - 0.1958926651, - 0.1974969467, - 0.1991006995, - 0.2007039192, - 0.2023066016, - 0.2039087424, - 0.2055103372, - 0.2071113819, - 0.2087118720, - 0.2103118034, - 0.2119111716, - 0.2135099726, - 0.2151082019, - 0.2167058553, - 0.2183029285, - 0.2198994172, - 0.2214953172, - 0.2230906242, - 0.2246853339, - 0.2262794421, - 0.2278729444, - 0.2294658367, - 0.2310581146, - 0.2326497739, - 0.2342408103, - 0.2358312196, - 0.2374209975, - 0.2390101398, - 0.2405986421, - 0.2421865003, - 0.2437737101, - 0.2453602672, - 0.2469461675, - 0.2485314066, - 0.2501159802, - 0.2516998843, - 0.2532831145, - 0.2548656665, - 0.2564475362, - 0.2580287194, - 0.2596092117, - 0.2611890089, - 0.2627681069, - 0.2643465014, - 0.2659241881, - 0.2675011628, - 0.2690774214, - 0.2706529596, - 0.2722277732, - 0.2738018579, - 0.2753752096, - 0.2769478240, - 0.2785196969, - 0.2800908242, - 0.2816612016, - 0.2832308248, - 0.2847996898, - 0.2863677923, - 0.2879351281, - 0.2895016930, - 0.2910674829, - 0.2926324934, - 0.2941967205, - 0.2957601599, - 0.2973228075, - 0.2988846591, - 0.3004457105, - 0.3020059575, - 0.3035653959, - 0.3051240216, - 0.3066818303, - 0.3082388180, - 0.3097949805, - 0.3113503135, - 0.3129048130, - 0.3144584747, - 0.3160112945, - 0.3175632683, - 0.3191143918, - 0.3206646610, - 0.3222140717, - 0.3237626197, - 0.3253103009, - 0.3268571111, - 0.3284030463, - 0.3299481022, - 0.3314922747, - 0.3330355597, - 0.3345779531, - 0.3361194508, - 0.3376600485, - 0.3391997422, - 0.3407385278, - 0.3422764011, - 0.3438133581, - 0.3453493945, - 0.3468845064, - 0.3484186895, - 0.3499519398, - 0.3514842532, - 0.3530156256, - 0.3545460528, - 0.3560755308, - 0.3576040555, - 0.3591316228, - 0.3606582285, - 0.3621838687, - 0.3637085392, - 0.3652322359, - 0.3667549548, - 0.3682766918, - 0.3697974428, - 0.3713172038, - 0.3728359706, - 0.3743537392, - 0.3758705056, - 0.3773862656, - 0.3789010153, - 0.3804147505, - 0.3819274673, - 0.3834391615, - 0.3849498291, - 0.3864594661, - 0.3879680685, - 0.3894756321, - 0.3909821530, - 0.3924876271, - 0.3939920504, - 0.3954954189, - 0.3969977285, - 0.3984989752, - 0.3999991550, - 0.4014982640, - 0.4029962979, - 0.4044932530, - 0.4059891250, - 0.4074839102, - 0.4089776043, - 0.4104702036, - 0.4119617038, - 0.4134521011, - 0.4149413915, - 0.4164295710, - 0.4179166355, - 0.4194025812, - 0.4208874040, - 0.4223710999, - 0.4238536651, - 0.4253350954, - 0.4268153870, - 0.4282945359, - 0.4297725381, - 0.4312493897, - 0.4327250867, - 0.4341996252, - 0.4356730012, - 0.4371452107, - 0.4386162499, - 0.4400861148, - 0.4415548014, - 0.4430223059, - 0.4444886242, - 0.4459537525, - 0.4474176869, - 0.4488804234, - 0.4503419581, - 0.4518022871, - 0.4532614065, - 0.4547193124, - 0.4561760009, - 0.4576314680, - 0.4590857100, - 0.4605387228, - 0.4619905026, - 0.4634410455, - 0.4648903477, - 0.4663384052, - 0.4677852142, - 0.4692307707, - 0.4706750710, - 0.4721181112, - 0.4735598874, - 0.4750003957, - 0.4764396322, - 0.4778775932, - 0.4793142748, - 0.4807496731, - 0.4821837843, - 0.4836166046, - 0.4850481301, - 0.4864783569, - 0.4879072813, - 0.4893348994, - 0.4907612075, - 0.4921862016, - 0.4936098779, - 0.4950322328, - 0.4964532623, - 0.4978729626, - 0.4992913300, - 0.5007083606, - 0.5021240507, - 0.5035383964, - 0.5049513940, - 0.5063630397, - 0.5077733298, - 0.5091822603, - 0.5105898276, - 0.5119960280, - 0.5134008575, - 0.5148043125, - 0.5162063893, - 0.5176070840, - 0.5190063929, - 0.5204043123, - 0.5218008384, - 0.5231959674, - 0.5245896958, - 0.5259820196, - 0.5273729352, - 0.5287624389, - 0.5301505270, - 0.5315371956, - 0.5329224412, - 0.5343062600, - 0.5356886483, - 0.5370696023, - 0.5384491185, - 0.5398271931, - 0.5412038224, - 0.5425790028, - 0.5439527305, - 0.5453250019, - 0.5466958133, - 0.5480651610, - 0.5494330413, - 0.5507994507, - 0.5521643854, - 0.5535278418, - 0.5548898163, - 0.5562503051, - 0.5576093047, - 0.5589668114, - 0.5603228216, - 0.5616773317, - 0.5630303379, - 0.5643818368, - 0.5657318246, - 0.5670802978, - 0.5684272527, - 0.5697726858, - 0.5711165935, - 0.5724589721, - 0.5737998180, - 0.5751391277, - 0.5764768976, - 0.5778131241, - 0.5791478036, - 0.5804809326, - 0.5818125074, - 0.5831425246, - 0.5844709805, - 0.5857978716, - 0.5871231943, - 0.5884469451, - 0.5897691205, - 0.5910897169, - 0.5924087308, - 0.5937261586, - 0.5950419968, - 0.5963562420, - 0.5976688905, - 0.5989799388, - 0.6002893835, - 0.6015972211, - 0.6029034480, - 0.6042080607, - 0.6055110558, - 0.6068124298, - 0.6081121791, - 0.6094103003, - 0.6107067900, - 0.6120016446, - 0.6132948607, - 0.6145864349, - 0.6158763636, - 0.6171646434, - 0.6184512709, - 0.6197362426, - 0.6210195550, - 0.6223012049, - 0.6235811886, - 0.6248595028, - 0.6261361441, - 0.6274111090, - 0.6286843942, - 0.6299559962, - 0.6312259115, - 0.6324941370, - 0.6337606690, - 0.6350255043, - 0.6362886394, - 0.6375500710, - 0.6388097956, - 0.6400678100, - 0.6413241107, - 0.6425786945, - 0.6438315578, - 0.6450826974, - 0.6463321099, - 0.6475797920, - 0.6488257403, - 0.6500699516, - 0.6513124223, - 0.6525531494, - 0.6537921293, - 0.6550293589, - 0.6562648347, - 0.6574985536, - 0.6587305121, - 0.6599607069, - 0.6611891349, - 0.6624157927, - 0.6636406770, - 0.6648637845, - 0.6660851120, - 0.6673046561, - 0.6685224137, - 0.6697383815, - 0.6709525561, - 0.6721649344, - 0.6733755132, - 0.6745842891, - 0.6757912589, - 0.6769964195, - 0.6781997675, - 0.6794012997, - 0.6806010131, - 0.6817989042, - 0.6829949700, - 0.6841892071, - 0.6853816125, - 0.6865721829, - 0.6877609152, - 0.6889478061, - 0.6901328525, - 0.6913160512, - 0.6924973990, - 0.6936768929, - 0.6948545295, - 0.6960303058, - 0.6972042186, - 0.6983762648, - 0.6995464412, - 0.7007147448, - 0.7018811723, - 0.7030457206, - 0.7042083867, - 0.7053691674, - 0.7065280597, - 0.7076850603, - 0.7088401663, - 0.7099933745, - 0.7111446818, - 0.7122940851, - 0.7134415815, - 0.7145871677, - 0.7157308408, - 0.7168725976, - 0.7180124352, - 0.7191503504, - 0.7202863403, - 0.7214204017, - 0.7225525317, - 0.7236827271, - 0.7248109851, - 0.7259373025, - 0.7270616764, - 0.7281841037, - 0.7293045814, - 0.7304231066, - 0.7315396762, - 0.7326542872, - 0.7337669368, - 0.7348776218, - 0.7359863393, - 0.7370930863, - 0.7381978600, - 0.7393006572, - 0.7404014752, - 0.7415003108, - 0.7425971612, - 0.7436920235, - 0.7447848947, - 0.7458757719, - 0.7469646521, - 0.7480515325, - 0.7491364101, - 0.7502192821, - 0.7513001455, - 0.7523789975, - 0.7534558351, - 0.7545306554, - 0.7556034557, - 0.7566742330, - 0.7577429844, - 0.7588097072, - 0.7598743984, - 0.7609370551, - 0.7619976746, - 0.7630562540, - 0.7641127905, - 0.7651672812, - 0.7662197234, - 0.7672701141, - 0.7683184506, - 0.7693647301, - 0.7704089498, - 0.7714511069, - 0.7724911985, - 0.7735292220, - 0.7745651745, - 0.7755990532, - 0.7766308555, - 0.7776605784, - 0.7786882194, - 0.7797137755, - 0.7807372441, - 0.7817586225, - 0.7827779079, - 0.7837950975, - 0.7848101886, - 0.7858231786, - 0.7868340647, - 0.7878428442, - 0.7888495145, - 0.7898540727, - 0.7908565162, - 0.7918568424, - 0.7928550486, - 0.7938511320, - 0.7948450901, - 0.7958369201, - 0.7968266194, - 0.7978141854, - 0.7987996154, - 0.7997829068, - 0.8007640569, - 0.8017430631, - 0.8027199228, - 0.8036946334, - 0.8046671923, - 0.8056375968, - 0.8066058444, - 0.8075719325, - 0.8085358584, - 0.8094976197, - 0.8104572137, - 0.8114146378, - 0.8123698896, - 0.8133229663, - 0.8142738656, - 0.8152225848, - 0.8161691215, - 0.8171134730, - 0.8180556368, - 0.8189956104, - 0.8199333914, - 0.8208689772, - 0.8218023652, - 0.8227335530, - 0.8236625381, - 0.8245893180, - 0.8255138903, - 0.8264362524, - 0.8273564019, - 0.8282743363, - 0.8291900531, - 0.8301035500, - 0.8310148244, - 0.8319238740, - 0.8328306962, - 0.8337352887, - 0.8346376491, - 0.8355377749, - 0.8364356636, - 0.8373313130, - 0.8382247206, - 0.8391158841, - 0.8400048009, - 0.8408914688, - 0.8417758854, - 0.8426580483, - 0.8435379552, - 0.8444156036, - 0.8452909913, - 0.8461641159, - 0.8470349751, - 0.8479035665, - 0.8487698878, - 0.8496339367, - 0.8504957108, - 0.8513552080, - 0.8522124258, - 0.8530673619, - 0.8539200142, - 0.8547703802, - 0.8556184578, - 0.8564642446, - 0.8573077384, - 0.8581489370, - 0.8589878380, - 0.8598244392, - 0.8606587385, - 0.8614907335, - 0.8623204220, - 0.8631478018, - 0.8639728707, - 0.8647956265, - 0.8656160670, - 0.8664341900, - 0.8672499933, - 0.8680634747, - 0.8688746320, - 0.8696834631, - 0.8704899657, - 0.8712941378, - 0.8720959772, - 0.8728954818, - 0.8736926493, - 0.8744874777, - 0.8752799648, - 0.8760701085, - 0.8768579067, - 0.8776433574, - 0.8784264583, - 0.8792072074, - 0.8799856025, - 0.8807616417, - 0.8815353229, - 0.8823066439, - 0.8830756027, - 0.8838421972, - 0.8846064254, - 0.8853682853, - 0.8861277748, - 0.8868848918, - 0.8876396344, - 0.8883920005, - 0.8891419881, - 0.8898895952, - 0.8906348198, - 0.8913776599, - 0.8921181136, - 0.8928561787, - 0.8935918534, - 0.8943251357, - 0.8950560237, - 0.8957845152, - 0.8965106085, - 0.8972343016, - 0.8979555925, - 0.8986744793, - 0.8993909601, - 0.9001050330, - 0.9008166959, - 0.9015259472, - 0.9022327848, - 0.9029372068, - 0.9036392114, - 0.9043387967, - 0.9050359608, - 0.9057307018, - 0.9064230179, - 0.9071129073, - 0.9078003680, - 0.9084853983, - 0.9091679963, - 0.9098481602, - 0.9105258881, - 0.9112011783, - 0.9118740290, - 0.9125444382, - 0.9132124044, - 0.9138779255, - 0.9145410000, - 0.9152016259, - 0.9158598016, - 0.9165155252, - 0.9171687951, - 0.9178196094, - 0.9184679665, - 0.9191138645, - 0.9197573017, - 0.9203982766, - 0.9210367872, - 0.9216728319, - 0.9223064091, - 0.9229375169, - 0.9235661538, - 0.9241923180, - 0.9248160078, - 0.9254372217, - 0.9260559578, - 0.9266722147, - 0.9272859906, - 0.9278972838, - 0.9285060928, - 0.9291124159, - 0.9297162514, - 0.9303175979, - 0.9309164536, - 0.9315128169, - 0.9321066864, - 0.9326980603, - 0.9332869370, - 0.9338733151, - 0.9344571929, - 0.9350385689, - 0.9356174416, - 0.9361938093, - 0.9367676705, - 0.9373390237, - 0.9379078674, - 0.9384742000, - 0.9390380200, - 0.9395993260, - 0.9401581163, - 0.9407143896, - 0.9412681443, - 0.9418193789, - 0.9423680920, - 0.9429142821, - 0.9434579477, - 0.9439990874, - 0.9445376998, - 0.9450737833, - 0.9456073366, - 0.9461383582, - 0.9466668467, - 0.9471928007, - 0.9477162188, - 0.9482370995, - 0.9487554416, - 0.9492712435, - 0.9497845040, - 0.9502952216, - 0.9508033949, - 0.9513090227, - 0.9518121035, - 0.9523126361, - 0.9528106190, - 0.9533060510, - 0.9537989307, - 0.9542892567, - 0.9547770279, - 0.9552622428, - 0.9557449002, - 0.9562249988, - 0.9567025372, - 0.9571775143, - 0.9576499288, - 0.9581197793, - 0.9585870647, - 0.9590517836, - 0.9595139348, - 0.9599735172, - 0.9604305294, - 0.9608849703, - 0.9613368385, - 0.9617861330, - 0.9622328525, - 0.9626769958, - 0.9631185617, - 0.9635575491, - 0.9639939567, - 0.9644277835, - 0.9648590281, - 0.9652876896, - 0.9657137667, - 0.9661372582, - 0.9665581632, - 0.9669764804, - 0.9673922086, - 0.9678053469, - 0.9682158941, - 0.9686238491, - 0.9690292108, - 0.9694319780, - 0.9698321499, - 0.9702297252, - 0.9706247029, - 0.9710170819, - 0.9714068613, - 0.9717940399, - 0.9721786167, - 0.9725605907, - 0.9729399608, - 0.9733167261, - 0.9736908855, - 0.9740624381, - 0.9744313828, - 0.9747977187, - 0.9751614448, - 0.9755225600, - 0.9758810635, - 0.9762369542, - 0.9765902313, - 0.9769408937, - 0.9772889406, - 0.9776343710, - 0.9779771840, - 0.9783173786, - 0.9786549539, - 0.9789899092, - 0.9793222433, - 0.9796519555, - 0.9799790449, - 0.9803035106, - 0.9806253518, - 0.9809445675, - 0.9812611569, - 0.9815751192, - 0.9818864535, - 0.9821951590, - 0.9825012349, - 0.9828046803, - 0.9831054945, - 0.9834036766, - 0.9836992258, - 0.9839921414, - 0.9842824225, - 0.9845700684, - 0.9848550783, - 0.9851374515, - 0.9854171871, - 0.9856942845, - 0.9859687429, - 0.9862405616, - 0.9865097398, - 0.9867762768, - 0.9870401719, - 0.9873014244, - 0.9875600336, - 0.9878159988, - 0.9880693193, - 0.9883199945, - 0.9885680237, - 0.9888134061, - 0.9890561412, - 0.9892962283, - 0.9895336667, - 0.9897684559, - 0.9900005952, - 0.9902300839, - 0.9904569215, - 0.9906811073, - 0.9909026408, - 0.9911215213, - 0.9913377484, - 0.9915513213, - 0.9917622395, - 0.9919705024, - 0.9921761096, - 0.9923790604, - 0.9925793543, - 0.9927769908, - 0.9929719693, - 0.9931642894, - 0.9933539504, - 0.9935409519, - 0.9937252935, - 0.9939069745, - 0.9940859945, - 0.9942623531, - 0.9944360497, - 0.9946070839, - 0.9947754553, - 0.9949411633, - 0.9951042076, - 0.9952645877, - 0.9954223032, - 0.9955773536, - 0.9957297385, - 0.9958794576, - 0.9960265105, - 0.9961708966, - 0.9963126157, - 0.9964516674, - 0.9965880513, - 0.9967217670, - 0.9968528142, - 0.9969811925, - 0.9971069016, - 0.9972299412, - 0.9973503108, - 0.9974680103, - 0.9975830392, - 0.9976953973, - 0.9978050843, - 0.9979120998, - 0.9980164436, - 0.9981181155, - 0.9982171151, - 0.9983134421, - 0.9984070964, - 0.9984980776, - 0.9985863855, - 0.9986720200, - 0.9987549807, - 0.9988352674, - 0.9989128799, - 0.9989878181, - 0.9990600816, - 0.9991296704, - 0.9991965842, - 0.9992608228, - 0.9993223862, - 0.9993812740, - 0.9994374862, - 0.9994910226, - 0.9995418831, - 0.9995900674, - 0.9996355756, - 0.9996784075, - 0.9997185629, - 0.9997560418, - 0.9997908440, - 0.9998229695, - 0.9998524181, - 0.9998791899, - 0.9999032846, - 0.9999247024, - 0.9999434430, - 0.9999595065, - 0.9999728928, - 0.9999836018, - 0.9999916336, - 0.9999969881, - 0.9999996654 -}; - -real_t sine_short_128[] = -{ - 0.0061358848, - 0.0184067304, - 0.0306748040, - 0.0429382581, - 0.0551952459, - 0.0674439214, - 0.0796824402, - 0.0919089590, - 0.1041216368, - 0.1163186341, - 0.1284981143, - 0.1406582432, - 0.1527971895, - 0.1649131250, - 0.1770042253, - 0.1890686693, - 0.2011046404, - 0.2131103258, - 0.2250839175, - 0.2370236125, - 0.2489276125, - 0.2607941250, - 0.2726213628, - 0.2844075449, - 0.2961508962, - 0.3078496483, - 0.3195020394, - 0.3311063146, - 0.3426607265, - 0.3541635348, - 0.3656130075, - 0.3770074202, - 0.3883450569, - 0.3996242103, - 0.4108431818, - 0.4220002818, - 0.4330938301, - 0.4441221560, - 0.4550835988, - 0.4659765077, - 0.4767992422, - 0.4875501725, - 0.4982276796, - 0.5088301553, - 0.5193560032, - 0.5298036379, - 0.5401714861, - 0.5504579865, - 0.5606615899, - 0.5707807598, - 0.5808139721, - 0.5907597160, - 0.6006164937, - 0.6103828207, - 0.6200572264, - 0.6296382536, - 0.6391244597, - 0.6485144160, - 0.6578067083, - 0.6669999374, - 0.6760927188, - 0.6850836831, - 0.6939714763, - 0.7027547599, - 0.7114322112, - 0.7200025235, - 0.7284644060, - 0.7368165845, - 0.7450578010, - 0.7531868147, - 0.7612024011, - 0.7691033533, - 0.7768884813, - 0.7845566127, - 0.7921065928, - 0.7995372846, - 0.8068475690, - 0.8140363451, - 0.8211025303, - 0.8280450605, - 0.8348628901, - 0.8415549925, - 0.8481203597, - 0.8545580032, - 0.8608669533, - 0.8670462601, - 0.8730949928, - 0.8790122407, - 0.8847971125, - 0.8904487372, - 0.8959662635, - 0.9013488606, - 0.9065957178, - 0.9117060451, - 0.9166790728, - 0.9215140520, - 0.9262102546, - 0.9307669733, - 0.9351835219, - 0.9394592352, - 0.9435934695, - 0.9475856021, - 0.9514350317, - 0.9551411788, - 0.9587034850, - 0.9621214141, - 0.9653944512, - 0.9685221034, - 0.9715038998, - 0.9743393912, - 0.9770281507, - 0.9795697733, - 0.9819638764, - 0.9842100992, - 0.9863081037, - 0.9882575738, - 0.9900582159, - 0.9917097588, - 0.9932119539, - 0.9945645750, - 0.9957674182, - 0.9968203026, - 0.9977230695, - 0.9984755829, - 0.9990777296, - 0.9995294188, - 0.9998305826, - 0.9999811755 -}; - -real_t sine_short_120[] = -{ - 0.0065449381, - 0.0196336930, - 0.0327190837, - 0.0457988682, - 0.0588708053, - 0.0719326552, - 0.0849821797, - 0.0980171430, - 0.1110353116, - 0.1240344549, - 0.1370123455, - 0.1499667597, - 0.1628954779, - 0.1757962848, - 0.1886669699, - 0.2015053279, - 0.2143091589, - 0.2270762692, - 0.2398044712, - 0.2524915839, - 0.2651354334, - 0.2777338534, - 0.2902846851, - 0.3027857780, - 0.3152349901, - 0.3276301883, - 0.3399692488, - 0.3522500573, - 0.3644705095, - 0.3766285116, - 0.3887219804, - 0.4007488436, - 0.4127070406, - 0.4245945223, - 0.4364092520, - 0.4481492051, - 0.4598123703, - 0.4713967489, - 0.4829003561, - 0.4943212208, - 0.5056573861, - 0.5169069096, - 0.5280678638, - 0.5391383363, - 0.5501164301, - 0.5610002644, - 0.5717879741, - 0.5824777109, - 0.5930676432, - 0.6035559563, - 0.6139408533, - 0.6242205546, - 0.6343932989, - 0.6444573433, - 0.6544109631, - 0.6642524530, - 0.6739801267, - 0.6835923173, - 0.6930873779, - 0.7024636815, - 0.7117196216, - 0.7208536122, - 0.7298640883, - 0.7387495058, - 0.7475083425, - 0.7561390974, - 0.7646402918, - 0.7730104690, - 0.7812481948, - 0.7893520577, - 0.7973206693, - 0.8051526640, - 0.8128467000, - 0.8204014588, - 0.8278156461, - 0.8350879914, - 0.8422172487, - 0.8492021964, - 0.8560416377, - 0.8627344006, - 0.8692793384, - 0.8756753297, - 0.8819212785, - 0.8880161146, - 0.8939587938, - 0.8997482976, - 0.9053836343, - 0.9108638381, - 0.9161879700, - 0.9213551179, - 0.9263643963, - 0.9312149469, - 0.9359059386, - 0.9404365677, - 0.9448060577, - 0.9490136602, - 0.9530586539, - 0.9569403460, - 0.9606580713, - 0.9642111928, - 0.9675991016, - 0.9708212173, - 0.9738769878, - 0.9767658894, - 0.9794874272, - 0.9820411349, - 0.9844265749, - 0.9866433385, - 0.9886910458, - 0.9905693459, - 0.9922779171, - 0.9938164666, - 0.9951847307, - 0.9963824750, - 0.9974094943, - 0.9982656127, - 0.9989506833, - 0.9994645889, - 0.9998072413, - 0.9999785819 -}; - -#ifdef LD_DEC -real_t sine_mid_512[] = +ALIGN static const real_t sine_long_1024[] = { - 0.0015339802, - 0.0046019262, - 0.0076698290, - 0.0107376595, - 0.0138053889, - 0.0168729884, - 0.0199404291, - 0.0230076821, - 0.0260747186, - 0.0291415096, - 0.0322080263, - 0.0352742399, - 0.0383401214, - 0.0414056421, - 0.0444707731, - 0.0475354855, - 0.0505997504, - 0.0536635391, - 0.0567268227, - 0.0597895724, - 0.0628517593, - 0.0659133546, - 0.0689743295, - 0.0720346552, - 0.0750943029, - 0.0781532438, - 0.0812114491, - 0.0842688899, - 0.0873255376, - 0.0903813634, - 0.0934363384, - 0.0964904340, - 0.0995436214, - 0.1025958719, - 0.1056471566, - 0.1086974470, - 0.1117467143, - 0.1147949298, - 0.1178420648, - 0.1208880906, - 0.1239329785, - 0.1269767000, - 0.1300192263, - 0.1330605288, - 0.1361005789, - 0.1391393480, - 0.1421768074, - 0.1452129287, - 0.1482476831, - 0.1512810421, - 0.1543129773, - 0.1573434600, - 0.1603724617, - 0.1633999539, - 0.1664259081, - 0.1694502959, - 0.1724730887, - 0.1754942582, - 0.1785137759, - 0.1815316133, - 0.1845477420, - 0.1875621337, - 0.1905747601, - 0.1935855926, - 0.1965946031, - 0.1996017631, - 0.2026070444, - 0.2056104187, - 0.2086118577, - 0.2116113332, - 0.2146088169, - 0.2176042806, - 0.2205976961, - 0.2235890353, - 0.2265782700, - 0.2295653721, - 0.2325503134, - 0.2355330658, - 0.2385136014, - 0.2414918919, - 0.2444679094, - 0.2474416259, - 0.2504130134, - 0.2533820439, - 0.2563486895, - 0.2593129222, - 0.2622747142, - 0.2652340375, - 0.2681908643, - 0.2711451669, - 0.2740969173, - 0.2770460878, - 0.2799926507, - 0.2829365781, - 0.2858778425, - 0.2888164160, - 0.2917522711, - 0.2946853801, - 0.2976157155, - 0.3005432495, - 0.3034679547, - 0.3063898036, - 0.3093087686, - 0.3122248223, - 0.3151379372, - 0.3180480859, - 0.3209552410, - 0.3238593752, - 0.3267604611, - 0.3296584714, - 0.3325533788, - 0.3354451561, - 0.3383337760, - 0.3412192114, - 0.3441014352, - 0.3469804201, - 0.3498561391, - 0.3527285651, - 0.3555976712, - 0.3584634302, - 0.3613258152, - 0.3641847992, - 0.3670403554, - 0.3698924569, - 0.3727410769, - 0.3755861884, - 0.3784277648, - 0.3812657793, - 0.3841002051, - 0.3869310157, - 0.3897581843, - 0.3925816844, - 0.3954014893, - 0.3982175726, - 0.4010299077, - 0.4038384682, - 0.4066432275, - 0.4094441594, - 0.4122412374, - 0.4150344353, - 0.4178237267, - 0.4206090854, - 0.4233904852, - 0.4261678998, - 0.4289413032, - 0.4317106692, - 0.4344759718, - 0.4372371850, - 0.4399942827, - 0.4427472390, - 0.4454960280, - 0.4482406238, - 0.4509810007, - 0.4537171327, - 0.4564489941, - 0.4591765593, - 0.4618998026, - 0.4646186982, - 0.4673332207, - 0.4700433445, - 0.4727490440, - 0.4754502939, - 0.4781470686, - 0.4808393428, - 0.4835270912, - 0.4862102885, - 0.4888889093, - 0.4915629286, - 0.4942323210, - 0.4968970616, - 0.4995571252, - 0.5022124867, - 0.5048631212, - 0.5075090038, - 0.5101501095, - 0.5127864135, - 0.5154178909, - 0.5180445171, - 0.5206662672, - 0.5232831165, - 0.5258950406, - 0.5285020147, - 0.5311040144, - 0.5337010151, - 0.5362929924, - 0.5388799219, - 0.5414617792, - 0.5440385402, - 0.5466101804, - 0.5491766757, - 0.5517380020, - 0.5542941351, - 0.5568450509, - 0.5593907256, - 0.5619311350, - 0.5644662553, - 0.5669960626, - 0.5695205332, - 0.5720396432, - 0.5745533690, - 0.5770616868, - 0.5795645732, - 0.5820620044, - 0.5845539570, - 0.5870404077, - 0.5895213328, - 0.5919967092, - 0.5944665134, - 0.5969307223, - 0.5993893127, - 0.6018422614, - 0.6042895453, - 0.6067311415, - 0.6091670268, - 0.6115971784, - 0.6140215735, - 0.6164401891, - 0.6188530025, - 0.6212599911, - 0.6236611322, - 0.6260564031, - 0.6284457813, - 0.6308292444, - 0.6332067698, - 0.6355783353, - 0.6379439184, - 0.6403034970, - 0.6426570488, - 0.6450045517, - 0.6473459836, - 0.6496813224, - 0.6520105461, - 0.6543336328, - 0.6566505608, - 0.6589613080, - 0.6612658529, - 0.6635641737, - 0.6658562488, - 0.6681420566, - 0.6704215756, - 0.6726947843, - 0.6749616613, - 0.6772221854, - 0.6794763352, - 0.6817240894, - 0.6839654271, - 0.6862003270, - 0.6884287681, - 0.6906507295, - 0.6928661902, - 0.6950751294, - 0.6972775262, - 0.6994733600, - 0.7016626102, - 0.7038452560, - 0.7060212769, - 0.7081906525, - 0.7103533623, - 0.7125093860, - 0.7146587034, - 0.7168012940, - 0.7189371379, - 0.7210662148, - 0.7231885048, - 0.7253039879, - 0.7274126442, - 0.7295144537, - 0.7316093968, - 0.7336974537, - 0.7357786047, - 0.7378528304, - 0.7399201111, - 0.7419804273, - 0.7440337598, - 0.7460800891, - 0.7481193961, - 0.7501516614, - 0.7521768661, - 0.7541949909, - 0.7562060170, - 0.7582099254, - 0.7602066973, - 0.7621963137, - 0.7641787561, - 0.7661540058, - 0.7681220441, - 0.7700828526, - 0.7720364128, - 0.7739827062, - 0.7759217146, - 0.7778534198, - 0.7797778035, - 0.7816948476, - 0.7836045342, - 0.7855068451, - 0.7874017626, - 0.7892892687, - 0.7911693458, - 0.7930419760, - 0.7949071418, - 0.7967648257, - 0.7986150101, - 0.8004576777, - 0.8022928110, - 0.8041203929, - 0.8059404060, - 0.8077528334, - 0.8095576578, - 0.8113548624, - 0.8131444302, - 0.8149263444, - 0.8167005882, - 0.8184671449, - 0.8202259979, - 0.8219771306, - 0.8237205265, - 0.8254561693, - 0.8271840425, - 0.8289041300, - 0.8306164155, - 0.8323208829, - 0.8340175162, - 0.8357062995, - 0.8373872167, - 0.8390602521, - 0.8407253900, - 0.8423826147, - 0.8440319105, - 0.8456732620, - 0.8473066536, - 0.8489320701, - 0.8505494961, - 0.8521589165, - 0.8537603160, - 0.8553536795, - 0.8569389922, - 0.8585162390, - 0.8600854051, - 0.8616464758, - 0.8631994363, - 0.8647442721, - 0.8662809686, - 0.8678095113, - 0.8693298858, - 0.8708420779, - 0.8723460733, - 0.8738418578, - 0.8753294174, - 0.8768087381, - 0.8782798059, - 0.8797426070, - 0.8811971277, - 0.8826433541, - 0.8840812728, - 0.8855108702, - 0.8869321328, - 0.8883450473, - 0.8897496003, - 0.8911457787, - 0.8925335692, - 0.8939129589, - 0.8952839348, - 0.8966464839, - 0.8980005934, - 0.8993462506, - 0.9006834428, - 0.9020121574, - 0.9033323820, - 0.9046441040, - 0.9059473112, - 0.9072419912, - 0.9085281320, - 0.9098057213, - 0.9110747472, - 0.9123351977, - 0.9135870610, - 0.9148303252, - 0.9160649787, - 0.9172910099, - 0.9185084071, - 0.9197171590, - 0.9209172542, - 0.9221086814, - 0.9232914293, - 0.9244654868, - 0.9256308430, - 0.9267874867, - 0.9279354072, - 0.9290745935, - 0.9302050351, - 0.9313267212, - 0.9324396413, - 0.9335437850, - 0.9346391418, - 0.9357257014, - 0.9368034535, - 0.9378723882, - 0.9389324952, - 0.9399837646, - 0.9410261866, - 0.9420597512, - 0.9430844489, - 0.9441002698, - 0.9451072045, - 0.9461052436, - 0.9470943775, - 0.9480745970, - 0.9490458928, - 0.9500082559, - 0.9509616771, - 0.9519061475, - 0.9528416583, - 0.9537682005, - 0.9546857654, - 0.9555943446, - 0.9564939293, - 0.9573845111, - 0.9582660816, - 0.9591386326, - 0.9600021558, - 0.9608566431, - 0.9617020864, - 0.9625384778, - 0.9633658095, - 0.9641840736, - 0.9649932624, - 0.9657933683, - 0.9665843838, - 0.9673663015, - 0.9681391139, - 0.9689028139, - 0.9696573941, - 0.9704028476, - 0.9711391673, - 0.9718663462, - 0.9725843776, - 0.9732932546, - 0.9739929706, - 0.9746835191, - 0.9753648934, - 0.9760370872, - 0.9767000942, - 0.9773539081, - 0.9779985228, - 0.9786339322, - 0.9792601304, - 0.9798771113, - 0.9804848693, - 0.9810833986, - 0.9816726935, - 0.9822527486, - 0.9828235583, - 0.9833851173, - 0.9839374204, - 0.9844804622, - 0.9850142377, - 0.9855387419, - 0.9860539698, - 0.9865599167, - 0.9870565776, - 0.9875439480, - 0.9880220232, - 0.9884907988, - 0.9889502704, - 0.9894004335, - 0.9898412841, - 0.9902728179, - 0.9906950309, - 0.9911079190, - 0.9915114785, - 0.9919057055, - 0.9922905963, - 0.9926661473, - 0.9930323550, - 0.9933892158, - 0.9937367265, - 0.9940748837, - 0.9944036844, - 0.9947231253, - 0.9950332035, - 0.9953339161, - 0.9956252602, - 0.9959072331, - 0.9961798322, - 0.9964430548, - 0.9966968986, - 0.9969413610, - 0.9971764399, - 0.9974021329, - 0.9976184380, - 0.9978253532, - 0.9980228764, - 0.9982110059, - 0.9983897398, - 0.9985590765, - 0.9987190144, - 0.9988695519, - 0.9990106877, - 0.9991424205, - 0.9992647489, - 0.9993776719, - 0.9994811883, - 0.9995752973, - 0.9996599979, - 0.9997352893, - 0.9998011707, - 0.9998576417, - 0.9999047017, - 0.9999423501, - 0.9999705868, - 0.9999894113, - 0.9999988235 + FRAC_CONST(0.00076699031874270449), + FRAC_CONST(0.002300969151425805), + FRAC_CONST(0.0038349425697062275), + FRAC_CONST(0.0053689069639963425), + FRAC_CONST(0.0069028587247297558), + FRAC_CONST(0.0084367942423697988), + FRAC_CONST(0.0099707099074180308), + FRAC_CONST(0.011504602110422714), + FRAC_CONST(0.013038467241987334), + FRAC_CONST(0.014572301692779064), + FRAC_CONST(0.016106101853537287), + FRAC_CONST(0.017639864115082053), + FRAC_CONST(0.019173584868322623), + FRAC_CONST(0.020707260504265895), + FRAC_CONST(0.022240887414024961), + FRAC_CONST(0.023774461988827555), + FRAC_CONST(0.025307980620024571), + FRAC_CONST(0.026841439699098531), + FRAC_CONST(0.028374835617672099), + FRAC_CONST(0.029908164767516555), + FRAC_CONST(0.031441423540560301), + FRAC_CONST(0.032974608328897335), + FRAC_CONST(0.03450771552479575), + FRAC_CONST(0.036040741520706229), + FRAC_CONST(0.037573682709270494), + FRAC_CONST(0.039106535483329888), + FRAC_CONST(0.040639296235933736), + FRAC_CONST(0.042171961360347947), + FRAC_CONST(0.043704527250063421), + FRAC_CONST(0.04523699029880459), + FRAC_CONST(0.046769346900537863), + FRAC_CONST(0.048301593449480144), + FRAC_CONST(0.049833726340107277), + FRAC_CONST(0.051365741967162593), + FRAC_CONST(0.052897636725665324), + FRAC_CONST(0.054429407010919133), + FRAC_CONST(0.055961049218520569), + FRAC_CONST(0.057492559744367566), + FRAC_CONST(0.059023934984667931), + FRAC_CONST(0.060555171335947788), + FRAC_CONST(0.062086265195060088), + FRAC_CONST(0.063617212959193106), + FRAC_CONST(0.065148011025878833), + FRAC_CONST(0.066678655793001557), + FRAC_CONST(0.068209143658806329), + FRAC_CONST(0.069739471021907307), + FRAC_CONST(0.071269634281296401), + FRAC_CONST(0.072799629836351673), + FRAC_CONST(0.074329454086845756), + FRAC_CONST(0.075859103432954447), + FRAC_CONST(0.077388574275265049), + FRAC_CONST(0.078917863014784942), + FRAC_CONST(0.080446966052950014), + FRAC_CONST(0.081975879791633066), + FRAC_CONST(0.083504600633152432), + FRAC_CONST(0.085033124980280275), + FRAC_CONST(0.08656144923625117), + FRAC_CONST(0.088089569804770507), + FRAC_CONST(0.089617483090022959), + FRAC_CONST(0.091145185496681005), + FRAC_CONST(0.09267267342991331), + FRAC_CONST(0.094199943295393204), + FRAC_CONST(0.095726991499307162), + FRAC_CONST(0.097253814448363271), + FRAC_CONST(0.098780408549799623), + FRAC_CONST(0.10030677021139286), + FRAC_CONST(0.10183289584146653), + FRAC_CONST(0.10335878184889961), + FRAC_CONST(0.10488442464313497), + FRAC_CONST(0.10640982063418768), + FRAC_CONST(0.10793496623265365), + FRAC_CONST(0.10945985784971798), + FRAC_CONST(0.11098449189716339), + FRAC_CONST(0.11250886478737869), + FRAC_CONST(0.1140329729333672), + FRAC_CONST(0.11555681274875526), + FRAC_CONST(0.11708038064780059), + FRAC_CONST(0.11860367304540072), + FRAC_CONST(0.1201266863571015), + FRAC_CONST(0.12164941699910553), + FRAC_CONST(0.12317186138828048), + FRAC_CONST(0.12469401594216764), + FRAC_CONST(0.12621587707899035), + FRAC_CONST(0.12773744121766231), + FRAC_CONST(0.12925870477779614), + FRAC_CONST(0.13077966417971171), + FRAC_CONST(0.13230031584444465), + FRAC_CONST(0.13382065619375472), + FRAC_CONST(0.13534068165013421), + FRAC_CONST(0.13686038863681638), + FRAC_CONST(0.13837977357778389), + FRAC_CONST(0.13989883289777721), + FRAC_CONST(0.14141756302230302), + FRAC_CONST(0.14293596037764267), + FRAC_CONST(0.14445402139086047), + FRAC_CONST(0.14597174248981221), + FRAC_CONST(0.14748912010315357), + FRAC_CONST(0.14900615066034845), + FRAC_CONST(0.1505228305916774), + FRAC_CONST(0.15203915632824605), + FRAC_CONST(0.15355512430199345), + FRAC_CONST(0.15507073094570051), + FRAC_CONST(0.15658597269299843), + FRAC_CONST(0.15810084597837698), + FRAC_CONST(0.15961534723719306), + FRAC_CONST(0.16112947290567881), + FRAC_CONST(0.16264321942095031), + FRAC_CONST(0.16415658322101581), + FRAC_CONST(0.16566956074478412), + FRAC_CONST(0.16718214843207294), + FRAC_CONST(0.16869434272361733), + FRAC_CONST(0.17020614006107807), + FRAC_CONST(0.17171753688704997), + FRAC_CONST(0.17322852964507032), + FRAC_CONST(0.1747391147796272), + FRAC_CONST(0.17624928873616788), + FRAC_CONST(0.17775904796110717), + FRAC_CONST(0.17926838890183575), + FRAC_CONST(0.18077730800672859), + FRAC_CONST(0.1822858017251533), + FRAC_CONST(0.18379386650747845), + FRAC_CONST(0.1853014988050819), + FRAC_CONST(0.18680869507035927), + FRAC_CONST(0.18831545175673212), + FRAC_CONST(0.18982176531865641), + FRAC_CONST(0.1913276322116309), + FRAC_CONST(0.19283304889220523), + FRAC_CONST(0.1943380118179886), + FRAC_CONST(0.19584251744765785), + FRAC_CONST(0.19734656224096592), + FRAC_CONST(0.19885014265875009), + FRAC_CONST(0.20035325516294045), + FRAC_CONST(0.20185589621656805), + FRAC_CONST(0.20335806228377332), + FRAC_CONST(0.20485974982981442), + FRAC_CONST(0.20636095532107551), + FRAC_CONST(0.20786167522507507), + FRAC_CONST(0.20936190601047416), + FRAC_CONST(0.21086164414708486), + FRAC_CONST(0.21236088610587842), + FRAC_CONST(0.21385962835899375), + FRAC_CONST(0.21535786737974555), + FRAC_CONST(0.21685559964263262), + FRAC_CONST(0.21835282162334632), + FRAC_CONST(0.2198495297987787), + FRAC_CONST(0.22134572064703081), + FRAC_CONST(0.22284139064742112), + FRAC_CONST(0.2243365362804936), + FRAC_CONST(0.22583115402802617), + FRAC_CONST(0.22732524037303886), + FRAC_CONST(0.22881879179980222), + FRAC_CONST(0.23031180479384544), + FRAC_CONST(0.23180427584196478), + FRAC_CONST(0.23329620143223159), + FRAC_CONST(0.23478757805400097), + FRAC_CONST(0.23627840219791957), + FRAC_CONST(0.23776867035593419), + FRAC_CONST(0.23925837902129998), + FRAC_CONST(0.24074752468858843), + FRAC_CONST(0.24223610385369601), + FRAC_CONST(0.24372411301385216), + FRAC_CONST(0.24521154866762754), + FRAC_CONST(0.24669840731494241), + FRAC_CONST(0.24818468545707478), + FRAC_CONST(0.24967037959666857), + FRAC_CONST(0.25115548623774192), + FRAC_CONST(0.25264000188569552), + FRAC_CONST(0.25412392304732062), + FRAC_CONST(0.25560724623080738), + FRAC_CONST(0.25708996794575312), + FRAC_CONST(0.25857208470317034), + FRAC_CONST(0.26005359301549519), + FRAC_CONST(0.26153448939659552), + FRAC_CONST(0.263014770361779), + FRAC_CONST(0.26449443242780163), + FRAC_CONST(0.26597347211287559), + FRAC_CONST(0.26745188593667762), + FRAC_CONST(0.26892967042035726), + FRAC_CONST(0.27040682208654482), + FRAC_CONST(0.27188333745935972), + FRAC_CONST(0.27335921306441868), + FRAC_CONST(0.27483444542884394), + FRAC_CONST(0.27630903108127108), + FRAC_CONST(0.27778296655185769), + FRAC_CONST(0.27925624837229118), + FRAC_CONST(0.28072887307579719), + FRAC_CONST(0.28220083719714756), + FRAC_CONST(0.28367213727266843), + FRAC_CONST(0.28514276984024867), + FRAC_CONST(0.28661273143934779), + FRAC_CONST(0.28808201861100413), + FRAC_CONST(0.28955062789784303), + FRAC_CONST(0.29101855584408509), + FRAC_CONST(0.29248579899555388), + FRAC_CONST(0.29395235389968466), + FRAC_CONST(0.29541821710553201), + FRAC_CONST(0.29688338516377827), + FRAC_CONST(0.2983478546267414), + FRAC_CONST(0.29981162204838335), + FRAC_CONST(0.30127468398431795), + FRAC_CONST(0.30273703699181914), + FRAC_CONST(0.30419867762982911), + FRAC_CONST(0.30565960245896612), + FRAC_CONST(0.3071198080415331), + FRAC_CONST(0.30857929094152509), + FRAC_CONST(0.31003804772463789), + FRAC_CONST(0.31149607495827591), + FRAC_CONST(0.3129533692115602), + FRAC_CONST(0.31440992705533666), + FRAC_CONST(0.31586574506218396), + FRAC_CONST(0.31732081980642174), + FRAC_CONST(0.31877514786411848), + FRAC_CONST(0.32022872581309986), + FRAC_CONST(0.32168155023295658), + FRAC_CONST(0.32313361770505233), + FRAC_CONST(0.32458492481253215), + FRAC_CONST(0.32603546814033024), + FRAC_CONST(0.327485244275178), + FRAC_CONST(0.3289342498056122), + FRAC_CONST(0.33038248132198278), + FRAC_CONST(0.33182993541646111), + FRAC_CONST(0.33327660868304793), + FRAC_CONST(0.33472249771758122), + FRAC_CONST(0.33616759911774452), + FRAC_CONST(0.33761190948307462), + FRAC_CONST(0.33905542541496964), + FRAC_CONST(0.34049814351669716), + FRAC_CONST(0.34194006039340219), + FRAC_CONST(0.34338117265211504), + FRAC_CONST(0.34482147690175929), + FRAC_CONST(0.34626096975316001), + FRAC_CONST(0.34769964781905138), + FRAC_CONST(0.34913750771408497), + FRAC_CONST(0.35057454605483751), + FRAC_CONST(0.35201075945981908), + FRAC_CONST(0.35344614454948081), + FRAC_CONST(0.35488069794622279), + FRAC_CONST(0.35631441627440241), + FRAC_CONST(0.3577472961603419), + FRAC_CONST(0.3591793342323365), + FRAC_CONST(0.36061052712066227), + FRAC_CONST(0.36204087145758418), + FRAC_CONST(0.36347036387736376), + FRAC_CONST(0.36489900101626732), + FRAC_CONST(0.36632677951257359), + FRAC_CONST(0.36775369600658198), + FRAC_CONST(0.36917974714062002), + FRAC_CONST(0.37060492955905167), + FRAC_CONST(0.37202923990828501), + FRAC_CONST(0.3734526748367803), + FRAC_CONST(0.37487523099505754), + FRAC_CONST(0.37629690503570479), + FRAC_CONST(0.37771769361338564), + FRAC_CONST(0.37913759338484732), + FRAC_CONST(0.38055660100892852), + FRAC_CONST(0.38197471314656722), + FRAC_CONST(0.38339192646080866), + FRAC_CONST(0.38480823761681288), + FRAC_CONST(0.38622364328186298), + FRAC_CONST(0.38763814012537273), + FRAC_CONST(0.38905172481889438), + FRAC_CONST(0.39046439403612659), + FRAC_CONST(0.39187614445292235), + FRAC_CONST(0.3932869727472964), + FRAC_CONST(0.39469687559943356), + FRAC_CONST(0.39610584969169627), + FRAC_CONST(0.39751389170863233), + FRAC_CONST(0.39892099833698291), + FRAC_CONST(0.40032716626569009), + FRAC_CONST(0.40173239218590501), + FRAC_CONST(0.4031366727909953), + FRAC_CONST(0.404540004776553), + FRAC_CONST(0.40594238484040251), + FRAC_CONST(0.40734380968260797), + FRAC_CONST(0.40874427600548136), + FRAC_CONST(0.41014378051359024), + FRAC_CONST(0.41154231991376522), + FRAC_CONST(0.41293989091510808), + FRAC_CONST(0.4143364902289991), + FRAC_CONST(0.41573211456910536), + FRAC_CONST(0.41712676065138787), + FRAC_CONST(0.4185204251941097), + FRAC_CONST(0.41991310491784362), + FRAC_CONST(0.42130479654547964), + FRAC_CONST(0.42269549680223295), + FRAC_CONST(0.42408520241565156), + FRAC_CONST(0.4254739101156238), + FRAC_CONST(0.42686161663438643), + FRAC_CONST(0.42824831870653196), + FRAC_CONST(0.42963401306901638), + FRAC_CONST(0.43101869646116703), + FRAC_CONST(0.43240236562469014), + FRAC_CONST(0.43378501730367852), + FRAC_CONST(0.43516664824461926), + FRAC_CONST(0.4365472551964012), + FRAC_CONST(0.43792683491032286), + FRAC_CONST(0.43930538414009995), + FRAC_CONST(0.4406828996418729), + FRAC_CONST(0.4420593781742147), + FRAC_CONST(0.44343481649813848), + FRAC_CONST(0.44480921137710488), + FRAC_CONST(0.44618255957703007), + FRAC_CONST(0.44755485786629301), + FRAC_CONST(0.44892610301574326), + FRAC_CONST(0.45029629179870861), + FRAC_CONST(0.45166542099100249), + FRAC_CONST(0.45303348737093158), + FRAC_CONST(0.45440048771930358), + FRAC_CONST(0.45576641881943464), + FRAC_CONST(0.45713127745715698), + FRAC_CONST(0.45849506042082627), + FRAC_CONST(0.45985776450132954), + FRAC_CONST(0.46121938649209238), + FRAC_CONST(0.46257992318908681), + FRAC_CONST(0.46393937139083852), + FRAC_CONST(0.4652977278984346), + FRAC_CONST(0.46665498951553092), + FRAC_CONST(0.46801115304835983), + FRAC_CONST(0.46936621530573752), + FRAC_CONST(0.4707201730990716), + FRAC_CONST(0.47207302324236866), + FRAC_CONST(0.47342476255224153), + FRAC_CONST(0.47477538784791712), + FRAC_CONST(0.47612489595124358), + FRAC_CONST(0.47747328368669806), + FRAC_CONST(0.47882054788139389), + FRAC_CONST(0.48016668536508839), + FRAC_CONST(0.48151169297018986), + FRAC_CONST(0.48285556753176567), + FRAC_CONST(0.48419830588754903), + FRAC_CONST(0.48553990487794696), + FRAC_CONST(0.48688036134604734), + FRAC_CONST(0.48821967213762679), + FRAC_CONST(0.48955783410115744), + FRAC_CONST(0.49089484408781509), + FRAC_CONST(0.49223069895148602), + FRAC_CONST(0.49356539554877477), + FRAC_CONST(0.49489893073901126), + FRAC_CONST(0.49623130138425825), + FRAC_CONST(0.49756250434931915), + FRAC_CONST(0.49889253650174459), + FRAC_CONST(0.50022139471184068), + FRAC_CONST(0.50154907585267539), + FRAC_CONST(0.50287557680008699), + FRAC_CONST(0.50420089443269034), + FRAC_CONST(0.50552502563188539), + FRAC_CONST(0.50684796728186321), + FRAC_CONST(0.5081697162696146), + FRAC_CONST(0.50949026948493636), + FRAC_CONST(0.51080962382043904), + FRAC_CONST(0.51212777617155469), + FRAC_CONST(0.51344472343654346), + FRAC_CONST(0.5147604625165012), + FRAC_CONST(0.51607499031536663), + FRAC_CONST(0.51738830373992906), + FRAC_CONST(0.51870039969983495), + FRAC_CONST(0.52001127510759604), + FRAC_CONST(0.52132092687859566), + FRAC_CONST(0.52262935193109661), + FRAC_CONST(0.5239365471862486), + FRAC_CONST(0.52524250956809471), + FRAC_CONST(0.52654723600357944), + FRAC_CONST(0.52785072342255523), + FRAC_CONST(0.52915296875779061), + FRAC_CONST(0.53045396894497632), + FRAC_CONST(0.53175372092273332), + FRAC_CONST(0.53305222163261945), + FRAC_CONST(0.53434946801913752), + FRAC_CONST(0.53564545702974109), + FRAC_CONST(0.53694018561484291), + FRAC_CONST(0.5382336507278217), + FRAC_CONST(0.53952584932502889), + FRAC_CONST(0.54081677836579667), + FRAC_CONST(0.54210643481244392), + FRAC_CONST(0.5433948156302848), + FRAC_CONST(0.54468191778763453), + FRAC_CONST(0.54596773825581757), + FRAC_CONST(0.54725227400917409), + FRAC_CONST(0.54853552202506739), + FRAC_CONST(0.54981747928389091), + FRAC_CONST(0.55109814276907543), + FRAC_CONST(0.55237750946709607), + FRAC_CONST(0.55365557636747931), + FRAC_CONST(0.55493234046281037), + FRAC_CONST(0.55620779874873993), + FRAC_CONST(0.55748194822399155), + FRAC_CONST(0.55875478589036831), + FRAC_CONST(0.56002630875276038), + FRAC_CONST(0.56129651381915147), + FRAC_CONST(0.56256539810062656), + FRAC_CONST(0.56383295861137817), + FRAC_CONST(0.56509919236871398), + FRAC_CONST(0.56636409639306384), + FRAC_CONST(0.56762766770798623), + FRAC_CONST(0.56888990334017586), + FRAC_CONST(0.5701508003194703), + FRAC_CONST(0.57141035567885723), + FRAC_CONST(0.57266856645448116), + FRAC_CONST(0.57392542968565075), + FRAC_CONST(0.57518094241484508), + FRAC_CONST(0.57643510168772183), + FRAC_CONST(0.5776879045531228), + FRAC_CONST(0.57893934806308178), + FRAC_CONST(0.58018942927283168), + FRAC_CONST(0.58143814524081017), + FRAC_CONST(0.58268549302866846), + FRAC_CONST(0.58393146970127618), + FRAC_CONST(0.58517607232673041), + FRAC_CONST(0.5864192979763605), + FRAC_CONST(0.58766114372473666), + FRAC_CONST(0.58890160664967572), + FRAC_CONST(0.59014068383224882), + FRAC_CONST(0.59137837235678758), + FRAC_CONST(0.59261466931089113), + FRAC_CONST(0.59384957178543363), + FRAC_CONST(0.59508307687456996), + FRAC_CONST(0.59631518167574371), + FRAC_CONST(0.59754588328969316), + FRAC_CONST(0.59877517882045872), + FRAC_CONST(0.60000306537538894), + FRAC_CONST(0.6012295400651485), + FRAC_CONST(0.60245460000372375), + FRAC_CONST(0.60367824230843037), + FRAC_CONST(0.60490046409991982), + FRAC_CONST(0.60612126250218612), + FRAC_CONST(0.60734063464257293), + FRAC_CONST(0.60855857765177945), + FRAC_CONST(0.60977508866386843), + FRAC_CONST(0.61099016481627166), + FRAC_CONST(0.61220380324979795), + FRAC_CONST(0.61341600110863859), + FRAC_CONST(0.61462675554037505), + FRAC_CONST(0.61583606369598509), + FRAC_CONST(0.61704392272984976), + FRAC_CONST(0.61825032979976025), + FRAC_CONST(0.61945528206692402), + FRAC_CONST(0.62065877669597214), + FRAC_CONST(0.62186081085496536), + FRAC_CONST(0.62306138171540126), + FRAC_CONST(0.62426048645222065), + FRAC_CONST(0.62545812224381436), + FRAC_CONST(0.62665428627202935), + FRAC_CONST(0.62784897572217646), + FRAC_CONST(0.629042187783036), + FRAC_CONST(0.63023391964686437), + FRAC_CONST(0.63142416850940186), + FRAC_CONST(0.63261293156987741), + FRAC_CONST(0.63380020603101728), + FRAC_CONST(0.63498598909904946), + FRAC_CONST(0.63617027798371217), + FRAC_CONST(0.63735306989825913), + FRAC_CONST(0.63853436205946679), + FRAC_CONST(0.63971415168764045), + FRAC_CONST(0.64089243600662138), + FRAC_CONST(0.64206921224379254), + FRAC_CONST(0.64324447763008585), + FRAC_CONST(0.64441822939998838), + FRAC_CONST(0.64559046479154869), + FRAC_CONST(0.64676118104638392), + FRAC_CONST(0.64793037540968534), + FRAC_CONST(0.64909804513022595), + FRAC_CONST(0.65026418746036585), + FRAC_CONST(0.65142879965605982), + FRAC_CONST(0.65259187897686244), + FRAC_CONST(0.65375342268593606), + FRAC_CONST(0.65491342805005603), + FRAC_CONST(0.6560718923396176), + FRAC_CONST(0.65722881282864254), + FRAC_CONST(0.65838418679478505), + FRAC_CONST(0.65953801151933866), + FRAC_CONST(0.6606902842872423), + FRAC_CONST(0.66184100238708687), + FRAC_CONST(0.66299016311112147), + FRAC_CONST(0.66413776375526001), + FRAC_CONST(0.66528380161908718), + FRAC_CONST(0.66642827400586524), + FRAC_CONST(0.66757117822254031), + FRAC_CONST(0.66871251157974798), + FRAC_CONST(0.66985227139182102), + FRAC_CONST(0.67099045497679422), + FRAC_CONST(0.67212705965641173), + FRAC_CONST(0.67326208275613297), + FRAC_CONST(0.67439552160513905), + FRAC_CONST(0.67552737353633852), + FRAC_CONST(0.67665763588637495), + FRAC_CONST(0.6777863059956315), + FRAC_CONST(0.67891338120823841), + FRAC_CONST(0.68003885887207893), + FRAC_CONST(0.68116273633879543), + FRAC_CONST(0.68228501096379557), + FRAC_CONST(0.68340568010625868), + FRAC_CONST(0.6845247411291423), + FRAC_CONST(0.68564219139918747), + FRAC_CONST(0.68675802828692589), + FRAC_CONST(0.68787224916668555), + FRAC_CONST(0.68898485141659704), + FRAC_CONST(0.69009583241859995), + FRAC_CONST(0.69120518955844845), + FRAC_CONST(0.69231292022571822), + FRAC_CONST(0.69341902181381176), + FRAC_CONST(0.69452349171996552), + FRAC_CONST(0.69562632734525487), + FRAC_CONST(0.6967275260946012), + FRAC_CONST(0.69782708537677729), + FRAC_CONST(0.69892500260441415), + FRAC_CONST(0.70002127519400625), + FRAC_CONST(0.70111590056591866), + FRAC_CONST(0.70220887614439187), + FRAC_CONST(0.70330019935754873), + FRAC_CONST(0.70438986763740041), + FRAC_CONST(0.7054778784198521), + FRAC_CONST(0.70656422914470951), + FRAC_CONST(0.70764891725568435), + FRAC_CONST(0.70873194020040065), + FRAC_CONST(0.70981329543040084), + FRAC_CONST(0.71089298040115168), + FRAC_CONST(0.71197099257204999), + FRAC_CONST(0.71304732940642923), + FRAC_CONST(0.71412198837156471), + FRAC_CONST(0.71519496693868001), + FRAC_CONST(0.71626626258295312), + FRAC_CONST(0.71733587278352173), + FRAC_CONST(0.71840379502348972), + FRAC_CONST(0.71947002678993299), + FRAC_CONST(0.72053456557390527), + FRAC_CONST(0.72159740887044366), + FRAC_CONST(0.72265855417857561), + FRAC_CONST(0.72371799900132339), + FRAC_CONST(0.72477574084571128), + FRAC_CONST(0.72583177722277037), + FRAC_CONST(0.72688610564754497), + FRAC_CONST(0.72793872363909862), + FRAC_CONST(0.72898962872051931), + FRAC_CONST(0.73003881841892615), + FRAC_CONST(0.73108629026547423), + FRAC_CONST(0.73213204179536129), + FRAC_CONST(0.73317607054783274), + FRAC_CONST(0.73421837406618817), + FRAC_CONST(0.73525894989778673), + FRAC_CONST(0.73629779559405306), + FRAC_CONST(0.73733490871048279), + FRAC_CONST(0.73837028680664851), + FRAC_CONST(0.73940392744620576), + FRAC_CONST(0.74043582819689802), + FRAC_CONST(0.74146598663056329), + FRAC_CONST(0.74249440032313918), + FRAC_CONST(0.74352106685466912), + FRAC_CONST(0.74454598380930725), + FRAC_CONST(0.74556914877532543), + FRAC_CONST(0.74659055934511731), + FRAC_CONST(0.74761021311520515), + FRAC_CONST(0.74862810768624533), + FRAC_CONST(0.74964424066303348), + FRAC_CONST(0.75065860965451059), + FRAC_CONST(0.75167121227376843), + FRAC_CONST(0.75268204613805523), + FRAC_CONST(0.75369110886878121), + FRAC_CONST(0.75469839809152439), + FRAC_CONST(0.75570391143603588), + FRAC_CONST(0.75670764653624567), + FRAC_CONST(0.75770960103026808), + FRAC_CONST(0.75870977256040739), + FRAC_CONST(0.75970815877316344), + FRAC_CONST(0.76070475731923692), + FRAC_CONST(0.76169956585353527), + FRAC_CONST(0.76269258203517787), + FRAC_CONST(0.76368380352750187), + FRAC_CONST(0.76467322799806714), + FRAC_CONST(0.76566085311866239), + FRAC_CONST(0.76664667656531038), + FRAC_CONST(0.76763069601827327), + FRAC_CONST(0.76861290916205827), + FRAC_CONST(0.76959331368542294), + FRAC_CONST(0.7705719072813807), + FRAC_CONST(0.7715486876472063), + FRAC_CONST(0.77252365248444133), + FRAC_CONST(0.77349679949889905), + FRAC_CONST(0.77446812640067086), + FRAC_CONST(0.77543763090413043), + FRAC_CONST(0.77640531072794039), + FRAC_CONST(0.7773711635950562), + FRAC_CONST(0.77833518723273309), + FRAC_CONST(0.7792973793725303), + FRAC_CONST(0.78025773775031659), + FRAC_CONST(0.78121626010627609), + FRAC_CONST(0.7821729441849129), + FRAC_CONST(0.78312778773505731), + FRAC_CONST(0.78408078850986995), + FRAC_CONST(0.78503194426684808), + FRAC_CONST(0.78598125276783015), + FRAC_CONST(0.7869287117790017), + FRAC_CONST(0.78787431907090011), + FRAC_CONST(0.78881807241842017), + FRAC_CONST(0.78975996960081907), + FRAC_CONST(0.79070000840172161), + FRAC_CONST(0.79163818660912577), + FRAC_CONST(0.79257450201540758), + FRAC_CONST(0.79350895241732666), + FRAC_CONST(0.79444153561603059), + FRAC_CONST(0.79537224941706119), + FRAC_CONST(0.79630109163035911), + FRAC_CONST(0.7972280600702687), + FRAC_CONST(0.79815315255554375), + FRAC_CONST(0.79907636690935235), + FRAC_CONST(0.79999770095928191), + FRAC_CONST(0.8009171525373443), + FRAC_CONST(0.80183471947998131), + FRAC_CONST(0.80275039962806916), + FRAC_CONST(0.80366419082692409), + FRAC_CONST(0.804576090926307), + FRAC_CONST(0.80548609778042912), + FRAC_CONST(0.80639420924795624), + FRAC_CONST(0.80730042319201445), + FRAC_CONST(0.80820473748019472), + FRAC_CONST(0.80910714998455813), + FRAC_CONST(0.81000765858164114), + FRAC_CONST(0.81090626115245967), + FRAC_CONST(0.81180295558251536), + FRAC_CONST(0.81269773976179949), + FRAC_CONST(0.81359061158479851), + FRAC_CONST(0.81448156895049861), + FRAC_CONST(0.81537060976239129), + FRAC_CONST(0.81625773192847739), + FRAC_CONST(0.81714293336127297), + FRAC_CONST(0.81802621197781344), + FRAC_CONST(0.81890756569965895), + FRAC_CONST(0.81978699245289899), + FRAC_CONST(0.82066449016815746), + FRAC_CONST(0.82154005678059761), + FRAC_CONST(0.82241369022992639), + FRAC_CONST(0.82328538846040011), + FRAC_CONST(0.82415514942082857), + FRAC_CONST(0.82502297106458022), + FRAC_CONST(0.82588885134958678), + FRAC_CONST(0.82675278823834852), + FRAC_CONST(0.8276147796979384), + FRAC_CONST(0.82847482370000713), + FRAC_CONST(0.82933291822078825), + FRAC_CONST(0.83018906124110237), + FRAC_CONST(0.83104325074636232), + FRAC_CONST(0.83189548472657759), + FRAC_CONST(0.83274576117635946), + FRAC_CONST(0.83359407809492514), + FRAC_CONST(0.83444043348610319), + FRAC_CONST(0.83528482535833737), + FRAC_CONST(0.83612725172469216), + FRAC_CONST(0.83696771060285702), + FRAC_CONST(0.83780620001515094), + FRAC_CONST(0.8386427179885273), + FRAC_CONST(0.83947726255457855), + FRAC_CONST(0.84030983174954077), + FRAC_CONST(0.84114042361429808), + FRAC_CONST(0.84196903619438768), + FRAC_CONST(0.84279566754000412), + FRAC_CONST(0.84362031570600404), + FRAC_CONST(0.84444297875191066), + FRAC_CONST(0.84526365474191822), + FRAC_CONST(0.84608234174489694), + FRAC_CONST(0.84689903783439735), + FRAC_CONST(0.84771374108865427), + FRAC_CONST(0.84852644959059265), + FRAC_CONST(0.84933716142783067), + FRAC_CONST(0.85014587469268521), + FRAC_CONST(0.85095258748217573), + FRAC_CONST(0.85175729789802912), + FRAC_CONST(0.85256000404668397), + FRAC_CONST(0.85336070403929543), + FRAC_CONST(0.85415939599173873), + FRAC_CONST(0.85495607802461482), + FRAC_CONST(0.85575074826325392), + FRAC_CONST(0.85654340483771996), + FRAC_CONST(0.85733404588281559), + FRAC_CONST(0.85812266953808602), + FRAC_CONST(0.8589092739478239), + FRAC_CONST(0.85969385726107261), + FRAC_CONST(0.86047641763163207), + FRAC_CONST(0.86125695321806206), + FRAC_CONST(0.86203546218368721), + FRAC_CONST(0.86281194269660033), + FRAC_CONST(0.86358639292966799), + FRAC_CONST(0.86435881106053403), + FRAC_CONST(0.86512919527162369), + FRAC_CONST(0.86589754375014882), + FRAC_CONST(0.86666385468811102), + FRAC_CONST(0.86742812628230692), + FRAC_CONST(0.86819035673433131), + FRAC_CONST(0.86895054425058238), + FRAC_CONST(0.86970868704226556), + FRAC_CONST(0.87046478332539767), + FRAC_CONST(0.8712188313208109), + FRAC_CONST(0.8719708292541577), + FRAC_CONST(0.8727207753559143), + FRAC_CONST(0.87346866786138488), + FRAC_CONST(0.8742145050107063), + FRAC_CONST(0.87495828504885154), + FRAC_CONST(0.8757000062256346), + FRAC_CONST(0.87643966679571361), + FRAC_CONST(0.87717726501859594), + FRAC_CONST(0.87791279915864173), + FRAC_CONST(0.87864626748506813), + FRAC_CONST(0.87937766827195318), + FRAC_CONST(0.88010699979824036), + FRAC_CONST(0.88083426034774204), + FRAC_CONST(0.88155944820914378), + FRAC_CONST(0.8822825616760086), + FRAC_CONST(0.88300359904678072), + FRAC_CONST(0.88372255862478966), + FRAC_CONST(0.8844394387182537), + FRAC_CONST(0.88515423764028511), + FRAC_CONST(0.88586695370889279), + FRAC_CONST(0.88657758524698704), + FRAC_CONST(0.88728613058238315), + FRAC_CONST(0.88799258804780556), + FRAC_CONST(0.88869695598089171), + FRAC_CONST(0.88939923272419552), + FRAC_CONST(0.89009941662519221), + FRAC_CONST(0.89079750603628149), + FRAC_CONST(0.89149349931479138), + FRAC_CONST(0.89218739482298248), + FRAC_CONST(0.89287919092805168), + FRAC_CONST(0.89356888600213602), + FRAC_CONST(0.89425647842231604), + FRAC_CONST(0.89494196657062075), + FRAC_CONST(0.89562534883403), + FRAC_CONST(0.89630662360447966), + FRAC_CONST(0.89698578927886397), + FRAC_CONST(0.89766284425904075), + FRAC_CONST(0.89833778695183419), + FRAC_CONST(0.89901061576903907), + FRAC_CONST(0.89968132912742393), + FRAC_CONST(0.9003499254487356), + FRAC_CONST(0.90101640315970233), + FRAC_CONST(0.90168076069203773), + FRAC_CONST(0.9023429964824442), + FRAC_CONST(0.90300310897261704), + FRAC_CONST(0.90366109660924798), + FRAC_CONST(0.90431695784402832), + FRAC_CONST(0.90497069113365325), + FRAC_CONST(0.90562229493982516), + FRAC_CONST(0.90627176772925766), + FRAC_CONST(0.90691910797367803), + FRAC_CONST(0.90756431414983252), + FRAC_CONST(0.9082073847394887), + FRAC_CONST(0.90884831822943912), + FRAC_CONST(0.90948711311150543), + FRAC_CONST(0.91012376788254157), + FRAC_CONST(0.91075828104443757), + FRAC_CONST(0.91139065110412232), + FRAC_CONST(0.91202087657356823), + FRAC_CONST(0.9126489559697939), + FRAC_CONST(0.91327488781486776), + FRAC_CONST(0.91389867063591168), + FRAC_CONST(0.91452030296510445), + FRAC_CONST(0.91513978333968526), + FRAC_CONST(0.91575711030195672), + FRAC_CONST(0.91637228239928914), + FRAC_CONST(0.91698529818412289), + FRAC_CONST(0.91759615621397295), + FRAC_CONST(0.9182048550514309), + FRAC_CONST(0.91881139326416994), + FRAC_CONST(0.91941576942494696), + FRAC_CONST(0.92001798211160657), + FRAC_CONST(0.92061802990708386), + FRAC_CONST(0.92121591139940873), + FRAC_CONST(0.92181162518170812), + FRAC_CONST(0.92240516985220988), + FRAC_CONST(0.92299654401424625), + FRAC_CONST(0.92358574627625656), + FRAC_CONST(0.9241727752517912), + FRAC_CONST(0.92475762955951391), + FRAC_CONST(0.9253403078232062), + FRAC_CONST(0.92592080867176996), + FRAC_CONST(0.92649913073923051), + FRAC_CONST(0.9270752726647401), + FRAC_CONST(0.92764923309258118), + FRAC_CONST(0.92822101067216944), + FRAC_CONST(0.92879060405805702), + FRAC_CONST(0.9293580119099355), + FRAC_CONST(0.92992323289263956), + FRAC_CONST(0.93048626567614978), + FRAC_CONST(0.93104710893559517), + FRAC_CONST(0.93160576135125783), + FRAC_CONST(0.93216222160857432), + FRAC_CONST(0.93271648839814025), + FRAC_CONST(0.93326856041571205), + FRAC_CONST(0.93381843636221096), + FRAC_CONST(0.9343661149437259), + FRAC_CONST(0.93491159487151609), + FRAC_CONST(0.93545487486201462), + FRAC_CONST(0.9359959536368313), + FRAC_CONST(0.9365348299227555), + FRAC_CONST(0.93707150245175919), + FRAC_CONST(0.93760596996099999), + FRAC_CONST(0.93813823119282436), + FRAC_CONST(0.93866828489477017), + FRAC_CONST(0.9391961298195699), + FRAC_CONST(0.93972176472515334), + FRAC_CONST(0.94024518837465088), + FRAC_CONST(0.94076639953639607), + FRAC_CONST(0.94128539698392866), + FRAC_CONST(0.94180217949599765), + FRAC_CONST(0.94231674585656378), + FRAC_CONST(0.94282909485480271), + FRAC_CONST(0.94333922528510772), + FRAC_CONST(0.94384713594709269), + FRAC_CONST(0.94435282564559475), + FRAC_CONST(0.94485629319067721), + FRAC_CONST(0.94535753739763229), + FRAC_CONST(0.94585655708698391), + FRAC_CONST(0.94635335108449059), + FRAC_CONST(0.946847918221148), + FRAC_CONST(0.94734025733319194), + FRAC_CONST(0.94783036726210101), + FRAC_CONST(0.94831824685459909), + FRAC_CONST(0.94880389496265838), + FRAC_CONST(0.94928731044350201), + FRAC_CONST(0.94976849215960668), + FRAC_CONST(0.95024743897870523), + FRAC_CONST(0.95072414977378961), + FRAC_CONST(0.95119862342311323), + FRAC_CONST(0.95167085881019386), + FRAC_CONST(0.95214085482381583), + FRAC_CONST(0.95260861035803324), + FRAC_CONST(0.9530741243121722), + FRAC_CONST(0.95353739559083328), + FRAC_CONST(0.95399842310389449), + FRAC_CONST(0.95445720576651349), + FRAC_CONST(0.95491374249913052), + FRAC_CONST(0.95536803222747024), + FRAC_CONST(0.95582007388254542), + FRAC_CONST(0.95626986640065814), + FRAC_CONST(0.95671740872340305), + FRAC_CONST(0.9571626997976701), + FRAC_CONST(0.95760573857564624), + FRAC_CONST(0.9580465240148186), + FRAC_CONST(0.9584850550779761), + FRAC_CONST(0.95892133073321306), + FRAC_CONST(0.95935534995393079), + FRAC_CONST(0.9597871117188399), + FRAC_CONST(0.96021661501196343), + FRAC_CONST(0.96064385882263847), + FRAC_CONST(0.96106884214551935), + FRAC_CONST(0.961491563980579), + FRAC_CONST(0.9619120233331121), + FRAC_CONST(0.9623302192137374), + FRAC_CONST(0.96274615063839941), + FRAC_CONST(0.96315981662837136), + FRAC_CONST(0.96357121621025721), + FRAC_CONST(0.96398034841599411), + FRAC_CONST(0.96438721228285429), + FRAC_CONST(0.9647918068534479), + FRAC_CONST(0.96519413117572472), + FRAC_CONST(0.96559418430297683), + FRAC_CONST(0.96599196529384057), + FRAC_CONST(0.96638747321229879), + FRAC_CONST(0.96678070712768327), + FRAC_CONST(0.96717166611467664), + FRAC_CONST(0.96756034925331436), + FRAC_CONST(0.9679467556289878), + FRAC_CONST(0.9683308843324453), + FRAC_CONST(0.96871273445979478), + FRAC_CONST(0.9690923051125061), + FRAC_CONST(0.96946959539741295), + FRAC_CONST(0.96984460442671483), + FRAC_CONST(0.97021733131797916), + FRAC_CONST(0.97058777519414363), + FRAC_CONST(0.97095593518351797), + FRAC_CONST(0.97132181041978616), + FRAC_CONST(0.97168540004200854), + FRAC_CONST(0.9720467031946235), + FRAC_CONST(0.97240571902744977), + FRAC_CONST(0.97276244669568857), + FRAC_CONST(0.97311688535992513), + FRAC_CONST(0.97346903418613095), + FRAC_CONST(0.9738188923456661), + FRAC_CONST(0.97416645901528032), + FRAC_CONST(0.97451173337711572), + FRAC_CONST(0.97485471461870843), + FRAC_CONST(0.97519540193299037), + FRAC_CONST(0.97553379451829136), + FRAC_CONST(0.97586989157834103), + FRAC_CONST(0.97620369232227056), + FRAC_CONST(0.97653519596461447), + FRAC_CONST(0.97686440172531264), + FRAC_CONST(0.97719130882971228), + FRAC_CONST(0.97751591650856928), + FRAC_CONST(0.97783822399805043), + FRAC_CONST(0.97815823053973505), + FRAC_CONST(0.97847593538061683), + FRAC_CONST(0.97879133777310567), + FRAC_CONST(0.97910443697502925), + FRAC_CONST(0.97941523224963478), + FRAC_CONST(0.97972372286559117), + FRAC_CONST(0.98002990809698998), + FRAC_CONST(0.98033378722334796), + FRAC_CONST(0.98063535952960812), + FRAC_CONST(0.98093462430614164), + FRAC_CONST(0.98123158084874973), + FRAC_CONST(0.98152622845866466), + FRAC_CONST(0.9818185664425525), + FRAC_CONST(0.98210859411251361), + FRAC_CONST(0.98239631078608469), + FRAC_CONST(0.98268171578624086), + FRAC_CONST(0.98296480844139644), + FRAC_CONST(0.98324558808540707), + FRAC_CONST(0.98352405405757126), + FRAC_CONST(0.98380020570263149), + FRAC_CONST(0.98407404237077645), + FRAC_CONST(0.9843455634176419), + FRAC_CONST(0.9846147682043126), + FRAC_CONST(0.9848816560973237), + FRAC_CONST(0.98514622646866223), + FRAC_CONST(0.98540847869576842), + FRAC_CONST(0.98566841216153755), + FRAC_CONST(0.98592602625432113), + FRAC_CONST(0.98618132036792827), + FRAC_CONST(0.98643429390162707), + FRAC_CONST(0.98668494626014669), + FRAC_CONST(0.98693327685367771), + FRAC_CONST(0.98717928509787434), + FRAC_CONST(0.98742297041385541), + FRAC_CONST(0.98766433222820571), + FRAC_CONST(0.98790336997297779), + FRAC_CONST(0.98814008308569257), + FRAC_CONST(0.98837447100934128), + FRAC_CONST(0.98860653319238645), + FRAC_CONST(0.98883626908876354), + FRAC_CONST(0.98906367815788154), + FRAC_CONST(0.98928875986462517), + FRAC_CONST(0.98951151367935519), + FRAC_CONST(0.98973193907791057), + FRAC_CONST(0.98995003554160899), + FRAC_CONST(0.9901658025572484), + FRAC_CONST(0.99037923961710816), + FRAC_CONST(0.99059034621895015), + FRAC_CONST(0.99079912186602037), + FRAC_CONST(0.99100556606704937), + FRAC_CONST(0.99120967833625406), + FRAC_CONST(0.99141145819333854), + FRAC_CONST(0.99161090516349537), + FRAC_CONST(0.99180801877740643), + FRAC_CONST(0.99200279857124452), + FRAC_CONST(0.99219524408667392), + FRAC_CONST(0.99238535487085167), + FRAC_CONST(0.99257313047642881), + FRAC_CONST(0.99275857046155114), + FRAC_CONST(0.99294167438986047), + FRAC_CONST(0.99312244183049558), + FRAC_CONST(0.99330087235809328), + FRAC_CONST(0.99347696555278919), + FRAC_CONST(0.99365072100021912), + FRAC_CONST(0.99382213829151966), + FRAC_CONST(0.99399121702332938), + FRAC_CONST(0.99415795679778973), + FRAC_CONST(0.99432235722254581), + FRAC_CONST(0.9944844179107476), + FRAC_CONST(0.99464413848105071), + FRAC_CONST(0.99480151855761711), + FRAC_CONST(0.99495655777011638), + FRAC_CONST(0.99510925575372611), + FRAC_CONST(0.99525961214913339), + FRAC_CONST(0.9954076266025349), + FRAC_CONST(0.99555329876563847), + FRAC_CONST(0.99569662829566352), + FRAC_CONST(0.99583761485534161), + FRAC_CONST(0.99597625811291779), + FRAC_CONST(0.99611255774215113), + FRAC_CONST(0.99624651342231552), + FRAC_CONST(0.99637812483820021), + FRAC_CONST(0.99650739168011082), + FRAC_CONST(0.9966343136438699), + FRAC_CONST(0.996758890430818), + FRAC_CONST(0.99688112174781385), + FRAC_CONST(0.99700100730723529), + FRAC_CONST(0.99711854682697998), + FRAC_CONST(0.99723374003046616), + FRAC_CONST(0.99734658664663323), + FRAC_CONST(0.99745708640994191), + FRAC_CONST(0.99756523906037575), + FRAC_CONST(0.997671044343441), + FRAC_CONST(0.99777450201016782), + FRAC_CONST(0.99787561181711015), + FRAC_CONST(0.99797437352634699), + FRAC_CONST(0.99807078690548234), + FRAC_CONST(0.99816485172764624), + FRAC_CONST(0.99825656777149518), + FRAC_CONST(0.99834593482121237), + FRAC_CONST(0.99843295266650844), + FRAC_CONST(0.99851762110262221), + FRAC_CONST(0.99859993993032037), + FRAC_CONST(0.99867990895589909), + FRAC_CONST(0.99875752799118334), + FRAC_CONST(0.99883279685352799), + FRAC_CONST(0.99890571536581829), + FRAC_CONST(0.99897628335646982), + FRAC_CONST(0.99904450065942929), + FRAC_CONST(0.99911036711417489), + FRAC_CONST(0.99917388256571638), + FRAC_CONST(0.99923504686459585), + FRAC_CONST(0.99929385986688779), + FRAC_CONST(0.99935032143419944), + FRAC_CONST(0.9994044314336713), + FRAC_CONST(0.99945618973797734), + FRAC_CONST(0.99950559622532531), + FRAC_CONST(0.99955265077945699), + FRAC_CONST(0.99959735328964838), + FRAC_CONST(0.9996397036507102), + FRAC_CONST(0.99967970176298793), + FRAC_CONST(0.99971734753236219), + FRAC_CONST(0.99975264087024884), + FRAC_CONST(0.99978558169359921), + FRAC_CONST(0.99981616992490041), + FRAC_CONST(0.99984440549217524), + FRAC_CONST(0.99987028832898295), + FRAC_CONST(0.99989381837441849), + FRAC_CONST(0.99991499557311347), + FRAC_CONST(0.999933819875236), + FRAC_CONST(0.99995029123649048), + FRAC_CONST(0.99996440961811828), + FRAC_CONST(0.99997617498689761), + FRAC_CONST(0.9999855873151432), + FRAC_CONST(0.99999264658070719), + FRAC_CONST(0.99999735276697821), + FRAC_CONST(0.99999970586288223) }; -real_t sine_mid_480[] = +#ifdef ALLOW_SMALL_FRAMELENGTH +ALIGN static const real_t sine_long_960[] = { - 0.0016362455, - 0.0049087189, - 0.0081811398, - 0.0114534731, - 0.0147256837, - 0.0179977366, - 0.0212695968, - 0.0245412292, - 0.0278125988, - 0.0310836705, - 0.0343544094, - 0.0376247803, - 0.0408947483, - 0.0441642784, - 0.0474333354, - 0.0507018846, - 0.0539698907, - 0.0572373189, - 0.0605041341, - 0.0637703013, - 0.0670357857, - 0.0703005521, - 0.0735645656, - 0.0768277914, - 0.0800901944, - 0.0833517396, - 0.0866123923, - 0.0898721174, - 0.0931308800, - 0.0963886453, - 0.0996453784, - 0.1029010443, - 0.1061556082, - 0.1094090353, - 0.1126612907, - 0.1159123396, - 0.1191621472, - 0.1224106786, - 0.1256578991, - 0.1289037739, - 0.1321482683, - 0.1353913474, - 0.1386329767, - 0.1418731213, - 0.1451117465, - 0.1483488177, - 0.1515843002, - 0.1548181594, - 0.1580503605, - 0.1612808691, - 0.1645096505, - 0.1677366702, - 0.1709618935, - 0.1741852859, - 0.1774068130, - 0.1806264402, - 0.1838441330, - 0.1870598570, - 0.1902735777, - 0.1934852607, - 0.1966948717, - 0.1999023762, - 0.2031077400, - 0.2063109286, - 0.2095119078, - 0.2127106433, - 0.2159071008, - 0.2191012462, - 0.2222930451, - 0.2254824635, - 0.2286694671, - 0.2318540218, - 0.2350360936, - 0.2382156484, - 0.2413926520, - 0.2445670705, - 0.2477388699, - 0.2509080162, - 0.2540744755, - 0.2572382139, - 0.2603991974, - 0.2635573923, - 0.2667127647, - 0.2698652808, - 0.2730149069, - 0.2761616092, - 0.2793053540, - 0.2824461077, - 0.2855838367, - 0.2887185072, - 0.2918500858, - 0.2949785389, - 0.2981038331, - 0.3012259348, - 0.3043448106, - 0.3074604271, - 0.3105727510, - 0.3136817488, - 0.3167873874, - 0.3198896335, - 0.3229884538, - 0.3260838151, - 0.3291756844, - 0.3322640284, - 0.3353488142, - 0.3384300086, - 0.3415075788, - 0.3445814916, - 0.3476517143, - 0.3507182139, - 0.3537809576, - 0.3568399126, - 0.3598950461, - 0.3629463254, - 0.3659937179, - 0.3690371908, - 0.3720767117, - 0.3751122479, - 0.3781437670, - 0.3811712365, - 0.3841946239, - 0.3872138969, - 0.3902290232, - 0.3932399704, - 0.3962467063, - 0.3992491987, - 0.4022474156, - 0.4052413246, - 0.4082308939, - 0.4112160913, - 0.4141968849, - 0.4171732429, - 0.4201451332, - 0.4231125241, - 0.4260753838, - 0.4290336806, - 0.4319873828, - 0.4349364587, - 0.4378808768, - 0.4408206056, - 0.4437556136, - 0.4466858692, - 0.4496113412, - 0.4525319983, - 0.4554478091, - 0.4583587424, - 0.4612647671, - 0.4641658519, - 0.4670619660, - 0.4699530782, - 0.4728391575, - 0.4757201731, - 0.4785960942, - 0.4814668899, - 0.4843325294, - 0.4871929822, - 0.4900482174, - 0.4928982047, - 0.4957429134, - 0.4985823131, - 0.5014163734, - 0.5042450640, - 0.5070683544, - 0.5098862146, - 0.5126986143, - 0.5155055234, - 0.5183069119, - 0.5211027497, - 0.5238930069, - 0.5266776537, - 0.5294566601, - 0.5322299965, - 0.5349976332, - 0.5377595404, - 0.5405156887, - 0.5432660485, - 0.5460105903, - 0.5487492848, - 0.5514821026, - 0.5542090145, - 0.5569299913, - 0.5596450038, - 0.5623540230, - 0.5650570198, - 0.5677539653, - 0.5704448306, - 0.5731295868, - 0.5758082054, - 0.5784806575, - 0.5811469145, - 0.5838069479, - 0.5864607292, - 0.5891082300, - 0.5917494219, - 0.5943842766, - 0.5970127660, - 0.5996348618, - 0.6022505361, - 0.6048597607, - 0.6074625077, - 0.6100587493, - 0.6126484577, - 0.6152316051, - 0.6178081639, - 0.6203781064, - 0.6229414052, - 0.6254980328, - 0.6280479618, - 0.6305911649, - 0.6331276149, - 0.6356572846, - 0.6381801469, - 0.6406961748, - 0.6432053414, - 0.6457076197, - 0.6482029831, - 0.6506914047, - 0.6531728580, - 0.6556473162, - 0.6581147531, - 0.6605751420, - 0.6630284567, - 0.6654746709, - 0.6679137584, - 0.6703456931, - 0.6727704490, - 0.6751880000, - 0.6775983202, - 0.6800013840, - 0.6823971654, - 0.6847856390, - 0.6871667790, - 0.6895405601, - 0.6919069567, - 0.6942659435, - 0.6966174953, - 0.6989615869, - 0.7012981932, - 0.7036272892, - 0.7059488498, - 0.7082628503, - 0.7105692659, - 0.7128680719, - 0.7151592436, - 0.7174427565, - 0.7197185862, - 0.7219867083, - 0.7242470985, - 0.7264997326, - 0.7287445864, - 0.7309816360, - 0.7332108574, - 0.7354322266, - 0.7376457200, - 0.7398513138, - 0.7420489844, - 0.7442387082, - 0.7464204618, - 0.7485942218, - 0.7507599651, - 0.7529176682, - 0.7550673083, - 0.7572088621, - 0.7593423069, - 0.7614676197, - 0.7635847778, - 0.7656937585, - 0.7677945393, - 0.7698870976, - 0.7719714111, - 0.7740474573, - 0.7761152141, - 0.7781746593, - 0.7802257710, - 0.7822685270, - 0.7843029055, - 0.7863288848, - 0.7883464432, - 0.7903555590, - 0.7923562107, - 0.7943483769, - 0.7963320363, - 0.7983071676, - 0.8002737497, - 0.8022317615, - 0.8041811820, - 0.8061219904, - 0.8080541659, - 0.8099776877, - 0.8118925354, - 0.8137986883, - 0.8156961261, - 0.8175848285, - 0.8194647752, - 0.8213359460, - 0.8231983211, - 0.8250518803, - 0.8268966039, - 0.8287324721, - 0.8305594652, - 0.8323775637, - 0.8341867481, - 0.8359869990, - 0.8377782972, - 0.8395606235, - 0.8413339587, - 0.8430982839, - 0.8448535802, - 0.8465998288, - 0.8483370110, - 0.8500651082, - 0.8517841019, - 0.8534939737, - 0.8551947052, - 0.8568862783, - 0.8585686748, - 0.8602418767, - 0.8619058662, - 0.8635606253, - 0.8652061363, - 0.8668423818, - 0.8684693440, - 0.8700870056, - 0.8716953493, - 0.8732943578, - 0.8748840140, - 0.8764643010, - 0.8780352017, - 0.8795966993, - 0.8811487772, - 0.8826914187, - 0.8842246072, - 0.8857483265, - 0.8872625600, - 0.8887672917, - 0.8902625055, - 0.8917481852, - 0.8932243150, - 0.8946908791, - 0.8961478618, - 0.8975952475, - 0.8990330206, - 0.9004611658, - 0.9018796678, - 0.9032885114, - 0.9046876815, - 0.9060771631, - 0.9074569413, - 0.9088270015, - 0.9101873288, - 0.9115379087, - 0.9128787268, - 0.9142097687, - 0.9155310202, - 0.9168424670, - 0.9181440952, - 0.9194358908, - 0.9207178400, - 0.9219899290, - 0.9232521443, - 0.9245044723, - 0.9257468996, - 0.9269794128, - 0.9282019989, - 0.9294146447, - 0.9306173372, - 0.9318100635, - 0.9329928109, - 0.9341655667, - 0.9353283183, - 0.9364810533, - 0.9376237593, - 0.9387564242, - 0.9398790357, - 0.9409915818, - 0.9420940507, - 0.9431864306, - 0.9442687096, - 0.9453408763, - 0.9464029192, - 0.9474548268, - 0.9484965880, - 0.9495281915, - 0.9505496264, - 0.9515608816, - 0.9525619463, - 0.9535528099, - 0.9545334617, - 0.9555038913, - 0.9564640881, - 0.9574140420, - 0.9583537427, - 0.9592831803, - 0.9602023446, - 0.9611112260, - 0.9620098147, - 0.9628981010, - 0.9637760755, - 0.9646437286, - 0.9655010512, - 0.9663480341, - 0.9671846682, - 0.9680109445, - 0.9688268541, - 0.9696323885, - 0.9704275388, - 0.9712122966, - 0.9719866535, - 0.9727506013, - 0.9735041316, - 0.9742472365, - 0.9749799080, - 0.9757021383, - 0.9764139195, - 0.9771152442, - 0.9778061047, - 0.9784864937, - 0.9791564039, - 0.9798158282, - 0.9804647593, - 0.9811031905, - 0.9817311149, - 0.9823485257, - 0.9829554164, - 0.9835517804, - 0.9841376113, - 0.9847129029, - 0.9852776490, - 0.9858318436, - 0.9863754808, - 0.9869085546, - 0.9874310595, - 0.9879429897, - 0.9884443399, - 0.9889351046, - 0.9894152786, - 0.9898848568, - 0.9903438341, - 0.9907922056, - 0.9912299666, - 0.9916571122, - 0.9920736380, - 0.9924795395, - 0.9928748124, - 0.9932594523, - 0.9936334552, - 0.9939968171, - 0.9943495342, - 0.9946916025, - 0.9950230184, - 0.9953437785, - 0.9956538793, - 0.9959533173, - 0.9962420896, - 0.9965201929, - 0.9967876242, - 0.9970443807, - 0.9972904597, - 0.9975258586, - 0.9977505747, - 0.9979646057, - 0.9981679493, - 0.9983606034, - 0.9985425657, - 0.9987138346, - 0.9988744079, - 0.9990242842, - 0.9991634617, - 0.9992919389, - 0.9994097146, - 0.9995167873, - 0.9996131561, - 0.9996988198, - 0.9997737775, - 0.9998380284, - 0.9998915719, - 0.9999344073, - 0.9999665343, - 0.9999879524, - 0.9999986614 -}; - -real_t ld_mid_512[] = -{ - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0061358848, - 0.0184067304, - 0.0306748040, - 0.0429382581, - 0.0551952459, - 0.0674439214, - 0.0796824402, - 0.0919089590, - 0.1041216368, - 0.1163186341, - 0.1284981143, - 0.1406582432, - 0.1527971895, - 0.1649131250, - 0.1770042253, - 0.1890686693, - 0.2011046404, - 0.2131103258, - 0.2250839175, - 0.2370236125, - 0.2489276125, - 0.2607941250, - 0.2726213628, - 0.2844075449, - 0.2961508962, - 0.3078496483, - 0.3195020394, - 0.3311063146, - 0.3426607265, - 0.3541635348, - 0.3656130075, - 0.3770074202, - 0.3883450569, - 0.3996242103, - 0.4108431818, - 0.4220002818, - 0.4330938301, - 0.4441221560, - 0.4550835988, - 0.4659765077, - 0.4767992422, - 0.4875501725, - 0.4982276796, - 0.5088301553, - 0.5193560032, - 0.5298036379, - 0.5401714861, - 0.5504579865, - 0.5606615899, - 0.5707807598, - 0.5808139721, - 0.5907597160, - 0.6006164937, - 0.6103828207, - 0.6200572264, - 0.6296382536, - 0.6391244597, - 0.6485144160, - 0.6578067083, - 0.6669999374, - 0.6760927188, - 0.6850836831, - 0.6939714763, - 0.7027547599, - 0.7114322112, - 0.7200025235, - 0.7284644060, - 0.7368165845, - 0.7450578010, - 0.7531868147, - 0.7612024011, - 0.7691033533, - 0.7768884813, - 0.7845566127, - 0.7921065928, - 0.7995372846, - 0.8068475690, - 0.8140363451, - 0.8211025303, - 0.8280450605, - 0.8348628901, - 0.8415549925, - 0.8481203597, - 0.8545580032, - 0.8608669533, - 0.8670462601, - 0.8730949928, - 0.8790122407, - 0.8847971125, - 0.8904487372, - 0.8959662635, - 0.9013488606, - 0.9065957178, - 0.9117060451, - 0.9166790728, - 0.9215140520, - 0.9262102546, - 0.9307669733, - 0.9351835219, - 0.9394592352, - 0.9435934695, - 0.9475856021, - 0.9514350317, - 0.9551411788, - 0.9587034850, - 0.9621214141, - 0.9653944512, - 0.9685221034, - 0.9715038998, - 0.9743393912, - 0.9770281507, - 0.9795697733, - 0.9819638764, - 0.9842100992, - 0.9863081037, - 0.9882575738, - 0.9900582159, - 0.9917097588, - 0.9932119539, - 0.9945645750, - 0.9957674182, - 0.9968203026, - 0.9977230695, - 0.9984755829, - 0.9990777296, - 0.9995294188, - 0.9998305826, - 0.9999811755, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000 -}; - -real_t ld_mid_480[] = -{ - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0000000000, - 0.0065449381, - 0.0196336930, - 0.0327190837, - 0.0457988682, - 0.0588708053, - 0.0719326552, - 0.0849821797, - 0.0980171430, - 0.1110353116, - 0.1240344549, - 0.1370123455, - 0.1499667597, - 0.1628954779, - 0.1757962848, - 0.1886669699, - 0.2015053279, - 0.2143091589, - 0.2270762692, - 0.2398044712, - 0.2524915839, - 0.2651354334, - 0.2777338534, - 0.2902846851, - 0.3027857780, - 0.3152349901, - 0.3276301883, - 0.3399692488, - 0.3522500573, - 0.3644705095, - 0.3766285116, - 0.3887219804, - 0.4007488436, - 0.4127070406, - 0.4245945223, - 0.4364092520, - 0.4481492051, - 0.4598123703, - 0.4713967489, - 0.4829003561, - 0.4943212208, - 0.5056573861, - 0.5169069096, - 0.5280678638, - 0.5391383363, - 0.5501164301, - 0.5610002644, - 0.5717879741, - 0.5824777109, - 0.5930676432, - 0.6035559563, - 0.6139408533, - 0.6242205546, - 0.6343932989, - 0.6444573433, - 0.6544109631, - 0.6642524530, - 0.6739801267, - 0.6835923173, - 0.6930873779, - 0.7024636815, - 0.7117196216, - 0.7208536122, - 0.7298640883, - 0.7387495058, - 0.7475083425, - 0.7561390974, - 0.7646402918, - 0.7730104690, - 0.7812481948, - 0.7893520577, - 0.7973206693, - 0.8051526640, - 0.8128467000, - 0.8204014588, - 0.8278156461, - 0.8350879914, - 0.8422172487, - 0.8492021964, - 0.8560416377, - 0.8627344006, - 0.8692793384, - 0.8756753297, - 0.8819212785, - 0.8880161146, - 0.8939587938, - 0.8997482976, - 0.9053836343, - 0.9108638381, - 0.9161879700, - 0.9213551179, - 0.9263643963, - 0.9312149469, - 0.9359059386, - 0.9404365677, - 0.9448060577, - 0.9490136602, - 0.9530586539, - 0.9569403460, - 0.9606580713, - 0.9642111928, - 0.9675991016, - 0.9708212173, - 0.9738769878, - 0.9767658894, - 0.9794874272, - 0.9820411349, - 0.9844265749, - 0.9866433385, - 0.9886910458, - 0.9905693459, - 0.9922779171, - 0.9938164666, - 0.9951847307, - 0.9963824750, - 0.9974094943, - 0.9982656127, - 0.9989506833, - 0.9994645889, - 0.9998072413, - 0.9999785819, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000, - 1.0000000000 + FRAC_CONST(0.00081812299560725323), + FRAC_CONST(0.0024543667964602917), + FRAC_CONST(0.0040906040262347889), + FRAC_CONST(0.0057268303042312674), + FRAC_CONST(0.0073630412497795667), + FRAC_CONST(0.0089992324822505774), + FRAC_CONST(0.010635399621067975), + FRAC_CONST(0.012271538285719924), + FRAC_CONST(0.013907644095770845), + FRAC_CONST(0.015543712670873098), + FRAC_CONST(0.017179739630778748), + FRAC_CONST(0.018815720595351273), + FRAC_CONST(0.020451651184577292), + FRAC_CONST(0.022087527018578291), + FRAC_CONST(0.023723343717622358), + FRAC_CONST(0.025359096902135895), + FRAC_CONST(0.02699478219271537), + FRAC_CONST(0.028630395210139003), + FRAC_CONST(0.030265931575378519), + FRAC_CONST(0.031901386909610863), + FRAC_CONST(0.033536756834229922), + FRAC_CONST(0.035172036970858266), + FRAC_CONST(0.036807222941358832), + FRAC_CONST(0.038442310367846677), + FRAC_CONST(0.040077294872700696), + FRAC_CONST(0.041712172078575326), + FRAC_CONST(0.043346937608412288), + FRAC_CONST(0.044981587085452281), + FRAC_CONST(0.046616116133246711), + FRAC_CONST(0.048250520375669431), + FRAC_CONST(0.049884795436928406), + FRAC_CONST(0.051518936941577477), + FRAC_CONST(0.053152940514528055), + FRAC_CONST(0.05478680178106083), + FRAC_CONST(0.056420516366837495), + FRAC_CONST(0.05805407989791244), + FRAC_CONST(0.059687488000744485), + FRAC_CONST(0.061320736302208578), + FRAC_CONST(0.062953820429607482), + FRAC_CONST(0.064586736010683557), + FRAC_CONST(0.066219478673630344), + FRAC_CONST(0.06785204404710439), + FRAC_CONST(0.069484427760236861), + FRAC_CONST(0.071116625442645326), + FRAC_CONST(0.072748632724445372), + FRAC_CONST(0.07438044523626236), + FRAC_CONST(0.076012058609243122), + FRAC_CONST(0.077643468475067631), + FRAC_CONST(0.079274670465960706), + FRAC_CONST(0.080905660214703745), + FRAC_CONST(0.082536433354646319), + FRAC_CONST(0.084166985519717977), + FRAC_CONST(0.085797312344439894), + FRAC_CONST(0.08742740946393647), + FRAC_CONST(0.089057272513947183), + FRAC_CONST(0.090686897130838162), + FRAC_CONST(0.092316278951613845), + FRAC_CONST(0.093945413613928788), + FRAC_CONST(0.095574296756099186), + FRAC_CONST(0.097202924017114667), + FRAC_CONST(0.098831291036649963), + FRAC_CONST(0.10045939345507648), + FRAC_CONST(0.10208722691347409), + FRAC_CONST(0.10371478705364276), + FRAC_CONST(0.10534206951811415), + FRAC_CONST(0.10696906995016341), + FRAC_CONST(0.10859578399382072), + FRAC_CONST(0.11022220729388306), + FRAC_CONST(0.11184833549592579), + FRAC_CONST(0.11347416424631435), + FRAC_CONST(0.11509968919221586), + FRAC_CONST(0.11672490598161089), + FRAC_CONST(0.11834981026330495), + FRAC_CONST(0.11997439768694031), + FRAC_CONST(0.12159866390300751), + FRAC_CONST(0.12322260456285709), + FRAC_CONST(0.12484621531871121), + FRAC_CONST(0.12646949182367517), + FRAC_CONST(0.12809242973174936), + FRAC_CONST(0.12971502469784052), + FRAC_CONST(0.13133727237777362), + FRAC_CONST(0.13295916842830346), + FRAC_CONST(0.13458070850712617), + FRAC_CONST(0.13620188827289101), + FRAC_CONST(0.1378227033852118), + FRAC_CONST(0.13944314950467873), + FRAC_CONST(0.14106322229286994), + FRAC_CONST(0.14268291741236291), + FRAC_CONST(0.14430223052674654), + FRAC_CONST(0.1459211573006321), + FRAC_CONST(0.14753969339966552), + FRAC_CONST(0.14915783449053857), + FRAC_CONST(0.15077557624100058), + FRAC_CONST(0.15239291431987001), + FRAC_CONST(0.1540098443970461), + FRAC_CONST(0.15562636214352044), + FRAC_CONST(0.15724246323138855), + FRAC_CONST(0.15885814333386142), + FRAC_CONST(0.16047339812527725), + FRAC_CONST(0.16208822328111283), + FRAC_CONST(0.16370261447799525), + FRAC_CONST(0.16531656739371339), + FRAC_CONST(0.16693007770722967), + FRAC_CONST(0.16854314109869134), + FRAC_CONST(0.17015575324944232), + FRAC_CONST(0.17176790984203447), + FRAC_CONST(0.17337960656023954), + FRAC_CONST(0.1749908390890603), + FRAC_CONST(0.17660160311474243), + FRAC_CONST(0.17821189432478593), + FRAC_CONST(0.17982170840795647), + FRAC_CONST(0.18143104105429744), + FRAC_CONST(0.18303988795514095), + FRAC_CONST(0.1846482448031197), + FRAC_CONST(0.18625610729217834), + FRAC_CONST(0.1878634711175852), + FRAC_CONST(0.18947033197594348), + FRAC_CONST(0.19107668556520319), + FRAC_CONST(0.19268252758467228), + FRAC_CONST(0.19428785373502844), + FRAC_CONST(0.19589265971833042), + FRAC_CONST(0.19749694123802966), + FRAC_CONST(0.19910069399898173), + FRAC_CONST(0.20070391370745785), + FRAC_CONST(0.20230659607115639), + FRAC_CONST(0.20390873679921437), + FRAC_CONST(0.20551033160221882), + FRAC_CONST(0.20711137619221856), + FRAC_CONST(0.2087118662827353), + FRAC_CONST(0.21031179758877552), + FRAC_CONST(0.21191116582684155), + FRAC_CONST(0.21350996671494335), + FRAC_CONST(0.21510819597260972), + FRAC_CONST(0.21670584932089998), + FRAC_CONST(0.2183029224824154), + FRAC_CONST(0.21989941118131037), + FRAC_CONST(0.22149531114330431), + FRAC_CONST(0.22309061809569264), + FRAC_CONST(0.22468532776735861), + FRAC_CONST(0.22627943588878449), + FRAC_CONST(0.22787293819206314), + FRAC_CONST(0.22946583041090929), + FRAC_CONST(0.23105810828067114), + FRAC_CONST(0.23264976753834157), + FRAC_CONST(0.23424080392256985), + FRAC_CONST(0.2358312131736727), + FRAC_CONST(0.23742099103364595), + FRAC_CONST(0.23901013324617584), + FRAC_CONST(0.24059863555665045), + FRAC_CONST(0.24218649371217096), + FRAC_CONST(0.24377370346156332), + FRAC_CONST(0.24536026055538934), + FRAC_CONST(0.24694616074595824), + FRAC_CONST(0.24853139978733788), + FRAC_CONST(0.25011597343536629), + FRAC_CONST(0.25169987744766298), + FRAC_CONST(0.25328310758364025), + FRAC_CONST(0.25486565960451457), + FRAC_CONST(0.25644752927331788), + FRAC_CONST(0.25802871235490898), + FRAC_CONST(0.25960920461598508), + FRAC_CONST(0.26118900182509258), + FRAC_CONST(0.26276809975263904), + FRAC_CONST(0.264346494170904), + FRAC_CONST(0.26592418085405067), + FRAC_CONST(0.26750115557813692), + FRAC_CONST(0.2690774141211269), + FRAC_CONST(0.27065295226290209), + FRAC_CONST(0.2722277657852728), + FRAC_CONST(0.27380185047198918), + FRAC_CONST(0.27537520210875299), + FRAC_CONST(0.2769478164832283), + FRAC_CONST(0.27851968938505312), + FRAC_CONST(0.28009081660585067), + FRAC_CONST(0.28166119393924061), + FRAC_CONST(0.28323081718085019), + FRAC_CONST(0.28479968212832563), + FRAC_CONST(0.28636778458134327), + FRAC_CONST(0.28793512034162105), + FRAC_CONST(0.2895016852129294), + FRAC_CONST(0.29106747500110264), + FRAC_CONST(0.29263248551405047), + FRAC_CONST(0.2941967125617686), + FRAC_CONST(0.29576015195635058), + FRAC_CONST(0.29732279951199847), + FRAC_CONST(0.29888465104503475), + FRAC_CONST(0.30044570237391266), + FRAC_CONST(0.30200594931922808), + FRAC_CONST(0.30356538770373032), + FRAC_CONST(0.30512401335233358), + FRAC_CONST(0.30668182209212791), + FRAC_CONST(0.3082388097523906), + FRAC_CONST(0.30979497216459695), + FRAC_CONST(0.31135030516243201), + FRAC_CONST(0.3129048045818012), + FRAC_CONST(0.31445846626084178), + FRAC_CONST(0.31601128603993378), + FRAC_CONST(0.31756325976171151), + FRAC_CONST(0.31911438327107416), + FRAC_CONST(0.32066465241519732), + FRAC_CONST(0.32221406304354389), + FRAC_CONST(0.3237626110078754), + FRAC_CONST(0.32531029216226293), + FRAC_CONST(0.32685710236309828), + FRAC_CONST(0.32840303746910487), + FRAC_CONST(0.32994809334134939), + FRAC_CONST(0.3314922658432522), + FRAC_CONST(0.33303555084059877), + FRAC_CONST(0.33457794420155085), + FRAC_CONST(0.33611944179665709), + FRAC_CONST(0.33766003949886464), + FRAC_CONST(0.33919973318352969), + FRAC_CONST(0.34073851872842903), + FRAC_CONST(0.34227639201377064), + FRAC_CONST(0.34381334892220483), + FRAC_CONST(0.34534938533883547), + FRAC_CONST(0.34688449715123082), + FRAC_CONST(0.34841868024943456), + FRAC_CONST(0.34995193052597684), + FRAC_CONST(0.35148424387588523), + FRAC_CONST(0.3530156161966958), + FRAC_CONST(0.35454604338846402), + FRAC_CONST(0.35607552135377557), + FRAC_CONST(0.35760404599775775), + FRAC_CONST(0.35913161322809023), + FRAC_CONST(0.36065821895501554), + FRAC_CONST(0.36218385909135092), + FRAC_CONST(0.36370852955249849), + FRAC_CONST(0.36523222625645668), + FRAC_CONST(0.36675494512383078), + FRAC_CONST(0.36827668207784414), + FRAC_CONST(0.36979743304434909), + FRAC_CONST(0.37131719395183754), + FRAC_CONST(0.37283596073145214), + FRAC_CONST(0.37435372931699717), + FRAC_CONST(0.37587049564494951), + FRAC_CONST(0.37738625565446909), + FRAC_CONST(0.37890100528741022), + FRAC_CONST(0.38041474048833229), + FRAC_CONST(0.38192745720451066), + FRAC_CONST(0.38343915138594736), + FRAC_CONST(0.38494981898538222), + FRAC_CONST(0.38645945595830333), + FRAC_CONST(0.38796805826295838), + FRAC_CONST(0.38947562186036483), + FRAC_CONST(0.39098214271432141), + FRAC_CONST(0.39248761679141814), + FRAC_CONST(0.3939920400610481), + FRAC_CONST(0.39549540849541737), + FRAC_CONST(0.39699771806955625), + FRAC_CONST(0.39849896476132979), + FRAC_CONST(0.39999914455144892), + FRAC_CONST(0.40149825342348083), + FRAC_CONST(0.4029962873638599), + FRAC_CONST(0.40449324236189854), + FRAC_CONST(0.40598911440979762), + FRAC_CONST(0.40748389950265762), + FRAC_CONST(0.40897759363848879), + FRAC_CONST(0.41047019281822261), + FRAC_CONST(0.41196169304572178), + FRAC_CONST(0.4134520903277914), + FRAC_CONST(0.41494138067418929), + FRAC_CONST(0.41642956009763715), + FRAC_CONST(0.41791662461383078), + FRAC_CONST(0.41940257024145089), + FRAC_CONST(0.42088739300217382), + FRAC_CONST(0.42237108892068231), + FRAC_CONST(0.42385365402467584), + FRAC_CONST(0.42533508434488143), + FRAC_CONST(0.42681537591506419), + FRAC_CONST(0.42829452477203828), + FRAC_CONST(0.42977252695567697), + FRAC_CONST(0.43124937850892364), + FRAC_CONST(0.4327250754778022), + FRAC_CONST(0.43419961391142781), + FRAC_CONST(0.43567298986201736), + FRAC_CONST(0.43714519938489987), + FRAC_CONST(0.43861623853852766), + FRAC_CONST(0.44008610338448595), + FRAC_CONST(0.44155478998750436), + FRAC_CONST(0.44302229441546676), + FRAC_CONST(0.4444886127394222), + FRAC_CONST(0.44595374103359531), + FRAC_CONST(0.44741767537539667), + FRAC_CONST(0.44888041184543348), + FRAC_CONST(0.45034194652752002), + FRAC_CONST(0.45180227550868812), + FRAC_CONST(0.45326139487919759), + FRAC_CONST(0.45471930073254679), + FRAC_CONST(0.45617598916548296), + FRAC_CONST(0.45763145627801283), + FRAC_CONST(0.45908569817341294), + FRAC_CONST(0.46053871095824001), + FRAC_CONST(0.46199049074234161), + FRAC_CONST(0.46344103363886635), + FRAC_CONST(0.46489033576427435), + FRAC_CONST(0.46633839323834758), + FRAC_CONST(0.46778520218420055), + FRAC_CONST(0.46923075872829029), + FRAC_CONST(0.47067505900042683), + FRAC_CONST(0.47211809913378361), + FRAC_CONST(0.47355987526490806), + FRAC_CONST(0.47500038353373153), + FRAC_CONST(0.47643962008357982), + FRAC_CONST(0.47787758106118372), + FRAC_CONST(0.47931426261668875), + FRAC_CONST(0.48074966090366611), + FRAC_CONST(0.48218377207912272), + FRAC_CONST(0.48361659230351117), + FRAC_CONST(0.48504811774074069), + FRAC_CONST(0.48647834455818684), + FRAC_CONST(0.48790726892670194), + FRAC_CONST(0.48933488702062544), + FRAC_CONST(0.49076119501779414), + FRAC_CONST(0.49218618909955225), + FRAC_CONST(0.4936098654507618), + FRAC_CONST(0.49503222025981269), + FRAC_CONST(0.49645324971863303), + FRAC_CONST(0.49787295002269943), + FRAC_CONST(0.49929131737104687), + FRAC_CONST(0.50070834796627917), + FRAC_CONST(0.50212403801457872), + FRAC_CONST(0.50353838372571758), + FRAC_CONST(0.50495138131306638), + FRAC_CONST(0.50636302699360547), + FRAC_CONST(0.50777331698793449), + FRAC_CONST(0.50918224752028263), + FRAC_CONST(0.51058981481851906), + FRAC_CONST(0.51199601511416237), + FRAC_CONST(0.51340084464239111), + FRAC_CONST(0.51480429964205421), + FRAC_CONST(0.51620637635567967), + FRAC_CONST(0.51760707102948678), + FRAC_CONST(0.51900637991339404), + FRAC_CONST(0.5204042992610306), + FRAC_CONST(0.52180082532974559), + FRAC_CONST(0.5231959543806185), + FRAC_CONST(0.52458968267846895), + FRAC_CONST(0.52598200649186677), + FRAC_CONST(0.52737292209314235), + FRAC_CONST(0.52876242575839572), + FRAC_CONST(0.53015051376750777), + FRAC_CONST(0.53153718240414882), + FRAC_CONST(0.53292242795578992), + FRAC_CONST(0.53430624671371152), + FRAC_CONST(0.53568863497301467), + FRAC_CONST(0.5370695890326298), + FRAC_CONST(0.5384491051953274), + FRAC_CONST(0.53982717976772743), + FRAC_CONST(0.54120380906030963), + FRAC_CONST(0.54257898938742311), + FRAC_CONST(0.54395271706729609), + FRAC_CONST(0.54532498842204646), + FRAC_CONST(0.54669579977769045), + FRAC_CONST(0.54806514746415402), + FRAC_CONST(0.54943302781528081), + FRAC_CONST(0.55079943716884383), + FRAC_CONST(0.55216437186655387), + FRAC_CONST(0.55352782825406999), + FRAC_CONST(0.55488980268100907), + FRAC_CONST(0.55625029150095584), + FRAC_CONST(0.55760929107147217), + FRAC_CONST(0.55896679775410718), + FRAC_CONST(0.56032280791440714), + FRAC_CONST(0.56167731792192455), + FRAC_CONST(0.56303032415022869), + FRAC_CONST(0.56438182297691453), + FRAC_CONST(0.56573181078361312), + FRAC_CONST(0.56708028395600085), + FRAC_CONST(0.56842723888380908), + FRAC_CONST(0.56977267196083425), + FRAC_CONST(0.57111657958494688), + FRAC_CONST(0.5724589581581021), + FRAC_CONST(0.57379980408634845), + FRAC_CONST(0.57513911377983773), + FRAC_CONST(0.57647688365283478), + FRAC_CONST(0.57781311012372738), + FRAC_CONST(0.57914778961503466), + FRAC_CONST(0.58048091855341843), + FRAC_CONST(0.5818124933696911), + FRAC_CONST(0.58314251049882604), + FRAC_CONST(0.58447096637996743), + FRAC_CONST(0.58579785745643886), + FRAC_CONST(0.5871231801757536), + FRAC_CONST(0.58844693098962408), + FRAC_CONST(0.58976910635397084), + FRAC_CONST(0.59108970272893235), + FRAC_CONST(0.59240871657887517), + FRAC_CONST(0.59372614437240179), + FRAC_CONST(0.59504198258236196), + FRAC_CONST(0.5963562276858605), + FRAC_CONST(0.59766887616426767), + FRAC_CONST(0.5989799245032289), + FRAC_CONST(0.60028936919267273), + FRAC_CONST(0.60159720672682204), + FRAC_CONST(0.60290343360420195), + FRAC_CONST(0.60420804632765002), + FRAC_CONST(0.60551104140432543), + FRAC_CONST(0.60681241534571839), + FRAC_CONST(0.60811216466765883), + FRAC_CONST(0.60941028589032709), + FRAC_CONST(0.61070677553826169), + FRAC_CONST(0.61200163014036979), + FRAC_CONST(0.61329484622993602), + FRAC_CONST(0.6145864203446314), + FRAC_CONST(0.61587634902652377), + FRAC_CONST(0.61716462882208556), + FRAC_CONST(0.61845125628220421), + FRAC_CONST(0.61973622796219074), + FRAC_CONST(0.6210195404217892), + FRAC_CONST(0.62230119022518593), + FRAC_CONST(0.62358117394101897), + FRAC_CONST(0.62485948814238634), + FRAC_CONST(0.62613612940685637), + FRAC_CONST(0.62741109431647646), + FRAC_CONST(0.62868437945778133), + FRAC_CONST(0.62995598142180387), + FRAC_CONST(0.6312258968040827), + FRAC_CONST(0.63249412220467238), + FRAC_CONST(0.63376065422815175), + FRAC_CONST(0.63502548948363347), + FRAC_CONST(0.63628862458477287), + FRAC_CONST(0.63755005614977711), + FRAC_CONST(0.63880978080141437), + FRAC_CONST(0.6400677951670225), + FRAC_CONST(0.6413240958785188), + FRAC_CONST(0.64257867957240766), + FRAC_CONST(0.6438315428897915), + FRAC_CONST(0.64508268247637779), + FRAC_CONST(0.64633209498248945), + FRAC_CONST(0.64757977706307335), + FRAC_CONST(0.64882572537770888), + FRAC_CONST(0.65006993659061751), + FRAC_CONST(0.65131240737067142), + FRAC_CONST(0.65255313439140239), + FRAC_CONST(0.65379211433101081), + FRAC_CONST(0.65502934387237444), + FRAC_CONST(0.6562648197030575), + FRAC_CONST(0.65749853851531959), + FRAC_CONST(0.65873049700612374), + FRAC_CONST(0.65996069187714679), + FRAC_CONST(0.66118911983478657), + FRAC_CONST(0.66241577759017178), + FRAC_CONST(0.66364066185917048), + FRAC_CONST(0.66486376936239888), + FRAC_CONST(0.66608509682523009), + FRAC_CONST(0.66730464097780284), + FRAC_CONST(0.66852239855503071), + FRAC_CONST(0.66973836629660977), + FRAC_CONST(0.67095254094702894), + FRAC_CONST(0.67216491925557675), + FRAC_CONST(0.67337549797635199), + FRAC_CONST(0.67458427386827102), + FRAC_CONST(0.67579124369507693), + FRAC_CONST(0.67699640422534846), + FRAC_CONST(0.67819975223250772), + FRAC_CONST(0.6794012844948305), + FRAC_CONST(0.68060099779545302), + FRAC_CONST(0.68179888892238183), + FRAC_CONST(0.6829949546685018), + FRAC_CONST(0.68418919183158522), + FRAC_CONST(0.68538159721429948), + FRAC_CONST(0.6865721676242168), + FRAC_CONST(0.68776089987382172), + FRAC_CONST(0.68894779078052026), + FRAC_CONST(0.69013283716664853), + FRAC_CONST(0.69131603585948032), + FRAC_CONST(0.69249738369123692), + FRAC_CONST(0.69367687749909468), + FRAC_CONST(0.69485451412519361), + FRAC_CONST(0.69603029041664599), + FRAC_CONST(0.6972042032255451), + FRAC_CONST(0.6983762494089728), + FRAC_CONST(0.69954642582900894), + FRAC_CONST(0.70071472935273893), + FRAC_CONST(0.70188115685226271), + FRAC_CONST(0.703045705204703), + FRAC_CONST(0.70420837129221303), + FRAC_CONST(0.70536915200198613), + FRAC_CONST(0.70652804422626281), + FRAC_CONST(0.70768504486233985), + FRAC_CONST(0.70884015081257845), + FRAC_CONST(0.70999335898441229), + FRAC_CONST(0.711144666290356), + FRAC_CONST(0.71229406964801356), + FRAC_CONST(0.71344156598008623), + FRAC_CONST(0.71458715221438096), + FRAC_CONST(0.71573082528381871), + FRAC_CONST(0.71687258212644234), + FRAC_CONST(0.7180124196854254), + FRAC_CONST(0.71915033490907943), + FRAC_CONST(0.72028632475086318), + FRAC_CONST(0.72142038616938997), + FRAC_CONST(0.72255251612843596), + FRAC_CONST(0.72368271159694852), + FRAC_CONST(0.72481096954905444), + FRAC_CONST(0.72593728696406756), + FRAC_CONST(0.72706166082649704), + FRAC_CONST(0.72818408812605595), + FRAC_CONST(0.72930456585766834), + FRAC_CONST(0.73042309102147851), + FRAC_CONST(0.73153966062285747), + FRAC_CONST(0.73265427167241282), + FRAC_CONST(0.73376692118599507), + FRAC_CONST(0.73487760618470677), + FRAC_CONST(0.73598632369490979), + FRAC_CONST(0.73709307074823405), + FRAC_CONST(0.73819784438158409), + FRAC_CONST(0.73930064163714881), + FRAC_CONST(0.74040145956240788), + FRAC_CONST(0.74150029521014049), + FRAC_CONST(0.74259714563843304), + FRAC_CONST(0.74369200791068657), + FRAC_CONST(0.74478487909562552), + FRAC_CONST(0.74587575626730485), + FRAC_CONST(0.74696463650511791), + FRAC_CONST(0.74805151689380456), + FRAC_CONST(0.74913639452345926), + FRAC_CONST(0.75021926648953785), + FRAC_CONST(0.75130012989286621), + FRAC_CONST(0.7523789818396478), + FRAC_CONST(0.75345581944147111), + FRAC_CONST(0.75453063981531809), + FRAC_CONST(0.75560344008357094), + FRAC_CONST(0.75667421737402052), + FRAC_CONST(0.7577429688198738), + FRAC_CONST(0.75880969155976163), + FRAC_CONST(0.75987438273774599), + FRAC_CONST(0.76093703950332836), + FRAC_CONST(0.76199765901145666), + FRAC_CONST(0.76305623842253345), + FRAC_CONST(0.76411277490242291), + FRAC_CONST(0.76516726562245885), + FRAC_CONST(0.76621970775945258), + FRAC_CONST(0.76727009849569949), + FRAC_CONST(0.76831843501898767), + FRAC_CONST(0.76936471452260458), + FRAC_CONST(0.77040893420534517), + FRAC_CONST(0.77145109127151923), + FRAC_CONST(0.77249118293095853), + FRAC_CONST(0.77352920639902467), + FRAC_CONST(0.77456515889661659), + FRAC_CONST(0.77559903765017746), + FRAC_CONST(0.7766308398917029), + FRAC_CONST(0.77766056285874774), + FRAC_CONST(0.77868820379443371), + FRAC_CONST(0.77971375994745684), + FRAC_CONST(0.78073722857209438), + FRAC_CONST(0.7817586069282132), + FRAC_CONST(0.78277789228127592), + FRAC_CONST(0.78379508190234881), + FRAC_CONST(0.78481017306810918), + FRAC_CONST(0.78582316306085265), + FRAC_CONST(0.78683404916849986), + FRAC_CONST(0.78784282868460476), + FRAC_CONST(0.78884949890836087), + FRAC_CONST(0.78985405714460888), + FRAC_CONST(0.7908565007038445), + FRAC_CONST(0.79185682690222425), + FRAC_CONST(0.79285503306157412), + FRAC_CONST(0.79385111650939566), + FRAC_CONST(0.79484507457887377), + FRAC_CONST(0.79583690460888357), + FRAC_CONST(0.79682660394399751), + FRAC_CONST(0.79781416993449272), + FRAC_CONST(0.79879959993635785), + FRAC_CONST(0.7997828913113002), + FRAC_CONST(0.80076404142675273), + FRAC_CONST(0.80174304765588156), + FRAC_CONST(0.80271990737759213), + FRAC_CONST(0.80369461797653707), + FRAC_CONST(0.80466717684312306), + FRAC_CONST(0.80563758137351682), + FRAC_CONST(0.80660582896965372), + FRAC_CONST(0.80757191703924336), + FRAC_CONST(0.80853584299577752), + FRAC_CONST(0.80949760425853612), + FRAC_CONST(0.81045719825259477), + FRAC_CONST(0.81141462240883167), + FRAC_CONST(0.81236987416393436), + FRAC_CONST(0.81332295096040608), + FRAC_CONST(0.81427385024657373), + FRAC_CONST(0.81522256947659355), + FRAC_CONST(0.81616910611045879), + FRAC_CONST(0.817113457614006), + FRAC_CONST(0.81805562145892186), + FRAC_CONST(0.81899559512275044), + FRAC_CONST(0.81993337608889916), + FRAC_CONST(0.82086896184664637), + FRAC_CONST(0.8218023498911472), + FRAC_CONST(0.82273353772344116), + FRAC_CONST(0.82366252285045805), + FRAC_CONST(0.82458930278502529), + FRAC_CONST(0.82551387504587381), + FRAC_CONST(0.82643623715764558), + FRAC_CONST(0.82735638665089983), + FRAC_CONST(0.82827432106211907), + FRAC_CONST(0.82919003793371693), + FRAC_CONST(0.83010353481404364), + FRAC_CONST(0.83101480925739324), + FRAC_CONST(0.83192385882400965), + FRAC_CONST(0.83283068108009373), + FRAC_CONST(0.8337352735978093), + FRAC_CONST(0.83463763395529011), + FRAC_CONST(0.83553775973664579), + FRAC_CONST(0.83643564853196872), + FRAC_CONST(0.83733129793734051), + FRAC_CONST(0.83822470555483797), + FRAC_CONST(0.83911586899254031), + FRAC_CONST(0.84000478586453453), + FRAC_CONST(0.84089145379092289), + FRAC_CONST(0.84177587039782842), + FRAC_CONST(0.84265803331740163), + FRAC_CONST(0.84353794018782702), + FRAC_CONST(0.844415588653329), + FRAC_CONST(0.8452909763641786), + FRAC_CONST(0.84616410097669936), + FRAC_CONST(0.84703496015327406), + FRAC_CONST(0.84790355156235053), + FRAC_CONST(0.84876987287844818), + FRAC_CONST(0.8496339217821639), + FRAC_CONST(0.85049569596017938), + FRAC_CONST(0.85135519310526508), + FRAC_CONST(0.85221241091628896), + FRAC_CONST(0.85306734709822085), + FRAC_CONST(0.85391999936213903), + FRAC_CONST(0.85477036542523732), + FRAC_CONST(0.85561844301082923), + FRAC_CONST(0.85646422984835635), + FRAC_CONST(0.85730772367339259), + FRAC_CONST(0.85814892222765116), + FRAC_CONST(0.85898782325899026), + FRAC_CONST(0.85982442452141961), + FRAC_CONST(0.86065872377510555), + FRAC_CONST(0.86149071878637817), + FRAC_CONST(0.8623204073277364), + FRAC_CONST(0.86314778717785412), + FRAC_CONST(0.8639728561215867), + FRAC_CONST(0.86479561194997623), + FRAC_CONST(0.86561605246025763), + FRAC_CONST(0.86643417545586487), + FRAC_CONST(0.8672499787464365), + FRAC_CONST(0.86806346014782154), + FRAC_CONST(0.8688746174820855), + FRAC_CONST(0.86968344857751589), + FRAC_CONST(0.87048995126862883), + FRAC_CONST(0.87129412339617363), + FRAC_CONST(0.87209596280713941), + FRAC_CONST(0.8728954673547612), + FRAC_CONST(0.87369263489852422), + FRAC_CONST(0.87448746330417149), + FRAC_CONST(0.87527995044370765), + FRAC_CONST(0.8760700941954066), + FRAC_CONST(0.87685789244381551), + FRAC_CONST(0.87764334307976144), + FRAC_CONST(0.87842644400035663), + FRAC_CONST(0.8792071931090043), + FRAC_CONST(0.87998558831540408), + FRAC_CONST(0.88076162753555787), + FRAC_CONST(0.88153530869177488), + FRAC_CONST(0.88230662971267804), + FRAC_CONST(0.88307558853320878), + FRAC_CONST(0.88384218309463292), + FRAC_CONST(0.8846064113445461), + FRAC_CONST(0.88536827123687933), + FRAC_CONST(0.88612776073190425), + FRAC_CONST(0.88688487779623937), + FRAC_CONST(0.88763962040285393), + FRAC_CONST(0.8883919865310751), + FRAC_CONST(0.88914197416659235), + FRAC_CONST(0.88988958130146301), + FRAC_CONST(0.8906348059341177), + FRAC_CONST(0.89137764606936609), + FRAC_CONST(0.89211809971840139), + FRAC_CONST(0.89285616489880615), + FRAC_CONST(0.89359183963455813), + FRAC_CONST(0.89432512195603453), + FRAC_CONST(0.89505600990001799), + FRAC_CONST(0.89578450150970124), + FRAC_CONST(0.8965105948346932), + FRAC_CONST(0.89723428793102367), + FRAC_CONST(0.89795557886114807), + FRAC_CONST(0.89867446569395382), + FRAC_CONST(0.89939094650476448), + FRAC_CONST(0.90010501937534515), + FRAC_CONST(0.900816682393908), + FRAC_CONST(0.90152593365511691), + FRAC_CONST(0.90223277126009283), + FRAC_CONST(0.90293719331641886), + FRAC_CONST(0.90363919793814496), + FRAC_CONST(0.90433878324579353), + FRAC_CONST(0.90503594736636439), + FRAC_CONST(0.90573068843333915), + FRAC_CONST(0.90642300458668679), + FRAC_CONST(0.90711289397286898), + FRAC_CONST(0.90780035474484411), + FRAC_CONST(0.90848538506207266), + FRAC_CONST(0.90916798309052227), + FRAC_CONST(0.90984814700267291), + FRAC_CONST(0.9105258749775208), + FRAC_CONST(0.91120116520058425), + FRAC_CONST(0.91187401586390815), + FRAC_CONST(0.91254442516606893), + FRAC_CONST(0.9132123913121788), + FRAC_CONST(0.91387791251389161), + FRAC_CONST(0.91454098698940678), + FRAC_CONST(0.91520161296347435), + FRAC_CONST(0.91585978866739981), + FRAC_CONST(0.91651551233904871), + FRAC_CONST(0.91716878222285148), + FRAC_CONST(0.91781959656980805), + FRAC_CONST(0.91846795363749245), + FRAC_CONST(0.91911385169005766), + FRAC_CONST(0.9197572889982405), + FRAC_CONST(0.9203982638393654), + FRAC_CONST(0.92103677449734989), + FRAC_CONST(0.92167281926270861), + FRAC_CONST(0.92230639643255874), + FRAC_CONST(0.92293750431062316), + FRAC_CONST(0.92356614120723612), + FRAC_CONST(0.92419230543934783), + FRAC_CONST(0.92481599533052783), + FRAC_CONST(0.92543720921097061), + FRAC_CONST(0.92605594541749991), + FRAC_CONST(0.92667220229357261), + FRAC_CONST(0.92728597818928349), + FRAC_CONST(0.9278972714613698), + FRAC_CONST(0.92850608047321548), + FRAC_CONST(0.9291124035948557), + FRAC_CONST(0.92971623920298097), + FRAC_CONST(0.93031758568094147), + FRAC_CONST(0.93091644141875196), + FRAC_CONST(0.93151280481309506), + FRAC_CONST(0.93210667426732674), + FRAC_CONST(0.93269804819147983), + FRAC_CONST(0.93328692500226818), + FRAC_CONST(0.93387330312309147), + FRAC_CONST(0.93445718098403896), + FRAC_CONST(0.93503855702189376), + FRAC_CONST(0.9356174296801375), + FRAC_CONST(0.93619379740895381), + FRAC_CONST(0.93676765866523259), + FRAC_CONST(0.93733901191257496), + FRAC_CONST(0.93790785562129597), + FRAC_CONST(0.93847418826842988), + FRAC_CONST(0.93903800833773399), + FRAC_CONST(0.93959931431969212), + FRAC_CONST(0.94015810471151917), + FRAC_CONST(0.94071437801716529), + FRAC_CONST(0.94126813274731924), + FRAC_CONST(0.94181936741941319), + FRAC_CONST(0.94236808055762578), + FRAC_CONST(0.94291427069288691), + FRAC_CONST(0.94345793636288133), + FRAC_CONST(0.94399907611205225), + FRAC_CONST(0.9445376884916058), + FRAC_CONST(0.94507377205951448), + FRAC_CONST(0.94560732538052128), + FRAC_CONST(0.94613834702614352), + FRAC_CONST(0.94666683557467624), + FRAC_CONST(0.94719278961119657), + FRAC_CONST(0.94771620772756759), + FRAC_CONST(0.94823708852244104), + FRAC_CONST(0.94875543060126255), + FRAC_CONST(0.94927123257627433), + FRAC_CONST(0.94978449306651924), + FRAC_CONST(0.95029521069784428), + FRAC_CONST(0.9508033841029051), + FRAC_CONST(0.95130901192116835), + FRAC_CONST(0.9518120927989161), + FRAC_CONST(0.95231262538924943), + FRAC_CONST(0.95281060835209208), + FRAC_CONST(0.95330604035419386), + FRAC_CONST(0.95379892006913403), + FRAC_CONST(0.95428924617732525), + FRAC_CONST(0.95477701736601728), + FRAC_CONST(0.95526223232929941), + FRAC_CONST(0.95574488976810545), + FRAC_CONST(0.95622498839021619), + FRAC_CONST(0.95670252691026292), + FRAC_CONST(0.95717750404973156), + FRAC_CONST(0.95764991853696524), + FRAC_CONST(0.95811976910716812), + FRAC_CONST(0.95858705450240911), + FRAC_CONST(0.95905177347162429), + FRAC_CONST(0.95951392477062125), + FRAC_CONST(0.95997350716208196), + FRAC_CONST(0.96043051941556579), + FRAC_CONST(0.96088496030751369), + FRAC_CONST(0.96133682862125036), + FRAC_CONST(0.96178612314698864), + FRAC_CONST(0.96223284268183173), + FRAC_CONST(0.9626769860297768), + FRAC_CONST(0.96311855200171881), + FRAC_CONST(0.96355753941545252), + FRAC_CONST(0.96399394709567654), + FRAC_CONST(0.96442777387399625), + FRAC_CONST(0.96485901858892686), + FRAC_CONST(0.96528768008589627), + FRAC_CONST(0.96571375721724895), + FRAC_CONST(0.96613724884224783), + FRAC_CONST(0.96655815382707866), + FRAC_CONST(0.96697647104485207), + FRAC_CONST(0.96739219937560694), + FRAC_CONST(0.96780533770631338), + FRAC_CONST(0.96821588493087585), + FRAC_CONST(0.9686238399501359), + FRAC_CONST(0.96902920167187501), + FRAC_CONST(0.96943196901081796), + FRAC_CONST(0.96983214088863534), + FRAC_CONST(0.9702297162339466), + FRAC_CONST(0.97062469398232287), + FRAC_CONST(0.97101707307629004), + FRAC_CONST(0.97140685246533098), + FRAC_CONST(0.97179403110588902), + FRAC_CONST(0.97217860796137046), + FRAC_CONST(0.97256058200214734), + FRAC_CONST(0.97293995220556007), + FRAC_CONST(0.97331671755592064), + FRAC_CONST(0.97369087704451474), + FRAC_CONST(0.97406242966960455), + FRAC_CONST(0.97443137443643235), + FRAC_CONST(0.97479771035722163), + FRAC_CONST(0.97516143645118103), + FRAC_CONST(0.97552255174450631), + FRAC_CONST(0.97588105527038305), + FRAC_CONST(0.97623694606898959), + FRAC_CONST(0.97659022318749911), + FRAC_CONST(0.97694088568008242), + FRAC_CONST(0.97728893260791039), + FRAC_CONST(0.97763436303915685), + FRAC_CONST(0.97797717604900047), + FRAC_CONST(0.97831737071962765), + FRAC_CONST(0.97865494614023485), + FRAC_CONST(0.97898990140703124), + FRAC_CONST(0.97932223562324061), + FRAC_CONST(0.97965194789910426), + FRAC_CONST(0.9799790373518833), + FRAC_CONST(0.98030350310586067), + FRAC_CONST(0.98062534429234405), + FRAC_CONST(0.98094456004966768), + FRAC_CONST(0.98126114952319499), + FRAC_CONST(0.98157511186532054), + FRAC_CONST(0.98188644623547261), + FRAC_CONST(0.98219515180011563), + FRAC_CONST(0.98250122773275184), + FRAC_CONST(0.98280467321392362), + FRAC_CONST(0.98310548743121629), + FRAC_CONST(0.98340366957925973), + FRAC_CONST(0.98369921885973044), + FRAC_CONST(0.98399213448135414), + FRAC_CONST(0.98428241565990748), + FRAC_CONST(0.98457006161822058), + FRAC_CONST(0.98485507158617835), + FRAC_CONST(0.98513744480072363), + FRAC_CONST(0.98541718050585803), + FRAC_CONST(0.98569427795264519), + FRAC_CONST(0.98596873639921168), + FRAC_CONST(0.98624055511074971), + FRAC_CONST(0.98650973335951875), + FRAC_CONST(0.98677627042484772), + FRAC_CONST(0.98704016559313645), + FRAC_CONST(0.98730141815785832), + FRAC_CONST(0.98756002741956173), + FRAC_CONST(0.9878159926858715), + FRAC_CONST(0.98806931327149194), + FRAC_CONST(0.98831998849820735), + FRAC_CONST(0.98856801769488489), + FRAC_CONST(0.98881340019747566), + FRAC_CONST(0.98905613534901682), + FRAC_CONST(0.98929622249963345), + FRAC_CONST(0.98953366100653983), + FRAC_CONST(0.98976845023404181), + FRAC_CONST(0.99000058955353776), + FRAC_CONST(0.99023007834352106), + FRAC_CONST(0.99045691598958097), + FRAC_CONST(0.99068110188440506), + FRAC_CONST(0.99090263542778001), + FRAC_CONST(0.99112151602659404), + FRAC_CONST(0.99133774309483769), + FRAC_CONST(0.99155131605360625), + FRAC_CONST(0.99176223433110056), + FRAC_CONST(0.99197049736262888), + FRAC_CONST(0.99217610459060845), + FRAC_CONST(0.99237905546456673), + FRAC_CONST(0.99257934944114334), + FRAC_CONST(0.99277698598409092), + FRAC_CONST(0.99297196456427694), + FRAC_CONST(0.99316428465968509), + FRAC_CONST(0.99335394575541669), + FRAC_CONST(0.99354094734369169), + FRAC_CONST(0.99372528892385081), + FRAC_CONST(0.99390697000235606), + FRAC_CONST(0.99408599009279242), + FRAC_CONST(0.99426234871586938), + FRAC_CONST(0.99443604539942176), + FRAC_CONST(0.99460707967841133), + FRAC_CONST(0.99477545109492771), + FRAC_CONST(0.99494115919819004), + FRAC_CONST(0.99510420354454787), + FRAC_CONST(0.99526458369748239), + FRAC_CONST(0.99542229922760772), + FRAC_CONST(0.99557734971267187), + FRAC_CONST(0.9957297347375581), + FRAC_CONST(0.99587945389428578), + FRAC_CONST(0.99602650678201154), + FRAC_CONST(0.99617089300703077), + FRAC_CONST(0.996312612182778), + FRAC_CONST(0.99645166392982831), + FRAC_CONST(0.99658804787589839), + FRAC_CONST(0.99672176365584741), + FRAC_CONST(0.99685281091167788), + FRAC_CONST(0.99698118929253687), + FRAC_CONST(0.99710689845471678), + FRAC_CONST(0.99722993806165661), + FRAC_CONST(0.99735030778394196), + FRAC_CONST(0.99746800729930707), + FRAC_CONST(0.99758303629263489), + FRAC_CONST(0.99769539445595812), + FRAC_CONST(0.99780508148846014), + FRAC_CONST(0.99791209709647588), + FRAC_CONST(0.99801644099349218), + FRAC_CONST(0.99811811290014918), + FRAC_CONST(0.9982171125442405), + FRAC_CONST(0.9983134396607144), + FRAC_CONST(0.99840709399167404), + FRAC_CONST(0.99849807528637868), + FRAC_CONST(0.99858638330124405), + FRAC_CONST(0.99867201779984294), + FRAC_CONST(0.99875497855290607), + FRAC_CONST(0.99883526533832245), + FRAC_CONST(0.99891287794114036), + FRAC_CONST(0.99898781615356746), + FRAC_CONST(0.99906007977497147), + FRAC_CONST(0.99912966861188113), + FRAC_CONST(0.99919658247798593), + FRAC_CONST(0.99926082119413751), + FRAC_CONST(0.99932238458834954), + FRAC_CONST(0.999381272495798), + FRAC_CONST(0.99943748475882255), + FRAC_CONST(0.9994910212269259), + FRAC_CONST(0.99954188175677483), + FRAC_CONST(0.99959006621220048), + FRAC_CONST(0.99963557446419837), + FRAC_CONST(0.99967840639092931), + FRAC_CONST(0.99971856187771946), + FRAC_CONST(0.99975604081706027), + FRAC_CONST(0.99979084310860955), + FRAC_CONST(0.99982296865919107), + FRAC_CONST(0.99985241738279484), + FRAC_CONST(0.99987918920057806), + FRAC_CONST(0.99990328404086426), + FRAC_CONST(0.9999247018391445), + FRAC_CONST(0.99994344253807688), + FRAC_CONST(0.99995950608748674), + FRAC_CONST(0.99997289244436727), + FRAC_CONST(0.99998360157287902), + FRAC_CONST(0.9999916334443506), + FRAC_CONST(0.99999698803727821), + FRAC_CONST(0.99999966533732598) }; #endif -#else - -real_t sine_long_1024[] = +ALIGN static const real_t sine_short_128[] = { - 0x3243F, - 0x96CBD, - 0xFB53A, - 0x15FDB5, - 0x1C462C, - 0x228E9E, - 0x28D70C, - 0x2F1F73, - 0x3567D2, - 0x3BB02A, - 0x41F878, - 0x4840BD, - 0x4E88F6, - 0x54D123, - 0x5B1942, - 0x616154, - 0x67A957, - 0x6DF14A, - 0x74392C, - 0x7A80FC, - 0x80C8B9, - 0x871062, - 0x8D57F6, - 0x939F75, - 0x99E6DC, - 0xA02E2C, - 0xA67564, - 0xACBC81, - 0xB30385, - 0xB94A6C, - 0xBF9137, - 0xC5D7E4, - 0xCC1E73, - 0xD264E2, - 0xD8AB31, - 0xDEF15F, - 0xE5376A, - 0xEB7D51, - 0xF1C315, - 0xF808B3, - 0xFE4E2B, - 0x104937C, - 0x10AD8A4, - 0x1111DA3, - 0x1176279, - 0x11DA723, - 0x123EBA1, - 0x12A2FF2, - 0x1307415, - 0x136B809, - 0x13CFBCD, - 0x1433F61, - 0x14982C2, - 0x14FC5F1, - 0x15608EC, - 0x15C4BB2, - 0x1628E42, - 0x168D09C, - 0x16F12BE, - 0x17554A8, - 0x17B9658, - 0x181D7CD, - 0x1881907, - 0x18E5A04, - 0x1949AC4, - 0x19ADB46, - 0x1A11B88, - 0x1A75B8A, - 0x1AD9B4B, - 0x1B3DAC9, - 0x1BA1A04, - 0x1C058FB, - 0x1C697AD, - 0x1CCD619, - 0x1D3143D, - 0x1D9521A, - 0x1DF8FAE, - 0x1E5CCF7, - 0x1EC09F6, - 0x1F246A9, - 0x1F8830F, - 0x1FEBF27, - 0x204FAF1, - 0x20B366B, - 0x2117194, - 0x217AC6B, - 0x21DE6F0, - 0x2242121, - 0x22A5AFE, - 0x2309485, - 0x236CDB6, - 0x23D0690, - 0x2433F11, - 0x2497738, - 0x24FAF06, - 0x255E678, - 0x25C1D8E, - 0x2625447, - 0x2688AA1, - 0x26EC09D, - 0x274F638, - 0x27B2B73, - 0x281604C, - 0x28794C1, - 0x28DC8D3, - 0x293FC80, - 0x29A2FC7, - 0x2A062A8, - 0x2A69521, - 0x2ACC731, - 0x2B2F8D8, - 0x2B92A14, - 0x2BF5AE4, - 0x2C58B48, - 0x2CBBB3F, - 0x2D1EAC7, - 0x2D819E0, - 0x2DE4889, - 0x2E476C0, - 0x2EAA485, - 0x2F0D1D7, - 0x2F6FEB5, - 0x2FD2B1E, - 0x3035711, - 0x309828D, - 0x30FAD91, - 0x315D81C, - 0x31C022E, - 0x3222BC4, - 0x32854DF, - 0x32E7D7E, - 0x334A59E, - 0x33ACD41, - 0x340F463, - 0x3471B05, - 0x34D4126, - 0x35366C5, - 0x3598BE0, - 0x35FB077, - 0x365D488, - 0x36BF814, - 0x3721B18, - 0x3783D95, - 0x37E5F88, - 0x38480F2, - 0x38AA1D1, - 0x390C223, - 0x396E1EA, - 0x39D0122, - 0x3A31FCC, - 0x3A93DE6, - 0x3AF5B70, - 0x3B57868, - 0x3BB94CD, - 0x3C1B0A0, - 0x3C7CBDE, - 0x3CDE687, - 0x3D40099, - 0x3DA1A15, - 0x3E032F8, - 0x3E64B43, - 0x3EC62F3, - 0x3F27A09, - 0x3F89083, - 0x3FEA660, - 0x404BB9F, - 0x40AD03F, - 0x410E441, - 0x416F7A1, - 0x41D0A60, - 0x4231C7D, - 0x4292DF6, - 0x42F3ECB, - 0x4354EFB, - 0x43B5E85, - 0x4416D68, - 0x4477BA2, - 0x44D8934, - 0x453961C, - 0x459A259, - 0x45FADEB, - 0x465B8CF, - 0x46BC306, - 0x471CC8F, - 0x477D568, - 0x47DDD91, - 0x483E508, - 0x489EBCD, - 0x48FF1DF, - 0x495F73D, - 0x49BFBE6, - 0x4A1FFD8, - 0x4A80314, - 0x4AE0598, - 0x4B40764, - 0x4BA0875, - 0x4C008CD, - 0x4C60868, - 0x4CC0747, - 0x4D20569, - 0x4D802CC, - 0x4DDFF70, - 0x4E3FB54, - 0x4E9F677, - 0x4EFF0D8, - 0x4F5EA76, - 0x4FBE351, - 0x501DB66, - 0x507D2B6, - 0x50DC93F, - 0x513BF01, - 0x519B3FA, - 0x51FA82A, - 0x5259B8F, - 0x52B8E2A, - 0x5317FF8, - 0x53770F9, - 0x53D612D, - 0x5435091, - 0x5493F26, - 0x54F2CEA, - 0x55519DC, - 0x55B05FC, - 0x560F149, - 0x566DBC1, - 0x56CC564, - 0x572AE30, - 0x5789626, - 0x57E7D44, - 0x5846388, - 0x58A48F3, - 0x5902D84, - 0x5961138, - 0x59BF410, - 0x5A1D60B, - 0x5A7B727, - 0x5AD9764, - 0x5B376C1, - 0x5B9553D, - 0x5BF32D6, - 0x5C50F8D, - 0x5CAEB60, - 0x5D0C64F, - 0x5D6A058, - 0x5DC797A, - 0x5E251B5, - 0x5E82908, - 0x5EDFF71, - 0x5F3D4F1, - 0x5F9A985, - 0x5FF7D2E, - 0x6054FE9, - 0x60B21B8, - 0x610F297, - 0x616C287, - 0x61C9187, - 0x6225F95, - 0x6282CB1, - 0x62DF8DA, - 0x633C40F, - 0x6398E4F, - 0x63F579A, - 0x6451FEE, - 0x64AE74A, - 0x650ADAE, - 0x6567319, - 0x65C3789, - 0x661FAFE, - 0x667BD78, - 0x66D7EF4, - 0x6733F73, - 0x678FEF3, - 0x67EBD74, - 0x6847AF4, - 0x68A3772, - 0x68FF2EF, - 0x695AD69, - 0x69B66DE, - 0x6A11F4F, - 0x6A6D6BA, - 0x6AC8D1F, - 0x6B2427C, - 0x6B7F6D0, - 0x6BDAA1C, - 0x6C35C5D, - 0x6C90D93, - 0x6CEBDBE, - 0x6D46CDB, - 0x6DA1AEB, - 0x6DFC7ED, - 0x6E573DF, - 0x6EB1EC1, - 0x6F0C891, - 0x6F67150, - 0x6FC18FC, - 0x701BF94, - 0x7076518, - 0x70D0986, - 0x712ACDD, - 0x7184F1E, - 0x71DF046, - 0x7239055, - 0x7292F4B, - 0x72ECD26, - 0x73469E5, - 0x73A0588, - 0x73FA00D, - 0x7453975, - 0x74AD1BD, - 0x75068E6, - 0x755FEED, - 0x75B93D3, - 0x7612797, - 0x766BA37, - 0x76C4BB3, - 0x771DC0A, - 0x7776B3C, - 0x77CF946, - 0x7828629, - 0x78811E3, - 0x78D9C74, - 0x79325DB, - 0x798AE16, - 0x79E3526, - 0x7A3BB09, - 0x7A93FBF, - 0x7AEC346, - 0x7B4459E, - 0x7B9C6C5, - 0x7BF46BC, - 0x7C4C581, - 0x7CA4313, - 0x7CFBF71, - 0x7D53A9B, - 0x7DAB490, - 0x7E02D4F, - 0x7E5A4D7, - 0x7EB1B27, - 0x7F0903F, - 0x7F6041D, - 0x7FB76C0, - 0x800E829, - 0x8065856, - 0x80BC746, - 0x81134F8, - 0x816A16C, - 0x81C0CA0, - 0x8217694, - 0x826DF48, - 0x82C46B9, - 0x831ACE8, - 0x83711D3, - 0x83C757A, - 0x841D7DC, - 0x84738F8, - 0x84C98CD, - 0x851F75B, - 0x85754A0, - 0x85CB09B, - 0x8620B4D, - 0x86764B4, - 0x86CBCCE, - 0x872139D, - 0x877691D, - 0x87CBD50, - 0x8821034, - 0x88761C7, - 0x88CB20A, - 0x89200FC, - 0x8974E9B, - 0x89C9AE7, - 0x8A1E5DE, - 0x8A72F82, - 0x8AC77CF, - 0x8B1BEC6, - 0x8B70466, - 0x8BC48AE, - 0x8C18B9D, - 0x8C6CD32, - 0x8CC0D6D, - 0x8D14C4C, - 0x8D689D0, - 0x8DBC5F6, - 0x8E100BF, - 0x8E63A29, - 0x8EB7234, - 0x8F0A8DF, - 0x8F5DE29, - 0x8FB1211, - 0x9004496, - 0x90575B9, - 0x90AA577, - 0x90FD3D0, - 0x91500C3, - 0x91A2C50, - 0x91F5675, - 0x9247F33, - 0x929A687, - 0x92ECC72, - 0x933F0F2, - 0x9391407, - 0x93E35AF, - 0x94355EB, - 0x94874B9, - 0x94D9219, - 0x952AE09, - 0x957C88A, - 0x95CE199, - 0x961F937, - 0x9670F62, - 0x96C241B, - 0x971375F, - 0x976492E, - 0x97B5988, - 0x980686C, - 0x98575D8, - 0x98A81CD, - 0x98F8C49, - 0x994954C, - 0x9999CD4, - 0x99EA2E1, - 0x9A3A773, - 0x9A8AA88, - 0x9ADAC1F, - 0x9B2AC39, - 0x9B7AAD4, - 0x9BCA7EF, - 0x9C1A389, - 0x9C69DA3, - 0x9CB963A, - 0x9D08D4F, - 0x9D582E1, - 0x9DA76EE, - 0x9DF6976, - 0x9E45A79, - 0x9E949F5, - 0x9EE37E9, - 0x9F32456, - 0x9F80F3A, - 0x9FCF894, - 0xA01E064, - 0xA06C6A9, - 0xA0BAB62, - 0xA108E8E, - 0xA15702D, - 0xA1A503E, - 0xA1F2EC0, - 0xA240BB3, - 0xA28E715, - 0xA2DC0E6, - 0xA329925, - 0xA376FD2, - 0xA3C44EC, - 0xA411871, - 0xA45EA61, - 0xA4ABABC, - 0xA4F8981, - 0xA5456AE, - 0xA592244, - 0xA5DEC41, - 0xA62B4A5, - 0xA677B6F, - 0xA6C409E, - 0xA710432, - 0xA75C62A, - 0xA7A8684, - 0xA7F4541, - 0xA840260, - 0xA88BDDF, - 0xA8D77BE, - 0xA922FFD, - 0xA96E69B, - 0xA9B9B96, - 0xAA04EEF, - 0xAA500A4, - 0xAA9B0B5, - 0xAAE5F21, - 0xAB30BE8, - 0xAB7B707, - 0xABC6080, - 0xAC10851, - 0xAC5AE7A, - 0xACA52F9, - 0xACEF5CE, - 0xAD396F9, - 0xAD83678, - 0xADCD44B, - 0xAE17071, - 0xAE60AE9, - 0xAEAA3B4, - 0xAEF3ACF, - 0xAF3D03B, - 0xAF863F6, - 0xAFCF600, - 0xB018658, - 0xB0614FE, - 0xB0AA1F1, - 0xB0F2D30, - 0xB13B6BA, - 0xB183E8F, - 0xB1CC4AE, - 0xB214916, - 0xB25CBC7, - 0xB2A4CC0, - 0xB2ECBFF, - 0xB334986, - 0xB37C552, - 0xB3C3F64, - 0xB40B7B9, - 0xB452E53, - 0xB49A330, - 0xB4E164F, - 0xB5287AF, - 0xB56F751, - 0xB5B6533, - 0xB5FD155, - 0xB643BB6, - 0xB68A455, - 0xB6D0B31, - 0xB71704B, - 0xB75D3A0, - 0xB7A3532, - 0xB7E94FE, - 0xB82F304, - 0xB874F44, - 0xB8BA9BD, - 0xB90026E, - 0xB945957, - 0xB98AE76, - 0xB9D01CC, - 0xBA15357, - 0xBA5A317, - 0xBA9F10B, - 0xBAE3D33, - 0xBB2878D, - 0xBB6D01A, - 0xBBB16D9, - 0xBBF5BC8, - 0xBC39EE7, - 0xBC7E036, - 0xBCC1FB4, - 0xBD05D60, - 0xBD4993A, - 0xBD8D341, - 0xBDD0B74, - 0xBE141D3, - 0xBE5765C, - 0xBE9A910, - 0xBEDD9EE, - 0xBF208F5, - 0xBF63624, - 0xBFA617B, - 0xBFE8AF9, - 0xC02B29E, - 0xC06D868, - 0xC0AFC58, - 0xC0F1E6C, - 0xC133EA4, - 0xC175D00, - 0xC1B797E, - 0xC1F941E, - 0xC23ACDF, - 0xC27C3C2, - 0xC2BD8C4, - 0xC2FEBE6, - 0xC33FD27, - 0xC380C86, - 0xC3C1A02, - 0xC40259C, - 0xC442F52, - 0xC483724, - 0xC4C3D10, - 0xC504118, - 0xC544339, - 0xC584373, - 0xC5C41C7, - 0xC603E32, - 0xC6438B4, - 0xC68314E, - 0xC6C27FD, - 0xC701CC2, - 0xC740F9D, - 0xC78008B, - 0xC7BEF8D, - 0xC7FDCA3, - 0xC83C7CB, - 0xC87B104, - 0xC8B9850, - 0xC8F7DAC, - 0xC936118, - 0xC974293, - 0xC9B221E, - 0xC9EFFB7, - 0xCA2DB5D, - 0xCA6B511, - 0xCAA8CD1, - 0xCAE629E, - 0xCB23675, - 0xCB60858, - 0xCB9D844, - 0xCBDA63A, - 0xCC1723A, - 0xCC53C41, - 0xCC90451, - 0xCCCCA67, - 0xCD08E85, - 0xCD450A8, - 0xCD810D1, - 0xCDBCEFF, - 0xCDF8B32, - 0xCE34568, - 0xCE6FDA1, - 0xCEAB3DD, - 0xCEE681B, - 0xCF21A5A, - 0xCF5CA9B, - 0xCF978DC, - 0xCFD251C, - 0xD00CF5C, - 0xD04779A, - 0xD081DD7, - 0xD0BC211, - 0xD0F6448, - 0xD13047C, - 0xD16A2AB, - 0xD1A3ED5, - 0xD1DD8FB, - 0xD21711A, - 0xD250733, - 0xD289B46, - 0xD2C2D50, - 0xD2FBD53, - 0xD334B4D, - 0xD36D73E, - 0xD3A6125, - 0xD3DE902, - 0xD416ED5, - 0xD44F29C, - 0xD487457, - 0xD4BF406, - 0xD4F71A7, - 0xD52ED3C, - 0xD5666C2, - 0xD59DE3A, - 0xD5D53A3, - 0xD60C6FC, - 0xD643845, - 0xD67A77D, - 0xD6B14A4, - 0xD6E7FB9, - 0xD71E8BC, - 0xD754FAD, - 0xD78B48A, - 0xD7C1753, - 0xD7F7808, - 0xD82D6A8, - 0xD863332, - 0xD898DA7, - 0xD8CE605, - 0xD903C4C, - 0xD93907C, - 0xD96E294, - 0xD9A3293, - 0xD9D8079, - 0xDA0CC46, - 0xDA415F9, - 0xDA75D91, - 0xDAAA30E, - 0xDADE670, - 0xDB127B6, - 0xDB466DF, - 0xDB7A3EB, - 0xDBADEDA, - 0xDBE17AA, - 0xDC14E5C, - 0xDC482EF, - 0xDC7B562, - 0xDCAE5B6, - 0xDCE13E9, - 0xDD13FFB, - 0xDD469EB, - 0xDD791B9, - 0xDDAB765, - 0xDDDDAEE, - 0xDE0FC54, - 0xDE41B96, - 0xDE738B3, - 0xDEA53AB, - 0xDED6C7E, - 0xDF0832C, - 0xDF397B3, - 0xDF6AA13, - 0xDF9BA4C, - 0xDFCC85D, - 0xDFFD446, - 0xE02DE06, - 0xE05E59D, - 0xE08EB0A, - 0xE0BEE4E, - 0xE0EEF67, - 0xE11EE55, - 0xE14EB17, - 0xE17E5AE, - 0xE1ADE18, - 0xE1DD455, - 0xE20C865, - 0xE23BA47, - 0xE26A9FB, - 0xE299781, - 0xE2C82D7, - 0xE2F6BFE, - 0xE3252F4, - 0xE3537BB, - 0xE381A50, - 0xE3AFAB4, - 0xE3DD8E6, - 0xE40B4E6, - 0xE438EB3, - 0xE46664D, - 0xE493BB4, - 0xE4C0EE7, - 0xE4EDFE5, - 0xE51AEAE, - 0xE547B42, - 0xE5745A0, - 0xE5A0DC9, - 0xE5CD3BA, - 0xE5F9775, - 0xE6258F8, - 0xE651843, - 0xE67D556, - 0xE6A9030, - 0xE6D48D1, - 0xE6FFF39, - 0xE72B366, - 0xE75655A, - 0xE781512, - 0xE7AC28F, - 0xE7D6DD1, - 0xE8016D6, - 0xE82BD9F, - 0xE85622C, - 0xE88047B, - 0xE8AA48C, - 0xE8D425F, - 0xE8FDDF4, - 0xE92774A, - 0xE950E60, - 0xE97A337, - 0xE9A35CE, - 0xE9CC624, - 0xE9F5439, - 0xEA1E00E, - 0xEA469A0, - 0xEA6F0F0, - 0xEA975FE, - 0xEABF8CA, - 0xEAE7952, - 0xEB0F796, - 0xEB37396, - 0xEB5ED52, - 0xEB864C9, - 0xEBAD9FC, - 0xEBD4CE8, - 0xEBFBD8F, - 0xEC22BEF, - 0xEC49809, - 0xEC701DC, - 0xEC96967, - 0xECBCEAB, - 0xECE31A6, - 0xED09259, - 0xED2F0C3, - 0xED54CE4, - 0xED7A6BC, - 0xED9FE49, - 0xEDC538C, - 0xEDEA685, - 0xEE0F732, - 0xEE34594, - 0xEE591AA, - 0xEE7DB74, - 0xEEA22F2, - 0xEEC6823, - 0xEEEAB06, - 0xEF0EB9D, - 0xEF329E5, - 0xEF565DF, - 0xEF79F8B, - 0xEF9D6E7, - 0xEFC0BF5, - 0xEFE3EB3, - 0xF006F21, - 0xF029D3F, - 0xF04C90C, - 0xF06F288, - 0xF0919B3, - 0xF0B3E8D, - 0xF0D6114, - 0xF0F8149, - 0xF119F2C, - 0xF13BABC, - 0xF15D3F9, - 0xF17EAE2, - 0xF19FF77, - 0xF1C11B8, - 0xF1E21A4, - 0xF202F3C, - 0xF223A7F, - 0xF24436C, - 0xF264A03, - 0xF284E44, - 0xF2A502F, - 0xF2C4FC3, - 0xF2E4D01, - 0xF3047E6, - 0xF324075, - 0xF3436AB, - 0xF362A89, - 0xF381C0F, - 0xF3A0B3B, - 0xF3BF80F, - 0xF3DE289, - 0xF3FCAAA, - 0xF41B070, - 0xF4393DC, - 0xF4574EE, - 0xF4753A4, - 0xF493000, - 0xF4B0A00, - 0xF4CE1A4, - 0xF4EB6EC, - 0xF5089D8, - 0xF525A67, - 0xF54289A, - 0xF55F46F, - 0xF57BDE7, - 0xF598501, - 0xF5B49BD, - 0xF5D0C1B, - 0xF5ECC1A, - 0xF6089BB, - 0xF6244FD, - 0xF63FDDF, - 0xF65B461, - 0xF676884, - 0xF691A47, - 0xF6AC9A9, - 0xF6C76AA, - 0xF6E214B, - 0xF6FC98B, - 0xF716F69, - 0xF7312E5, - 0xF74B400, - 0xF7652B8, - 0xF77EF0E, - 0xF798901, - 0xF7B2092, - 0xF7CB5BF, - 0xF7E4888, - 0xF7FD8EF, - 0xF8166F1, - 0xF82F28F, - 0xF847BC9, - 0xF86029E, - 0xF87870E, - 0xF890919, - 0xF8A88BF, - 0xF8C05FF, - 0xF8D80DA, - 0xF8EF94E, - 0xF906F5D, - 0xF91E305, - 0xF935446, - 0xF94C320, - 0xF962F93, - 0xF97999F, - 0xF990144, - 0xF9A6680, - 0xF9BC955, - 0xF9D29C1, - 0xF9E87C5, - 0xF9FE360, - 0xFA13C93, - 0xFA2935C, - 0xFA3E7BC, - 0xFA539B3, - 0xFA68940, - 0xFA7D663, - 0xFA9211D, - 0xFAA696C, - 0xFABAF50, - 0xFACF2CA, - 0xFAE33D9, - 0xFAF727D, - 0xFB0AEB5, - 0xFB1E883, - 0xFB31FE4, - 0xFB454DA, - 0xFB58764, - 0xFB6B782, - 0xFB7E533, - 0xFB91078, - 0xFBA3950, - 0xFBB5FBB, - 0xFBC83B9, - 0xFBDA54A, - 0xFBEC46E, - 0xFBFE124, - 0xFC0FB6C, - 0xFC21346, - 0xFC328B2, - 0xFC43BB0, - 0xFC54C3F, - 0xFC65A60, - 0xFC76612, - 0xFC86F55, - 0xFC97629, - 0xFCA7A8D, - 0xFCB7C83, - 0xFCC7C08, - 0xFCD791F, - 0xFCE73C5, - 0xFCF6BFB, - 0xFD061C1, - 0xFD15517, - 0xFD245FC, - 0xFD33471, - 0xFD42074, - 0xFD50A07, - 0xFD5F129, - 0xFD6D5DA, - 0xFD7B81A, - 0xFD897E8, - 0xFD97544, - 0xFDA502F, - 0xFDB28A8, - 0xFDBFEAF, - 0xFDCD244, - 0xFDDA366, - 0xFDE7217, - 0xFDF3E54, - 0xFE00820, - 0xFE0CF78, - 0xFE1945E, - 0xFE256D0, - 0xFE316D0, - 0xFE3D45C, - 0xFE48F75, - 0xFE5481B, - 0xFE5FE4D, - 0xFE6B20C, - 0xFE76356, - 0xFE8122D, - 0xFE8BE90, - 0xFE9687F, - 0xFEA0FFA, - 0xFEAB500, - 0xFEB5792, - 0xFEBF7AF, - 0xFEC9558, - 0xFED308D, - 0xFEDC94C, - 0xFEE5F97, - 0xFEEF36D, - 0xFEF84CE, - 0xFF013B9, - 0xFF0A030, - 0xFF12A31, - 0xFF1B1BD, - 0xFF236D3, - 0xFF2B974, - 0xFF3399F, - 0xFF3B754, - 0xFF43294, - 0xFF4AB5E, - 0xFF521B2, - 0xFF59590, - 0xFF606F8, - 0xFF675EA, - 0xFF6E266, - 0xFF74C6B, - 0xFF7B3FA, - 0xFF81913, - 0xFF87BB5, - 0xFF8DBE1, - 0xFF93996, - 0xFF994D5, - 0xFF9ED9D, - 0xFFA43EE, - 0xFFA97C9, - 0xFFAE92D, - 0xFFB3819, - 0xFFB848F, - 0xFFBCE8E, - 0xFFC1616, - 0xFFC5B27, - 0xFFC9DC1, - 0xFFCDDE3, - 0xFFD1B8F, - 0xFFD56C3, - 0xFFD8F80, - 0xFFDC5C6, - 0xFFDF994, - 0xFFE2AEB, - 0xFFE59CB, - 0xFFE8633, - 0xFFEB024, - 0xFFED79E, - 0xFFEFCA0, - 0xFFF1F2A, - 0xFFF3F3D, - 0xFFF5CD9, - 0xFFF77FC, - 0xFFF90A9, - 0xFFFA6DD, - 0xFFFBA9B, - 0xFFFCBE0, - 0xFFFDAAE, - 0xFFFE704, - 0xFFFF0E3, - 0xFFFF84A, - 0xFFFFD39, - 0xFFFFFB1 + FRAC_CONST(0.0061358846491544753), + FRAC_CONST(0.01840672990580482), + FRAC_CONST(0.030674803176636626), + FRAC_CONST(0.04293825693494082), + FRAC_CONST(0.055195244349689934), + FRAC_CONST(0.067443919563664051), + FRAC_CONST(0.079682437971430126), + FRAC_CONST(0.091908956497132724), + FRAC_CONST(0.10412163387205459), + FRAC_CONST(0.11631863091190475), + FRAC_CONST(0.12849811079379317), + FRAC_CONST(0.14065823933284921), + FRAC_CONST(0.15279718525844344), + FRAC_CONST(0.16491312048996989), + FRAC_CONST(0.17700422041214875), + FRAC_CONST(0.18906866414980619), + FRAC_CONST(0.2011046348420919), + FRAC_CONST(0.21311031991609136), + FRAC_CONST(0.22508391135979283), + FRAC_CONST(0.2370236059943672), + FRAC_CONST(0.24892760574572015), + FRAC_CONST(0.26079411791527551), + FRAC_CONST(0.27262135544994898), + FRAC_CONST(0.28440753721127188), + FRAC_CONST(0.29615088824362379), + FRAC_CONST(0.30784964004153487), + FRAC_CONST(0.31950203081601569), + FRAC_CONST(0.33110630575987643), + FRAC_CONST(0.34266071731199438), + FRAC_CONST(0.35416352542049034), + FRAC_CONST(0.36561299780477385), + FRAC_CONST(0.37700741021641826), + FRAC_CONST(0.38834504669882625), + FRAC_CONST(0.39962419984564679), + FRAC_CONST(0.41084317105790391), + FRAC_CONST(0.42200027079979968), + FRAC_CONST(0.43309381885315196), + FRAC_CONST(0.4441221445704292), + FRAC_CONST(0.45508358712634384), + FRAC_CONST(0.46597649576796618), + FRAC_CONST(0.47679923006332209), + FRAC_CONST(0.487550160148436), + FRAC_CONST(0.49822766697278187), + FRAC_CONST(0.50883014254310699), + FRAC_CONST(0.51935599016558964), + FRAC_CONST(0.52980362468629461), + FRAC_CONST(0.54017147272989285), + FRAC_CONST(0.55045797293660481), + FRAC_CONST(0.56066157619733603), + FRAC_CONST(0.57078074588696726), + FRAC_CONST(0.58081395809576453), + FRAC_CONST(0.59075970185887416), + FRAC_CONST(0.60061647938386897), + FRAC_CONST(0.61038280627630948), + FRAC_CONST(0.6200572117632891), + FRAC_CONST(0.62963823891492698), + FRAC_CONST(0.63912444486377573), + FRAC_CONST(0.64851440102211244), + FRAC_CONST(0.65780669329707864), + FRAC_CONST(0.66699992230363747), + FRAC_CONST(0.67609270357531592), + FRAC_CONST(0.68508366777270036), + FRAC_CONST(0.693971460889654), + FRAC_CONST(0.7027547444572253), + FRAC_CONST(0.71143219574521643), + FRAC_CONST(0.72000250796138165), + FRAC_CONST(0.7284643904482252), + FRAC_CONST(0.73681656887736979), + FRAC_CONST(0.74505778544146595), + FRAC_CONST(0.75318679904361241), + FRAC_CONST(0.76120238548426178), + FRAC_CONST(0.76910333764557959), + FRAC_CONST(0.77688846567323244), + FRAC_CONST(0.78455659715557524), + FRAC_CONST(0.79210657730021239), + FRAC_CONST(0.79953726910790501), + FRAC_CONST(0.80684755354379922), + FRAC_CONST(0.8140363297059483), + FRAC_CONST(0.82110251499110465), + FRAC_CONST(0.8280450452577558), + FRAC_CONST(0.83486287498638001), + FRAC_CONST(0.84155497743689833), + FRAC_CONST(0.84812034480329712), + FRAC_CONST(0.85455798836540053), + FRAC_CONST(0.86086693863776731), + FRAC_CONST(0.86704624551569265), + FRAC_CONST(0.87309497841829009), + FRAC_CONST(0.87901222642863341), + FRAC_CONST(0.88479709843093779), + FRAC_CONST(0.89044872324475788), + FRAC_CONST(0.89596624975618511), + FRAC_CONST(0.90134884704602203), + FRAC_CONST(0.90659570451491533), + FRAC_CONST(0.91170603200542988), + FRAC_CONST(0.9166790599210427), + FRAC_CONST(0.9215140393420419), + FRAC_CONST(0.92621024213831127), + FRAC_CONST(0.93076696107898371), + FRAC_CONST(0.9351835099389475), + FRAC_CONST(0.93945922360218992), + FRAC_CONST(0.94359345816196039), + FRAC_CONST(0.94758559101774109), + FRAC_CONST(0.95143502096900834), + FRAC_CONST(0.95514116830577067), + FRAC_CONST(0.9587034748958716), + FRAC_CONST(0.96212140426904158), + FRAC_CONST(0.9653944416976894), + FRAC_CONST(0.96852209427441727), + FRAC_CONST(0.97150389098625178), + FRAC_CONST(0.97433938278557586), + FRAC_CONST(0.97702814265775439), + FRAC_CONST(0.97956976568544052), + FRAC_CONST(0.98196386910955524), + FRAC_CONST(0.98421009238692903), + FRAC_CONST(0.98630809724459867), + FRAC_CONST(0.98825756773074946), + FRAC_CONST(0.99005821026229712), + FRAC_CONST(0.99170975366909953), + FRAC_CONST(0.9932119492347945), + FRAC_CONST(0.99456457073425542), + FRAC_CONST(0.99576741446765982), + FRAC_CONST(0.99682029929116567), + FRAC_CONST(0.99772306664419164), + FRAC_CONST(0.99847558057329477), + FRAC_CONST(0.99907772775264536), + FRAC_CONST(0.99952941750109314), + FRAC_CONST(0.9998305817958234), + FRAC_CONST(0.99998117528260111) }; -real_t sine_long_960[] = { - 0x359DD, - 0xA0D97, - 0x10C14F, - 0x177504, - 0x1E28B5, - 0x24DC61, - 0x2B9006, - 0x3243A4, - 0x38F738, - 0x3FAAC3, - 0x465E43, - 0x4D11B6, - 0x53C51C, - 0x5A7873, - 0x612BBA, - 0x67DEF0, - 0x6E9214, - 0x754525, - 0x7BF821, - 0x82AB07, - 0x895DD6, - 0x90108E, - 0x96C32B, - 0x9D75AF, - 0xA42817, - 0xAADA62, - 0xB18C8F, - 0xB83E9D, - 0xBEF08A, - 0xC5A256, - 0xCC5400, - 0xD30585, - 0xD9B6E6, - 0xE06820, - 0xE71933, - 0xEDCA1D, - 0xF47ADE, - 0xFB2B74, - 0x101DBDD, - 0x1088C1A, - 0x10F3C28, - 0x115EC06, - 0x11C9BB4, - 0x1234B30, - 0x129FA78, - 0x130A98D, - 0x137586C, - 0x13E0714, - 0x144B584, - 0x14B63BC, - 0x15211B9, - 0x158BF7B, - 0x15F6D01, - 0x1661A49, - 0x16CC752, - 0x173741B, - 0x17A20A3, - 0x180CCE8, - 0x18778EA, - 0x18E24A7, - 0x194D01F, - 0x19B7B4F, - 0x1A22638, - 0x1A8D0D6, - 0x1AF7B2B, - 0x1B62533, - 0x1BCCEEF, - 0x1C3785D, - 0x1CA217B, - 0x1D0CA49, - 0x1D772C6, - 0x1DE1AF0, - 0x1E4C2C6, - 0x1EB6A47, - 0x1F21171, - 0x1F8B844, - 0x1FF5EBF, - 0x20604E0, - 0x20CAAA6, - 0x2135010, - 0x219F51D, - 0x22099CB, - 0x2273E1A, - 0x22DE208, - 0x2348595, - 0x23B28BE, - 0x241CB83, - 0x2486DE3, - 0x24F0FDC, - 0x255B16D, - 0x25C5295, - 0x262F354, - 0x26993A7, - 0x270338E, - 0x276D307, - 0x27D7212, - 0x28410AD, - 0x28AAED7, - 0x2914C8E, - 0x297E9D3, - 0x29E86A3, - 0x2A522FD, - 0x2ABBEE0, - 0x2B25A4C, - 0x2B8F53E, - 0x2BF8FB6, - 0x2C629B3, - 0x2CCC332, - 0x2D35C35, - 0x2D9F4B8, - 0x2E08CBB, - 0x2E7243D, - 0x2EDBB3D, - 0x2F451B9, - 0x2FAE7B0, - 0x3017D21, - 0x308120C, - 0x30EA66E, - 0x3153A47, - 0x31BCD96, - 0x3226058, - 0x328F28E, - 0x32F8437, - 0x3361550, - 0x33CA5D8, - 0x34335D0, - 0x349C535, - 0x3505406, - 0x356E242, - 0x35D6FE8, - 0x363FCF7, - 0x36A896E, - 0x371154C, - 0x377A08F, - 0x37E2B36, - 0x384B540, - 0x38B3EAC, - 0x391C779, - 0x3984FA6, - 0x39ED731, - 0x3A55E19, - 0x3ABE45E, - 0x3B269FE, - 0x3B8EEF8, - 0x3BF734A, - 0x3C5F6F4, - 0x3CC79F5, - 0x3D2FC4B, - 0x3D97DF6, - 0x3DFFEF3, - 0x3E67F43, - 0x3ECFEE3, - 0x3F37DD3, - 0x3F9FC11, - 0x400799D, - 0x406F675, - 0x40D7298, - 0x413EE05, - 0x41A68BB, - 0x420E2B8, - 0x4275BFD, - 0x42DD486, - 0x4344C54, - 0x43AC365, - 0x44139B8, - 0x447AF4C, - 0x44E2420, - 0x4549832, - 0x45B0B82, - 0x4617E0E, - 0x467EFD5, - 0x46E60D7, - 0x474D111, - 0x47B4084, - 0x481AF2D, - 0x4881D0B, - 0x48E8A1E, - 0x494F664, - 0x49B61DD, - 0x4A1CC86, - 0x4A83660, - 0x4AE9F68, - 0x4B5079E, - 0x4BB6F01, - 0x4C1D58F, - 0x4C83B47, - 0x4CEA029, - 0x4D50432, - 0x4DB6763, - 0x4E1C9B9, - 0x4E82B34, - 0x4EE8BD3, - 0x4F4EB94, - 0x4FB4A77, - 0x501A87A, - 0x508059C, - 0x50E61DB, - 0x514BD38, - 0x51B17B1, - 0x5217144, - 0x527C9F1, - 0x52E21B6, - 0x5347892, - 0x53ACE85, - 0x541238D, - 0x54777A9, - 0x54DCAD7, - 0x5541D18, - 0x55A6E69, - 0x560BECA, - 0x5670E39, - 0x56D5CB5, - 0x573AA3E, - 0x579F6D1, - 0x580426F, - 0x5868D16, - 0x58CD6C4, - 0x5931F79, - 0x5996734, - 0x59FADF3, - 0x5A5F3B6, - 0x5AC387B, - 0x5B27C41, - 0x5B8BF07, - 0x5BF00CC, - 0x5C54190, - 0x5CB814F, - 0x5D1C00B, - 0x5D7FDC1, - 0x5DE3A71, - 0x5E47619, - 0x5EAB0B9, - 0x5F0EA4E, - 0x5F722D9, - 0x5FD5A58, - 0x60390CA, - 0x609C62E, - 0x60FFA82, - 0x6162DC7, - 0x61C5FF9, - 0x622911A, - 0x628C126, - 0x62EF01F, - 0x6351E01, - 0x63B4ACC, - 0x6417680, - 0x647A11B, - 0x64DCA9B, - 0x653F301, - 0x65A1A4A, - 0x6604076, - 0x6666583, - 0x66C8971, - 0x672AC3F, - 0x678CDEA, - 0x67EEE73, - 0x6850DD9, - 0x68B2C19, - 0x6914934, - 0x6976527, - 0x69D7FF3, - 0x6A39995, - 0x6A9B20D, - 0x6AFC95A, - 0x6B5DF7B, - 0x6BBF46E, - 0x6C20832, - 0x6C81AC7, - 0x6CE2C2C, - 0x6D43C5F, - 0x6DA4B5F, - 0x6E0592B, - 0x6E665C2, - 0x6EC7123, - 0x6F27B4E, - 0x6F88440, - 0x6FE8BF9, - 0x7049279, - 0x70A97BC, - 0x7109BC4, - 0x7169E8E, - 0x71CA01A, - 0x722A066, - 0x7289F72, - 0x72E9D3D, - 0x73499C4, - 0x73A9508, - 0x7408F08, - 0x74687C1, - 0x74C7F34, - 0x752755F, - 0x7586A41, - 0x75E5DDA, - 0x7645027, - 0x76A4128, - 0x77030DC, - 0x7761F42, - 0x77C0C59, - 0x781F81F, - 0x787E295, - 0x78DCBB8, - 0x793B388, - 0x7999A03, - 0x79F7F29, - 0x7A562F9, - 0x7AB4571, - 0x7B12691, - 0x7B70658, - 0x7BCE4C3, - 0x7C2C1D3, - 0x7C89D87, - 0x7CE77DD, - 0x7D450D4, - 0x7DA286C, - 0x7DFFEA3, - 0x7E5D378, - 0x7EBA6EB, - 0x7F178F9, - 0x7F749A3, - 0x7FD18E7, - 0x802E6C5, - 0x808B33A, - 0x80E7E47, - 0x81447E9, - 0x81A1021, - 0x81FD6ED, - 0x8259C4C, - 0x82B603D, - 0x83122BF, - 0x836E3D1, - 0x83CA372, - 0x84261A1, - 0x8481E5D, - 0x84DD9A5, - 0x8539378, - 0x8594BD5, - 0x85F02BC, - 0x864B82A, - 0x86A6C1F, - 0x8701E9A, - 0x875CF9A, - 0x87B7F1E, - 0x8812D25, - 0x886D9AE, - 0x88C84B8, - 0x8922E42, - 0x897D64B, - 0x89D7CD2, - 0x8A321D6, - 0x8A8C556, - 0x8AE6752, - 0x8B407C7, - 0x8B9A6B5, - 0x8BF441B, - 0x8C4DFF9, - 0x8CA7A4C, - 0x8D01315, - 0x8D5AA52, - 0x8DB4002, - 0x8E0D424, - 0x8E666B8, - 0x8EBF7BB, - 0x8F1872E, - 0x8F71510, - 0x8FCA15E, - 0x9022C19, - 0x907B53F, - 0x90D3CD0, - 0x912C2CA, - 0x918472C, - 0x91DC9F6, - 0x9234B27, - 0x928CABD, - 0x92E48B7, - 0x933C516, - 0x9393FD6, - 0x93EB8F9, - 0x944307C, - 0x949A65F, - 0x94F1AA1, - 0x9548D41, - 0x959FE3E, - 0x95F6D96, - 0x964DB4A, - 0x96A4758, - 0x96FB1BE, - 0x9751A7D, - 0x97A8193, - 0x97FE700, - 0x9854AC1, - 0x98AACD7, - 0x9900D41, - 0x9956BFD, - 0x99AC90A, - 0x9A02468, - 0x9A57E15, - 0x9AAD612, - 0x9B02C5C, - 0x9B580F3, - 0x9BAD3D6, - 0x9C02503, - 0x9C5747B, - 0x9CAC23C, - 0x9D00E45, - 0x9D55895, - 0x9DAA12C, - 0x9DFE808, - 0x9E52D28, - 0x9EA708C, - 0x9EFB233, - 0x9F4F21B, - 0x9FA3044, - 0x9FF6CAD, - 0xA04A755, - 0xA09E03B, - 0xA0F175E, - 0xA144CBD, - 0xA198057, - 0xA1EB22C, - 0xA23E23A, - 0xA291080, - 0xA2E3CFF, - 0xA3367B4, - 0xA38909E, - 0xA3DB7BE, - 0xA42DD12, - 0xA480098, - 0xA4D2251, - 0xA52423C, - 0xA576056, - 0xA5C7CA0, - 0xA619719, - 0xA66AFBF, - 0xA6BC693, - 0xA70DB92, - 0xA75EEBC, - 0xA7B0010, - 0xA800F8E, - 0xA851D34, - 0xA8A2901, - 0xA8F32F5, - 0xA943B0E, - 0xA99414D, - 0xA9E45AF, - 0xAA34835, - 0xAA848DC, - 0xAAD47A5, - 0xAB2448E, - 0xAB73F97, - 0xABC38BF, - 0xAC13004, - 0xAC62566, - 0xACB18E5, - 0xAD00A7E, - 0xAD4FA32, - 0xAD9E7FF, - 0xADED3E5, - 0xAE3BDE3, - 0xAE8A5F7, - 0xAED8C22, - 0xAF27061, - 0xAF752B5, - 0xAFC331D, - 0xB011196, - 0xB05EE22, - 0xB0AC8BE, - 0xB0FA16B, - 0xB147827, - 0xB194CF1, - 0xB1E1FC8, - 0xB22F0AC, - 0xB27BF9C, - 0xB2C8C97, - 0xB31579B, - 0xB3620AA, - 0xB3AE7C0, - 0xB3FACDE, - 0xB447003, - 0xB49312E, - 0xB4DF05D, - 0xB52AD91, - 0xB5768C9, - 0xB5C2203, - 0xB60D93E, - 0xB658E7B, - 0xB6A41B8, - 0xB6EF2F4, - 0xB73A22E, - 0xB784F66, - 0xB7CFA9B, - 0xB81A3CC, - 0xB864AF8, - 0xB8AF01E, - 0xB8F933E, - 0xB943456, - 0xB98D367, - 0xB9D706E, - 0xBA20B6C, - 0xBA6A45F, - 0xBAB3B47, - 0xBAFD023, - 0xBB462F2, - 0xBB8F3B3, - 0xBBD8266, - 0xBC20F09, - 0xBC6999C, - 0xBCB221E, - 0xBCFA88F, - 0xBD42CED, - 0xBD8AF37, - 0xBDD2F6E, - 0xBE1AD8F, - 0xBE6299B, - 0xBEAA390, - 0xBEF1B6E, - 0xBF39135, - 0xBF804E2, - 0xBFC7675, - 0xC00E5EF, - 0xC05534D, - 0xC09BE8F, - 0xC0E27B4, - 0xC128EBC, - 0xC16F3A6, - 0xC1B5670, - 0xC1FB71B, - 0xC2415A5, - 0xC28720E, - 0xC2CCC55, - 0xC312479, - 0xC357A79, - 0xC39CE55, - 0xC3E200C, - 0xC426F9C, - 0xC46BD06, - 0xC4B0849, - 0xC4F5164, - 0xC539855, - 0xC57DD1D, - 0xC5C1FBB, - 0xC60602D, - 0xC649E73, - 0xC68DA8D, - 0xC6D1479, - 0xC714C37, - 0xC7581C7, - 0xC79B526, - 0xC7DE656, - 0xC821554, - 0xC864220, - 0xC8A6CBA, - 0xC8E9520, - 0xC92BB53, - 0xC96DF50, - 0xC9B0119, - 0xC9F20AB, - 0xCA33E06, - 0xCA75929, - 0xCAB7214, - 0xCAF88C6, - 0xCB39D3E, - 0xCB7AF7C, - 0xCBBBF7E, - 0xCBFCD44, - 0xCC3D8CE, - 0xCC7E21B, - 0xCCBE929, - 0xCCFEDF8, - 0xCD3F088, - 0xCD7F0D8, - 0xCDBEEE7, - 0xCDFEAB4, - 0xCE3E43F, - 0xCE7DB87, - 0xCEBD08B, - 0xCEFC34B, - 0xCF3B3C6, - 0xCF7A1FB, - 0xCFB8DEA, - 0xCFF7791, - 0xD035EF1, - 0xD074408, - 0xD0B26D6, - 0xD0F075A, - 0xD12E593, - 0xD16C181, - 0xD1A9B24, - 0xD1E7279, - 0xD224782, - 0xD261A3C, - 0xD29EAA8, - 0xD2DB8C5, - 0xD318491, - 0xD354E0D, - 0xD391538, - 0xD3CDA11, - 0xD409C97, - 0xD445CCA, - 0xD481AA8, - 0xD4BD633, - 0xD4F8F68, - 0xD534647, - 0xD56FAD0, - 0xD5AAD01, - 0xD5E5CDB, - 0xD620A5C, - 0xD65B584, - 0xD695E53, - 0xD6D04C6, - 0xD70A8DF, - 0xD744A9C, - 0xD77E9FD, - 0xD7B8701, - 0xD7F21A7, - 0xD82B9EF, - 0xD864FD8, - 0xD89E362, - 0xD8D748B, - 0xD910354, - 0xD948FBB, - 0xD9819C1, - 0xD9BA163, - 0xD9F26A3, - 0xDA2A97F, - 0xDA629F6, - 0xDA9A808, - 0xDAD23B4, - 0xDB09CFA, - 0xDB413DA, - 0xDB78851, - 0xDBAFA61, - 0xDBE6A07, - 0xDC1D745, - 0xDC54218, - 0xDC8AA81, - 0xDCC107F, - 0xDCF7411, - 0xDD2D537, - 0xDD633F0, - 0xDD9903B, - 0xDDCEA18, - 0xDE04187, - 0xDE39686, - 0xDE6E916, - 0xDEA3934, - 0xDED86E2, - 0xDF0D21F, - 0xDF41AE9, - 0xDF76140, - 0xDFAA524, - 0xDFDE694, - 0xE012590, - 0xE046217, - 0xE079C28, - 0xE0AD3C2, - 0xE0E08E6, - 0xE113B93, - 0xE146BC8, - 0xE179984, - 0xE1AC4C8, - 0xE1DED92, - 0xE2113E2, - 0xE2437B7, - 0xE275911, - 0xE2A77EF, - 0xE2D9451, - 0xE30AE36, - 0xE33C59E, - 0xE36DA87, - 0xE39ECF3, - 0xE3CFCDF, - 0xE400A4B, - 0xE431538, - 0xE461DA4, - 0xE49238F, - 0xE4C26F8, - 0xE4F27DF, - 0xE522643, - 0xE552224, - 0xE581B82, - 0xE5B125A, - 0xE5E06AE, - 0xE60F87D, - 0xE63E7C6, - 0xE66D488, - 0xE69BEC4, - 0xE6CA678, - 0xE6F8BA4, - 0xE726E48, - 0xE754E63, - 0xE782BF5, - 0xE7B06FC, - 0xE7DDF79, - 0xE80B56C, - 0xE8388D2, - 0xE8659AD, - 0xE8927FC, - 0xE8BF3BD, - 0xE8EBCF1, - 0xE918397, - 0xE9447AF, - 0xE970938, - 0xE99C832, - 0xE9C849C, - 0xE9F3E75, - 0xEA1F5BE, - 0xEA4AA75, - 0xEA75C9B, - 0xEAA0C2E, - 0xEACB92F, - 0xEAF639D, - 0xEB20B77, - 0xEB4B0BD, - 0xEB7536E, - 0xEB9F38B, - 0xEBC9111, - 0xEBF2C02, - 0xEC1C45D, - 0xEC45A21, - 0xEC6ED4D, - 0xEC97DE2, - 0xECC0BDE, - 0xECE9742, - 0xED1200D, - 0xED3A63E, - 0xED629D5, - 0xED8AAD2, - 0xEDB2934, - 0xEDDA4FB, - 0xEE01E25, - 0xEE294B4, - 0xEE508A6, - 0xEE779FB, - 0xEE9E8B3, - 0xEEC54CD, - 0xEEEBE48, - 0xEF12525, - 0xEF38962, - 0xEF5EB00, - 0xEF849FE, - 0xEFAA65C, - 0xEFD0018, - 0xEFF5734, - 0xF01ABAE, - 0xF03FD85, - 0xF064CBB, - 0xF08994D, - 0xF0AE33C, - 0xF0D2A88, - 0xF0F6F2F, - 0xF11B132, - 0xF13F090, - 0xF162D49, - 0xF18675C, - 0xF1A9EC9, - 0xF1CD390, - 0xF1F05AF, - 0xF213528, - 0xF2361F9, - 0xF258C22, - 0xF27B3A3, - 0xF29D87B, - 0xF2BFAAA, - 0xF2E1A2F, - 0xF30370B, - 0xF32513C, - 0xF3468C3, - 0xF367D9E, - 0xF388FCF, - 0xF3A9F54, - 0xF3CAC2C, - 0xF3EB658, - 0xF40BDD8, - 0xF42C2AA, - 0xF44C4CF, - 0xF46C446, - 0xF48C10F, - 0xF4ABB2A, - 0xF4CB295, - 0xF4EA751, - 0xF50995E, - 0xF5288BB, - 0xF547567, - 0xF565F63, - 0xF5846AE, - 0xF5A2B48, - 0xF5C0D30, - 0xF5DEC67, - 0xF5FC8EB, - 0xF61A2BC, - 0xF6379DB, - 0xF654E46, - 0xF671FFE, - 0xF68EF02, - 0xF6ABB52, - 0xF6C84ED, - 0xF6E4BD3, - 0xF701005, - 0xF71D181, - 0xF739047, - 0xF754C57, - 0xF7705B1, - 0xF78BC54, - 0xF7A7040, - 0xF7C2175, - 0xF7DCFF3, - 0xF7F7BB8, - 0xF8124C6, - 0xF82CB1B, - 0xF846EB7, - 0xF860F9A, - 0xF87ADC4, - 0xF894935, - 0xF8AE1EB, - 0xF8C77E8, - 0xF8E0B2A, - 0xF8F9BB1, - 0xF91297E, - 0xF92B48F, - 0xF943CE4, - 0xF95C27E, - 0xF97455C, - 0xF98C57E, - 0xF9A42E3, - 0xF9BBD8B, - 0xF9D3576, - 0xF9EAAA3, - 0xFA01D14, - 0xFA18CC6, - 0xFA2F9BA, - 0xFA463F0, - 0xFA5CB67, - 0xFA7301F, - 0xFA89218, - 0xFA9F152, - 0xFAB4DCC, - 0xFACA787, - 0xFADFE81, - 0xFAF52BB, - 0xFB0A435, - 0xFB1F2EE, - 0xFB33EE6, - 0xFB4881C, - 0xFB5CE91, - 0xFB71245, - 0xFB85337, - 0xFB99166, - 0xFBACCD3, - 0xFBC057E, - 0xFBD3B66, - 0xFBE6E8B, - 0xFBF9EEC, - 0xFC0CC8B, - 0xFC1F766, - 0xFC31F7D, - 0xFC444CF, - 0xFC5675E, - 0xFC68729, - 0xFC7A42E, - 0xFC8BE6F, - 0xFC9D5EB, - 0xFCAEAA2, - 0xFCBFC94, - 0xFCD0BBF, - 0xFCE1826, - 0xFCF21C6, - 0xFD028A0, - 0xFD12CB4, - 0xFD22E01, - 0xFD32C88, - 0xFD42848, - 0xFD52141, - 0xFD61772, - 0xFD70ADD, - 0xFD7FB80, - 0xFD8E95B, - 0xFD9D46E, - 0xFDABCBA, - 0xFDBA23D, - 0xFDC84F8, - 0xFDD64EB, - 0xFDE4214, - 0xFDF1C76, - 0xFDFF40E, - 0xFE0C8DD, - 0xFE19AE3, - 0xFE26A20, - 0xFE33693, - 0xFE4003C, - 0xFE4C71C, - 0xFE58B32, - 0xFE64C7E, - 0xFE70AFF, - 0xFE7C6B7, - 0xFE87FA4, - 0xFE935C6, - 0xFE9E91E, - 0xFEA99AA, - 0xFEB476C, - 0xFEBF263, - 0xFEC9A8F, - 0xFED3FEF, - 0xFEDE284, - 0xFEE824E, - 0xFEF1F4C, - 0xFEFB97E, - 0xFF050E4, - 0xFF0E57F, - 0xFF1774D, - 0xFF2064F, - 0xFF29286, - 0xFF31BEF, - 0xFF3A28D, - 0xFF4265D, - 0xFF4A761, - 0xFF52599, - 0xFF5A104, - 0xFF619A2, - 0xFF68F72, - 0xFF70276, - 0xFF772AD, - 0xFF7E017, - 0xFF84AB3, - 0xFF8B282, - 0xFF91784, - 0xFF979B8, - 0xFF9D91E, - 0xFFA35B7, - 0xFFA8F83, - 0xFFAE680, - 0xFFB3AB0, - 0xFFB8C12, - 0xFFBDAA6, - 0xFFC266C, - 0xFFC6F64, - 0xFFCB58E, - 0xFFCF8EA, - 0xFFD3978, - 0xFFD7738, - 0xFFDB229, - 0xFFDEA4C, - 0xFFE1FA1, - 0xFFE5227, - 0xFFE81DF, - 0xFFEAEC9, - 0xFFED8E4, - 0xFFF0030, - 0xFFF24AF, - 0xFFF465E, - 0xFFF653F, - 0xFFF8152, - 0xFFF9A96, - 0xFFFB10B, - 0xFFFC4B2, - 0xFFFD58A, - 0xFFFE393, - 0xFFFEECE, - 0xFFFF73A, - 0xFFFFCD7, - 0xFFFFFA6 -}; - -real_t sine_short_128[] = -{ - 0x1921F1, - 0x4B64DB, - 0x7DA4DD, - 0xAFE006, - 0xE21468, - 0x1144013, - 0x1466118, - 0x1787587, - 0x1AA7B73, - 0x1DC70ED, - 0x20E5409, - 0x24022DB, - 0x271DB77, - 0x2A37BF1, - 0x2D50261, - 0x3066CDE, - 0x337B97F, - 0x368E65F, - 0x399F198, - 0x3CAD945, - 0x3FB9B85, - 0x42C3675, - 0x45CA837, - 0x48CEEED, - 0x4BD08B8, - 0x4ECF3C0, - 0x51CAE2B, - 0x54C3622, - 0x57B89D0, - 0x5AAA761, - 0x5D98D06, - 0x60838EE, - 0x636A94E, - 0x664DC5B, - 0x692D04C, - 0x6C0835E, - 0x6EDF3CB, - 0x71B1FD5, - 0x74805BD, - 0x774A3C8, - 0x7A0F83E, - 0x7CD0168, - 0x7F8BD96, - 0x8242B16, - 0x84F483D, - 0x87A1361, - 0x8A48ADB, - 0x8CEAD08, - 0x8F87849, - 0x921EB01, - 0x94B0397, - 0x973C075, - 0x99C200A, - 0x9C420C6, - 0x9EBC120, - 0xA12FF8F, - 0xA39DA91, - 0xA6050A6, - 0xA866053, - 0xAAC0820, - 0xAD14699, - 0xAF61A4E, - 0xB1A81D5, - 0xB3E7BC6, - 0xB6206BE, - 0xB85215D, - 0xBA7CA4B, - 0xBCA002F, - 0xBEBC1BA, - 0xC0D0D9E, - 0xC2DE291, - 0xC4E3F51, - 0xC6E229D, - 0xC8D8B3C, - 0xCAC77F6, - 0xCCAE79B, - 0xCE8D8FF, - 0xD064AF9, - 0xD233C68, - 0xD3FAC2D, - 0xD5B9930, - 0xD77025E, - 0xD91E6A7, - 0xDAC4503, - 0xDC61C6D, - 0xDDF6BE6, - 0xDF83274, - 0xE106F23, - 0xE282104, - 0xE3F472C, - 0xE55E0B8, - 0xE6BECC8, - 0xE816A82, - 0xE965913, - 0xEAAB7AC, - 0xEBE8584, - 0xED1C1D8, - 0xEE46BE8, - 0xEF682FF, - 0xF080668, - 0xF18F577, - 0xF294F85, - 0xF3913F0, - 0xF48421D, - 0xF56D977, - 0xF64D96C, - 0xF724173, - 0xF7F1108, - 0xF8B47AC, - 0xF96E4E6, - 0xFA1E845, - 0xFAC515A, - 0xFB61FC0, - 0xFBF5316, - 0xFC7EB01, - 0xFCFE72C, - 0xFD74748, - 0xFDE0B0D, - 0xFE43237, - 0xFE9BC8B, - 0xFEEA9D0, - 0xFF2F9D8, - 0xFF6AC77, - 0xFF9C188, - 0xFFC38ED, - 0xFFE128F, - 0xFFF4E5A, - 0xFFFEC42 -}; - -real_t sine_short_120[] = +#ifdef ALLOW_SMALL_FRAMELENGTH +ALIGN static const real_t sine_short_120[] = { - 0x1ACEDD, - 0x506B6B, - 0x860472, - 0xBB9798, - 0xF12283, - 0x126A2DB, - 0x15C1646, - 0x1917A6C, - 0x1C6CCF6, - 0x1FC0B8D, - 0x23133DB, - 0x266438B, - 0x29B3849, - 0x2D00FC3, - 0x304C7A8, - 0x3395DA6, - 0x36DCF70, - 0x3A21AB9, - 0x3D63D36, - 0x40A349D, - 0x43DFEA6, - 0x471990D, - 0x4A5018D, - 0x4D835E6, - 0x50B33D8, - 0x53DF927, - 0x5708398, - 0x5A2D0F4, - 0x5D4DF07, - 0x606AB9E, - 0x638348A, - 0x669779E, - 0x69A72B2, - 0x6CB23A0, - 0x6FB8844, - 0x72B9E80, - 0x75B6437, - 0x78AD751, - 0x7B9F5B9, - 0x7E8BD5E, - 0x8172C33, - 0x845402D, - 0x872F749, - 0x8A04F85, - 0x8CD46E2, - 0x8F9DB69, - 0x9260B25, - 0x951D425, - 0x97D347F, - 0x9A82A4A, - 0x9D2B3A4, - 0x9FCCEB1, - 0xA267996, - 0xA4FB280, - 0xA7877A1, - 0xAA0C72E, - 0xAC89F62, - 0xAEFFE7F, - 0xB16E2CA, - 0xB3D4A8E, - 0xB63341D, - 0xB889DCC, - 0xBAD85F7, - 0xBD1EB00, - 0xBF5CB4E, - 0xC19254F, - 0xC3BF775, - 0xC5E4039, - 0xC7FFE1B, - 0xCA12F9F, - 0xCC1D351, - 0xCE1E7C2, - 0xD016B8A, - 0xD205D47, - 0xD3EBB9E, - 0xD5C8539, - 0xD79B8CB, - 0xD96550A, - 0xDB258B7, - 0xDCDC296, - 0xDE89173, - 0xE02C422, - 0xE1C597C, - 0xE355062, - 0xE4DA7BC, - 0xE655E78, - 0xE7C738C, - 0xE92E5F5, - 0xEA8B4B7, - 0xEBDDEDD, - 0xED26379, - 0xEE641A4, - 0xEF97881, - 0xF0C0736, - 0xF1DECF4, - 0xF2F28F2, - 0xF3FBA6E, - 0xF4FA0AE, - 0xF5EDAFF, - 0xF6D68B7, - 0xF7B4932, - 0xF887BD4, - 0xF950009, - 0xFA0D544, - 0xFABFB02, - 0xFB670C3, - 0xFC03614, - 0xFC94A86, - 0xFD1ADB3, - 0xFD95F3E, - 0xFE05ECF, - 0xFE6AC18, - 0xFEC46D2, - 0xFF12EC0, - 0xFF563A8, - 0xFF8E55C, - 0xFFBB3B6, - 0xFFDCE94, - 0xFFF35E0, - 0xFFFE98A + FRAC_CONST(0.0065449379673518581), + FRAC_CONST(0.019633692460628301), + FRAC_CONST(0.032719082821776137), + FRAC_CONST(0.045798866936520771), + FRAC_CONST(0.058870803651189033), + FRAC_CONST(0.071932653156719387), + FRAC_CONST(0.084982177372441667), + FRAC_CONST(0.09801714032956059), + FRAC_CONST(0.11103530855427769), + FRAC_CONST(0.12403445145048532), + FRAC_CONST(0.13701234168196802), + FRAC_CONST(0.14996675555404498), + FRAC_CONST(0.16289547339458874), + FRAC_CONST(0.17579627993435451), + FRAC_CONST(0.18866696468655525), + FRAC_CONST(0.2015053223256171), + FRAC_CONST(0.21430915306505074), + FRAC_CONST(0.2270762630343732), + FRAC_CONST(0.23980446465501654), + FRAC_CONST(0.25249157701515795), + FRAC_CONST(0.26513542624340797), + FRAC_CONST(0.27773384588129219), + FRAC_CONST(0.29028467725446233), + FRAC_CONST(0.3027857698425746), + FRAC_CONST(0.31523498164776964), + FRAC_CONST(0.32763017956169349), + FRAC_CONST(0.33996923973099424), + FRAC_CONST(0.35225004792123354), + FRAC_CONST(0.36447049987914965), + FRAC_CONST(0.37662850169321077), + FRAC_CONST(0.38872197015239557), + FRAC_CONST(0.40074883310314097), + FRAC_CONST(0.41270702980439467), + FRAC_CONST(0.42459451128071307), + FRAC_CONST(0.43640924067334208), + FRAC_CONST(0.44814919358922256), + FRAC_CONST(0.45981235844785984), + FRAC_CONST(0.47139673682599764), + FRAC_CONST(0.48290034380003727), + FRAC_CONST(0.49432120828614462), + FRAC_CONST(0.50565737337798455), + FRAC_CONST(0.51690689668202761), + FRAC_CONST(0.52806785065036799), + FRAC_CONST(0.53913832291100017), + FRAC_CONST(0.55011641659549337), + FRAC_CONST(0.56100025066400983), + FRAC_CONST(0.57178796022761225), + FRAC_CONST(0.58247769686780215), + FRAC_CONST(0.59306762895323706), + FRAC_CONST(0.60355594195357143), + FRAC_CONST(0.61394083875036642), + FRAC_CONST(0.62422053994501758), + FRAC_CONST(0.63439328416364549), + FRAC_CONST(0.64445732835889735), + FRAC_CONST(0.65441094810861034), + FRAC_CONST(0.66425243791128175), + FRAC_CONST(0.67398011147829784), + FRAC_CONST(0.68359230202287125), + FRAC_CONST(0.69308736254563585), + FRAC_CONST(0.70246366611685174), + FRAC_CONST(0.71171960615517138), + FRAC_CONST(0.72085359670291882), + FRAC_CONST(0.7298640726978356), + FRAC_CONST(0.73874949024124625), + FRAC_CONST(0.74750832686259672), + FRAC_CONST(0.75613908178032285), + FRAC_CONST(0.76464027615900032), + FRAC_CONST(0.77301045336273699), + FRAC_CONST(0.78124817920475853), + FRAC_CONST(0.78935204219315003), + FRAC_CONST(0.79732065377270711), + FRAC_CONST(0.80515264856285829), + FRAC_CONST(0.81284668459161513), + FRAC_CONST(0.82040144352551359), + FRAC_CONST(0.82781563089550203), + FRAC_CONST(0.83508797631874299), + FRAC_CONST(0.84221723371628654), + FRAC_CONST(0.84920218152657889), + FRAC_CONST(0.85604162291477137), + FRAC_CONST(0.86273438597779184), + FRAC_CONST(0.86927932394514362), + FRAC_CONST(0.87567531537539967), + FRAC_CONST(0.88192126434835494), + FRAC_CONST(0.88801610065280734), + FRAC_CONST(0.89395877996993212), + FRAC_CONST(0.8997482840522214), + FRAC_CONST(0.90538362089795521), + FRAC_CONST(0.91086382492117568), + FRAC_CONST(0.91618795711713596), + FRAC_CONST(0.92135510522319242), + FRAC_CONST(0.9263643838751181), + FRAC_CONST(0.93121493475880346), + FRAC_CONST(0.93590592675732565), + FRAC_CONST(0.94043655609335486), + FRAC_CONST(0.94480604646687805), + FRAC_CONST(0.94901364918821385), + FRAC_CONST(0.95305864330629697), + FRAC_CONST(0.95694033573220882), + FRAC_CONST(0.9606580613579353), + FRAC_CONST(0.96421118317032928), + FRAC_CONST(0.96759909236025976), + FRAC_CONST(0.9708212084269281), + FRAC_CONST(0.97387697927733363), + FRAC_CONST(0.97676588132087239), + FRAC_CONST(0.97948741955905139), + FRAC_CONST(0.98204112767030394), + FRAC_CONST(0.98442656808989171), + FRAC_CONST(0.98664333208487898), + FRAC_CONST(0.98869103982416728), + FRAC_CONST(0.99056934044357725), + FRAC_CONST(0.99227791210596705), + FRAC_CONST(0.99381646205637808), + FRAC_CONST(0.99518472667219682), + FRAC_CONST(0.99638247150832537), + FRAC_CONST(0.99740949133735191), + FRAC_CONST(0.99826561018471593), + FRAC_CONST(0.99895068135886012), + FRAC_CONST(0.99946458747636568), + FRAC_CONST(0.99980724048206482), + FRAC_CONST(0.99997858166412923) }; +#endif #ifdef LD_DEC -real_t sine_mid_512[] = +ALIGN static const real_t sine_mid_512[] = { - 0x6487E, - 0x12D978, - 0x1F6A66, - 0x2BFB40, - 0x388BFF, - 0x451C9C, - 0x51AD0E, - 0x5E3D4D, - 0x6ACD52, - 0x775D16, - 0x83EC90, - 0x907BB8, - 0x9D0A87, - 0xA998F6, - 0xB626FC, - 0xC2B491, - 0xCF41AF, - 0xDBCE4C, - 0xE85A62, - 0xF4E5E9, - 0x10170D8, - 0x10DFB29, - 0x11A84D3, - 0x1270DCF, - 0x1339615, - 0x1401D9D, - 0x14CA460, - 0x1592A55, - 0x165AF76, - 0x17233BA, - 0x17EB71A, - 0x18B398D, - 0x197BB0D, - 0x1A43B91, - 0x1B0BB12, - 0x1BD3988, - 0x1C9B6EC, - 0x1D63335, - 0x1E2AE5C, - 0x1EF2859, - 0x1FBA125, - 0x20818B8, - 0x2148F0A, - 0x2210413, - 0x22D77CC, - 0x239EA2E, - 0x2465B30, - 0x252CACA, - 0x25F38F6, - 0x26BA5AB, - 0x27810E2, - 0x2847A93, - 0x290E2B6, - 0x29D4945, - 0x2A9AE36, - 0x2B61183, - 0x2C27324, - 0x2CED311, - 0x2DB3142, - 0x2E78DB1, - 0x2F3E855, - 0x3004126, - 0x30C981E, - 0x318ED34, - 0x3254061, - 0x331919E, - 0x33DE0E2, - 0x34A2E26, - 0x3567963, - 0x362C290, - 0x36F09A7, - 0x37B4EA0, - 0x3879173, - 0x393D218, - 0x3A01089, - 0x3AC4CBD, - 0x3B886AD, - 0x3C4BE51, - 0x3D0F3A3, - 0x3DD269A, - 0x3E9572E, - 0x3F58559, - 0x401B113, - 0x40DDA54, - 0x41A0115, - 0x426254E, - 0x43246F8, - 0x43E660B, - 0x44A8280, - 0x4569C50, - 0x462B372, - 0x46EC7E0, - 0x47AD992, - 0x486E881, - 0x492F4A5, - 0x49EFDF6, - 0x4AB046D, - 0x4B70804, - 0x4C308B2, - 0x4CF0670, - 0x4DB0136, - 0x4E6F8FE, - 0x4F2EDC0, - 0x4FEDF74, - 0x50ACE13, - 0x516B996, - 0x522A1F6, - 0x52E872B, - 0x53A692D, - 0x54647F6, - 0x552237D, - 0x55DFBBD, - 0x569D0AD, - 0x575A246, - 0x5817081, - 0x58D3B57, - 0x59902C0, - 0x5A4C6B5, - 0x5B0872F, - 0x5BC4426, - 0x5C7FD93, - 0x5D3B370, - 0x5DF65B5, - 0x5EB145A, - 0x5F6BF58, - 0x60266A9, - 0x60E0A45, - 0x619AA25, - 0x6254641, - 0x630DE93, - 0x63C7313, - 0x64803BB, - 0x6539083, - 0x65F1963, - 0x66A9E56, - 0x6761F53, - 0x6819C54, - 0x68D1551, - 0x6988A44, - 0x6A3FB25, - 0x6AF67EE, - 0x6BAD097, - 0x6C63519, - 0x6D1956E, - 0x6DCF18E, - 0x6E84972, - 0x6F39D13, - 0x6FEEC6B, - 0x70A3771, - 0x7157E20, - 0x720C071, - 0x72BFE5C, - 0x73737DA, - 0x7426CE5, - 0x74D9D75, - 0x758C985, - 0x763F10C, - 0x76F1404, - 0x77A3266, - 0x7854C2B, - 0x790614D, - 0x79B71C4, - 0x7A67D8A, - 0x7B18498, - 0x7BC86E7, - 0x7C78470, - 0x7D27D2D, - 0x7DD7116, - 0x7E86026, - 0x7F34A55, - 0x7FE2F9C, - 0x8090FF5, - 0x813EB5A, - 0x81EC1C2, - 0x8299329, - 0x8345F86, - 0x83F26D4, - 0x849E90C, - 0x854A626, - 0x85F5E1E, - 0x86A10EB, - 0x874BE87, - 0x87F66EC, - 0x88A0A13, - 0x894A7F5, - 0x89F408D, - 0x8A9D3D3, - 0x8B461C1, - 0x8BEEA51, - 0x8C96D7B, - 0x8D3EB3A, - 0x8DE6386, - 0x8E8D65B, - 0x8F343B0, - 0x8FDAB80, - 0x9080DC4, - 0x9126A76, - 0x91CC190, - 0x927130A, - 0x9315EDF, - 0x93BA509, - 0x945E580, - 0x950203F, - 0x95A5540, - 0x964847B, - 0x96EADEB, - 0x978D18A, - 0x982EF51, - 0x98D073A, - 0x997193F, - 0x9A12559, - 0x9AB2B83, - 0x9B52BB6, - 0x9BF25EC, - 0x9C91A1F, - 0x9D30849, - 0x9DCF063, - 0x9E6D267, - 0x9F0AE51, - 0x9FA8418, - 0xA0453B8, - 0xA0E1D29, - 0xA17E067, - 0xA219D6B, - 0xA2B5430, - 0xA3504AE, - 0xA3EAEE1, - 0xA4852C1, - 0xA51F04A, - 0xA5B8776, - 0xA65183E, - 0xA6EA29C, - 0xA78268B, - 0xA81A404, - 0xA8B1B03, - 0xA948B80, - 0xA9DF577, - 0xAA758E1, - 0xAB0B5B9, - 0xABA0BF9, - 0xAC35B9B, - 0xACCA499, - 0xAD5E6EE, - 0xADF2293, - 0xAE85784, - 0xAF185BB, - 0xAFAAD31, - 0xB03CDE2, - 0xB0CE7C7, - 0xB15FADB, - 0xB1F0719, - 0xB280C7A, - 0xB310AFA, - 0xB3A0292, - 0xB42F33E, - 0xB4BDCF7, - 0xB54BFB8, - 0xB5D9B7C, - 0xB66703D, - 0xB6F3DF6, - 0xB7804A2, - 0xB80C43A, - 0xB897CBA, - 0xB922E1C, - 0xB9AD85A, - 0xBA37B70, - 0xBAC1759, - 0xBB4AC0E, - 0xBBD398A, - 0xBC5BFC9, - 0xBCE3EC4, - 0xBD6B678, - 0xBDF26DE, - 0xBE78FF1, - 0xBEFF1AC, - 0xBF84C0B, - 0xC009F07, - 0xC08EA9C, - 0xC112EC4, - 0xC196B7B, - 0xC21A0BB, - 0xC29CE7F, - 0xC31F4C3, - 0xC3A1380, - 0xC422AB3, - 0xC4A3A57, - 0xC524265, - 0xC5A42DA, - 0xC623BB0, - 0xC6A2CE3, - 0xC72166D, - 0xC79F84A, - 0xC81D274, - 0xC89A4E8, - 0xC916FA0, - 0xC993297, - 0xCA0EDC8, - 0xCA8A130, - 0xCB04CC8, - 0xCB7F08D, - 0xCBF8C79, - 0xCC72088, - 0xCCEACB5, - 0xCD630FC, - 0xCDDAD58, - 0xCE521C4, - 0xCEC8E3C, - 0xCF3F2BB, - 0xCFB4F3C, - 0xD02A3BB, - 0xD09F034, - 0xD1134A2, - 0xD187101, - 0xD1FA54B, - 0xD26D17D, - 0xD2DF593, - 0xD351187, - 0xD3C2555, - 0xD4330FA, - 0xD4A3470, - 0xD512FB3, - 0xD5822C0, - 0xD5F0D91, - 0xD65F023, - 0xD6CCA71, - 0xD739C77, - 0xD7A6631, - 0xD81279A, - 0xD87E0AF, - 0xD8E916B, - 0xD9539CB, - 0xD9BD9C9, - 0xDA27163, - 0xDA90093, - 0xDAF8757, - 0xDB605A9, - 0xDBC7B86, - 0xDC2E8E9, - 0xDC94DD0, - 0xDCFAA36, - 0xDD5FE17, - 0xDDC496E, - 0xDE28C39, - 0xDE8C674, - 0xDEEF81A, - 0xDF52127, - 0xDFB4199, - 0xE01596B, - 0xE076899, - 0xE0D6F20, - 0xE136CFB, - 0xE196228, - 0xE1F4EA3, - 0xE253267, - 0xE2B0D72, - 0xE30DFBF, - 0xE36A94B, - 0xE3C6A13, - 0xE422213, - 0xE47D147, - 0xE4D77AC, - 0xE53153F, - 0xE58A9FB, - 0xE5E35DE, - 0xE63B8E4, - 0xE69330A, - 0xE6EA44C, - 0xE740CA7, - 0xE796C18, - 0xE7EC29B, - 0xE84102D, - 0xE8954CB, - 0xE8E9071, - 0xE93C31D, - 0xE98ECCA, - 0xE9E0D77, - 0xEA3251F, - 0xEA833C0, - 0xEAD3956, - 0xEB235DF, - 0xEB72956, - 0xEBC13BB, - 0xEC0F508, - 0xEC5CD3B, - 0xECA9C52, - 0xECF6249, - 0xED41F1D, - 0xED8D2CC, - 0xEDD7D52, - 0xEE21EAC, - 0xEE6B6D9, - 0xEEB45D4, - 0xEEFCB9B, - 0xEF4482C, - 0xEF8BB83, - 0xEFD259E, - 0xF01867A, - 0xF05DE14, - 0xF0A2C6A, - 0xF0E7179, - 0xF12AD3E, - 0xF16DFB8, - 0xF1B08E2, - 0xF1F28BB, - 0xF233F40, - 0xF274C6F, - 0xF2B5044, - 0xF2F4ABF, - 0xF333BDB, - 0xF372397, - 0xF3B01F0, - 0xF3ED6E5, - 0xF42A271, - 0xF466494, - 0xF4A1D4B, - 0xF4DCC94, - 0xF51726B, - 0xF550ED0, - 0xF58A1C0, - 0xF5C2B38, - 0xF5FAB37, - 0xF6321BA, - 0xF668EBF, - 0xF69F244, - 0xF6D4C47, - 0xF709CC6, - 0xF73E3BF, - 0xF77212F, - 0xF7A5516, - 0xF7D7F70, - 0xF80A03C, - 0xF83B778, - 0xF86C522, - 0xF89C939, - 0xF8CC3B9, - 0xF8FB4A2, - 0xF929BF2, - 0xF9579A7, - 0xF984DBE, - 0xF9B1837, - 0xF9DD910, - 0xFA09047, - 0xFA33DDA, - 0xFA5E1C7, - 0xFA87C0D, - 0xFAB0CAB, - 0xFAD939F, - 0xFB010E6, - 0xFB28481, - 0xFB4EE6D, - 0xFB74EA8, - 0xFB9A532, - 0xFBBF208, - 0xFBE352A, - 0xFC06E95, - 0xFC29E4A, - 0xFC4C445, - 0xFC6E087, - 0xFC8F30D, - 0xFCAFBD6, - 0xFCCFAE1, - 0xFCEF02E, - 0xFD0DBBA, - 0xFD2BD84, - 0xFD4958C, - 0xFD663D0, - 0xFD8284F, - 0xFD9E308, - 0xFDB93FA, - 0xFDD3B23, - 0xFDED884, - 0xFE06C1A, - 0xFE1F5E5, - 0xFE375E5, - 0xFE4EC17, - 0xFE6587B, - 0xFE7BB10, - 0xFE913D6, - 0xFEA62CB, - 0xFEBA7EF, - 0xFECE341, - 0xFEE14C0, - 0xFEF3C6C, - 0xFF05A43, - 0xFF16E45, - 0xFF27872, - 0xFF378C8, - 0xFF46F48, - 0xFF55BF0, - 0xFF63EC0, - 0xFF717B7, - 0xFF7E6D5, - 0xFF8AC1A, - 0xFF96785, - 0xFFA1915, - 0xFFAC0CA, - 0xFFB5EA3, - 0xFFBF2A1, - 0xFFC7CC3, - 0xFFCFD08, - 0xFFD7371, - 0xFFDDFFC, - 0xFFE42AA, - 0xFFE9B7B, - 0xFFEEA6E, - 0xFFF2F83, - 0xFFF6AB9, - 0xFFF9C12, - 0xFFFC38C, - 0xFFFE128, - 0xFFFF4E5, - 0xFFFFEC4 + FRAC_CONST(0.0015339801862847655), + FRAC_CONST(0.0046019261204485705), + FRAC_CONST(0.007669828739531097), + FRAC_CONST(0.010737659167264491), + FRAC_CONST(0.013805388528060391), + FRAC_CONST(0.01687298794728171), + FRAC_CONST(0.019940428551514441), + FRAC_CONST(0.023007681468839369), + FRAC_CONST(0.026074717829103901), + FRAC_CONST(0.029141508764193722), + FRAC_CONST(0.032208025408304586), + FRAC_CONST(0.035274238898213947), + FRAC_CONST(0.038340120373552694), + FRAC_CONST(0.041405640977076739), + FRAC_CONST(0.044470771854938668), + FRAC_CONST(0.047535484156959303), + FRAC_CONST(0.050599749036899282), + FRAC_CONST(0.05366353765273052), + FRAC_CONST(0.056726821166907748), + FRAC_CONST(0.059789570746639868), + FRAC_CONST(0.062851757564161406), + FRAC_CONST(0.065913352797003805), + FRAC_CONST(0.068974327628266746), + FRAC_CONST(0.072034653246889332), + FRAC_CONST(0.075094300847921305), + FRAC_CONST(0.078153241632794232), + FRAC_CONST(0.081211446809592441), + FRAC_CONST(0.084268887593324071), + FRAC_CONST(0.087325535206192059), + FRAC_CONST(0.090381360877864983), + FRAC_CONST(0.093436335845747787), + FRAC_CONST(0.096490431355252593), + FRAC_CONST(0.099543618660069319), + FRAC_CONST(0.10259586902243628), + FRAC_CONST(0.10564715371341062), + FRAC_CONST(0.10869744401313872), + FRAC_CONST(0.11174671121112659), + FRAC_CONST(0.11479492660651008), + FRAC_CONST(0.11784206150832498), + FRAC_CONST(0.12088808723577708), + FRAC_CONST(0.12393297511851216), + FRAC_CONST(0.12697669649688587), + FRAC_CONST(0.13001922272223335), + FRAC_CONST(0.13306052515713906), + FRAC_CONST(0.1361005751757062), + FRAC_CONST(0.1391393441638262), + FRAC_CONST(0.14217680351944803), + FRAC_CONST(0.14521292465284746), + FRAC_CONST(0.14824767898689603), + FRAC_CONST(0.15128103795733022), + FRAC_CONST(0.1543129730130201), + FRAC_CONST(0.15734345561623825), + FRAC_CONST(0.16037245724292828), + FRAC_CONST(0.16339994938297323), + FRAC_CONST(0.1664259035404641), + FRAC_CONST(0.16945029123396796), + FRAC_CONST(0.17247308399679595), + FRAC_CONST(0.17549425337727143), + FRAC_CONST(0.17851377093899751), + FRAC_CONST(0.18153160826112497), + FRAC_CONST(0.18454773693861962), + FRAC_CONST(0.1875621285825296), + FRAC_CONST(0.19057475482025274), + FRAC_CONST(0.19358558729580361), + FRAC_CONST(0.19659459767008022), + FRAC_CONST(0.19960175762113097), + FRAC_CONST(0.20260703884442113), + FRAC_CONST(0.20561041305309924), + FRAC_CONST(0.20861185197826349), + FRAC_CONST(0.21161132736922755), + FRAC_CONST(0.21460881099378676), + FRAC_CONST(0.21760427463848364), + FRAC_CONST(0.22059769010887351), + FRAC_CONST(0.22358902922978999), + FRAC_CONST(0.22657826384561), + FRAC_CONST(0.22956536582051887), + FRAC_CONST(0.23255030703877524), + FRAC_CONST(0.23553305940497549), + FRAC_CONST(0.23851359484431842), + FRAC_CONST(0.24149188530286933), + FRAC_CONST(0.24446790274782415), + FRAC_CONST(0.24744161916777327), + FRAC_CONST(0.25041300657296522), + FRAC_CONST(0.25338203699557016), + FRAC_CONST(0.25634868248994291), + FRAC_CONST(0.25931291513288623), + FRAC_CONST(0.26227470702391359), + FRAC_CONST(0.26523403028551179), + FRAC_CONST(0.26819085706340318), + FRAC_CONST(0.27114515952680801), + FRAC_CONST(0.27409690986870638), + FRAC_CONST(0.2770460803060999), + FRAC_CONST(0.27999264308027322), + FRAC_CONST(0.28293657045705539), + FRAC_CONST(0.28587783472708062), + FRAC_CONST(0.28881640820604948), + FRAC_CONST(0.29175226323498926), + FRAC_CONST(0.29468537218051433), + FRAC_CONST(0.2976157074350862), + FRAC_CONST(0.30054324141727345), + FRAC_CONST(0.30346794657201132), + FRAC_CONST(0.30638979537086092), + FRAC_CONST(0.30930876031226873), + FRAC_CONST(0.31222481392182488), + FRAC_CONST(0.31513792875252244), + FRAC_CONST(0.31804807738501495), + FRAC_CONST(0.32095523242787521), + FRAC_CONST(0.32385936651785285), + FRAC_CONST(0.32676045232013173), + FRAC_CONST(0.32965846252858749), + FRAC_CONST(0.33255336986604422), + FRAC_CONST(0.3354451470845316), + FRAC_CONST(0.33833376696554113), + FRAC_CONST(0.34121920232028236), + FRAC_CONST(0.34410142598993881), + FRAC_CONST(0.34698041084592368), + FRAC_CONST(0.34985612979013492), + FRAC_CONST(0.35272855575521073), + FRAC_CONST(0.35559766170478385), + FRAC_CONST(0.35846342063373654), + FRAC_CONST(0.36132580556845428), + FRAC_CONST(0.36418478956707989), + FRAC_CONST(0.36704034571976718), + FRAC_CONST(0.3698924471489341), + FRAC_CONST(0.37274106700951576), + FRAC_CONST(0.37558617848921722), + FRAC_CONST(0.37842775480876556), + FRAC_CONST(0.38126576922216238), + FRAC_CONST(0.38410019501693504), + FRAC_CONST(0.38693100551438858), + FRAC_CONST(0.38975817406985641), + FRAC_CONST(0.39258167407295147), + FRAC_CONST(0.39540147894781635), + FRAC_CONST(0.39821756215337356), + FRAC_CONST(0.40102989718357562), + FRAC_CONST(0.40383845756765407), + FRAC_CONST(0.40664321687036903), + FRAC_CONST(0.40944414869225759), + FRAC_CONST(0.41224122666988289), + FRAC_CONST(0.41503442447608163), + FRAC_CONST(0.41782371582021227), + FRAC_CONST(0.42060907444840251), + FRAC_CONST(0.42339047414379605), + FRAC_CONST(0.42616788872679962), + FRAC_CONST(0.42894129205532949), + FRAC_CONST(0.43171065802505726), + FRAC_CONST(0.43447596056965565), + FRAC_CONST(0.43723717366104409), + FRAC_CONST(0.43999427130963326), + FRAC_CONST(0.44274722756457002), + FRAC_CONST(0.44549601651398174), + FRAC_CONST(0.44824061228521989), + FRAC_CONST(0.45098098904510386), + FRAC_CONST(0.45371712100016387), + FRAC_CONST(0.45644898239688392), + FRAC_CONST(0.45917654752194409), + FRAC_CONST(0.46189979070246273), + FRAC_CONST(0.46461868630623782), + FRAC_CONST(0.46733320874198842), + FRAC_CONST(0.47004333245959562), + FRAC_CONST(0.47274903195034279), + FRAC_CONST(0.47545028174715587), + FRAC_CONST(0.47814705642484301), + FRAC_CONST(0.48083933060033396), + FRAC_CONST(0.48352707893291874), + FRAC_CONST(0.48621027612448642), + FRAC_CONST(0.48888889691976317), + FRAC_CONST(0.4915629161065499), + FRAC_CONST(0.49423230851595967), + FRAC_CONST(0.49689704902265447), + FRAC_CONST(0.49955711254508184), + FRAC_CONST(0.50221247404571079), + FRAC_CONST(0.50486310853126759), + FRAC_CONST(0.50750899105297087), + FRAC_CONST(0.51015009670676681), + FRAC_CONST(0.51278640063356296), + FRAC_CONST(0.51541787801946293), + FRAC_CONST(0.51804450409599934), + FRAC_CONST(0.52066625414036716), + FRAC_CONST(0.52328310347565643), + FRAC_CONST(0.52589502747108463), + FRAC_CONST(0.52850200154222848), + FRAC_CONST(0.531104001151255), + FRAC_CONST(0.53370100180715296), + FRAC_CONST(0.53629297906596318), + FRAC_CONST(0.53887990853100842), + FRAC_CONST(0.54146176585312344), + FRAC_CONST(0.54403852673088382), + FRAC_CONST(0.54661016691083486), + FRAC_CONST(0.54917666218771966), + FRAC_CONST(0.55173798840470734), + FRAC_CONST(0.55429412145362), + FRAC_CONST(0.5568450372751601), + FRAC_CONST(0.55939071185913614), + FRAC_CONST(0.56193112124468947), + FRAC_CONST(0.5644662415205195), + FRAC_CONST(0.56699604882510868), + FRAC_CONST(0.56952051934694714), + FRAC_CONST(0.57203962932475705), + FRAC_CONST(0.57455335504771576), + FRAC_CONST(0.57706167285567944), + FRAC_CONST(0.57956455913940563), + FRAC_CONST(0.58206199034077544), + FRAC_CONST(0.58455394295301533), + FRAC_CONST(0.58704039352091797), + FRAC_CONST(0.58952131864106394), + FRAC_CONST(0.59199669496204099), + FRAC_CONST(0.59446649918466443), + FRAC_CONST(0.5969307080621965), + FRAC_CONST(0.59938929840056454), + FRAC_CONST(0.60184224705858003), + FRAC_CONST(0.60428953094815596), + FRAC_CONST(0.60673112703452448), + FRAC_CONST(0.60916701233645321), + FRAC_CONST(0.61159716392646191), + FRAC_CONST(0.61402155893103838), + FRAC_CONST(0.61644017453085365), + FRAC_CONST(0.61885298796097632), + FRAC_CONST(0.62125997651108755), + FRAC_CONST(0.62366111752569453), + FRAC_CONST(0.62605638840434352), + FRAC_CONST(0.62844576660183271), + FRAC_CONST(0.63082922962842447), + FRAC_CONST(0.63320675505005719), + FRAC_CONST(0.63557832048855611), + FRAC_CONST(0.63794390362184406), + FRAC_CONST(0.64030348218415167), + FRAC_CONST(0.64265703396622686), + FRAC_CONST(0.64500453681554393), + FRAC_CONST(0.64734596863651206), + FRAC_CONST(0.64968130739068319), + FRAC_CONST(0.6520105310969595), + FRAC_CONST(0.65433361783180044), + FRAC_CONST(0.65665054572942894), + FRAC_CONST(0.65896129298203732), + FRAC_CONST(0.66126583783999227), + FRAC_CONST(0.66356415861203977), + FRAC_CONST(0.66585623366550972), + FRAC_CONST(0.66814204142651845), + FRAC_CONST(0.67042156038017309), + FRAC_CONST(0.67269476907077286), + FRAC_CONST(0.67496164610201193), + FRAC_CONST(0.67722217013718033), + FRAC_CONST(0.67947631989936497), + FRAC_CONST(0.68172407417164971), + FRAC_CONST(0.6839654117973154), + FRAC_CONST(0.68620031168003859), + FRAC_CONST(0.68842875278409044), + FRAC_CONST(0.6906507141345346), + FRAC_CONST(0.69286617481742463), + FRAC_CONST(0.69507511398000088), + FRAC_CONST(0.69727751083088652), + FRAC_CONST(0.69947334464028377), + FRAC_CONST(0.70166259474016845), + FRAC_CONST(0.70384524052448494), + FRAC_CONST(0.70602126144933974), + FRAC_CONST(0.70819063703319529), + FRAC_CONST(0.71035334685706231), + FRAC_CONST(0.71250937056469232), + FRAC_CONST(0.71465868786276898), + FRAC_CONST(0.71680127852109954), + FRAC_CONST(0.71893712237280438), + FRAC_CONST(0.72106619931450811), + FRAC_CONST(0.72318848930652735), + FRAC_CONST(0.72530397237306066), + FRAC_CONST(0.72741262860237577), + FRAC_CONST(0.7295144381469969), + FRAC_CONST(0.73160938122389252), + FRAC_CONST(0.73369743811466026), + FRAC_CONST(0.73577858916571348), + FRAC_CONST(0.73785281478846598), + FRAC_CONST(0.73992009545951609), + FRAC_CONST(0.74198041172083096), + FRAC_CONST(0.74403374417992918), + FRAC_CONST(0.74608007351006378), + FRAC_CONST(0.74811938045040349), + FRAC_CONST(0.75015164580621496), + FRAC_CONST(0.7521768504490427), + FRAC_CONST(0.75419497531688917), + FRAC_CONST(0.75620600141439454), + FRAC_CONST(0.75820990981301528), + FRAC_CONST(0.76020668165120242), + FRAC_CONST(0.7621962981345789), + FRAC_CONST(0.76417874053611667), + FRAC_CONST(0.76615399019631281), + FRAC_CONST(0.76812202852336531), + FRAC_CONST(0.7700828369933479), + FRAC_CONST(0.77203639715038441), + FRAC_CONST(0.77398269060682279), + FRAC_CONST(0.77592169904340758), + FRAC_CONST(0.77785340420945304), + FRAC_CONST(0.77977778792301444), + FRAC_CONST(0.78169483207105939), + FRAC_CONST(0.7836045186096382), + FRAC_CONST(0.78550682956405393), + FRAC_CONST(0.78740174702903132), + FRAC_CONST(0.78928925316888565), + FRAC_CONST(0.79116933021769009), + FRAC_CONST(0.79304196047944364), + FRAC_CONST(0.79490712632823701), + FRAC_CONST(0.79676481020841872), + FRAC_CONST(0.79861499463476082), + FRAC_CONST(0.80045766219262271), + FRAC_CONST(0.80229279553811572), + FRAC_CONST(0.8041203773982657), + FRAC_CONST(0.80594039057117628), + FRAC_CONST(0.80775281792619036), + FRAC_CONST(0.80955764240405126), + FRAC_CONST(0.81135484701706373), + FRAC_CONST(0.81314441484925359), + FRAC_CONST(0.81492632905652662), + FRAC_CONST(0.81670057286682785), + FRAC_CONST(0.81846712958029866), + FRAC_CONST(0.82022598256943469), + FRAC_CONST(0.82197711527924155), + FRAC_CONST(0.82372051122739132), + FRAC_CONST(0.82545615400437744), + FRAC_CONST(0.82718402727366902), + FRAC_CONST(0.82890411477186487), + FRAC_CONST(0.8306164003088462), + FRAC_CONST(0.83232086776792968), + FRAC_CONST(0.83401750110601813), + FRAC_CONST(0.8357062843537526), + FRAC_CONST(0.83738720161566194), + FRAC_CONST(0.83906023707031263), + FRAC_CONST(0.84072537497045807), + FRAC_CONST(0.84238259964318596), + FRAC_CONST(0.84403189549006641), + FRAC_CONST(0.84567324698729907), + FRAC_CONST(0.84730663868585832), + FRAC_CONST(0.84893205521163961), + FRAC_CONST(0.85054948126560337), + FRAC_CONST(0.85215890162391983), + FRAC_CONST(0.8537603011381113), + FRAC_CONST(0.85535366473519603), + FRAC_CONST(0.85693897741782865), + FRAC_CONST(0.85851622426444274), + FRAC_CONST(0.86008539042939014), + FRAC_CONST(0.8616464611430813), + FRAC_CONST(0.86319942171212416), + FRAC_CONST(0.86474425751946238), + FRAC_CONST(0.86628095402451299), + FRAC_CONST(0.86780949676330321), + FRAC_CONST(0.86932987134860673), + FRAC_CONST(0.87084206347007886), + FRAC_CONST(0.87234605889439154), + FRAC_CONST(0.87384184346536675), + FRAC_CONST(0.87532940310411078), + FRAC_CONST(0.87680872380914576), + FRAC_CONST(0.87827979165654146), + FRAC_CONST(0.87974259280004741), + FRAC_CONST(0.88119711347122198), + FRAC_CONST(0.88264333997956279), + FRAC_CONST(0.88408125871263499), + FRAC_CONST(0.88551085613619995), + FRAC_CONST(0.88693211879434208), + FRAC_CONST(0.88834503330959624), + FRAC_CONST(0.88974958638307289), + FRAC_CONST(0.89114576479458318), + FRAC_CONST(0.89253355540276469), + FRAC_CONST(0.89391294514520325), + FRAC_CONST(0.89528392103855758), + FRAC_CONST(0.89664647017868015), + FRAC_CONST(0.89800057974073988), + FRAC_CONST(0.89934623697934146), + FRAC_CONST(0.90068342922864686), + FRAC_CONST(0.90201214390249307), + FRAC_CONST(0.90333236849451182), + FRAC_CONST(0.90464409057824624), + FRAC_CONST(0.90594729780726846), + FRAC_CONST(0.90724197791529593), + FRAC_CONST(0.90852811871630612), + FRAC_CONST(0.90980570810465222), + FRAC_CONST(0.91107473405517625), + FRAC_CONST(0.91233518462332275), + FRAC_CONST(0.91358704794525081), + FRAC_CONST(0.91483031223794609), + FRAC_CONST(0.91606496579933161), + FRAC_CONST(0.91729099700837791), + FRAC_CONST(0.91850839432521225), + FRAC_CONST(0.91971714629122736), + FRAC_CONST(0.92091724152918952), + FRAC_CONST(0.92210866874334507), + FRAC_CONST(0.92329141671952764), + FRAC_CONST(0.9244654743252626), + FRAC_CONST(0.92563083050987272), + FRAC_CONST(0.92678747430458175), + FRAC_CONST(0.92793539482261789), + FRAC_CONST(0.92907458125931575), + FRAC_CONST(0.93020502289221907), + FRAC_CONST(0.93132670908118043), + FRAC_CONST(0.93243962926846236), + FRAC_CONST(0.93354377297883617), + FRAC_CONST(0.93463912981968078), + FRAC_CONST(0.93572568948108037), + FRAC_CONST(0.93680344173592156), + FRAC_CONST(0.93787237643998989), + FRAC_CONST(0.93893248353206449), + FRAC_CONST(0.93998375303401394), + FRAC_CONST(0.94102617505088926), + FRAC_CONST(0.94205973977101731), + FRAC_CONST(0.94308443746609349), + FRAC_CONST(0.94410025849127266), + FRAC_CONST(0.94510719328526061), + FRAC_CONST(0.94610523237040334), + FRAC_CONST(0.94709436635277722), + FRAC_CONST(0.94807458592227623), + FRAC_CONST(0.94904588185270056), + FRAC_CONST(0.950008245001843), + FRAC_CONST(0.95096166631157508), + FRAC_CONST(0.95190613680793223), + FRAC_CONST(0.95284164760119872), + FRAC_CONST(0.95376818988599033), + FRAC_CONST(0.95468575494133834), + FRAC_CONST(0.95559433413077111), + FRAC_CONST(0.95649391890239499), + FRAC_CONST(0.95738450078897586), + FRAC_CONST(0.95826607140801767), + FRAC_CONST(0.95913862246184189), + FRAC_CONST(0.96000214573766585), + FRAC_CONST(0.96085663310767966), + FRAC_CONST(0.96170207652912254), + FRAC_CONST(0.96253846804435916), + FRAC_CONST(0.96336579978095405), + FRAC_CONST(0.96418406395174572), + FRAC_CONST(0.96499325285492032), + FRAC_CONST(0.96579335887408357), + FRAC_CONST(0.96658437447833312), + FRAC_CONST(0.96736629222232851), + FRAC_CONST(0.96813910474636233), + FRAC_CONST(0.96890280477642887), + FRAC_CONST(0.96965738512429245), + FRAC_CONST(0.9704028386875555), + FRAC_CONST(0.97113915844972509), + FRAC_CONST(0.9718663374802794), + FRAC_CONST(0.97258436893473221), + FRAC_CONST(0.97329324605469825), + FRAC_CONST(0.97399296216795583), + FRAC_CONST(0.97468351068851067), + FRAC_CONST(0.97536488511665687), + FRAC_CONST(0.97603707903903902), + FRAC_CONST(0.97670008612871184), + FRAC_CONST(0.97735390014519996), + FRAC_CONST(0.97799851493455714), + FRAC_CONST(0.9786339244294231), + FRAC_CONST(0.97926012264908202), + FRAC_CONST(0.97987710369951764), + FRAC_CONST(0.98048486177346938), + FRAC_CONST(0.98108339115048659), + FRAC_CONST(0.98167268619698311), + FRAC_CONST(0.98225274136628937), + FRAC_CONST(0.98282355119870524), + FRAC_CONST(0.98338511032155118), + FRAC_CONST(0.98393741344921892), + FRAC_CONST(0.98448045538322093), + FRAC_CONST(0.98501423101223984), + FRAC_CONST(0.98553873531217606), + FRAC_CONST(0.98605396334619544), + FRAC_CONST(0.98655991026477541), + FRAC_CONST(0.98705657130575097), + FRAC_CONST(0.98754394179435923), + FRAC_CONST(0.98802201714328353), + FRAC_CONST(0.98849079285269659), + FRAC_CONST(0.98895026451030299), + FRAC_CONST(0.98940042779138038), + FRAC_CONST(0.98984127845882053), + FRAC_CONST(0.99027281236316911), + FRAC_CONST(0.99069502544266463), + FRAC_CONST(0.99110791372327678), + FRAC_CONST(0.9915114733187439), + FRAC_CONST(0.99190570043060933), + FRAC_CONST(0.99229059134825737), + FRAC_CONST(0.99266614244894802), + FRAC_CONST(0.99303235019785141), + FRAC_CONST(0.99338921114808065), + FRAC_CONST(0.9937367219407246), + FRAC_CONST(0.99407487930487937), + FRAC_CONST(0.9944036800576791), + FRAC_CONST(0.9947231211043257), + FRAC_CONST(0.99503319943811863), + FRAC_CONST(0.99533391214048228), + FRAC_CONST(0.99562525638099431), + FRAC_CONST(0.99590722941741172), + FRAC_CONST(0.99617982859569687), + FRAC_CONST(0.99644305135004263), + FRAC_CONST(0.99669689520289606), + FRAC_CONST(0.99694135776498216), + FRAC_CONST(0.99717643673532619), + FRAC_CONST(0.9974021299012753), + FRAC_CONST(0.99761843513851955), + FRAC_CONST(0.99782535041111164), + FRAC_CONST(0.99802287377148624), + FRAC_CONST(0.99821100336047819), + FRAC_CONST(0.99838973740734016), + FRAC_CONST(0.99855907422975931), + FRAC_CONST(0.99871901223387294), + FRAC_CONST(0.99886954991428356), + FRAC_CONST(0.99901068585407338), + FRAC_CONST(0.99914241872481691), + FRAC_CONST(0.99926474728659442), + FRAC_CONST(0.99937767038800285), + FRAC_CONST(0.99948118696616695), + FRAC_CONST(0.99957529604674922), + FRAC_CONST(0.99965999674395922), + FRAC_CONST(0.99973528826056168), + FRAC_CONST(0.99980116988788426), + FRAC_CONST(0.99985764100582386), + FRAC_CONST(0.9999047010828529), + FRAC_CONST(0.99994234967602391), + FRAC_CONST(0.99997058643097414), + FRAC_CONST(0.9999894110819284), + FRAC_CONST(0.99999882345170188) }; -real_t sine_mid_480[] = +#ifdef ALLOW_SMALL_FRAMELENGTH +ALIGN static const real_t sine_mid_480[] = { - 0x6B3BA, - 0x141B2A, - 0x21828C, - 0x2EE9D6, - 0x3C50FF, - 0x49B7FE, - 0x571EC9, - 0x648558, - 0x71EB9F, - 0x7F5197, - 0x8CB735, - 0x9A1C71, - 0xA78140, - 0xB4E59A, - 0xC24975, - 0xCFACC7, - 0xDD0F88, - 0xEA71AD, - 0xF7D32E, - 0x1053401, - 0x112941D, - 0x11FF378, - 0x12D5209, - 0x13AAFC7, - 0x1480CA7, - 0x15568A2, - 0x162C3AD, - 0x1701DBE, - 0x17D76CE, - 0x18ACED1, - 0x19825C0, - 0x1A57B90, - 0x1B2D039, - 0x1C023B0, - 0x1CD75EC, - 0x1DAC6E5, - 0x1E81691, - 0x1F564E6, - 0x202B1DB, - 0x20FFD67, - 0x21D4780, - 0x22A901E, - 0x237D736, - 0x2451CBF, - 0x25260B1, - 0x25FA302, - 0x26CE3A8, - 0x27A229B, - 0x2875FD0, - 0x2949B3F, - 0x2A1D4DF, - 0x2AF0CA5, - 0x2BC4289, - 0x2C97682, - 0x2D6A886, - 0x2E3D88C, - 0x2F1068B, - 0x2FE3279, - 0x30B5C4E, - 0x3188400, - 0x325A985, - 0x332CCD5, - 0x33FEDE6, - 0x34D0CB0, - 0x35A2928, - 0x3674346, - 0x3745B01, - 0x381704E, - 0x38E8326, - 0x39B937F, - 0x3A8A150, - 0x3B5AC90, - 0x3C2B534, - 0x3CFBB36, - 0x3DCBE8A, - 0x3E9BF29, - 0x3F6BD08, - 0x403B81F, - 0x410B065, - 0x41DA5D1, - 0x42A9859, - 0x43787F4, - 0x444749A, - 0x4515E41, - 0x45E44E1, - 0x46B286F, - 0x47808E4, - 0x484E635, - 0x491C05B, - 0x49E974C, - 0x4AB6AFE, - 0x4B83B6A, - 0x4C50886, - 0x4D1D249, - 0x4DE98AA, - 0x4EB5B9F, - 0x4F81B22, - 0x504D727, - 0x5118FA6, - 0x51E4497, - 0x52AF5F0, - 0x537A3A9, - 0x5444DB8, - 0x550F415, - 0x55D96B7, - 0x56A3595, - 0x576D0A6, - 0x58367E1, - 0x58FFB3E, - 0x59C8AB3, - 0x5A91638, - 0x5B59DC4, - 0x5C2214E, - 0x5CEA0CE, - 0x5DB1C3A, - 0x5E7938A, - 0x5F406B5, - 0x60075B3, - 0x60CE07A, - 0x6194702, - 0x625A943, - 0x6320732, - 0x63E60C9, - 0x64AB5FE, - 0x65706C9, - 0x6635320, - 0x66F9AFC, - 0x67BDE53, - 0x6881D1E, - 0x6945752, - 0x6A08CE9, - 0x6ACBDD9, - 0x6B8EA1A, - 0x6C511A3, - 0x6D1346B, - 0x6DD526B, - 0x6E96B9A, - 0x6F57FEE, - 0x7018F60, - 0x70D99E8, - 0x7199F7C, - 0x725A014, - 0x7319BA9, - 0x73D9231, - 0x74983A4, - 0x7556FFA, - 0x761572A, - 0x76D392C, - 0x77915F7, - 0x784ED84, - 0x790BFCA, - 0x79C8CC1, - 0x7A85460, - 0x7B416A0, - 0x7BFD377, - 0x7CB8ADE, - 0x7D73CCC, - 0x7E2E93A, - 0x7EE901F, - 0x7FA3172, - 0x805CD2C, - 0x8116345, - 0x81CF3B4, - 0x8287E72, - 0x8340376, - 0x83F82B8, - 0x84AFC30, - 0x8566FD6, - 0x861DDA2, - 0x86D458C, - 0x878A78B, - 0x8840399, - 0x88F59AD, - 0x89AA9BF, - 0x8A5F3C7, - 0x8B137BD, - 0x8BC7599, - 0x8C7AD54, - 0x8D2DEE5, - 0x8DE0A45, - 0x8E92F6C, - 0x8F44E51, - 0x8FF66EE, - 0x90A793A, - 0x915852E, - 0x9208AC2, - 0x92B89ED, - 0x93682AA, - 0x94174EF, - 0x94C60B4, - 0x95745F4, - 0x96224A5, - 0x96CFCC0, - 0x977CE3D, - 0x9829916, - 0x98D5D42, - 0x9981AB9, - 0x9A2D175, - 0x9AD816D, - 0x9B82A9B, - 0x9C2CCF6, - 0x9CD6878, - 0x9D7FD18, - 0x9E28AD0, - 0x9ED1197, - 0x9F79168, - 0xA020A39, - 0xA0C7C05, - 0xA16E6C2, - 0xA214A6C, - 0xA2BA6F9, - 0xA35FC62, - 0xA404AA1, - 0xA4A91AF, - 0xA54D183, - 0xA5F0A17, - 0xA693B63, - 0xA736561, - 0xA7D880A, - 0xA87A355, - 0xA91B73D, - 0xA9BC3BA, - 0xAA5C8C4, - 0xAAFC656, - 0xAB9BC67, - 0xAC3AAF2, - 0xACD91EE, - 0xAD77156, - 0xAE14921, - 0xAEB194A, - 0xAF4E1C9, - 0xAFEA297, - 0xB085BAE, - 0xB120D07, - 0xB1BB69B, - 0xB255863, - 0xB2EF258, - 0xB388474, - 0xB420EB0, - 0xB4B9105, - 0xB550B6D, - 0xB5E7DE0, - 0xB67E859, - 0xB714AD1, - 0xB7AA541, - 0xB83F7A2, - 0xB8D41EF, - 0xB968420, - 0xB9FBE2E, - 0xBA8F015, - 0xBB219CC, - 0xBBB3B4E, - 0xBC45495, - 0xBCD6599, - 0xBD66E54, - 0xBDF6EC1, - 0xBE866D9, - 0xBF15695, - 0xBFA3DEF, - 0xC031CE1, - 0xC0BF365, - 0xC14C175, - 0xC1D870A, - 0xC26441E, - 0xC2EF8AB, - 0xC37A4AC, - 0xC404819, - 0xC48E2ED, - 0xC517522, - 0xC59FEB1, - 0xC627F96, - 0xC6AF7C9, - 0xC736745, - 0xC7BCE04, - 0xC842C00, - 0xC8C8134, - 0xC94CD98, - 0xC9D1128, - 0xCA54BDE, - 0xCAD7DB4, - 0xCB5A6A4, - 0xCBDC6A9, - 0xCC5DDBC, - 0xCCDEBD8, - 0xCD5F0F8, - 0xCDDED16, - 0xCE5E02C, - 0xCEDCA34, - 0xCF5AB29, - 0xCFD8306, - 0xD0551C5, - 0xD0D1761, - 0xD14D3D4, - 0xD1C8718, - 0xD243129, - 0xD2BD200, - 0xD336999, - 0xD3AF7EE, - 0xD427CFB, - 0xD49F8B8, - 0xD516B22, - 0xD58D434, - 0xD6033E7, - 0xD678A37, - 0xD6ED71E, - 0xD761A98, - 0xD7D54A0, - 0xD848530, - 0xD8BAC43, - 0xD92C9D4, - 0xD99DDDE, - 0xDA0E85D, - 0xDA7E94C, - 0xDAEE0A4, - 0xDB5CE62, - 0xDBCB281, - 0xDC38CFC, - 0xDCA5DCE, - 0xDD124F2, - 0xDD7E263, - 0xDDE961E, - 0xDE5401C, - 0xDEBE05A, - 0xDF276D2, - 0xDF90381, - 0xDFF8661, - 0xE05FF6E, - 0xE0C6EA3, - 0xE12D3FD, - 0xE192F75, - 0xE1F8109, - 0xE25C8B3, - 0xE2C066F, - 0xE323A39, - 0xE38640D, - 0xE3E83E5, - 0xE4499BE, - 0xE4AA594, - 0xE50A762, - 0xE569F23, - 0xE5C8CD5, - 0xE627072, - 0xE6849F7, - 0xE6E195F, - 0xE73DEA7, - 0xE7999CA, - 0xE7F4AC4, - 0xE84F191, - 0xE8A8E2E, - 0xE902096, - 0xE95A8C6, - 0xE9B26B9, - 0xEA09A6C, - 0xEA603DA, - 0xEAB6301, - 0xEB0B7DC, - 0xEB60268, - 0xEBB42A1, - 0xEC07883, - 0xEC5A40A, - 0xECAC533, - 0xECFDBFB, - 0xED4E85D, - 0xED9EA56, - 0xEDEE1E3, - 0xEE3CF01, - 0xEE8B1AB, - 0xEED89DE, - 0xEF25797, - 0xEF71AD3, - 0xEFBD38E, - 0xF0081C5, - 0xF052574, - 0xF09BE99, - 0xF0E4D30, - 0xF12D136, - 0xF174AA7, - 0xF1BB981, - 0xF201DC1, - 0xF247763, - 0xF28C664, - 0xF2D0AC2, - 0xF314479, - 0xF357386, - 0xF3997E7, - 0xF3DB198, - 0xF41C097, - 0xF45C4E1, - 0xF49BE72, - 0xF4DAD49, - 0xF519162, - 0xF556ABB, - 0xF593951, - 0xF5CFD22, - 0xF60B62A, - 0xF646467, - 0xF6807D6, - 0xF6BA076, - 0xF6F2E43, - 0xF72B13A, - 0xF76295B, - 0xF7996A1, - 0xF7CF90B, - 0xF805096, - 0xF839D40, - 0xF86DF06, - 0xF8A15E7, - 0xF8D41E0, - 0xF9062EF, - 0xF937911, - 0xF968445, - 0xF998488, - 0xF9C79D8, - 0xF9F6433, - 0xFA24398, - 0xFA51803, - 0xFA7E174, - 0xFAA9FE7, - 0xFAD535C, - 0xFAFFBD0, - 0xFB29942, - 0xFB52BAF, - 0xFB7B316, - 0xFBA2F75, - 0xFBCA0CA, - 0xFBF0714, - 0xFC16251, - 0xFC3B27F, - 0xFC5F79C, - 0xFC831A7, - 0xFCA609F, - 0xFCC8482, - 0xFCE9D4E, - 0xFD0AB03, - 0xFD2AD9D, - 0xFD4A51D, - 0xFD69180, - 0xFD872C6, - 0xFDA48ED, - 0xFDC13F4, - 0xFDDD3D9, - 0xFDF889B, - 0xFE13239, - 0xFE2D0B3, - 0xFE46406, - 0xFE5EC31, - 0xFE76934, - 0xFE8DB0E, - 0xFEA41BD, - 0xFEB9D41, - 0xFECED99, - 0xFEE32C3, - 0xFEF6CBE, - 0xFF09B8B, - 0xFF1BF28, - 0xFF2D794, - 0xFF3E4CE, - 0xFF4E6D7, - 0xFF5DDAC, - 0xFF6C94E, - 0xFF7A9BC, - 0xFF87EF4, - 0xFF948F7, - 0xFFA07C4, - 0xFFABB5B, - 0xFFB63BB, - 0xFFC00E3, - 0xFFC92D3, - 0xFFD198B, - 0xFFD950A, - 0xFFE0550, - 0xFFE6A5D, - 0xFFEC430, - 0xFFF12C9, - 0xFFF5629, - 0xFFF8E4E, - 0xFFFBB38, - 0xFFFDCE8, - 0xFFFF35D, - 0xFFFFE98 + FRAC_CONST(0.0016362454436240478), + FRAC_CONST(0.00490871880799799), + FRAC_CONST(0.0081811396039371282), + FRAC_CONST(0.011453472786443779), + FRAC_CONST(0.014725683311458524), + FRAC_CONST(0.017997736136235509), + FRAC_CONST(0.021269596219717739), + FRAC_CONST(0.024541228522912285), + FRAC_CONST(0.027812598009265607), + FRAC_CONST(0.03108366964503869), + FRAC_CONST(0.034354408399682276), + FRAC_CONST(0.037624779246211978), + FRAC_CONST(0.04089474716158345), + FRAC_CONST(0.044164277127067358), + FRAC_CONST(0.047433334128624507), + FRAC_CONST(0.050701883157280733), + FRAC_CONST(0.053969889209501881), + FRAC_CONST(0.057237317287568618), + FRAC_CONST(0.060504132399951269), + FRAC_CONST(0.063770299561684493), + FRAC_CONST(0.06703578379474201), + FRAC_CONST(0.070300550128411174), + FRAC_CONST(0.073564563599667426), + FRAC_CONST(0.076827789253548759), + FRAC_CONST(0.080090192143530081), + FRAC_CONST(0.083351737331897449), + FRAC_CONST(0.086612389890122182), + FRAC_CONST(0.089872114899234967), + FRAC_CONST(0.093130877450199795), + FRAC_CONST(0.096388642644287828), + FRAC_CONST(0.09964537559345106), + FRAC_CONST(0.1029010414206961), + FRAC_CONST(0.10615560526045748), + FRAC_CONST(0.10940903225897117), + FRAC_CONST(0.11266128757464781), + FRAC_CONST(0.11591233637844581), + FRAC_CONST(0.11916214385424433), + FRAC_CONST(0.1224106751992162), + FRAC_CONST(0.12565789562420052), + FRAC_CONST(0.12890377035407541), + FRAC_CONST(0.13214826462813015), + FRAC_CONST(0.13539134370043773), + FRAC_CONST(0.13863297284022669), + FRAC_CONST(0.14187311733225325), + FRAC_CONST(0.14511174247717309), + FRAC_CONST(0.14834881359191271), + FRAC_CONST(0.15158429601004111), + FRAC_CONST(0.15481815508214106), + FRAC_CONST(0.1580503561761798), + FRAC_CONST(0.16128086467788047), + FRAC_CONST(0.16450964599109233), + FRAC_CONST(0.16773666553816149), + FRAC_CONST(0.17096188876030122), + FRAC_CONST(0.17418528111796186), + FRAC_CONST(0.17740680809120093), + FRAC_CONST(0.18062643518005275), + FRAC_CONST(0.18384412790489776), + FRAC_CONST(0.18705985180683199), + FRAC_CONST(0.19027357244803589), + FRAC_CONST(0.19348525541214331), + FRAC_CONST(0.19669486630460997), + FRAC_CONST(0.19990237075308173), + FRAC_CONST(0.20310773440776286), + FRAC_CONST(0.20631092294178383), + FRAC_CONST(0.20951190205156878), + FRAC_CONST(0.21271063745720317), + FRAC_CONST(0.21590709490280058), + FRAC_CONST(0.2191012401568698), + FRAC_CONST(0.22229303901268133), + FRAC_CONST(0.22548245728863364), + FRAC_CONST(0.22866946082861941), + FRAC_CONST(0.23185401550239115), + FRAC_CONST(0.23503608720592667), + FRAC_CONST(0.23821564186179459), + FRAC_CONST(0.24139264541951888), + FRAC_CONST(0.24456706385594387), + FRAC_CONST(0.24773886317559846), + FRAC_CONST(0.25090800941106001), + FRAC_CONST(0.25407446862331851), + FRAC_CONST(0.25723820690213967), + FRAC_CONST(0.26039919036642817), + FRAC_CONST(0.26355738516459076), + FRAC_CONST(0.26671275747489837), + FRAC_CONST(0.2698652735058486), + FRAC_CONST(0.27301489949652735), + FRAC_CONST(0.27616160171697068), + FRAC_CONST(0.27930534646852595), + FRAC_CONST(0.28244610008421245), + FRAC_CONST(0.2855838289290823), + FRAC_CONST(0.28871849940058025), + FRAC_CONST(0.29185007792890405), + FRAC_CONST(0.29497853097736348), + FRAC_CONST(0.2981038250427398), + FRAC_CONST(0.30122592665564446), + FRAC_CONST(0.30434480238087736), + FRAC_CONST(0.30746041881778519), + FRAC_CONST(0.31057274260061901), + FRAC_CONST(0.31368174039889146), + FRAC_CONST(0.31678737891773395), + FRAC_CONST(0.31988962489825296), + FRAC_CONST(0.32298844511788638), + FRAC_CONST(0.32608380639075912), + FRAC_CONST(0.32917567556803889), + FRAC_CONST(0.33226401953829071), + FRAC_CONST(0.33534880522783189), + FRAC_CONST(0.33842999960108583), + FRAC_CONST(0.34150756966093632), + FRAC_CONST(0.34458148244908043), + FRAC_CONST(0.34765170504638188), + FRAC_CONST(0.35071820457322322), + FRAC_CONST(0.35378094818985806), + FRAC_CONST(0.35683990309676283), + FRAC_CONST(0.35989503653498811), + FRAC_CONST(0.36294631578650921), + FRAC_CONST(0.36599370817457672), + FRAC_CONST(0.36903718106406647), + FRAC_CONST(0.37207670186182878), + FRAC_CONST(0.37511223801703802), + FRAC_CONST(0.37814375702154046), + FRAC_CONST(0.38117122641020335), + FRAC_CONST(0.38419461376126157), + FRAC_CONST(0.38721388669666562), + FRAC_CONST(0.39022901288242801), + FRAC_CONST(0.39323996002896966), + FRAC_CONST(0.39624669589146555), + FRAC_CONST(0.39924918827019029), + FRAC_CONST(0.40224740501086254), + FRAC_CONST(0.40524131400498986), + FRAC_CONST(0.40823088319021217), + FRAC_CONST(0.41121608055064529), + FRAC_CONST(0.41419687411722372), + FRAC_CONST(0.41717323196804335), + FRAC_CONST(0.42014512222870243), + FRAC_CONST(0.42311251307264408), + FRAC_CONST(0.42607537272149631), + FRAC_CONST(0.4290336694454126), + FRAC_CONST(0.43198737156341183), + FRAC_CONST(0.43493644744371707), + FRAC_CONST(0.43788086550409511), + FRAC_CONST(0.44082059421219388), + FRAC_CONST(0.44375560208588088), + FRAC_CONST(0.44668585769357955), + FRAC_CONST(0.4496113296546066), + FRAC_CONST(0.45253198663950756), + FRAC_CONST(0.45544779737039259), + FRAC_CONST(0.45835873062127125), + FRAC_CONST(0.46126475521838717), + FRAC_CONST(0.46416584004055156), + FRAC_CONST(0.46706195401947659), + FRAC_CONST(0.46995306614010829), + FRAC_CONST(0.47283914544095862), + FRAC_CONST(0.47572016101443682), + FRAC_CONST(0.47859608200718085), + FRAC_CONST(0.4814668776203872), + FRAC_CONST(0.48433251711014125), + FRAC_CONST(0.4871929697877464), + FRAC_CONST(0.49004820502005247), + FRAC_CONST(0.49289819222978404), + FRAC_CONST(0.49574290089586776), + FRAC_CONST(0.49858230055375902), + FRAC_CONST(0.50141636079576901), + FRAC_CONST(0.50424505127138919), + FRAC_CONST(0.50706834168761705), + FRAC_CONST(0.50988620180928057), + FRAC_CONST(0.51269860145936175), + FRAC_CONST(0.51550551051931948), + FRAC_CONST(0.51830689892941317), + FRAC_CONST(0.5211027366890234), + FRAC_CONST(0.52389299385697385), + FRAC_CONST(0.52667764055185196), + FRAC_CONST(0.52945664695232897), + FRAC_CONST(0.53222998329747884), + FRAC_CONST(0.53499761988709726), + FRAC_CONST(0.53775952708201991), + FRAC_CONST(0.54051567530443978), + FRAC_CONST(0.54326603503822357), + FRAC_CONST(0.54601057682922816), + FRAC_CONST(0.54874927128561579), + FRAC_CONST(0.55148208907816942), + FRAC_CONST(0.55420900094060566), + FRAC_CONST(0.55692997766988939), + FRAC_CONST(0.559644990126546), + FRAC_CONST(0.56235400923497314), + FRAC_CONST(0.56505700598375252), + FRAC_CONST(0.56775395142596052), + FRAC_CONST(0.57044481667947822), + FRAC_CONST(0.57312957292730071), + FRAC_CONST(0.57580819141784534), + FRAC_CONST(0.57848064346525996), + FRAC_CONST(0.58114690044973039), + FRAC_CONST(0.58380693381778626), + FRAC_CONST(0.58646071508260733), + FRAC_CONST(0.58910821582432815), + FRAC_CONST(0.5917494076903429), + FRAC_CONST(0.5943842623956086), + FRAC_CONST(0.59701275172294799), + FRAC_CONST(0.59963484752335228), + FRAC_CONST(0.60225052171628191), + FRAC_CONST(0.60485974628996786), + FRAC_CONST(0.60746249330171098), + FRAC_CONST(0.61005873487818185), + FRAC_CONST(0.61264844321571899), + FRAC_CONST(0.61523159058062682), + FRAC_CONST(0.61780814930947225), + FRAC_CONST(0.62037809180938108), + FRAC_CONST(0.62294139055833397), + FRAC_CONST(0.6254980181054608), + FRAC_CONST(0.62804794707133416), + FRAC_CONST(0.63059115014826372), + FRAC_CONST(0.63312760010058777), + FRAC_CONST(0.63565726976496484), + FRAC_CONST(0.63818013205066515), + FRAC_CONST(0.64069615993986073), + FRAC_CONST(0.64320532648791406), + FRAC_CONST(0.64570760482366729), + FRAC_CONST(0.64820296814972966), + FRAC_CONST(0.65069138974276486), + FRAC_CONST(0.65317284295377676), + FRAC_CONST(0.65564730120839498), + FRAC_CONST(0.65811473800715958), + FRAC_CONST(0.660575126925805), + FRAC_CONST(0.66302844161554231), + FRAC_CONST(0.6654746558033422), + FRAC_CONST(0.66791374329221598), + FRAC_CONST(0.67034567796149647), + FRAC_CONST(0.67277043376711676), + FRAC_CONST(0.67518798474189046), + FRAC_CONST(0.67759830499578866), + FRAC_CONST(0.68000136871621808), + FRAC_CONST(0.68239715016829683), + FRAC_CONST(0.6847856236951303), + FRAC_CONST(0.68716676371808583), + FRAC_CONST(0.68954054473706683), + FRAC_CONST(0.69190694133078579), + FRAC_CONST(0.69426592815703603), + FRAC_CONST(0.69661747995296419), + FRAC_CONST(0.69896157153533944), + FRAC_CONST(0.70129817780082437), + FRAC_CONST(0.7036272737262429), + FRAC_CONST(0.70594883436884903), + FRAC_CONST(0.70826283486659336), + FRAC_CONST(0.71056925043838959), + FRAC_CONST(0.71286805638437978), + FRAC_CONST(0.71515922808619936), + FRAC_CONST(0.71744274100723993), + FRAC_CONST(0.71971857069291278), + FRAC_CONST(0.7219866927709101), + FRAC_CONST(0.72424708295146689), + FRAC_CONST(0.72649971702762028), + FRAC_CONST(0.72874457087546896), + FRAC_CONST(0.73098162045443171), + FRAC_CONST(0.73321084180750484), + FRAC_CONST(0.73543221106151868), + FRAC_CONST(0.73764570442739286), + FRAC_CONST(0.73985129820039208), + FRAC_CONST(0.74204896876037885), + FRAC_CONST(0.7442386925720671), + FRAC_CONST(0.74642044618527381), + FRAC_CONST(0.74859420623517081), + FRAC_CONST(0.75075994944253421), + FRAC_CONST(0.75291765261399446), + FRAC_CONST(0.75506729264228367), + FRAC_CONST(0.75720884650648446), + FRAC_CONST(0.75934229127227548), + FRAC_CONST(0.76146760409217706), + FRAC_CONST(0.76358476220579641), + FRAC_CONST(0.7656937429400712), + FRAC_CONST(0.76779452370951196), + FRAC_CONST(0.76988708201644451), + FRAC_CONST(0.77197139545125026), + FRAC_CONST(0.7740474416926072), + FRAC_CONST(0.77611519850772781), + FRAC_CONST(0.77817464375259782), + FRAC_CONST(0.78022575537221317), + FRAC_CONST(0.78226851140081632), + FRAC_CONST(0.78430288996213138), + FRAC_CONST(0.78632886926959822), + FRAC_CONST(0.78834642762660623), + FRAC_CONST(0.79035554342672631), + FRAC_CONST(0.79235619515394229), + FRAC_CONST(0.79434836138288134), + FRAC_CONST(0.79633202077904397), + FRAC_CONST(0.79830715209903147), + FRAC_CONST(0.8002737341907743), + FRAC_CONST(0.80223174599375802), + FRAC_CONST(0.80418116653924954), + FRAC_CONST(0.80612197495052085), + FRAC_CONST(0.80805415044307316), + FRAC_CONST(0.80997767232485907), + FRAC_CONST(0.81189251999650469), + FRAC_CONST(0.81379867295152986), + FRAC_CONST(0.81569611077656778), + FRAC_CONST(0.81758481315158371), + FRAC_CONST(0.81946475985009259), + FRAC_CONST(0.82133593073937561), + FRAC_CONST(0.82319830578069586), + FRAC_CONST(0.82505186502951278), + FRAC_CONST(0.82689658863569615), + FRAC_CONST(0.82873245684373809), + FRAC_CONST(0.83055944999296494), + FRAC_CONST(0.83237754851774781), + FRAC_CONST(0.83418673294771239), + FRAC_CONST(0.83598698390794668), + FRAC_CONST(0.83777828211920935), + FRAC_CONST(0.83956060839813562), + FRAC_CONST(0.84133394365744296), + FRAC_CONST(0.84309826890613537), + FRAC_CONST(0.84485356524970701), + FRAC_CONST(0.84659981389034411), + FRAC_CONST(0.84833699612712676), + FRAC_CONST(0.85006509335622882), + FRAC_CONST(0.8517840870711173), + FRAC_CONST(0.85349395886275037), + FRAC_CONST(0.85519469041977514), + FRAC_CONST(0.85688626352872277), + FRAC_CONST(0.85856866007420429), + FRAC_CONST(0.86024186203910447), + FRAC_CONST(0.86190585150477417), + FRAC_CONST(0.86356061065122347), + FRAC_CONST(0.86520612175731115), + FRAC_CONST(0.86684236720093533), + FRAC_CONST(0.86846932945922151), + FRAC_CONST(0.87008699110871135), + FRAC_CONST(0.87169533482554817), + FRAC_CONST(0.87329434338566281), + FRAC_CONST(0.87488399966495822), + FRAC_CONST(0.87646428663949283), + FRAC_CONST(0.87803518738566277), + FRAC_CONST(0.87959668508038291), + FRAC_CONST(0.88114876300126743), + FRAC_CONST(0.88269140452680916), + FRAC_CONST(0.8842245931365561), + FRAC_CONST(0.88574831241129048), + FRAC_CONST(0.88726254603320276), + FRAC_CONST(0.88876727778606746), + FRAC_CONST(0.89026249155541637), + FRAC_CONST(0.8917481713287112), + FRAC_CONST(0.89322430119551532), + FRAC_CONST(0.89469086534766362), + FRAC_CONST(0.89614784807943237), + FRAC_CONST(0.89759523378770689), + FRAC_CONST(0.89903300697214927), + FRAC_CONST(0.9004611522353636), + FRAC_CONST(0.90187965428306172), + FRAC_CONST(0.90328849792422594), + FRAC_CONST(0.90468766807127299), + FRAC_CONST(0.90607714974021469), + FRAC_CONST(0.90745692805081868), + FRAC_CONST(0.90882698822676755), + FRAC_CONST(0.91018731559581767), + FRAC_CONST(0.91153789558995579), + FRAC_CONST(0.91287871374555518), + FRAC_CONST(0.91420975570353069), + FRAC_CONST(0.9155310072094921), + FRAC_CONST(0.91684245411389753), + FRAC_CONST(0.91814408237220391), + FRAC_CONST(0.91943587804501858), + FRAC_CONST(0.92071782729824769), + FRAC_CONST(0.92198991640324446), + FRAC_CONST(0.92325213173695675), + FRAC_CONST(0.92450445978207241), + FRAC_CONST(0.92574688712716402), + FRAC_CONST(0.92697940046683291), + FRAC_CONST(0.92820198660185149), + FRAC_CONST(0.92941463243930444), + FRAC_CONST(0.93061732499272909), + FRAC_CONST(0.93181005138225426), + FRAC_CONST(0.93299279883473885), + FRAC_CONST(0.93416555468390772), + FRAC_CONST(0.93532830637048769), + FRAC_CONST(0.93648104144234268), + FRAC_CONST(0.93762374755460598), + FRAC_CONST(0.93875641246981323), + FRAC_CONST(0.93987902405803303), + FRAC_CONST(0.94099157029699743), + FRAC_CONST(0.94209403927222979), + FRAC_CONST(0.94318641917717327), + FRAC_CONST(0.9442686983133165), + FRAC_CONST(0.94534086509031956), + FRAC_CONST(0.9464029080261378), + FRAC_CONST(0.94745481574714419), + FRAC_CONST(0.94849657698825252), + FRAC_CONST(0.94952818059303667), + FRAC_CONST(0.95054961551385087), + FRAC_CONST(0.95156087081194762), + FRAC_CONST(0.95256193565759528), + FRAC_CONST(0.95355279933019343), + FRAC_CONST(0.9545334512183884), + FRAC_CONST(0.95550388082018611), + FRAC_CONST(0.95646407774306541), + FRAC_CONST(0.95741403170408834), + FRAC_CONST(0.95835373253001133), + FRAC_CONST(0.95928317015739362), + FRAC_CONST(0.96020233463270466), + FRAC_CONST(0.96111121611243155), + FRAC_CONST(0.96200980486318388), + FRAC_CONST(0.96289809126179782), + FRAC_CONST(0.96377606579543984), + FRAC_CONST(0.96464371906170809), + FRAC_CONST(0.96550104176873297), + FRAC_CONST(0.96634802473527726), + FRAC_CONST(0.96718465889083372), + FRAC_CONST(0.96801093527572268), + FRAC_CONST(0.96882684504118799), + FRAC_CONST(0.96963237944949143), + FRAC_CONST(0.97042752987400682), + FRAC_CONST(0.97121228779931179), + FRAC_CONST(0.97198664482127939), + FRAC_CONST(0.97275059264716823), + FRAC_CONST(0.97350412309571066), + FRAC_CONST(0.97424722809720088), + FRAC_CONST(0.97497989969358168), + FRAC_CONST(0.97570213003852857), + FRAC_CONST(0.97641391139753486), + FRAC_CONST(0.97711523614799412), + FRAC_CONST(0.97780609677928154), + FRAC_CONST(0.97848648589283505), + FRAC_CONST(0.97915639620223371), + FRAC_CONST(0.9798158205332762), + FRAC_CONST(0.98046475182405801), + FRAC_CONST(0.98110318312504607), + FRAC_CONST(0.98173110759915416), + FRAC_CONST(0.98234851852181571), + FRAC_CONST(0.98295540928105563), + FRAC_CONST(0.9835517733775615), + FRAC_CONST(0.98413760442475307), + FRAC_CONST(0.98471289614885038), + FRAC_CONST(0.98527764238894122), + FRAC_CONST(0.98583183709704714), + FRAC_CONST(0.98637547433818806), + FRAC_CONST(0.98690854829044583), + FRAC_CONST(0.98743105324502667), + FRAC_CONST(0.98794298360632238), + FRAC_CONST(0.98844433389196995), + FRAC_CONST(0.98893509873291074), + FRAC_CONST(0.98941527287344755), + FRAC_CONST(0.98988485117130098), + FRAC_CONST(0.99034382859766479), + FRAC_CONST(0.99079220023725967), + FRAC_CONST(0.99122996128838525), + FRAC_CONST(0.9916571070629725), + FRAC_CONST(0.99207363298663342), + FRAC_CONST(0.99247953459870997), + FRAC_CONST(0.99287480755232194), + FRAC_CONST(0.99325944761441354), + FRAC_CONST(0.99363345066579889), + FRAC_CONST(0.99399681270120555), + FRAC_CONST(0.99434952982931812), + FRAC_CONST(0.9946915982728195), + FRAC_CONST(0.99502301436843166), + FRAC_CONST(0.99534377456695422), + FRAC_CONST(0.9956538754333033), + FRAC_CONST(0.99595331364654771), + FRAC_CONST(0.99624208599994479), + FRAC_CONST(0.99652018940097464), + FRAC_CONST(0.99678762087137318), + FRAC_CONST(0.99704437754716424), + FRAC_CONST(0.99729045667869021), + FRAC_CONST(0.99752585563064111), + FRAC_CONST(0.99775057188208349), + FRAC_CONST(0.9979646030264866), + FRAC_CONST(0.99816794677174903), + FRAC_CONST(0.9983606009402225), + FRAC_CONST(0.99854256346873571), + FRAC_CONST(0.99871383240861611), + FRAC_CONST(0.99887440592571108), + FRAC_CONST(0.99902428230040718), + FRAC_CONST(0.99916345992764877), + FRAC_CONST(0.99929193731695531), + FRAC_CONST(0.99940971309243731), + FRAC_CONST(0.99951678599281069), + FRAC_CONST(0.99961315487141078), + FRAC_CONST(0.99969881869620425), + FRAC_CONST(0.99977377654980037), + FRAC_CONST(0.99983802762946083), + FRAC_CONST(0.99989157124710804), + FRAC_CONST(0.9999344068293331), + FRAC_CONST(0.99996653391740109), + FRAC_CONST(0.99998795216725689), + FRAC_CONST(0.99999866134952808) }; +#endif -real_t ld_mid_512[] = +ALIGN static const real_t ld_mid_512[] = { - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x1921F1, - 0x4B64DB, - 0x7DA4DD, - 0xAFE006, - 0xE21468, - 0x1144013, - 0x1466118, - 0x1787587, - 0x1AA7B73, - 0x1DC70ED, - 0x20E5409, - 0x24022DB, - 0x271DB77, - 0x2A37BF1, - 0x2D50261, - 0x3066CDE, - 0x337B97F, - 0x368E65F, - 0x399F198, - 0x3CAD945, - 0x3FB9B85, - 0x42C3675, - 0x45CA837, - 0x48CEEED, - 0x4BD08B8, - 0x4ECF3C0, - 0x51CAE2B, - 0x54C3622, - 0x57B89D0, - 0x5AAA761, - 0x5D98D06, - 0x60838EE, - 0x636A94E, - 0x664DC5B, - 0x692D04C, - 0x6C0835E, - 0x6EDF3CB, - 0x71B1FD5, - 0x74805BD, - 0x774A3C8, - 0x7A0F83E, - 0x7CD0168, - 0x7F8BD96, - 0x8242B16, - 0x84F483D, - 0x87A1361, - 0x8A48ADB, - 0x8CEAD08, - 0x8F87849, - 0x921EB01, - 0x94B0397, - 0x973C075, - 0x99C200A, - 0x9C420C6, - 0x9EBC120, - 0xA12FF8F, - 0xA39DA91, - 0xA6050A6, - 0xA866053, - 0xAAC0820, - 0xAD14699, - 0xAF61A4E, - 0xB1A81D5, - 0xB3E7BC6, - 0xB6206BE, - 0xB85215D, - 0xBA7CA4B, - 0xBCA002F, - 0xBEBC1BA, - 0xC0D0D9E, - 0xC2DE291, - 0xC4E3F51, - 0xC6E229D, - 0xC8D8B3C, - 0xCAC77F6, - 0xCCAE79B, - 0xCE8D8FF, - 0xD064AF9, - 0xD233C68, - 0xD3FAC2D, - 0xD5B9930, - 0xD77025E, - 0xD91E6A7, - 0xDAC4503, - 0xDC61C6D, - 0xDDF6BE6, - 0xDF83274, - 0xE106F23, - 0xE282104, - 0xE3F472C, - 0xE55E0B8, - 0xE6BECC8, - 0xE816A82, - 0xE965913, - 0xEAAB7AC, - 0xEBE8584, - 0xED1C1D8, - 0xEE46BE8, - 0xEF682FF, - 0xF080668, - 0xF18F577, - 0xF294F85, - 0xF3913F0, - 0xF48421D, - 0xF56D977, - 0xF64D96C, - 0xF724173, - 0xF7F1108, - 0xF8B47AC, - 0xF96E4E6, - 0xFA1E845, - 0xFAC515A, - 0xFB61FC0, - 0xFBF5316, - 0xFC7EB01, - 0xFCFE72C, - 0xFD74748, - 0xFDE0B0D, - 0xFE43237, - 0xFE9BC8B, - 0xFEEA9D0, - 0xFF2F9D8, - 0xFF6AC77, - 0xFF9C188, - 0xFFC38ED, - 0xFFE128F, - 0xFFF4E5A, - 0xFFFEC42, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000 + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0.0061358846491544753), + FRAC_CONST(0.01840672990580482), + FRAC_CONST(0.030674803176636626), + FRAC_CONST(0.04293825693494082), + FRAC_CONST(0.055195244349689934), + FRAC_CONST(0.067443919563664051), + FRAC_CONST(0.079682437971430126), + FRAC_CONST(0.091908956497132724), + FRAC_CONST(0.10412163387205459), + FRAC_CONST(0.11631863091190475), + FRAC_CONST(0.12849811079379317), + FRAC_CONST(0.14065823933284921), + FRAC_CONST(0.15279718525844344), + FRAC_CONST(0.16491312048996989), + FRAC_CONST(0.17700422041214875), + FRAC_CONST(0.18906866414980619), + FRAC_CONST(0.2011046348420919), + FRAC_CONST(0.21311031991609136), + FRAC_CONST(0.22508391135979283), + FRAC_CONST(0.2370236059943672), + FRAC_CONST(0.24892760574572015), + FRAC_CONST(0.26079411791527551), + FRAC_CONST(0.27262135544994898), + FRAC_CONST(0.28440753721127188), + FRAC_CONST(0.29615088824362379), + FRAC_CONST(0.30784964004153487), + FRAC_CONST(0.31950203081601569), + FRAC_CONST(0.33110630575987643), + FRAC_CONST(0.34266071731199438), + FRAC_CONST(0.35416352542049034), + FRAC_CONST(0.36561299780477385), + FRAC_CONST(0.37700741021641826), + FRAC_CONST(0.38834504669882625), + FRAC_CONST(0.39962419984564679), + FRAC_CONST(0.41084317105790391), + FRAC_CONST(0.42200027079979968), + FRAC_CONST(0.43309381885315196), + FRAC_CONST(0.4441221445704292), + FRAC_CONST(0.45508358712634384), + FRAC_CONST(0.46597649576796618), + FRAC_CONST(0.47679923006332209), + FRAC_CONST(0.487550160148436), + FRAC_CONST(0.49822766697278187), + FRAC_CONST(0.50883014254310699), + FRAC_CONST(0.51935599016558964), + FRAC_CONST(0.52980362468629461), + FRAC_CONST(0.54017147272989285), + FRAC_CONST(0.55045797293660481), + FRAC_CONST(0.56066157619733603), + FRAC_CONST(0.57078074588696726), + FRAC_CONST(0.58081395809576453), + FRAC_CONST(0.59075970185887416), + FRAC_CONST(0.60061647938386897), + FRAC_CONST(0.61038280627630948), + FRAC_CONST(0.6200572117632891), + FRAC_CONST(0.62963823891492698), + FRAC_CONST(0.63912444486377573), + FRAC_CONST(0.64851440102211244), + FRAC_CONST(0.65780669329707864), + FRAC_CONST(0.66699992230363747), + FRAC_CONST(0.67609270357531592), + FRAC_CONST(0.68508366777270036), + FRAC_CONST(0.693971460889654), + FRAC_CONST(0.7027547444572253), + FRAC_CONST(0.71143219574521643), + FRAC_CONST(0.72000250796138165), + FRAC_CONST(0.7284643904482252), + FRAC_CONST(0.73681656887736979), + FRAC_CONST(0.74505778544146595), + FRAC_CONST(0.75318679904361241), + FRAC_CONST(0.76120238548426178), + FRAC_CONST(0.76910333764557959), + FRAC_CONST(0.77688846567323244), + FRAC_CONST(0.78455659715557524), + FRAC_CONST(0.79210657730021239), + FRAC_CONST(0.79953726910790501), + FRAC_CONST(0.80684755354379922), + FRAC_CONST(0.8140363297059483), + FRAC_CONST(0.82110251499110465), + FRAC_CONST(0.8280450452577558), + FRAC_CONST(0.83486287498638001), + FRAC_CONST(0.84155497743689833), + FRAC_CONST(0.84812034480329712), + FRAC_CONST(0.85455798836540053), + FRAC_CONST(0.86086693863776731), + FRAC_CONST(0.86704624551569265), + FRAC_CONST(0.87309497841829009), + FRAC_CONST(0.87901222642863341), + FRAC_CONST(0.88479709843093779), + FRAC_CONST(0.89044872324475788), + FRAC_CONST(0.89596624975618511), + FRAC_CONST(0.90134884704602203), + FRAC_CONST(0.90659570451491533), + FRAC_CONST(0.91170603200542988), + FRAC_CONST(0.9166790599210427), + FRAC_CONST(0.9215140393420419), + FRAC_CONST(0.92621024213831127), + FRAC_CONST(0.93076696107898371), + FRAC_CONST(0.9351835099389475), + FRAC_CONST(0.93945922360218992), + FRAC_CONST(0.94359345816196039), + FRAC_CONST(0.94758559101774109), + FRAC_CONST(0.95143502096900834), + FRAC_CONST(0.95514116830577067), + FRAC_CONST(0.9587034748958716), + FRAC_CONST(0.96212140426904158), + FRAC_CONST(0.9653944416976894), + FRAC_CONST(0.96852209427441727), + FRAC_CONST(0.97150389098625178), + FRAC_CONST(0.97433938278557586), + FRAC_CONST(0.97702814265775439), + FRAC_CONST(0.97956976568544052), + FRAC_CONST(0.98196386910955524), + FRAC_CONST(0.98421009238692903), + FRAC_CONST(0.98630809724459867), + FRAC_CONST(0.98825756773074946), + FRAC_CONST(0.99005821026229712), + FRAC_CONST(0.99170975366909953), + FRAC_CONST(0.9932119492347945), + FRAC_CONST(0.99456457073425542), + FRAC_CONST(0.99576741446765982), + FRAC_CONST(0.99682029929116567), + FRAC_CONST(0.99772306664419164), + FRAC_CONST(0.99847558057329477), + FRAC_CONST(0.99907772775264536), + FRAC_CONST(0.99952941750109314), + FRAC_CONST(0.9998305817958234), + FRAC_CONST(0.99998117528260111), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1) }; -real_t ld_mid_480[] = +#ifdef ALLOW_SMALL_FRAMELENGTH +ALIGN static const real_t ld_mid_480[] = { - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x0, - 0x1ACEDD, - 0x506B6B, - 0x860472, - 0xBB9798, - 0xF12283, - 0x126A2DB, - 0x15C1646, - 0x1917A6C, - 0x1C6CCF6, - 0x1FC0B8D, - 0x23133DB, - 0x266438B, - 0x29B3849, - 0x2D00FC3, - 0x304C7A8, - 0x3395DA6, - 0x36DCF70, - 0x3A21AB9, - 0x3D63D36, - 0x40A349D, - 0x43DFEA6, - 0x471990D, - 0x4A5018D, - 0x4D835E6, - 0x50B33D8, - 0x53DF927, - 0x5708398, - 0x5A2D0F4, - 0x5D4DF07, - 0x606AB9E, - 0x638348A, - 0x669779E, - 0x69A72B2, - 0x6CB23A0, - 0x6FB8844, - 0x72B9E80, - 0x75B6437, - 0x78AD751, - 0x7B9F5B9, - 0x7E8BD5E, - 0x8172C33, - 0x845402D, - 0x872F749, - 0x8A04F85, - 0x8CD46E2, - 0x8F9DB69, - 0x9260B25, - 0x951D425, - 0x97D347F, - 0x9A82A4A, - 0x9D2B3A4, - 0x9FCCEB1, - 0xA267996, - 0xA4FB280, - 0xA7877A1, - 0xAA0C72E, - 0xAC89F62, - 0xAEFFE7F, - 0xB16E2CA, - 0xB3D4A8E, - 0xB63341D, - 0xB889DCC, - 0xBAD85F7, - 0xBD1EB00, - 0xBF5CB4E, - 0xC19254F, - 0xC3BF775, - 0xC5E4039, - 0xC7FFE1B, - 0xCA12F9F, - 0xCC1D351, - 0xCE1E7C2, - 0xD016B8A, - 0xD205D47, - 0xD3EBB9E, - 0xD5C8539, - 0xD79B8CB, - 0xD96550A, - 0xDB258B7, - 0xDCDC296, - 0xDE89173, - 0xE02C422, - 0xE1C597C, - 0xE355062, - 0xE4DA7BC, - 0xE655E78, - 0xE7C738C, - 0xE92E5F5, - 0xEA8B4B7, - 0xEBDDEDD, - 0xED26379, - 0xEE641A4, - 0xEF97881, - 0xF0C0736, - 0xF1DECF4, - 0xF2F28F2, - 0xF3FBA6E, - 0xF4FA0AE, - 0xF5EDAFF, - 0xF6D68B7, - 0xF7B4932, - 0xF887BD4, - 0xF950009, - 0xFA0D544, - 0xFABFB02, - 0xFB670C3, - 0xFC03614, - 0xFC94A86, - 0xFD1ADB3, - 0xFD95F3E, - 0xFE05ECF, - 0xFE6AC18, - 0xFEC46D2, - 0xFF12EC0, - 0xFF563A8, - 0xFF8E55C, - 0xFFBB3B6, - 0xFFDCE94, - 0xFFF35E0, - 0xFFFE98A, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000, - 0x10000000 + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0), + FRAC_CONST(0.0065449379673518581), + FRAC_CONST(0.019633692460628301), + FRAC_CONST(0.032719082821776137), + FRAC_CONST(0.045798866936520771), + FRAC_CONST(0.058870803651189033), + FRAC_CONST(0.071932653156719387), + FRAC_CONST(0.084982177372441667), + FRAC_CONST(0.09801714032956059), + FRAC_CONST(0.11103530855427769), + FRAC_CONST(0.12403445145048532), + FRAC_CONST(0.13701234168196802), + FRAC_CONST(0.14996675555404498), + FRAC_CONST(0.16289547339458874), + FRAC_CONST(0.17579627993435451), + FRAC_CONST(0.18866696468655525), + FRAC_CONST(0.2015053223256171), + FRAC_CONST(0.21430915306505074), + FRAC_CONST(0.2270762630343732), + FRAC_CONST(0.23980446465501654), + FRAC_CONST(0.25249157701515795), + FRAC_CONST(0.26513542624340797), + FRAC_CONST(0.27773384588129219), + FRAC_CONST(0.29028467725446233), + FRAC_CONST(0.3027857698425746), + FRAC_CONST(0.31523498164776964), + FRAC_CONST(0.32763017956169349), + FRAC_CONST(0.33996923973099424), + FRAC_CONST(0.35225004792123354), + FRAC_CONST(0.36447049987914965), + FRAC_CONST(0.37662850169321077), + FRAC_CONST(0.38872197015239557), + FRAC_CONST(0.40074883310314097), + FRAC_CONST(0.41270702980439467), + FRAC_CONST(0.42459451128071307), + FRAC_CONST(0.43640924067334208), + FRAC_CONST(0.44814919358922256), + FRAC_CONST(0.45981235844785984), + FRAC_CONST(0.47139673682599764), + FRAC_CONST(0.48290034380003727), + FRAC_CONST(0.49432120828614462), + FRAC_CONST(0.50565737337798455), + FRAC_CONST(0.51690689668202761), + FRAC_CONST(0.52806785065036799), + FRAC_CONST(0.53913832291100017), + FRAC_CONST(0.55011641659549337), + FRAC_CONST(0.56100025066400983), + FRAC_CONST(0.57178796022761225), + FRAC_CONST(0.58247769686780215), + FRAC_CONST(0.59306762895323706), + FRAC_CONST(0.60355594195357143), + FRAC_CONST(0.61394083875036642), + FRAC_CONST(0.62422053994501758), + FRAC_CONST(0.63439328416364549), + FRAC_CONST(0.64445732835889735), + FRAC_CONST(0.65441094810861034), + FRAC_CONST(0.66425243791128175), + FRAC_CONST(0.67398011147829784), + FRAC_CONST(0.68359230202287125), + FRAC_CONST(0.69308736254563585), + FRAC_CONST(0.70246366611685174), + FRAC_CONST(0.71171960615517138), + FRAC_CONST(0.72085359670291882), + FRAC_CONST(0.7298640726978356), + FRAC_CONST(0.73874949024124625), + FRAC_CONST(0.74750832686259672), + FRAC_CONST(0.75613908178032285), + FRAC_CONST(0.76464027615900032), + FRAC_CONST(0.77301045336273699), + FRAC_CONST(0.78124817920475853), + FRAC_CONST(0.78935204219315003), + FRAC_CONST(0.79732065377270711), + FRAC_CONST(0.80515264856285829), + FRAC_CONST(0.81284668459161513), + FRAC_CONST(0.82040144352551359), + FRAC_CONST(0.82781563089550203), + FRAC_CONST(0.83508797631874299), + FRAC_CONST(0.84221723371628654), + FRAC_CONST(0.84920218152657889), + FRAC_CONST(0.85604162291477137), + FRAC_CONST(0.86273438597779184), + FRAC_CONST(0.86927932394514362), + FRAC_CONST(0.87567531537539967), + FRAC_CONST(0.88192126434835494), + FRAC_CONST(0.88801610065280734), + FRAC_CONST(0.89395877996993212), + FRAC_CONST(0.8997482840522214), + FRAC_CONST(0.90538362089795521), + FRAC_CONST(0.91086382492117568), + FRAC_CONST(0.91618795711713596), + FRAC_CONST(0.92135510522319242), + FRAC_CONST(0.9263643838751181), + FRAC_CONST(0.93121493475880346), + FRAC_CONST(0.93590592675732565), + FRAC_CONST(0.94043655609335486), + FRAC_CONST(0.94480604646687805), + FRAC_CONST(0.94901364918821385), + FRAC_CONST(0.95305864330629697), + FRAC_CONST(0.95694033573220882), + FRAC_CONST(0.9606580613579353), + FRAC_CONST(0.96421118317032928), + FRAC_CONST(0.96759909236025976), + FRAC_CONST(0.9708212084269281), + FRAC_CONST(0.97387697927733363), + FRAC_CONST(0.97676588132087239), + FRAC_CONST(0.97948741955905139), + FRAC_CONST(0.98204112767030394), + FRAC_CONST(0.98442656808989171), + FRAC_CONST(0.98664333208487898), + FRAC_CONST(0.98869103982416728), + FRAC_CONST(0.99056934044357725), + FRAC_CONST(0.99227791210596705), + FRAC_CONST(0.99381646205637808), + FRAC_CONST(0.99518472667219682), + FRAC_CONST(0.99638247150832537), + FRAC_CONST(0.99740949133735191), + FRAC_CONST(0.99826561018471593), + FRAC_CONST(0.99895068135886012), + FRAC_CONST(0.99946458747636568), + FRAC_CONST(0.99980724048206482), + FRAC_CONST(0.99997858166412923), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1), + FRAC_CONST(1) }; #endif - #endif #ifdef __cplusplus diff --git a/src/libfaad/specrec.c b/src/libfaad/specrec.c index 81904b3a5..a509c69e1 100644 --- a/src/libfaad/specrec.c +++ b/src/libfaad/specrec.c @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: specrec.c,v 1.3 2003/04/12 14:58:47 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: specrec.c,v 1.4 2003/12/30 02:00:11 miguelfreitas Exp $ **/ /* @@ -30,11 +36,243 @@ #include "structs.h" #include <string.h> +#include <stdlib.h> #include "specrec.h" #include "syntax.h" -#include "data.h" #include "iq_table.h" +#include "ms.h" +#include "is.h" +#include "pns.h" +#include "tns.h" +#include "lt_predict.h" +#include "ic_predict.h" +#ifdef SSR_DEC +#include "ssr.h" +#include "ssr_fb.h" +#endif + + +#ifdef LD_DEC +ALIGN static const uint8_t num_swb_512_window[] = +{ + 0, 0, 0, 36, 36, 37, 31, 31, 0, 0, 0, 0 +}; +ALIGN static const uint8_t num_swb_480_window[] = +{ + 0, 0, 0, 35, 35, 37, 30, 30, 0, 0, 0, 0 +}; +#endif + +ALIGN static const uint8_t num_swb_960_window[] = +{ + 40, 40, 45, 49, 49, 49, 46, 46, 42, 42, 42, 40 +}; + +ALIGN static const uint8_t num_swb_1024_window[] = +{ + 41, 41, 47, 49, 49, 51, 47, 47, 43, 43, 43, 40 +}; + +ALIGN static const uint8_t num_swb_128_window[] = +{ + 12, 12, 12, 14, 14, 14, 15, 15, 15, 15, 15, 15 +}; + +ALIGN static const uint16_t swb_offset_1024_96[] = +{ + 0, 4, 8, 12, 16, 20, 24, 28, 32, 36, 40, 44, 48, 52, 56, + 64, 72, 80, 88, 96, 108, 120, 132, 144, 156, 172, 188, 212, 240, + 276, 320, 384, 448, 512, 576, 640, 704, 768, 832, 896, 960, 1024 +}; + +ALIGN static const uint16_t swb_offset_128_96[] = +{ + 0, 4, 8, 12, 16, 20, 24, 32, 40, 48, 64, 92, 128 +}; + +ALIGN static const uint16_t swb_offset_1024_64[] = +{ + 0, 4, 8, 12, 16, 20, 24, 28, 32, 36, 40, 44, 48, 52, 56, + 64, 72, 80, 88, 100, 112, 124, 140, 156, 172, 192, 216, 240, 268, + 304, 344, 384, 424, 464, 504, 544, 584, 624, 664, 704, 744, 784, 824, + 864, 904, 944, 984, 1024 +}; + +ALIGN static const uint16_t swb_offset_128_64[] = +{ + 0, 4, 8, 12, 16, 20, 24, 32, 40, 48, 64, 92, 128 +}; + +ALIGN static const uint16_t swb_offset_1024_48[] = +{ + 0, 4, 8, 12, 16, 20, 24, 28, 32, 36, 40, 48, 56, 64, 72, + 80, 88, 96, 108, 120, 132, 144, 160, 176, 196, 216, 240, 264, 292, + 320, 352, 384, 416, 448, 480, 512, 544, 576, 608, 640, 672, 704, 736, + 768, 800, 832, 864, 896, 928, 1024 +}; + +#ifdef LD_DEC +ALIGN static const uint16_t swb_offset_512_48[] = +{ + 0, 4, 8, 12, 16, 20, 24, 28, 32, 36, 40, 44, 48, 52, 56, 60, 68, 76, 84, + 92, 100, 112, 124, 136, 148, 164, 184, 208, 236, 268, 300, 332, 364, 396, + 428, 460, 512 +}; + +ALIGN static const uint16_t swb_offset_480_48[] = +{ + 0, 4, 8, 12, 16, 20, 24, 28, 32, 36, 40, 44, 48, 52, 56, 64, 72 ,80 ,88, + 96, 108, 120, 132, 144, 156, 172, 188, 212, 240, 272, 304, 336, 368, 400, + 432, 480 +}; +#endif + +ALIGN static const uint16_t swb_offset_128_48[] = +{ + 0, 4, 8, 12, 16, 20, 28, 36, 44, 56, 68, 80, 96, 112, 128 +}; +ALIGN static const uint16_t swb_offset_1024_32[] = +{ + 0, 4, 8, 12, 16, 20, 24, 28, 32, 36, 40, 48, 56, 64, 72, + 80, 88, 96, 108, 120, 132, 144, 160, 176, 196, 216, 240, 264, 292, + 320, 352, 384, 416, 448, 480, 512, 544, 576, 608, 640, 672, 704, 736, + 768, 800, 832, 864, 896, 928, 960, 992, 1024 +}; + +#ifdef LD_DEC +ALIGN static const uint16_t swb_offset_512_32[] = +{ + 0, 4, 8, 12, 16, 20, 24, 28, 32, 36, 40, 44, 48, 52, 56, 64, 72, 80, + 88, 96, 108, 120, 132, 144, 160, 176, 192, 212, 236, 260, 288, 320, 352, + 384, 416, 448, 480, 512 +}; + +ALIGN static const uint16_t swb_offset_480_32[] = +{ + 0, 4, 8, 12, 16, 20, 24, 28, 32, 36, 40, 44, 48, 52, 56, 60, 64, 72, 80, + 88, 96, 104, 112, 124, 136, 148, 164, 180, 200, 224, 256, 288, 320, 352, + 384, 416, 448, 480 +}; +#endif + +ALIGN static const uint16_t swb_offset_1024_24[] = +{ + 0, 4, 8, 12, 16, 20, 24, 28, 32, 36, 40, 44, 52, 60, 68, + 76, 84, 92, 100, 108, 116, 124, 136, 148, 160, 172, 188, 204, 220, + 240, 260, 284, 308, 336, 364, 396, 432, 468, 508, 552, 600, 652, 704, + 768, 832, 896, 960, 1024 +}; + +#ifdef LD_DEC +ALIGN static const uint16_t swb_offset_512_24[] = +{ + 0, 4, 8, 12, 16, 20, 24, 28, 32, 36, 40, 44, 52, 60, 68, + 80, 92, 104, 120, 140, 164, 192, 224, 256, 288, 320, 352, 384, 416, + 448, 480, 512 +}; + +ALIGN static const uint16_t swb_offset_480_24[] = +{ + 0, 4, 8, 12, 16, 20, 24, 28, 32, 36, 40, 44, 52, 60, 68, 80, 92, 104, 120, + 140, 164, 192, 224, 256, 288, 320, 352, 384, 416, 448, 480 +}; +#endif + +ALIGN static const uint16_t swb_offset_128_24[] = +{ + 0, 4, 8, 12, 16, 20, 24, 28, 36, 44, 52, 64, 76, 92, 108, 128 +}; + +ALIGN static const uint16_t swb_offset_1024_16[] = +{ + 0, 8, 16, 24, 32, 40, 48, 56, 64, 72, 80, 88, 100, 112, 124, + 136, 148, 160, 172, 184, 196, 212, 228, 244, 260, 280, 300, 320, 344, + 368, 396, 424, 456, 492, 532, 572, 616, 664, 716, 772, 832, 896, 960, 1024 +}; + +ALIGN static const uint16_t swb_offset_128_16[] = +{ + 0, 4, 8, 12, 16, 20, 24, 28, 32, 40, 48, 60, 72, 88, 108, 128 +}; + +ALIGN static const uint16_t swb_offset_1024_8[] = +{ + 0, 12, 24, 36, 48, 60, 72, 84, 96, 108, 120, 132, 144, 156, 172, + 188, 204, 220, 236, 252, 268, 288, 308, 328, 348, 372, 396, 420, 448, + 476, 508, 544, 580, 620, 664, 712, 764, 820, 880, 944, 1024 +}; + +ALIGN static const uint16_t swb_offset_128_8[] = +{ + 0, 4, 8, 12, 16, 20, 24, 28, 36, 44, 52, 60, 72, 88, 108, 128 +}; + +ALIGN static const uint16_t *swb_offset_1024_window[] = +{ + swb_offset_1024_96, /* 96000 */ + swb_offset_1024_96, /* 88200 */ + swb_offset_1024_64, /* 64000 */ + swb_offset_1024_48, /* 48000 */ + swb_offset_1024_48, /* 44100 */ + swb_offset_1024_32, /* 32000 */ + swb_offset_1024_24, /* 24000 */ + swb_offset_1024_24, /* 22050 */ + swb_offset_1024_16, /* 16000 */ + swb_offset_1024_16, /* 12000 */ + swb_offset_1024_16, /* 11025 */ + swb_offset_1024_8 /* 8000 */ +}; + +#ifdef LD_DEC +ALIGN static const uint16_t *swb_offset_512_window[] = +{ + 0, /* 96000 */ + 0, /* 88200 */ + 0, /* 64000 */ + swb_offset_512_48, /* 48000 */ + swb_offset_512_48, /* 44100 */ + swb_offset_512_32, /* 32000 */ + swb_offset_512_24, /* 24000 */ + swb_offset_512_24, /* 22050 */ + 0, /* 16000 */ + 0, /* 12000 */ + 0, /* 11025 */ + 0 /* 8000 */ +}; + +ALIGN static const uint16_t *swb_offset_480_window[] = +{ + 0, /* 96000 */ + 0, /* 88200 */ + 0, /* 64000 */ + swb_offset_480_48, /* 48000 */ + swb_offset_480_48, /* 44100 */ + swb_offset_480_32, /* 32000 */ + swb_offset_480_24, /* 24000 */ + swb_offset_480_24, /* 22050 */ + 0, /* 16000 */ + 0, /* 12000 */ + 0, /* 11025 */ + 0 /* 8000 */ +}; +#endif + +ALIGN static const uint16_t *swb_offset_128_window[] = +{ + swb_offset_128_96, /* 96000 */ + swb_offset_128_96, /* 88200 */ + swb_offset_128_64, /* 64000 */ + swb_offset_128_48, /* 48000 */ + swb_offset_128_48, /* 44100 */ + swb_offset_128_48, /* 32000 */ + swb_offset_128_24, /* 24000 */ + swb_offset_128_24, /* 22050 */ + swb_offset_128_16, /* 16000 */ + swb_offset_128_16, /* 12000 */ + swb_offset_128_16, /* 11025 */ + swb_offset_128_8 /* 8000 */ +}; #define bit_set(A, B) ((A) & (1<<(B))) @@ -183,148 +421,152 @@ uint8_t window_grouping_info(faacDecHandle hDecoder, ic_stream *ics) - Within a scalefactor window band, the coefficients are in ascending spectral order. */ -void quant_to_spec(ic_stream *ics, real_t *spec_data, uint16_t frame_len) +static void quant_to_spec(ic_stream *ics, real_t *spec_data, uint16_t frame_len) { uint8_t g, sfb, win; - uint16_t width, bin; - real_t *start_inptr, *start_win_ptr, *win_ptr; + uint16_t width, bin, k, gindex; - real_t tmp_spec[1024]; - real_t *tmp_spec_ptr, *spec_ptr; + ALIGN real_t tmp_spec[1024] = {0}; - tmp_spec_ptr = tmp_spec; - memset(tmp_spec_ptr, 0, frame_len*sizeof(real_t)); - - spec_ptr = spec_data; - tmp_spec_ptr = tmp_spec; - start_win_ptr = tmp_spec_ptr; + k = 0; + gindex = 0; for (g = 0; g < ics->num_window_groups; g++) { uint16_t j = 0; - uint16_t win_inc = 0; - - start_inptr = spec_ptr; - - win_inc = ics->swb_offset[ics->num_swb]; + uint16_t gincrease = 0; + uint16_t win_inc = ics->swb_offset[ics->num_swb]; for (sfb = 0; sfb < ics->num_swb; sfb++) { width = ics->swb_offset[sfb+1] - ics->swb_offset[sfb]; - win_ptr = start_win_ptr; - for (win = 0; win < ics->window_group_length[g]; win++) { - tmp_spec_ptr = win_ptr + j; - for (bin = 0; bin < width; bin += 4) { - tmp_spec_ptr[0] = spec_ptr[0]; - tmp_spec_ptr[1] = spec_ptr[1]; - tmp_spec_ptr[2] = spec_ptr[2]; - tmp_spec_ptr[3] = spec_ptr[3]; - tmp_spec_ptr += 4; - spec_ptr += 4; + tmp_spec[gindex+(win*win_inc)+j+bin+0] = spec_data[k+0]; + tmp_spec[gindex+(win*win_inc)+j+bin+1] = spec_data[k+1]; + tmp_spec[gindex+(win*win_inc)+j+bin+2] = spec_data[k+2]; + tmp_spec[gindex+(win*win_inc)+j+bin+3] = spec_data[k+3]; + gincrease += 4; + k += 4; } - - win_ptr += win_inc; } j += width; } - start_win_ptr += (spec_ptr - start_inptr); + gindex += gincrease; } - spec_ptr = spec_data; - tmp_spec_ptr = tmp_spec; - - memcpy(spec_ptr, tmp_spec_ptr, frame_len*sizeof(real_t)); + memcpy(spec_data, tmp_spec, frame_len*sizeof(real_t)); } -#ifndef FIXED_POINT -void build_tables(real_t *pow2_table) -{ - uint16_t i; - - /* build pow(2, 0.25*x) table for scalefactors */ - for(i = 0; i < POW_TABLE_SIZE; i++) - { - pow2_table[i] = REAL_CONST(pow(2.0, 0.25 * (i-100))); - } -} -#endif - -static INLINE real_t iquant(int16_t q) +static INLINE real_t iquant(int16_t q, const real_t *tab, uint8_t *error) { +#ifdef FIXED_POINT + static const real_t errcorr[] = { + REAL_CONST(0), REAL_CONST(1.0/8.0), REAL_CONST(2.0/8.0), REAL_CONST(3.0/8.0), + REAL_CONST(4.0/8.0), REAL_CONST(5.0/8.0), REAL_CONST(6.0/8.0), REAL_CONST(7.0/8.0), + REAL_CONST(0) + }; + real_t x1, x2; int16_t sgn = 1; - if (q == 0) return 0; - if (q < 0) { q = -q; sgn = -1; } - if (q >= IQ_TABLE_SIZE) - return sgn * iq_table[q>>3] * 16; + if (q < IQ_TABLE_SIZE) + return sgn * tab[q]; - return sgn * iq_table[q]; + /* linear interpolation */ + x1 = tab[q>>3]; + x2 = tab[(q>>3) + 1]; + return sgn * 16 * (MUL_R(errcorr[q&7],(x2-x1)) + x1); +#else + if (q < 0) + { + /* tab contains a value for all possible q [0,8192] */ + if (-q < IQ_TABLE_SIZE) + return -tab[-q]; + + *error = 17; + return 0; + } else { + /* tab contains a value for all possible q [0,8192] */ + if (q < IQ_TABLE_SIZE) + return tab[q]; + + *error = 17; + return 0; + } +#endif } -void inverse_quantization(real_t *x_invquant, int16_t *x_quant, uint16_t frame_len) +static uint8_t inverse_quantization(real_t *x_invquant, const int16_t *x_quant, const uint16_t frame_len) { int16_t i; - int16_t *in_ptr = x_quant; - real_t *out_ptr = x_invquant; + uint8_t error = 0; /* Init error flag */ + const real_t *tab = iq_table; - for(i = frame_len/4-1; i >= 0; --i) + for(i = 0; i < frame_len; i+=4) { - out_ptr[0] = iquant(in_ptr[0]); - out_ptr[1] = iquant(in_ptr[1]); - out_ptr[2] = iquant(in_ptr[2]); - out_ptr[3] = iquant(in_ptr[3]); - out_ptr += 4; - in_ptr += 4; + x_invquant[i] = iquant(x_quant[i], tab, &error); + x_invquant[i+1] = iquant(x_quant[i+1], tab, &error); + x_invquant[i+2] = iquant(x_quant[i+2], tab, &error); + x_invquant[i+3] = iquant(x_quant[i+3], tab, &error); } + + return error; } #ifndef FIXED_POINT -static INLINE real_t get_scale_factor_gain(uint16_t scale_factor, real_t *pow2_table) -{ - if (scale_factor < POW_TABLE_SIZE) - return pow2_table[scale_factor]; - else - return REAL_CONST(pow(2.0, 0.25 * (scale_factor - 100))); -} -#else -static real_t pow2_table[] = -{ - COEF_CONST(0.59460355750136), - COEF_CONST(0.70710678118655), - COEF_CONST(0.84089641525371), - COEF_CONST(1.0), - COEF_CONST(1.18920711500272), - COEF_CONST(1.41421356237310), - COEF_CONST(1.68179283050743) +ALIGN static const real_t pow2sf_tab[] = { + 2.9802322387695313E-008, 5.9604644775390625E-008, 1.1920928955078125E-007, + 2.384185791015625E-007, 4.76837158203125E-007, 9.5367431640625E-007, + 1.9073486328125E-006, 3.814697265625E-006, 7.62939453125E-006, + 1.52587890625E-005, 3.0517578125E-005, 6.103515625E-005, + 0.0001220703125, 0.000244140625, 0.00048828125, + 0.0009765625, 0.001953125, 0.00390625, + 0.0078125, 0.015625, 0.03125, + 0.0625, 0.125, 0.25, + 0.5, 1, 2, + 4, 8, 16, 32, + 64, 128, 256, + 512, 1024, 2048, + 4096, 8192, 16384, + 32768, 65536, 131072, + 262144, 524288, 1048576, + 2097152, 4194304, 8388608, + 16777216, 33554432, 67108864, + 134217728, 268435456, 536870912, + 1073741824, 2147483648, 4294967296, + 8589934592, 17179869184, 34359738368, + 68719476736, 137438953472, 274877906944 }; #endif -#ifdef FIXED_POINT -void apply_scalefactors(ic_stream *ics, real_t *x_invquant, uint16_t frame_len) -#else -void apply_scalefactors(ic_stream *ics, real_t *x_invquant, real_t *pow2_table, - uint16_t frame_len) +ALIGN static real_t pow2_table[] = +{ +#if 0 + COEF_CONST(0.59460355750136053335874998528024), /* 2^-0.75 */ + COEF_CONST(0.70710678118654752440084436210485), /* 2^-0.5 */ + COEF_CONST(0.84089641525371454303112547623321), /* 2^-0.25 */ #endif + COEF_CONST(1.0), + COEF_CONST(1.1892071150027210667174999705605), /* 2^0.25 */ + COEF_CONST(1.4142135623730950488016887242097), /* 2^0.5 */ + COEF_CONST(1.6817928305074290860622509524664) /* 2^0.75 */ +}; + +void apply_scalefactors(faacDecHandle hDecoder, ic_stream *ics, + real_t *x_invquant, uint16_t frame_len) { uint8_t g, sfb; uint16_t top; - real_t *fp; -#ifndef FIXED_POINT - real_t scale; -#else int32_t exp, frac; -#endif uint8_t groups = 0; uint16_t nshort = frame_len/8; @@ -332,56 +574,489 @@ void apply_scalefactors(ic_stream *ics, real_t *x_invquant, real_t *pow2_table, { uint16_t k = 0; - /* using this 128*groups doesn't hurt long blocks, because + /* using this nshort*groups doesn't hurt long blocks, because long blocks only have 1 group, so that means 'groups' is always 0 for long blocks */ - fp = x_invquant + (groups*nshort); - for (sfb = 0; sfb < ics->max_sfb; sfb++) { top = ics->sect_sfb_offset[g][sfb+1]; -#ifndef FIXED_POINT - scale = get_scale_factor_gain(ics->scale_factors[g][sfb], pow2_table); -#else - exp = (ics->scale_factors[g][sfb] - 100) / 4; - frac = (ics->scale_factors[g][sfb] - 100) % 4; + exp = (ics->scale_factors[g][sfb] /* - 100 */) >> 2; + frac = (ics->scale_factors[g][sfb] /* - 100 */) & 3; + +#ifdef FIXED_POINT + exp -= 25; + /* IMDCT pre-scaling */ + if (hDecoder->object_type == LD) + { + exp -= 6 /*9*/; + } else { + if (ics->window_sequence == EIGHT_SHORT_SEQUENCE) + exp -= 4 /*7*/; + else + exp -= 7 /*10*/; + } #endif /* minimum size of a sf band is 4 and always a multiple of 4 */ for ( ; k < top; k += 4) { -#ifndef FIXED_POINT - fp[0] = MUL(fp[0],scale); - fp[1] = MUL(fp[1],scale); - fp[2] = MUL(fp[2],scale); - fp[3] = MUL(fp[3],scale); -#else +#ifdef FIXED_POINT if (exp < 0) { - fp[0] >>= -exp; - fp[1] >>= -exp; - fp[2] >>= -exp; - fp[3] >>= -exp; + x_invquant[k+(groups*nshort)] >>= -exp; + x_invquant[k+(groups*nshort)+1] >>= -exp; + x_invquant[k+(groups*nshort)+2] >>= -exp; + x_invquant[k+(groups*nshort)+3] >>= -exp; } else { - fp[0] <<= exp; - fp[1] <<= exp; - fp[2] <<= exp; - fp[3] <<= exp; - } - - if (frac) - { - fp[0] = MUL_R_C(fp[0],pow2_table[frac + 3]); - fp[1] = MUL_R_C(fp[1],pow2_table[frac + 3]); - fp[2] = MUL_R_C(fp[2],pow2_table[frac + 3]); - fp[3] = MUL_R_C(fp[3],pow2_table[frac + 3]); + x_invquant[k+(groups*nshort)] <<= exp; + x_invquant[k+(groups*nshort)+1] <<= exp; + x_invquant[k+(groups*nshort)+2] <<= exp; + x_invquant[k+(groups*nshort)+3] <<= exp; } +#else + x_invquant[k+(groups*nshort)] = x_invquant[k+(groups*nshort)] * pow2sf_tab[exp/*+25*/]; + x_invquant[k+(groups*nshort)+1] = x_invquant[k+(groups*nshort)+1] * pow2sf_tab[exp/*+25*/]; + x_invquant[k+(groups*nshort)+2] = x_invquant[k+(groups*nshort)+2] * pow2sf_tab[exp/*+25*/]; + x_invquant[k+(groups*nshort)+3] = x_invquant[k+(groups*nshort)+3] * pow2sf_tab[exp/*+25*/]; #endif - fp += 4; + + x_invquant[k+(groups*nshort)] = MUL_C(x_invquant[k+(groups*nshort)],pow2_table[frac /* + 3*/]); + x_invquant[k+(groups*nshort)+1] = MUL_C(x_invquant[k+(groups*nshort)+1],pow2_table[frac /* + 3*/]); + x_invquant[k+(groups*nshort)+2] = MUL_C(x_invquant[k+(groups*nshort)+2],pow2_table[frac /* + 3*/]); + x_invquant[k+(groups*nshort)+3] = MUL_C(x_invquant[k+(groups*nshort)+3],pow2_table[frac /* + 3*/]); } } groups += ics->window_group_length[g]; } } + +#ifdef USE_SSE +void apply_scalefactors_sse(faacDecHandle hDecoder, ic_stream *ics, + real_t *x_invquant, uint16_t frame_len) +{ + uint8_t g, sfb; + uint16_t top; + int32_t exp, frac; + uint8_t groups = 0; + uint16_t nshort = frame_len/8; + + for (g = 0; g < ics->num_window_groups; g++) + { + uint16_t k = 0; + + /* using this nshort*groups doesn't hurt long blocks, because + long blocks only have 1 group, so that means 'groups' is + always 0 for long blocks + */ + for (sfb = 0; sfb < ics->max_sfb; sfb++) + { + top = ics->sect_sfb_offset[g][sfb+1]; + + exp = (ics->scale_factors[g][sfb] /* - 100 */) >> 2; + frac = (ics->scale_factors[g][sfb] /* - 100 */) & 3; + + /* minimum size of a sf band is 4 and always a multiple of 4 */ + for ( ; k < top; k += 4) + { + __m128 m1 = _mm_load_ps(&x_invquant[k+(groups*nshort)]); + __m128 m2 = _mm_load_ps1(&pow2sf_tab[exp /*+25*/]); + __m128 m3 = _mm_load_ps1(&pow2_table[frac /* + 3*/]); + __m128 m4 = _mm_mul_ps(m1, m2); + __m128 m5 = _mm_mul_ps(m3, m4); + _mm_store_ps(&x_invquant[k+(groups*nshort)], m5); + } + } + groups += ics->window_group_length[g]; + } +} +#endif + +uint8_t reconstruct_single_channel(faacDecHandle hDecoder, ic_stream *ics, + element *sce, int16_t *spec_data) +{ + uint8_t retval; + ALIGN real_t spec_coef[1024]; + +#ifdef PROFILE + int64_t count = faad_get_ts(); +#endif + + /* inverse quantization */ + retval = inverse_quantization(spec_coef, spec_data, hDecoder->frameLength); + if (retval > 0) + return retval; + + /* apply scalefactors */ +#ifndef USE_SSE + apply_scalefactors(hDecoder, ics, spec_coef, hDecoder->frameLength); +#else + hDecoder->apply_sf_func(hDecoder, ics, spec_coef, hDecoder->frameLength); +#endif + + /* deinterleave short block grouping */ + if (ics->window_sequence == EIGHT_SHORT_SEQUENCE) + quant_to_spec(ics, spec_coef, hDecoder->frameLength); + +#ifdef PROFILE + count = faad_get_ts() - count; + hDecoder->requant_cycles += count; +#endif + + + /* pns decoding */ + pns_decode(ics, NULL, spec_coef, NULL, hDecoder->frameLength, 0, hDecoder->object_type); + +#ifdef MAIN_DEC + /* MAIN object type prediction */ + if (hDecoder->object_type == MAIN) + { + /* allocate the state only when needed */ + if (hDecoder->pred_stat[sce->channel] == NULL) + { + hDecoder->pred_stat[sce->channel] = (pred_state*)faad_malloc(hDecoder->frameLength * sizeof(pred_state)); + reset_all_predictors(hDecoder->pred_stat[sce->channel], hDecoder->frameLength); + } + + /* intra channel prediction */ + ic_prediction(ics, spec_coef, hDecoder->pred_stat[sce->channel], hDecoder->frameLength, + hDecoder->sf_index); + + /* In addition, for scalefactor bands coded by perceptual + noise substitution the predictors belonging to the + corresponding spectral coefficients are reset. + */ + pns_reset_pred_state(ics, hDecoder->pred_stat[sce->channel]); + } +#endif + +#ifdef LTP_DEC + if (is_ltp_ot(hDecoder->object_type)) + { +#ifdef LD_DEC + if (hDecoder->object_type == LD) + { + if (ics->ltp.data_present) + { + if (ics->ltp.lag_update) + hDecoder->ltp_lag[sce->channel] = ics->ltp.lag; + } + ics->ltp.lag = hDecoder->ltp_lag[sce->channel]; + } +#endif + + /* allocate the state only when needed */ + if (hDecoder->lt_pred_stat[sce->channel] == NULL) + { + hDecoder->lt_pred_stat[sce->channel] = (int16_t*)faad_malloc(hDecoder->frameLength*4 * sizeof(int16_t)); + memset(hDecoder->lt_pred_stat[sce->channel], 0, hDecoder->frameLength*4 * sizeof(int16_t)); + } + + /* long term prediction */ + lt_prediction(ics, &(ics->ltp), spec_coef, hDecoder->lt_pred_stat[sce->channel], hDecoder->fb, + ics->window_shape, hDecoder->window_shape_prev[sce->channel], + hDecoder->sf_index, hDecoder->object_type, hDecoder->frameLength); + } +#endif + + /* tns decoding */ + tns_decode_frame(ics, &(ics->tns), hDecoder->sf_index, hDecoder->object_type, + spec_coef, hDecoder->frameLength); + + /* drc decoding */ + if (hDecoder->drc->present) + { + if (!hDecoder->drc->exclude_mask[sce->channel] || !hDecoder->drc->excluded_chns_present) + drc_decode(hDecoder->drc, spec_coef); + } + + if (hDecoder->time_out[sce->channel] == NULL) + { + hDecoder->time_out[sce->channel] = (real_t*)faad_malloc(hDecoder->frameLength*2*sizeof(real_t)); + memset(hDecoder->time_out[sce->channel], 0, hDecoder->frameLength*2*sizeof(real_t)); + } + + /* filter bank */ +#ifdef SSR_DEC + if (hDecoder->object_type != SSR) + { +#endif +#ifdef USE_SSE + hDecoder->fb->if_func(hDecoder->fb, ics->window_sequence, ics->window_shape, + hDecoder->window_shape_prev[sce->channel], spec_coef, + hDecoder->time_out[sce->channel], hDecoder->object_type, hDecoder->frameLength); +#else + ifilter_bank(hDecoder->fb, ics->window_sequence, ics->window_shape, + hDecoder->window_shape_prev[sce->channel], spec_coef, + hDecoder->time_out[sce->channel], hDecoder->object_type, hDecoder->frameLength); +#endif +#ifdef SSR_DEC + } else { + if (hDecoder->ssr_overlap[sce->channel] == NULL) + { + hDecoder->ssr_overlap[sce->channel] = (real_t*)faad_malloc(2*hDecoder->frameLength*sizeof(real_t)); + memset(hDecoder->ssr_overlap[sce->channel], 0, 2*hDecoder->frameLength*sizeof(real_t)); + } + if (hDecoder->prev_fmd[sce->channel] == NULL) + { + uint16_t k; + hDecoder->prev_fmd[sce->channel] = (real_t*)faad_malloc(2*hDecoder->frameLength*sizeof(real_t)); + for (k = 0; k < 2*hDecoder->frameLength; k++) + hDecoder->prev_fmd[sce->channel][k] = REAL_CONST(-1); + } + + ssr_decode(&(ics->ssr), hDecoder->fb, ics->window_sequence, ics->window_shape, + hDecoder->window_shape_prev[sce->channel], spec_coef, hDecoder->time_out[sce->channel], + hDecoder->ssr_overlap[sce->channel], hDecoder->ipqf_buffer[sce->channel], hDecoder->prev_fmd[sce->channel], + hDecoder->frameLength); + } +#endif + + /* save window shape for next frame */ + hDecoder->window_shape_prev[sce->channel] = ics->window_shape; + +#ifdef LTP_DEC + if (is_ltp_ot(hDecoder->object_type)) + { + lt_update_state(hDecoder->lt_pred_stat[sce->channel], hDecoder->time_out[sce->channel], + hDecoder->time_out[sce->channel]+hDecoder->frameLength, hDecoder->frameLength, hDecoder->object_type); + } +#endif + + return 0; +} + +uint8_t reconstruct_channel_pair(faacDecHandle hDecoder, ic_stream *ics1, ic_stream *ics2, + element *cpe, int16_t *spec_data1, int16_t *spec_data2) +{ + uint8_t retval; + ALIGN real_t spec_coef1[1024]; + ALIGN real_t spec_coef2[1024]; + +#ifdef PROFILE + int64_t count = faad_get_ts(); +#endif + + /* inverse quantization */ + retval = inverse_quantization(spec_coef1, spec_data1, hDecoder->frameLength); + if (retval > 0) + return retval; + + retval = inverse_quantization(spec_coef2, spec_data2, hDecoder->frameLength); + if (retval > 0) + return retval; + + /* apply scalefactors */ +#ifndef USE_SSE + apply_scalefactors(hDecoder, ics1, spec_coef1, hDecoder->frameLength); + apply_scalefactors(hDecoder, ics2, spec_coef2, hDecoder->frameLength); +#else + hDecoder->apply_sf_func(hDecoder, ics1, spec_coef1, hDecoder->frameLength); + hDecoder->apply_sf_func(hDecoder, ics2, spec_coef2, hDecoder->frameLength); +#endif + + /* deinterleave short block grouping */ + if (ics1->window_sequence == EIGHT_SHORT_SEQUENCE) + quant_to_spec(ics1, spec_coef1, hDecoder->frameLength); + if (ics2->window_sequence == EIGHT_SHORT_SEQUENCE) + quant_to_spec(ics2, spec_coef2, hDecoder->frameLength); + +#ifdef PROFILE + count = faad_get_ts() - count; + hDecoder->requant_cycles += count; +#endif + + + /* pns decoding */ + if (ics1->ms_mask_present) + { + pns_decode(ics1, ics2, spec_coef1, spec_coef2, hDecoder->frameLength, 1, hDecoder->object_type); + } else { + pns_decode(ics1, NULL, spec_coef1, NULL, hDecoder->frameLength, 0, hDecoder->object_type); + pns_decode(ics2, NULL, spec_coef2, NULL, hDecoder->frameLength, 0, hDecoder->object_type); + } + + /* mid/side decoding */ + ms_decode(ics1, ics2, spec_coef1, spec_coef2, hDecoder->frameLength); + + /* intensity stereo decoding */ + is_decode(ics1, ics2, spec_coef1, spec_coef2, hDecoder->frameLength); + +#ifdef MAIN_DEC + /* MAIN object type prediction */ + if (hDecoder->object_type == MAIN) + { + /* allocate the state only when needed */ + if (hDecoder->pred_stat[cpe->channel] == NULL) + { + hDecoder->pred_stat[cpe->channel] = (pred_state*)faad_malloc(hDecoder->frameLength * sizeof(pred_state)); + reset_all_predictors(hDecoder->pred_stat[cpe->channel], hDecoder->frameLength); + } + if (hDecoder->pred_stat[cpe->paired_channel] == NULL) + { + hDecoder->pred_stat[cpe->paired_channel] = (pred_state*)faad_malloc(hDecoder->frameLength * sizeof(pred_state)); + reset_all_predictors(hDecoder->pred_stat[cpe->paired_channel], hDecoder->frameLength); + } + + /* intra channel prediction */ + ic_prediction(ics1, spec_coef1, hDecoder->pred_stat[cpe->channel], hDecoder->frameLength, + hDecoder->sf_index); + ic_prediction(ics2, spec_coef2, hDecoder->pred_stat[cpe->paired_channel], hDecoder->frameLength, + hDecoder->sf_index); + + /* In addition, for scalefactor bands coded by perceptual + noise substitution the predictors belonging to the + corresponding spectral coefficients are reset. + */ + pns_reset_pred_state(ics1, hDecoder->pred_stat[cpe->channel]); + pns_reset_pred_state(ics2, hDecoder->pred_stat[cpe->paired_channel]); + } +#endif + +#ifdef LTP_DEC + if (is_ltp_ot(hDecoder->object_type)) + { + ltp_info *ltp1 = &(ics1->ltp); + ltp_info *ltp2 = (cpe->common_window) ? &(ics2->ltp2) : &(ics2->ltp) ; +#ifdef LD_DEC + if (hDecoder->object_type == LD) + { + if (ltp1->data_present) + { + if (ltp1->lag_update) + hDecoder->ltp_lag[cpe->channel] = ltp1->lag; + } + ltp1->lag = hDecoder->ltp_lag[cpe->channel]; + if (ltp2->data_present) + { + if (ltp2->lag_update) + hDecoder->ltp_lag[cpe->paired_channel] = ltp2->lag; + } + ltp2->lag = hDecoder->ltp_lag[cpe->paired_channel]; + } +#endif + + /* allocate the state only when needed */ + if (hDecoder->lt_pred_stat[cpe->channel] == NULL) + { + hDecoder->lt_pred_stat[cpe->channel] = (int16_t*)faad_malloc(hDecoder->frameLength*4 * sizeof(int16_t)); + memset(hDecoder->lt_pred_stat[cpe->channel], 0, hDecoder->frameLength*4 * sizeof(int16_t)); + } + if (hDecoder->lt_pred_stat[cpe->paired_channel] == NULL) + { + hDecoder->lt_pred_stat[cpe->paired_channel] = (int16_t*)faad_malloc(hDecoder->frameLength*4 * sizeof(int16_t)); + memset(hDecoder->lt_pred_stat[cpe->paired_channel], 0, hDecoder->frameLength*4 * sizeof(int16_t)); + } + + /* long term prediction */ + lt_prediction(ics1, ltp1, spec_coef1, hDecoder->lt_pred_stat[cpe->channel], hDecoder->fb, + ics1->window_shape, hDecoder->window_shape_prev[cpe->channel], + hDecoder->sf_index, hDecoder->object_type, hDecoder->frameLength); + lt_prediction(ics2, ltp2, spec_coef2, hDecoder->lt_pred_stat[cpe->paired_channel], hDecoder->fb, + ics2->window_shape, hDecoder->window_shape_prev[cpe->paired_channel], + hDecoder->sf_index, hDecoder->object_type, hDecoder->frameLength); + } +#endif + + /* tns decoding */ + tns_decode_frame(ics1, &(ics1->tns), hDecoder->sf_index, hDecoder->object_type, + spec_coef1, hDecoder->frameLength); + tns_decode_frame(ics2, &(ics2->tns), hDecoder->sf_index, hDecoder->object_type, + spec_coef2, hDecoder->frameLength); + + /* drc decoding */ + if (hDecoder->drc->present) + { + if (!hDecoder->drc->exclude_mask[cpe->channel] || !hDecoder->drc->excluded_chns_present) + drc_decode(hDecoder->drc, spec_coef1); + if (!hDecoder->drc->exclude_mask[cpe->paired_channel] || !hDecoder->drc->excluded_chns_present) + drc_decode(hDecoder->drc, spec_coef2); + } + + if (hDecoder->time_out[cpe->channel] == NULL) + { + hDecoder->time_out[cpe->channel] = (real_t*)faad_malloc(hDecoder->frameLength*2*sizeof(real_t)); + memset(hDecoder->time_out[cpe->channel], 0, hDecoder->frameLength*2*sizeof(real_t)); + } + if (hDecoder->time_out[cpe->paired_channel] == NULL) + { + hDecoder->time_out[cpe->paired_channel] = (real_t*)faad_malloc(hDecoder->frameLength*2*sizeof(real_t)); + memset(hDecoder->time_out[cpe->paired_channel], 0, hDecoder->frameLength*2*sizeof(real_t)); + } + + /* filter bank */ +#ifdef SSR_DEC + if (hDecoder->object_type != SSR) + { +#endif +#ifdef USE_SSE + hDecoder->fb->if_func(hDecoder->fb, ics1->window_sequence, ics1->window_shape, + hDecoder->window_shape_prev[cpe->channel], spec_coef1, + hDecoder->time_out[cpe->channel], hDecoder->object_type, hDecoder->frameLength); + hDecoder->fb->if_func(hDecoder->fb, ics2->window_sequence, ics2->window_shape, + hDecoder->window_shape_prev[cpe->paired_channel], spec_coef2, + hDecoder->time_out[cpe->paired_channel], hDecoder->object_type, hDecoder->frameLength); +#else + ifilter_bank(hDecoder->fb, ics1->window_sequence, ics1->window_shape, + hDecoder->window_shape_prev[cpe->channel], spec_coef1, + hDecoder->time_out[cpe->channel], hDecoder->object_type, hDecoder->frameLength); + ifilter_bank(hDecoder->fb, ics2->window_sequence, ics2->window_shape, + hDecoder->window_shape_prev[cpe->paired_channel], spec_coef2, + hDecoder->time_out[cpe->paired_channel], hDecoder->object_type, hDecoder->frameLength); +#endif +#ifdef SSR_DEC + } else { + if (hDecoder->ssr_overlap[cpe->channel] == NULL) + { + hDecoder->ssr_overlap[cpe->channel] = (real_t*)faad_malloc(2*hDecoder->frameLength*sizeof(real_t)); + memset(hDecoder->ssr_overlap[cpe->channel], 0, 2*hDecoder->frameLength*sizeof(real_t)); + } + if (hDecoder->ssr_overlap[cpe->paired_channel] == NULL) + { + hDecoder->ssr_overlap[cpe->paired_channel] = (real_t*)faad_malloc(2*hDecoder->frameLength*sizeof(real_t)); + memset(hDecoder->ssr_overlap[cpe->paired_channel], 0, 2*hDecoder->frameLength*sizeof(real_t)); + } + if (hDecoder->prev_fmd[cpe->channel] == NULL) + { + uint16_t k; + hDecoder->prev_fmd[cpe->channel] = (real_t*)faad_malloc(2*hDecoder->frameLength*sizeof(real_t)); + for (k = 0; k < 2*hDecoder->frameLength; k++) + hDecoder->prev_fmd[cpe->channel][k] = REAL_CONST(-1); + } + if (hDecoder->prev_fmd[cpe->paired_channel] == NULL) + { + uint16_t k; + hDecoder->prev_fmd[cpe->paired_channel] = (real_t*)faad_malloc(2*hDecoder->frameLength*sizeof(real_t)); + for (k = 0; k < 2*hDecoder->frameLength; k++) + hDecoder->prev_fmd[cpe->paired_channel][k] = REAL_CONST(-1); + } + + ssr_decode(&(ics1->ssr), hDecoder->fb, ics1->window_sequence, ics1->window_shape, + hDecoder->window_shape_prev[cpe->channel], spec_coef1, hDecoder->time_out[cpe->channel], + hDecoder->ssr_overlap[cpe->channel], hDecoder->ipqf_buffer[cpe->channel], + hDecoder->prev_fmd[cpe->channel], hDecoder->frameLength); + ssr_decode(&(ics2->ssr), hDecoder->fb, ics2->window_sequence, ics2->window_shape, + hDecoder->window_shape_prev[cpe->paired_channel], spec_coef2, hDecoder->time_out[cpe->paired_channel], + hDecoder->ssr_overlap[cpe->paired_channel], hDecoder->ipqf_buffer[cpe->paired_channel], + hDecoder->prev_fmd[cpe->paired_channel], hDecoder->frameLength); + } +#endif + + /* save window shape for next frame */ + hDecoder->window_shape_prev[cpe->channel] = ics1->window_shape; + hDecoder->window_shape_prev[cpe->paired_channel] = ics2->window_shape; + +#ifdef LTP_DEC + if (is_ltp_ot(hDecoder->object_type)) + { + lt_update_state(hDecoder->lt_pred_stat[cpe->channel], hDecoder->time_out[cpe->channel], + hDecoder->time_out[cpe->channel]+hDecoder->frameLength, hDecoder->frameLength, hDecoder->object_type); + lt_update_state(hDecoder->lt_pred_stat[cpe->paired_channel], hDecoder->time_out[cpe->paired_channel], + hDecoder->time_out[cpe->paired_channel]+hDecoder->frameLength, hDecoder->frameLength, + hDecoder->object_type); + } +#endif + + return 0; +} diff --git a/src/libfaad/specrec.h b/src/libfaad/specrec.h index 882c13c4d..cf3fe222a 100644 --- a/src/libfaad/specrec.h +++ b/src/libfaad/specrec.h @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: specrec.h,v 1.2 2002/12/16 19:01:16 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: specrec.h,v 1.3 2003/12/30 02:00:11 miguelfreitas Exp $ **/ #ifndef __SPECREC_H__ @@ -29,15 +35,18 @@ extern "C" { #include "syntax.h" uint8_t window_grouping_info(faacDecHandle hDecoder, ic_stream *ics); -void quant_to_spec(ic_stream *ics, real_t *spec_data, uint16_t frame_len); -void inverse_quantization(real_t *x_invquant, int16_t *x_quant, uint16_t frame_len); -#ifdef FIXED_POINT -void apply_scalefactors(ic_stream *ics, real_t *x_invquant, uint16_t frame_len); -#else -void build_tables(real_t *pow2_table); -void apply_scalefactors(ic_stream *ics, real_t *x_invquant, real_t *pow2_table, +static void quant_to_spec(ic_stream *ics, real_t *spec_data, uint16_t frame_len); +static uint8_t inverse_quantization(real_t *x_invquant, const int16_t *x_quant, const uint16_t frame_len); +void apply_scalefactors(faacDecHandle hDecoder, ic_stream *ics, real_t *x_invquant, uint16_t frame_len); +#ifdef USE_SSE +void apply_scalefactors_sse(faacDecHandle hDecoder, ic_stream *ics, real_t *x_invquant, + uint16_t frame_len); #endif +uint8_t reconstruct_channel_pair(faacDecHandle hDecoder, ic_stream *ics1, ic_stream *ics2, + element *cpe, int16_t *spec_data1, int16_t *spec_data2); +uint8_t reconstruct_single_channel(faacDecHandle hDecoder, ic_stream *ics, element *sce, + int16_t *spec_data); #ifdef __cplusplus } diff --git a/src/libfaad/ssr.c b/src/libfaad/ssr.c index a4865a25d..dccd36964 100644 --- a/src/libfaad/ssr.c +++ b/src/libfaad/ssr.c @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: ssr.c,v 1.1 2002/12/16 19:01:17 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: ssr.c,v 1.2 2003/12/30 02:00:11 miguelfreitas Exp $ **/ #include "common.h" @@ -37,11 +43,8 @@ void ssr_decode(ssr_info *ssr, fb_info *fb, uint8_t window_sequence, { uint8_t band; uint16_t ssr_frame_len = frame_len/SSR_BANDS; - real_t time_tmp[2048]; - real_t output[1024]; - - memset(output, 0, 1024*sizeof(real_t)); - memset(time_tmp, 0, 2048*sizeof(real_t)); + real_t time_tmp[2048] = {0}; + real_t output[1024] = {0}; for (band = 0; band < SSR_BANDS; band++) { @@ -84,7 +87,7 @@ static void ssr_gain_control(ssr_info *ssr, real_t *data, real_t *output, if (window_sequence != EIGHT_SHORT_SEQUENCE) { ssr_gc_function(ssr, &prev_fmd[band * frame_len*2], - gc_function, window_sequence, frame_len); + gc_function, window_sequence, band, frame_len); for (i = 0; i < frame_len*2; i++) data[band * frame_len*2 + i] *= gc_function[i]; @@ -130,7 +133,7 @@ static void ssr_gain_control(ssr_info *ssr, real_t *data, real_t *output, static void ssr_gc_function(ssr_info *ssr, real_t *prev_fmd, real_t *gc_function, uint8_t window_sequence, - uint16_t frame_len) + uint8_t band, uint16_t frame_len) { uint16_t i; uint16_t len_area1, len_area2; diff --git a/src/libfaad/ssr.h b/src/libfaad/ssr.h index e562f2a1d..6f4bfe997 100644 --- a/src/libfaad/ssr.h +++ b/src/libfaad/ssr.h @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: ssr.h,v 1.1 2002/12/16 19:01:29 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: ssr.h,v 1.2 2003/12/30 02:00:11 miguelfreitas Exp $ **/ #ifndef __SSR_H__ diff --git a/src/libfaad/ssr_fb.c b/src/libfaad/ssr_fb.c index 8ad869d68..8a73c1810 100644 --- a/src/libfaad/ssr_fb.c +++ b/src/libfaad/ssr_fb.c @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: ssr_fb.c,v 1.1 2002/12/16 19:01:32 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: ssr_fb.c,v 1.2 2003/12/30 02:00:11 miguelfreitas Exp $ **/ #include "common.h" @@ -36,7 +42,7 @@ fb_info *ssr_filter_bank_init(uint16_t frame_len) { uint16_t nshort = frame_len/8; - fb_info *fb = (fb_info*)malloc(sizeof(fb_info)); + fb_info *fb = (fb_info*)faad_malloc(sizeof(fb_info)); memset(fb, 0, sizeof(fb_info)); /* normal */ @@ -56,7 +62,7 @@ void ssr_filter_bank_end(fb_info *fb) faad_mdct_end(fb->mdct256); faad_mdct_end(fb->mdct2048); - if (fb) free(fb); + if (fb) faad_free(fb); } static INLINE void imdct_ssr(fb_info *fb, real_t *in_data, @@ -96,7 +102,7 @@ void ssr_ifilter_bank(fb_info *fb, uint8_t window_sequence, uint8_t window_shape uint16_t nflat_ls = (nlong-nshort)/2; - transf_buf = (real_t*)malloc(2*nlong*sizeof(real_t)); + transf_buf = (real_t*)faad_malloc(2*nlong*sizeof(real_t)); window_long = fb->long_window[window_shape]; window_long_prev = fb->long_window[window_shape_prev]; @@ -169,7 +175,7 @@ void ssr_ifilter_bank(fb_info *fb, uint8_t window_sequence, uint8_t window_shape break; } - free(transf_buf); + faad_free(transf_buf); } diff --git a/src/libfaad/ssr_fb.h b/src/libfaad/ssr_fb.h index 55eebf130..860d1ad4a 100644 --- a/src/libfaad/ssr_fb.h +++ b/src/libfaad/ssr_fb.h @@ -16,7 +16,7 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: ssr_fb.h,v 1.1 2002/12/16 19:01:38 miguelfreitas Exp $ +** $Id: ssr_fb.h,v 1.2 2003/12/30 02:00:11 miguelfreitas Exp $ **/ #ifndef __SSR_FB_H__ diff --git a/src/libfaad/ssr_ipqf.c b/src/libfaad/ssr_ipqf.c index 78a50870b..6ca22bc4a 100644 --- a/src/libfaad/ssr_ipqf.c +++ b/src/libfaad/ssr_ipqf.c @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: ssr_ipqf.c,v 1.1 2002/12/16 19:01:44 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: ssr_ipqf.c,v 1.2 2003/12/30 02:00:11 miguelfreitas Exp $ **/ #include "common.h" diff --git a/src/libfaad/ssr_ipqf.h b/src/libfaad/ssr_ipqf.h index 655db7ffe..fae364020 100644 --- a/src/libfaad/ssr_ipqf.h +++ b/src/libfaad/ssr_ipqf.h @@ -16,7 +16,7 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: ssr_ipqf.h,v 1.1 2002/12/16 19:01:50 miguelfreitas Exp $ +** $Id: ssr_ipqf.h,v 1.2 2003/12/30 02:00:11 miguelfreitas Exp $ **/ #ifndef __SSR_IPQF_H__ diff --git a/src/libfaad/ssr_win.h b/src/libfaad/ssr_win.h index cb38d541f..c7516231b 100644 --- a/src/libfaad/ssr_win.h +++ b/src/libfaad/ssr_win.h @@ -16,7 +16,7 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: ssr_win.h,v 1.1 2002/12/16 19:01:54 miguelfreitas Exp $ +** $Id: ssr_win.h,v 1.2 2003/12/30 02:00:11 miguelfreitas Exp $ **/ #ifndef __SSR_WIN_H__ diff --git a/src/libfaad/structs.h b/src/libfaad/structs.h index 8a857dae3..6afef3390 100644 --- a/src/libfaad/structs.h +++ b/src/libfaad/structs.h @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: structs.h,v 1.2 2003/04/12 14:58:47 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: structs.h,v 1.3 2003/12/30 02:00:11 miguelfreitas Exp $ **/ #ifndef __STRUCTS_H__ @@ -26,6 +32,11 @@ extern "C" { #endif +#include "cfft.h" +#ifdef SBR_DEC +#include "sbr_dec.h" +#endif + #define MAX_CHANNELS 64 #define MAX_SYNTAX_ELEMENTS 48 #define MAX_WINDOW_GROUPS 8 @@ -35,32 +46,27 @@ extern "C" { /* used to save the prediction state */ typedef struct { - real_t r[2]; - real_t KOR[2]; - real_t VAR[2]; + int16_t r[2]; + int16_t COR[2]; + int16_t VAR[2]; } pred_state; -typedef struct -{ - uint16_t n; - uint16_t ifac[15]; - complex_t *work; - complex_t *tab; -} cfft_info; - typedef struct { uint16_t N; cfft_info *cfft; complex_t *sincos; - complex_t *Z1; +#ifdef PROFILE + int64_t cycles; + int64_t fft_cycles; +#endif } mdct_info; typedef struct { - real_t *long_window[2]; - real_t *short_window[2]; + const real_t *long_window[2]; + const real_t *short_window[2]; #ifdef LD_DEC - real_t *ld_window[2]; + const real_t *ld_window[2]; #endif mdct_info *mdct256; @@ -68,6 +74,12 @@ typedef struct mdct_info *mdct1024; #endif mdct_info *mdct2048; +#ifdef PROFILE + int64_t cycles; +#endif +#ifdef USE_SSE + void (*if_func)(void *a, uint8_t b, uint8_t c, uint8_t d, real_t *e, real_t *f, uint8_t g, uint16_t h); +#endif } fb_info; typedef struct @@ -121,6 +133,14 @@ typedef struct uint8_t comment_field_bytes; uint8_t comment_field_data[257]; + + /* extra added values */ + uint8_t num_front_channels; + uint8_t num_side_channels; + uint8_t num_back_channels; + uint8_t num_lfe_channels; + uint8_t sce_channel[16]; + uint8_t cpe_channel[16]; } program_config; typedef struct @@ -142,6 +162,9 @@ typedef struct uint16_t adts_buffer_fullness; uint8_t no_raw_data_blocks_in_frame; uint16_t crc_check; + + /* control param */ + uint8_t old_format; } adts_header; typedef struct @@ -155,7 +178,8 @@ typedef struct uint8_t num_program_config_elements; uint32_t adif_buffer_fullness; - program_config pce; + /* maximum of 16 PCEs */ + program_config pce[16]; } adif_header; typedef struct @@ -230,7 +254,7 @@ typedef struct uint8_t num_sec[8]; /* number of sections in a group */ uint8_t global_gain; - int16_t scale_factors[8][51]; + int16_t scale_factors[8][51]; /* [0..255] */ uint8_t ms_mask_present; uint8_t ms_used[MAX_WINDOW_GROUPS][MAX_SFB]; @@ -298,6 +322,8 @@ typedef struct mp4AudioSpecificConfig uint8_t aacSpectralDataResilienceFlag; uint8_t epConfig; + int8_t sbr_present_flag; + int8_t forceUpSampling; } mp4AudioSpecificConfig; typedef struct faacDecConfiguration @@ -305,6 +331,8 @@ typedef struct faacDecConfiguration uint8_t defObjectType; uint32_t defSampleRate; uint8_t outputFormat; + uint8_t downMatrix; + uint8_t useOldADTSFormat; } faacDecConfiguration, *faacDecConfigurationPtr; typedef struct faacDecFrameInfo @@ -314,6 +342,22 @@ typedef struct faacDecFrameInfo uint8_t channels; uint8_t error; uint32_t samplerate; + + /* SBR: 0: off, 1: on; normal, 2: on; downsampled */ + uint8_t sbr; + + /* MPEG-4 ObjectType */ + uint8_t object_type; + + /* AAC header type; MP4 will be signalled as RAW also */ + uint8_t header_type; + + /* multichannel configuration */ + uint8_t num_front_channels; + uint8_t num_side_channels; + uint8_t num_back_channels; + uint8_t num_lfe_channels; + uint8_t channel_position[MAX_CHANNELS]; } faacDecFrameInfo; typedef struct @@ -329,9 +373,13 @@ typedef struct uint8_t aacSpectralDataResilienceFlag; #endif uint16_t frameLength; + uint8_t postSeekResetFlag; uint32_t frame; + uint8_t downMatrix; + uint8_t first_syn_ele; + uint8_t has_lfe; uint8_t fr_channels; uint8_t fr_ch_ele; @@ -346,6 +394,20 @@ typedef struct real_t *time_out[MAX_CHANNELS]; +#ifdef SBR_DEC + int8_t sbr_present_flag; + int8_t forceUpSampling; + + real_t *time_out2[MAX_CHANNELS]; + + uint8_t sbr_used[32]; + + sbr_info *sbr[32]; +#ifdef DRM + int8_t lcstereo_flag; +#endif +#endif + #ifdef SSR_DEC real_t *ssr_overlap[MAX_CHANNELS]; real_t *prev_fmd[MAX_CHANNELS]; @@ -356,17 +418,30 @@ typedef struct pred_state *pred_stat[MAX_CHANNELS]; #endif #ifdef LTP_DEC - real_t *lt_pred_stat[MAX_CHANNELS]; + int16_t *lt_pred_stat[MAX_CHANNELS]; #endif -#ifndef FIXED_POINT -#if POW_TABLE_SIZE - real_t *pow2_table; -#endif -#endif + /* Program Config Element */ + uint8_t pce_set; + program_config pce; + uint8_t element_id[MAX_CHANNELS]; + uint8_t channel_element[MAX_CHANNELS]; + uint8_t internal_channel[MAX_CHANNELS]; /* Configuration data */ faacDecConfiguration config; + +#ifdef USE_SSE + void (*apply_sf_func)(void *a, void *b, void *c, uint16_t d); +#endif + +#ifdef PROFILE + int64_t cycles; + int64_t spectral_cycles; + int64_t output_cycles; + int64_t scalefac_cycles; + int64_t requant_cycles; +#endif } faacDecStruct, *faacDecHandle; diff --git a/src/libfaad/syntax.c b/src/libfaad/syntax.c index 08b3e6747..dda0f02de 100644 --- a/src/libfaad/syntax.c +++ b/src/libfaad/syntax.c @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: syntax.c,v 1.4 2003/04/12 14:58:47 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: syntax.c,v 1.5 2003/12/30 02:00:11 miguelfreitas Exp $ **/ /* @@ -34,54 +40,30 @@ #include "specrec.h" #include "huffman.h" #include "bits.h" -#include "data.h" #include "pulse.h" #include "analysis.h" #include "drc.h" #ifdef ERROR_RESILIENCE #include "rvlc.h" #endif - -/* static declarations moved to avoid compiler warnings [MF] */ -/* static functions */ -static uint8_t single_lfe_channel_element(faacDecHandle hDecoder, - element *sce, bitfile *ld, - int16_t *spec_data); -static uint8_t channel_pair_element(faacDecHandle hDecoder, element *cpe, - bitfile *ld, int16_t *spec_data1, - int16_t *spec_data2); -static uint16_t data_stream_element(bitfile *ld); -static uint8_t program_config_element(program_config *pce, bitfile *ld); -static uint8_t fill_element(bitfile *ld, drc_info *drc); -static uint8_t individual_channel_stream(faacDecHandle hDecoder, element *ele, - bitfile *ld, ic_stream *ics, uint8_t scal_flag, - int16_t *spec_data); -static uint8_t ics_info(faacDecHandle hDecoder, ic_stream *ics, bitfile *ld, - uint8_t common_window); -static void section_data(faacDecHandle hDecoder, ic_stream *ics, bitfile *ld); -static uint8_t scale_factor_data(faacDecHandle hDecoder, ic_stream *ics, bitfile *ld); -static void gain_control_data(bitfile *ld, ic_stream *ics); -static uint8_t spectral_data(faacDecHandle hDecoder, ic_stream *ics, bitfile *ld, - int16_t *spectral_data); -static uint16_t extension_payload(bitfile *ld, drc_info *drc, uint16_t count); -static void pulse_data(ic_stream *ics, pulse_info *pul, bitfile *ld); -static void tns_data(ic_stream *ics, tns_info *tns, bitfile *ld); -static void ltp_data(faacDecHandle hDecoder, ic_stream *ics, ltp_info *ltp, bitfile *ld); -static uint8_t adts_fixed_header(adts_header *adts, bitfile *ld); -static void adts_variable_header(adts_header *adts, bitfile *ld); -static void adts_error_check(adts_header *adts, bitfile *ld); -static uint8_t dynamic_range_info(bitfile *ld, drc_info *drc); -static uint8_t excluded_channels(bitfile *ld, drc_info *drc); +#ifdef SBR_DEC +#include "sbr_syntax.h" +#endif /* Table 4.4.1 */ -int8_t GASpecificConfig(bitfile *ld, mp4AudioSpecificConfig *mp4ASC) +int8_t GASpecificConfig(bitfile *ld, mp4AudioSpecificConfig *mp4ASC, + program_config *pce_out) { program_config pce; /* 1024 or 960 */ mp4ASC->frameLengthFlag = faad_get1bit(ld DEBUGVAR(1,138,"GASpecificConfig(): FrameLengthFlag")); +#ifndef ALLOW_SMALL_FRAMELENGTH + if (mp4ASC->frameLengthFlag == 1) + return -3; +#endif mp4ASC->dependsOnCoreCoder = faad_get1bit(ld DEBUGVAR(1,139,"GASpecificConfig(): DependsOnCoreCoder")); @@ -95,10 +77,15 @@ int8_t GASpecificConfig(bitfile *ld, mp4AudioSpecificConfig *mp4ASC) if (mp4ASC->channelsConfiguration == 0) { program_config_element(&pce, ld); - mp4ASC->channelsConfiguration = pce.channels; + //mp4ASC->channelsConfiguration = pce.channels; + + if (pce_out != NULL) + memcpy(pce_out, &pce, sizeof(program_config)); + /* if (pce.num_valid_cc_elements) return -3; + */ } #ifdef ERROR_RESILIENCE @@ -133,6 +120,8 @@ uint8_t program_config_element(program_config *pce, bitfile *ld) { uint8_t i; + memset(pce, 0, sizeof(program_config)); + pce->channels = 0; pce->element_instance_tag = (uint8_t)faad_getbits(ld, 4 @@ -183,48 +172,69 @@ uint8_t program_config_element(program_config *pce, bitfile *ld) for (i = 0; i < pce->num_front_channel_elements; i++) { - if ((pce->front_element_is_cpe[i] = faad_get1bit(ld - DEBUGVAR(1,26,"program_config_element(): front_element_is_cpe"))) & 1) + pce->front_element_is_cpe[i] = faad_get1bit(ld + DEBUGVAR(1,26,"program_config_element(): front_element_is_cpe")); + pce->front_element_tag_select[i] = (uint8_t)faad_getbits(ld, 4 + DEBUGVAR(1,27,"program_config_element(): front_element_tag_select")); + + if (pce->front_element_is_cpe[i] & 1) { + pce->cpe_channel[pce->front_element_tag_select[i]] = pce->channels; + pce->num_front_channels += 2; pce->channels += 2; } else { + pce->sce_channel[pce->front_element_tag_select[i]] = pce->channels; + pce->num_front_channels++; pce->channels++; } - pce->front_element_tag_select[i] = (uint8_t)faad_getbits(ld, 4 - DEBUGVAR(1,27,"program_config_element(): front_element_tag_select")); } for (i = 0; i < pce->num_side_channel_elements; i++) { - if ((pce->side_element_is_cpe[i] = faad_get1bit(ld - DEBUGVAR(1,28,"program_config_element(): side_element_is_cpe"))) & 1) + pce->side_element_is_cpe[i] = faad_get1bit(ld + DEBUGVAR(1,28,"program_config_element(): side_element_is_cpe")); + pce->side_element_tag_select[i] = (uint8_t)faad_getbits(ld, 4 + DEBUGVAR(1,29,"program_config_element(): side_element_tag_select")); + + if (pce->side_element_is_cpe[i] & 1) { + pce->cpe_channel[pce->side_element_tag_select[i]] = pce->channels; + pce->num_side_channels += 2; pce->channels += 2; } else { + pce->sce_channel[pce->side_element_tag_select[i]] = pce->channels; + pce->num_side_channels++; pce->channels++; } - pce->side_element_tag_select[i] = (uint8_t)faad_getbits(ld, 4 - DEBUGVAR(1,29,"program_config_element(): side_element_tag_select")); } for (i = 0; i < pce->num_back_channel_elements; i++) { - if ((pce->back_element_is_cpe[i] = faad_get1bit(ld - DEBUGVAR(1,30,"program_config_element(): back_element_is_cpe"))) & 1) + pce->back_element_is_cpe[i] = faad_get1bit(ld + DEBUGVAR(1,30,"program_config_element(): back_element_is_cpe")); + pce->back_element_tag_select[i] = (uint8_t)faad_getbits(ld, 4 + DEBUGVAR(1,31,"program_config_element(): back_element_tag_select")); + + if (pce->back_element_is_cpe[i] & 1) { + pce->cpe_channel[pce->back_element_tag_select[i]] = pce->channels; pce->channels += 2; + pce->num_back_channels += 2; } else { + pce->sce_channel[pce->back_element_tag_select[i]] = pce->channels; + pce->num_back_channels++; pce->channels++; } - pce->back_element_tag_select[i] = (uint8_t)faad_getbits(ld, 4 - DEBUGVAR(1,31,"program_config_element(): back_element_tag_select")); } for (i = 0; i < pce->num_lfe_channel_elements; i++) { - pce->channels++; pce->lfe_element_tag_select[i] = (uint8_t)faad_getbits(ld, 4 DEBUGVAR(1,32,"program_config_element(): lfe_element_tag_select")); + + pce->sce_channel[pce->lfe_element_tag_select[i]] = pce->channels; + pce->num_lfe_channels++; + pce->channels++; } for (i = 0; i < pce->num_assoc_data_elements; i++) @@ -233,9 +243,6 @@ uint8_t program_config_element(program_config *pce, bitfile *ld) for (i = 0; i < pce->num_valid_cc_elements; i++) { - /* have to count these as channels too?? (1 or 2) */ - pce->channels += 2; - pce->cc_element_is_ind_sw[i] = faad_get1bit(ld DEBUGVAR(1,34,"program_config_element(): cc_element_is_ind_sw")); pce->valid_cc_element_tag_select[i] = (uint8_t)faad_getbits(ld, 4 @@ -257,92 +264,87 @@ uint8_t program_config_element(program_config *pce, bitfile *ld) return 0; } -element *decode_sce_lfe(faacDecHandle hDecoder, - faacDecFrameInfo *hInfo, bitfile *ld, - int16_t **spec_data, real_t **spec_coef, - uint8_t id_syn_ele) +void decode_sce_lfe(faacDecHandle hDecoder, + faacDecFrameInfo *hInfo, bitfile *ld, + uint8_t id_syn_ele) { - element *ele; uint8_t channels = hDecoder->fr_channels; + uint8_t tag = 0; - if (channels+1 >= MAX_CHANNELS) + if (channels+1 > MAX_CHANNELS) { hInfo->error = 12; - return NULL; + return; } - if (hDecoder->fr_ch_ele+1 >= MAX_SYNTAX_ELEMENTS) + if (hDecoder->fr_ch_ele+1 > MAX_SYNTAX_ELEMENTS) { hInfo->error = 13; - return NULL; + return; } - spec_data[channels] = (int16_t*)malloc(hDecoder->frameLength*sizeof(int16_t)); - spec_coef[channels] = (real_t*)malloc(hDecoder->frameLength*sizeof(real_t)); + hInfo->error = single_lfe_channel_element(hDecoder, ld, channels, &tag); - ele = (element*)malloc(sizeof(element)); - memset(ele, 0, sizeof(element)); - ele->ele_id = id_syn_ele; - ele->channel = channels; - ele->paired_channel = -1; + if (hDecoder->pce_set) + hDecoder->internal_channel[hDecoder->pce.sce_channel[tag]] = channels; + else + hDecoder->internal_channel[channels] = channels; - hInfo->error = single_lfe_channel_element(hDecoder, ele, - ld, spec_data[channels]); + if (id_syn_ele == ID_SCE) + hDecoder->channel_element[channels] = hDecoder->fr_ch_ele; + else /* LFE */ + hDecoder->channel_element[channels] = hDecoder->fr_ch_ele; + hDecoder->element_id[hDecoder->fr_ch_ele] = id_syn_ele; hDecoder->fr_channels++; hDecoder->fr_ch_ele++; - - return ele; } -element *decode_cpe(faacDecHandle hDecoder, - faacDecFrameInfo *hInfo, bitfile *ld, - int16_t **spec_data, real_t **spec_coef, - uint8_t id_syn_ele) +void decode_cpe(faacDecHandle hDecoder, faacDecFrameInfo *hInfo, bitfile *ld, + uint8_t id_syn_ele) { - element *ele; uint8_t channels = hDecoder->fr_channels; + uint8_t tag = 0; - if (channels+2 >= MAX_CHANNELS) + if (channels+2 > MAX_CHANNELS) { hInfo->error = 12; - return NULL; + return; } - if (hDecoder->fr_ch_ele+1 >= MAX_SYNTAX_ELEMENTS) + if (hDecoder->fr_ch_ele+1 > MAX_SYNTAX_ELEMENTS) { hInfo->error = 13; - return NULL; + return; } - spec_data[channels] = (int16_t*)malloc(hDecoder->frameLength*sizeof(int16_t)); - spec_data[channels+1] = (int16_t*)malloc(hDecoder->frameLength*sizeof(int16_t)); - spec_coef[channels] = (real_t*)malloc(hDecoder->frameLength*sizeof(real_t)); - spec_coef[channels+1] = (real_t*)malloc(hDecoder->frameLength*sizeof(real_t)); + hInfo->error = channel_pair_element(hDecoder, ld, channels, &tag); - ele = (element*)malloc(sizeof(element)); - memset(ele, 0, sizeof(element)); - ele->ele_id = id_syn_ele; - ele->channel = channels; - ele->paired_channel = channels+1; + if (hDecoder->pce_set) + { + hDecoder->internal_channel[hDecoder->pce.cpe_channel[tag]] = channels; + hDecoder->internal_channel[hDecoder->pce.cpe_channel[tag]+1] = channels+1; + } else { + hDecoder->internal_channel[channels] = channels; + hDecoder->internal_channel[channels+1] = channels+1; + } - hInfo->error = channel_pair_element(hDecoder, ele, - ld, spec_data[channels], spec_data[channels+1]); + hDecoder->channel_element[channels] = hDecoder->fr_ch_ele; + hDecoder->channel_element[channels+1] = hDecoder->fr_ch_ele; + hDecoder->element_id[hDecoder->fr_ch_ele] = id_syn_ele; hDecoder->fr_channels += 2; hDecoder->fr_ch_ele++; - - return ele; } -element **raw_data_block(faacDecHandle hDecoder, faacDecFrameInfo *hInfo, - bitfile *ld, element **elements, - int16_t **spec_data, real_t **spec_coef, - program_config *pce, drc_info *drc) +void raw_data_block(faacDecHandle hDecoder, faacDecFrameInfo *hInfo, + bitfile *ld, program_config *pce, drc_info *drc) { uint8_t id_syn_ele; uint8_t ch_ele = 0; hDecoder->fr_channels = 0; hDecoder->fr_ch_ele = 0; + hDecoder->first_syn_ele = 25; + hDecoder->has_lfe = 0; #ifdef ERROR_RESILIENCE if (hDecoder->object_type < ER_OBJECT_START) @@ -354,31 +356,59 @@ element **raw_data_block(faacDecHandle hDecoder, faacDecFrameInfo *hInfo, { switch (id_syn_ele) { case ID_SCE: - case ID_LFE: - elements[ch_ele++] = decode_sce_lfe(hDecoder, - hInfo, ld, spec_data, spec_coef, id_syn_ele); + if (hDecoder->first_syn_ele == 25) hDecoder->first_syn_ele = id_syn_ele; + decode_sce_lfe(hDecoder, hInfo, ld, id_syn_ele); + ch_ele++; if (hInfo->error > 0) - return elements; + return; break; case ID_CPE: - elements[ch_ele++] = decode_cpe(hDecoder, - hInfo, ld, spec_data, spec_coef, id_syn_ele); + if (hDecoder->first_syn_ele == 25) hDecoder->first_syn_ele = id_syn_ele; + decode_cpe(hDecoder, hInfo, ld, id_syn_ele); + ch_ele++; + if (hInfo->error > 0) + return; + break; + case ID_LFE: + hDecoder->has_lfe++; + decode_sce_lfe(hDecoder, hInfo, ld, id_syn_ele); + ch_ele++; if (hInfo->error > 0) - return elements; + return; break; - case ID_CCE: /* not implemented yet */ + case ID_CCE: /* not implemented yet, but skip the bits */ +#ifdef COUPLING_DEC + hInfo->error = coupling_channel_element(hDecoder, ld); +#else hInfo->error = 6; - return elements; +#endif + if (hInfo->error > 0) + return; + break; case ID_DSE: - data_stream_element(ld); + data_stream_element(hDecoder, ld); break; case ID_PCE: if ((hInfo->error = program_config_element(pce, ld)) > 0) - return elements; + return; + hDecoder->pce_set = 1; break; case ID_FIL: - if ((hInfo->error = fill_element(ld, drc)) > 0) - return elements; + /* one sbr_info describes a channel_element not a channel! */ + if ((hInfo->error = fill_element(hDecoder, ld, drc +#ifdef SBR_DEC + , (ch_ele-1) +#endif + )) > 0) + return; +#ifdef SBR_DEC + if (hDecoder->sbr_used[ch_ele-1]) + { + hDecoder->sbr_present_flag = 1; + hDecoder->sbr[ch_ele-1]->sample_rate = get_sample_rate(hDecoder->sf_index); + hDecoder->sbr[ch_ele-1]->sample_rate *= 2; + } +#endif break; } } @@ -388,74 +418,74 @@ element **raw_data_block(faacDecHandle hDecoder, faacDecFrameInfo *hInfo, switch (hDecoder->channelConfiguration) { case 1: - elements[ch_ele++] = decode_sce_lfe(hDecoder, - hInfo, ld, spec_data, spec_coef, ID_SCE); + decode_sce_lfe(hDecoder, hInfo, ld, ID_SCE); + ch_ele++; if (hInfo->error > 0) - return elements; + return; break; case 2: - elements[ch_ele++] = decode_cpe(hDecoder, - hInfo, ld, spec_data, spec_coef, ID_CPE); + decode_cpe(hDecoder, hInfo, ld, ID_CPE); + ch_ele++; if (hInfo->error > 0) - return elements; + return; break; case 3: - elements[ch_ele++] = decode_sce_lfe(hDecoder, - hInfo, ld, spec_data, spec_coef, ID_SCE); - elements[ch_ele++] = decode_cpe(hDecoder, - hInfo, ld, spec_data, spec_coef, ID_CPE); + decode_sce_lfe(hDecoder, hInfo, ld, ID_SCE); + ch_ele++; + decode_cpe(hDecoder, hInfo, ld, ID_CPE); + ch_ele++; if (hInfo->error > 0) - return elements; + return; break; case 4: - elements[ch_ele++] = decode_sce_lfe(hDecoder, - hInfo, ld, spec_data, spec_coef, ID_SCE); - elements[ch_ele++] = decode_cpe(hDecoder, - hInfo, ld, spec_data, spec_coef, ID_CPE); - elements[ch_ele++] = decode_sce_lfe(hDecoder, - hInfo, ld, spec_data, spec_coef, ID_SCE); + decode_sce_lfe(hDecoder, hInfo, ld, ID_SCE); + ch_ele++; + decode_cpe(hDecoder, hInfo, ld, ID_CPE); + ch_ele++; + decode_sce_lfe(hDecoder, hInfo, ld, ID_SCE); + ch_ele++; if (hInfo->error > 0) - return elements; + return; break; case 5: - elements[ch_ele++] = decode_sce_lfe(hDecoder, - hInfo, ld, spec_data, spec_coef, ID_SCE); - elements[ch_ele++] = decode_cpe(hDecoder, - hInfo, ld, spec_data, spec_coef, ID_CPE); - elements[ch_ele++] = decode_cpe(hDecoder, - hInfo, ld, spec_data, spec_coef, ID_CPE); + decode_sce_lfe(hDecoder, hInfo, ld, ID_SCE); + ch_ele++; + decode_cpe(hDecoder, hInfo, ld, ID_CPE); + ch_ele++; + decode_cpe(hDecoder, hInfo, ld, ID_CPE); + ch_ele++; if (hInfo->error > 0) - return elements; + return; break; case 6: - elements[ch_ele++] = decode_sce_lfe(hDecoder, - hInfo, ld, spec_data, spec_coef, ID_SCE); - elements[ch_ele++] = decode_cpe(hDecoder, - hInfo, ld, spec_data, spec_coef, ID_CPE); - elements[ch_ele++] = decode_cpe(hDecoder, - hInfo, ld, spec_data, spec_coef, ID_CPE); - elements[ch_ele++] = decode_sce_lfe(hDecoder, - hInfo, ld, spec_data, spec_coef, ID_LFE); + decode_sce_lfe(hDecoder, hInfo, ld, ID_SCE); + ch_ele++; + decode_cpe(hDecoder, hInfo, ld, ID_CPE); + ch_ele++; + decode_cpe(hDecoder, hInfo, ld, ID_CPE); + ch_ele++; + decode_sce_lfe(hDecoder, hInfo, ld, ID_LFE); + ch_ele++; if (hInfo->error > 0) - return elements; + return; break; case 7: - elements[ch_ele++] = decode_sce_lfe(hDecoder, - hInfo, ld, spec_data, spec_coef, ID_SCE); - elements[ch_ele++] = decode_cpe(hDecoder, - hInfo, ld, spec_data, spec_coef, ID_CPE); - elements[ch_ele++] = decode_cpe(hDecoder, - hInfo, ld, spec_data, spec_coef, ID_CPE); - elements[ch_ele++] = decode_cpe(hDecoder, - hInfo, ld, spec_data, spec_coef, ID_CPE); - elements[ch_ele++] = decode_sce_lfe(hDecoder, - hInfo, ld, spec_data, spec_coef, ID_LFE); + decode_sce_lfe(hDecoder, hInfo, ld, ID_SCE); + ch_ele++; + decode_cpe(hDecoder, hInfo, ld, ID_CPE); + ch_ele++; + decode_cpe(hDecoder, hInfo, ld, ID_CPE); + ch_ele++; + decode_cpe(hDecoder, hInfo, ld, ID_CPE); + ch_ele++; + decode_sce_lfe(hDecoder, hInfo, ld, ID_LFE); + ch_ele++; if (hInfo->error > 0) - return elements; + return; break; default: hInfo->error = 7; - return elements; + return; } #if 0 cnt = bits_to_decode() / 8; @@ -468,105 +498,68 @@ element **raw_data_block(faacDecHandle hDecoder, faacDecFrameInfo *hInfo, #endif /* new in corrigendum 14496-3:2002 */ - faad_byte_align(ld); - - return elements; -} - #ifdef DRM -static uint8_t faad_check_CRC(bitfile *ld) -{ - uint16_t len = faad_get_processed_bits(ld) - 8; - uint8_t CRC; - uint16_t r=255; /* Initialize to all ones */ - - /* CRC polynome used x^8 + x^4 + x^3 + x^2 +1 */ -#define GPOLY 0435 - - faad_rewindbits(ld); - - CRC = ~faad_getbits(ld, 8 - DEBUGVAR(1,999,"faad_check_CRC(): CRC")); /* CRC is stored inverted */ - - for (; len>0; len--) - { - r = ( (r << 1) ^ (( ( faad_get1bit(ld - DEBUGVAR(1,998,"")) & 1) ^ ((r >> 7) & 1)) * GPOLY )) & 0xFF; - } - if (r != CRC) + if (hDecoder->object_type != DRM_ER_LC) +#endif { - return 8; - } else { - return 0; + faad_byte_align(ld); } + + return; } -#endif /* Table 4.4.4 and */ /* Table 4.4.9 */ -static uint8_t single_lfe_channel_element(faacDecHandle hDecoder, - element *sce, bitfile *ld, - int16_t *spec_data) +static uint8_t single_lfe_channel_element(faacDecHandle hDecoder, bitfile *ld, + uint8_t channel, uint8_t *tag) { - ic_stream *ics = &(sce->ics1); -#ifdef DRM - uint8_t result; + uint8_t retval = 0; + element sce = {0}; + ic_stream *ics = &(sce.ics1); + ALIGN int16_t spec_data[1024] = {0}; - if (hDecoder->object_type != DRM_ER_LC) -#endif - sce->element_instance_tag = (uint8_t)faad_getbits(ld, LEN_TAG + sce.element_instance_tag = (uint8_t)faad_getbits(ld, LEN_TAG DEBUGVAR(1,38,"single_lfe_channel_element(): element_instance_tag")); -#ifdef DRM - if (hDecoder->object_type == DRM_ER_LC) - { - individual_channel_stream(hDecoder, sce, ld, ics, 0, spec_data); - - if (ics->tns_data_present) - tns_data(ics, &(ics->tns), ld); + *tag = sce.element_instance_tag; + sce.channel = channel; + sce.paired_channel = -1; - if ((result = faad_check_CRC( ld )) > 0) - return result; - - /* error resilient spectral data decoding */ - if ((result = reordered_spectral_data(hDecoder, ics, ld, spec_data)) > 0) - return result; + retval = individual_channel_stream(hDecoder, &sce, ld, ics, 0, spec_data); + if (retval > 0) + return retval; - /* pulse coding reconstruction */ - if (ics->pulse_data_present) - { - if (ics->window_sequence != EIGHT_SHORT_SEQUENCE) - pulse_decode(ics, spec_data, hDecoder->frameLength); - else - return 2; /* pulse coding not allowed for short blocks */ - } - return 0; - } else -#endif + /* noiseless coding is done, spectral reconstruction is done now */ + retval = reconstruct_single_channel(hDecoder, ics, &sce, spec_data); + if (retval > 0) + return retval; - return individual_channel_stream(hDecoder, sce, ld, ics, 0, spec_data); + return 0; } /* Table 4.4.5 */ -static uint8_t channel_pair_element(faacDecHandle hDecoder, element *cpe, - bitfile *ld, int16_t *spec_data1, - int16_t *spec_data2) +static uint8_t channel_pair_element(faacDecHandle hDecoder, bitfile *ld, + uint8_t channels, uint8_t *tag) { + ALIGN int16_t spec_data1[1024] = {0}; + ALIGN int16_t spec_data2[1024] = {0}; + element cpe = {0}; + ic_stream *ics1 = &(cpe.ics1); + ic_stream *ics2 = &(cpe.ics2); uint8_t result; - ic_stream *ics1 = &(cpe->ics1); - ic_stream *ics2 = &(cpe->ics2); -#ifdef DRM - if (hDecoder->object_type != DRM_ER_LC) -#endif - cpe->element_instance_tag = (uint8_t)faad_getbits(ld, LEN_TAG + cpe.channel = channels; + cpe.paired_channel = channels+1; + + cpe.element_instance_tag = (uint8_t)faad_getbits(ld, LEN_TAG DEBUGVAR(1,39,"channel_pair_element(): element_instance_tag")); + *tag = cpe.element_instance_tag; - if ((cpe->common_window = faad_get1bit(ld + if ((cpe.common_window = faad_get1bit(ld DEBUGVAR(1,40,"channel_pair_element(): common_window"))) & 1) { /* both channels have common ics information */ - if ((result = ics_info(hDecoder, ics1, ld, cpe->common_window)) > 0) + if ((result = ics_info(hDecoder, ics1, ld, cpe.common_window)) > 0) return result; ics1->ms_mask_present = (uint8_t)faad_getbits(ld, 2 @@ -590,7 +583,10 @@ static uint8_t channel_pair_element(faacDecHandle hDecoder, element *cpe, if ((ics1->ltp.data_present = faad_get1bit(ld DEBUGVAR(1,50,"channel_pair_element(): ltp.data_present"))) & 1) { - ltp_data(hDecoder, ics1, &(ics1->ltp), ld); + if ((result = ltp_data(hDecoder, ics1, &(ics1->ltp), ld)) > 0) + { + return result; + } } } #endif @@ -600,66 +596,39 @@ static uint8_t channel_pair_element(faacDecHandle hDecoder, element *cpe, ics1->ms_mask_present = 0; } - if ((result = individual_channel_stream(hDecoder, cpe, ld, ics1, + if ((result = individual_channel_stream(hDecoder, &cpe, ld, ics1, 0, spec_data1)) > 0) { return result; } #ifdef ERROR_RESILIENCE - if (cpe->common_window && (hDecoder->object_type >= ER_OBJECT_START) && + if (cpe.common_window && (hDecoder->object_type >= ER_OBJECT_START) && (ics1->predictor_data_present)) { if ((ics1->ltp2.data_present = faad_get1bit(ld DEBUGVAR(1,50,"channel_pair_element(): ltp.data_present"))) & 1) { - ltp_data(hDecoder, ics1, &(ics1->ltp2), ld); + if ((result = ltp_data(hDecoder, ics1, &(ics1->ltp2), ld)) > 0) + { + return result; + } } } #endif - if ((result = individual_channel_stream(hDecoder, cpe, ld, ics2, + if ((result = individual_channel_stream(hDecoder, &cpe, ld, ics2, 0, spec_data2)) > 0) { return result; } -#ifdef DRM - if (hDecoder->object_type == DRM_ER_LC) + /* noiseless coding is done, spectral reconstruction is done now */ + if ((result = reconstruct_channel_pair(hDecoder, ics1, ics2, &cpe, + spec_data1, spec_data2)) > 0) { - if (ics1->tns_data_present) - tns_data(ics1, &(ics1->tns), ld); - - if (ics1->tns_data_present) - tns_data(ics2, &(ics2->tns), ld); - - if ((result = faad_check_CRC( ld )) > 0) - { - return result; - } - /* error resilient spectral data decoding */ - if ((result = reordered_spectral_data(hDecoder, ics1, ld, spec_data1)) > 0) - return result; - if ((result = reordered_spectral_data(hDecoder, ics2, ld, spec_data2)) > 0) - return result; - /* pulse coding reconstruction */ - if (ics1->pulse_data_present) - { - if (ics1->window_sequence != EIGHT_SHORT_SEQUENCE) - pulse_decode(ics1, spec_data1, hDecoder->frameLength); - else - return 2; /* pulse coding not allowed for short blocks */ - } - if (ics2->pulse_data_present) - { - if (ics2->window_sequence != EIGHT_SHORT_SEQUENCE) - pulse_decode(ics2, spec_data2, hDecoder->frameLength); - else - return 2; /* pulse coding not allowed for short blocks */ - } - return 0; - } else -#endif + return result; + } return 0; } @@ -689,12 +658,13 @@ static uint8_t ics_info(faacDecHandle hDecoder, ic_stream *ics, bitfile *ld, } /* get the grouping information */ - retval = window_grouping_info(hDecoder, ics); + if ((retval = window_grouping_info(hDecoder, ics)) > 0) + return retval; /* should be an error */ /* check the range of max_sfb */ if (ics->max_sfb > ics->num_swb) - ics->max_sfb = ics->num_swb; + return 16; if (ics->window_sequence != EIGHT_SHORT_SEQUENCE) { @@ -705,7 +675,7 @@ static uint8_t ics_info(faacDecHandle hDecoder, ic_stream *ics, bitfile *ld, { uint8_t sfb; - ics->pred.limit = min(ics->max_sfb, pred_sfb_max[hDecoder->sf_index]); + ics->pred.limit = min(ics->max_sfb, max_pred_sfb(hDecoder->sf_index)); if ((ics->pred.predictor_reset = faad_get1bit(ld DEBUGVAR(1,53,"ics_info(): pred.predictor_reset"))) & 1) @@ -727,14 +697,20 @@ static uint8_t ics_info(faacDecHandle hDecoder, ic_stream *ics, bitfile *ld, if ((ics->ltp.data_present = faad_get1bit(ld DEBUGVAR(1,50,"ics_info(): ltp.data_present"))) & 1) { - ltp_data(hDecoder, ics, &(ics->ltp), ld); + if ((retval = ltp_data(hDecoder, ics, &(ics->ltp), ld)) > 0) + { + return retval; + } } if (common_window) { if ((ics->ltp2.data_present = faad_get1bit(ld DEBUGVAR(1,51,"ics_info(): ltp2.data_present"))) & 1) { - ltp_data(hDecoder, ics, &(ics->ltp2), ld); + if ((retval = ltp_data(hDecoder, ics, &(ics->ltp2), ld)) > 0) + { + return retval; + } } } } @@ -757,7 +733,7 @@ static uint8_t ics_info(faacDecHandle hDecoder, ic_stream *ics, bitfile *ld, } /* Table 4.4.7 */ -static void pulse_data(ic_stream *ics, pulse_info *pul, bitfile *ld) +static uint8_t pulse_data(ic_stream *ics, pulse_info *pul, bitfile *ld) { uint8_t i; @@ -768,7 +744,7 @@ static void pulse_data(ic_stream *ics, pulse_info *pul, bitfile *ld) /* check the range of pulse_start_sfb */ if (pul->pulse_start_sfb > ics->num_swb) - pul->pulse_start_sfb = ics->num_swb; + return 16; for (i = 0; i < pul->number_pulse+1; i++) { @@ -777,10 +753,102 @@ static void pulse_data(ic_stream *ics, pulse_info *pul, bitfile *ld) pul->pulse_amp[i] = (uint8_t)faad_getbits(ld, 4 DEBUGVAR(1,59,"pulse_data(): pulse_amp")); } + + return 0; +} + +#ifdef COUPLING_DEC +/* Table 4.4.8: Currently just for skipping the bits... */ +static uint8_t coupling_channel_element(faacDecHandle hDecoder, bitfile *ld) +{ + uint8_t c, result = 0; + uint8_t ind_sw_cce_flag = 0; + uint8_t num_gain_element_lists = 0; + uint8_t num_coupled_elements = 0; + + element el_empty = {0}; + ic_stream ics_empty = {0}; + int16_t sh_data[1024]; + + c = faad_getbits(ld, LEN_TAG + DEBUGVAR(1,900,"coupling_channel_element(): element_instance_tag")); + + ind_sw_cce_flag = faad_get1bit(ld + DEBUGVAR(1,901,"coupling_channel_element(): ind_sw_cce_flag")); + num_coupled_elements = faad_getbits(ld, 3 + DEBUGVAR(1,902,"coupling_channel_element(): num_coupled_elements")); + + for (c = 0; c < num_coupled_elements + 1; c++) + { + uint8_t cc_target_is_cpe, cc_target_tag_select; + + num_gain_element_lists++; + + cc_target_is_cpe = faad_get1bit(ld + DEBUGVAR(1,903,"coupling_channel_element(): cc_target_is_cpe")); + cc_target_tag_select = faad_getbits(ld, 4 + DEBUGVAR(1,904,"coupling_channel_element(): cc_target_tag_select")); + + if (cc_target_is_cpe) + { + uint8_t cc_l = faad_get1bit(ld + DEBUGVAR(1,905,"coupling_channel_element(): cc_l")); + uint8_t cc_r = faad_get1bit(ld + DEBUGVAR(1,906,"coupling_channel_element(): cc_r")); + + if (cc_l && cc_r) + num_gain_element_lists++; + } + } + + faad_get1bit(ld + DEBUGVAR(1,907,"coupling_channel_element(): cc_domain")); + faad_get1bit(ld + DEBUGVAR(1,908,"coupling_channel_element(): gain_element_sign")); + faad_getbits(ld, 2 + DEBUGVAR(1,909,"coupling_channel_element(): gain_element_scale")); + + if ((result = individual_channel_stream(hDecoder, &el_empty, ld, &ics_empty, + 0, sh_data)) > 0) + { + return result; + } + + for (c = 1; c < num_gain_element_lists; c++) + { + uint8_t cge; + + if (ind_sw_cce_flag) + { + cge = 1; + } else { + cge = faad_get1bit(ld + DEBUGVAR(1,910,"coupling_channel_element(): common_gain_element_present")); + } + + if (cge) + { + huffman_scale_factor(ld); + } else { + uint8_t g, sfb; + + for (g = 0; g < ics_empty.num_window_groups; g++) + { + for (sfb = 0; sfb < ics_empty.max_sfb; sfb++) + { + if (ics_empty.sfb_cb[g][sfb] != ZERO_HCB) + huffman_scale_factor(ld); + } + } + } + } + + return 0; } +#endif /* Table 4.4.10 */ -static uint16_t data_stream_element(bitfile *ld) +static uint16_t data_stream_element(faacDecHandle hDecoder, bitfile *ld) { uint8_t byte_aligned; uint16_t i, count; @@ -801,7 +869,7 @@ static uint16_t data_stream_element(bitfile *ld) for (i = 0; i < count; i++) { - faad_getbits(ld, LEN_BYTE + uint8_t data = (uint8_t)faad_getbits(ld, LEN_BYTE DEBUGVAR(1,64,"data_stream_element(): data_stream_byte")); } @@ -809,9 +877,16 @@ static uint16_t data_stream_element(bitfile *ld) } /* Table 4.4.11 */ -static uint8_t fill_element(bitfile *ld, drc_info *drc) +static uint8_t fill_element(faacDecHandle hDecoder, bitfile *ld, drc_info *drc +#ifdef SBR_DEC + ,uint8_t sbr_ele +#endif + ) { uint16_t count; +#ifdef SBR_DEC + uint8_t bs_extension_type; +#endif count = (uint16_t)faad_getbits(ld, 4 DEBUGVAR(1,65,"fill_element(): count")); @@ -821,9 +896,41 @@ static uint8_t fill_element(bitfile *ld, drc_info *drc) DEBUGVAR(1,66,"fill_element(): extra count")) - 1; } - while (count > 0) + if (count > 0) { - count -= extension_payload(ld, drc, count); +#ifdef SBR_DEC + hDecoder->sbr_used[sbr_ele] = 0; + bs_extension_type = (uint8_t)faad_showbits(ld, 4); + + if ((bs_extension_type == EXT_SBR_DATA) || + (bs_extension_type == EXT_SBR_DATA_CRC)) + { + hDecoder->sbr_used[sbr_ele] = 1; + + if (!hDecoder->sbr[sbr_ele]) + { + hDecoder->sbr[sbr_ele] = sbrDecodeInit(hDecoder->frameLength +#ifdef DRM + , 0 +#endif + ); + } + + /* read in all the SBR data for processing later on */ + hDecoder->sbr[sbr_ele]->data = (uint8_t*)faad_getbitbuffer(ld, count*8); + hDecoder->sbr[sbr_ele]->data_size = count; + /* save id of previous element, this sbr object belongs to that element */ + hDecoder->sbr[sbr_ele]->id_aac = hDecoder->element_id[sbr_ele]; + } else { + hDecoder->sbr_used[sbr_ele] = 0; +#endif + while (count > 0) + { + count -= extension_payload(ld, drc, count); + } +#ifdef SBR_DEC + } +#endif } return 0; @@ -925,6 +1032,183 @@ static void gain_control_data(bitfile *ld, ic_stream *ics) } #endif +#ifdef SCALABLE_DEC +/* Table 4.4.13 ASME */ +void aac_scalable_main_element(faacDecHandle hDecoder, faacDecFrameInfo *hInfo, + bitfile *ld, program_config *pce, drc_info *drc) +{ + uint8_t retval = 0; + uint8_t channels = hDecoder->fr_channels = 0; + uint8_t ch; + uint8_t this_layer_stereo = (hDecoder->channelConfiguration > 1) ? 1 : 0; + element cpe = {0}; + ic_stream *ics1 = &(cpe.ics1); + ic_stream *ics2 = &(cpe.ics2); + int16_t *spec_data; + ALIGN int16_t spec_data1[1024] = {0}; + ALIGN int16_t spec_data2[1024] = {0}; + + hDecoder->fr_ch_ele = 0; + + hInfo->error = aac_scalable_main_header(hDecoder, ics1, ics2, ld, this_layer_stereo); + if (hInfo->error > 0) + return; + + cpe.common_window = 1; + if (this_layer_stereo) + cpe.ele_id = ID_CPE; + else + cpe.ele_id = ID_SCE; + + for (ch = 0; ch < (this_layer_stereo ? 2 : 1); ch++) + { + ic_stream *ics; + if (ch == 0) + { + ics = ics1; + spec_data = spec_data1; + } else { + ics = ics2; + spec_data = spec_data2; + } + + hDecoder->internal_channel[channels+ch] = channels+ch; + hDecoder->channel_element[channels+ch] = hDecoder->fr_ch_ele; + + hInfo->error = individual_channel_stream(hDecoder, &cpe, ld, ics, 1, spec_data); + if (hInfo->error > 0) + return; + } + + if (this_layer_stereo) + { + hInfo->error = reconstruct_channel_pair(hDecoder, ics1, ics2, &cpe, spec_data1, spec_data2); + if (hInfo->error > 0) + return; + } else { + hInfo->error = reconstruct_single_channel(hDecoder, ics1, &cpe, spec_data1); + if (hInfo->error > 0) + return; + } + + hDecoder->element_id[hDecoder->fr_ch_ele] = cpe.ele_id; + + hDecoder->fr_channels += (this_layer_stereo ? 2 : 1); + hDecoder->fr_ch_ele++; + + return; +} + +/* Table 4.4.15 */ +static int8_t aac_scalable_main_header(faacDecHandle hDecoder, ic_stream *ics1, ic_stream *ics2, + bitfile *ld, uint8_t this_layer_stereo) +{ + uint8_t retval = 0; + uint8_t ch; + ic_stream *ics; + + /* ics1->ics_reserved_bit = */ faad_get1bit(ld + DEBUGVAR(1,300,"aac_scalable_main_header(): ics_reserved_bits")); + ics1->window_sequence = (uint8_t)faad_getbits(ld, 2 + DEBUGVAR(1,301,"aac_scalable_main_header(): window_sequence")); + ics1->window_shape = faad_get1bit(ld + DEBUGVAR(1,302,"aac_scalable_main_header(): window_shape")); + + if (ics1->window_sequence == EIGHT_SHORT_SEQUENCE) + { + ics1->max_sfb = (uint8_t)faad_getbits(ld, 4 + DEBUGVAR(1,303,"aac_scalable_main_header(): max_sfb (short)")); + ics1->scale_factor_grouping = (uint8_t)faad_getbits(ld, 7 + DEBUGVAR(1,304,"aac_scalable_main_header(): scale_factor_grouping")); + } else { + ics1->max_sfb = (uint8_t)faad_getbits(ld, 6 + DEBUGVAR(1,305,"aac_scalable_main_header(): max_sfb (long)")); + } + + /* get the grouping information */ + if ((retval = window_grouping_info(hDecoder, ics1)) > 0) + return retval; + + /* should be an error */ + /* check the range of max_sfb */ + if (ics1->max_sfb > ics1->num_swb) + return 16; + + if (this_layer_stereo) + { + ics1->ms_mask_present = (uint8_t)faad_getbits(ld, 2 + DEBUGVAR(1,306,"aac_scalable_main_header(): ms_mask_present")); + if (ics1->ms_mask_present == 1) + { + uint8_t g, sfb; + for (g = 0; g < ics1->num_window_groups; g++) + { + for (sfb = 0; sfb < ics1->max_sfb; sfb++) + { + ics1->ms_used[g][sfb] = faad_get1bit(ld + DEBUGVAR(1,307,"aac_scalable_main_header(): faad_get1bit")); + } + } + } + + memcpy(ics2, ics1, sizeof(ic_stream)); + } else { + ics1->ms_mask_present = 0; + } + + if (0) + { + faad_get1bit(ld + DEBUGVAR(1,308,"aac_scalable_main_header(): tns_channel_mono_layer")); + } + + for (ch = 0; ch < (this_layer_stereo ? 2 : 1); ch++) + { + if (ch == 0) + ics = ics1; + else + ics = ics2; + + if ( 1 /*!tvq_layer_pesent || (tns_aac_tvq_en[ch] == 1)*/) + { + if ((ics->tns_data_present = faad_get1bit(ld + DEBUGVAR(1,309,"aac_scalable_main_header(): tns_data_present"))) & 1) + { +#ifdef DRM + /* different order of data units in DRM */ + if (hDecoder->object_type != DRM_ER_LC) +#endif + { + tns_data(ics, &(ics->tns), ld); + } + } + } +#if 0 + if (0 /*core_flag || tvq_layer_pesent*/) + { + if ((ch==0) || ((ch==1) && (core_stereo || tvq_stereo)) + diff_control_data(); + if (mono_stereo_flag) + diff_control_data_lr(); + } else { +#endif + if ((ics->ltp.data_present = faad_get1bit(ld + DEBUGVAR(1,310,"aac_scalable_main_header(): ltp.data_present"))) & 1) + { + if ((retval = ltp_data(hDecoder, ics, &(ics->ltp), ld)) > 0) + { + return retval; + } + } +#if 0 + } +#endif + } + + return 0; +} +#endif + /* Table 4.4.24 */ static uint8_t individual_channel_stream(faacDecHandle hDecoder, element *ele, bitfile *ld, ic_stream *ics, uint8_t scal_flag, @@ -940,7 +1224,10 @@ static uint8_t individual_channel_stream(faacDecHandle hDecoder, element *ele, if ((result = ics_info(hDecoder, ics, ld, ele->common_window)) > 0) return result; } - section_data(hDecoder, ics, ld); + + if ((result = section_data(hDecoder, ics, ld)) > 0) + return result; + if ((result = scale_factor_data(hDecoder, ics, ld)) > 0) return result; @@ -955,7 +1242,8 @@ static uint8_t individual_channel_stream(faacDecHandle hDecoder, element *ele, if ((ics->pulse_data_present = faad_get1bit(ld DEBUGVAR(1,68,"individual_channel_stream(): pulse_data_present"))) & 1) { - pulse_data(ics, &(ics->pul), ld); + if ((result = pulse_data(ics, &(ics->pul), ld)) > 0) + return result; } /* get tns data */ @@ -1011,17 +1299,19 @@ static uint8_t individual_channel_stream(faacDecHandle hDecoder, element *ele, return result; } -#ifdef DRM - if (hDecoder->object_type == DRM_ER_LC) - return 0; -#endif - if (hDecoder->object_type >= ER_OBJECT_START) { if (ics->tns_data_present) tns_data(ics, &(ics->tns), ld); } +#ifdef DRM + /* CRC check */ + if (hDecoder->object_type == DRM_ER_LC) + if ((result = faad_check_CRC(ld, faad_get_processed_bits(ld) - 8)) > 0) + return result; +#endif + if (hDecoder->aacSpectralDataResilienceFlag) { /* error resilient spectral data decoding */ @@ -1044,16 +1334,19 @@ static uint8_t individual_channel_stream(faacDecHandle hDecoder, element *ele, if (ics->pulse_data_present) { if (ics->window_sequence != EIGHT_SHORT_SEQUENCE) - pulse_decode(ics, spec_data, hDecoder->frameLength); - else + { + if ((result = pulse_decode(ics, spec_data, hDecoder->frameLength)) > 0) + return result; + } else { return 2; /* pulse coding not allowed for short blocks */ + } } return 0; } /* Table 4.4.25 */ -static void section_data(faacDecHandle hDecoder, ic_stream *ics, bitfile *ld) +static uint8_t section_data(faacDecHandle hDecoder, ic_stream *ics, bitfile *ld) { uint8_t g; uint8_t sect_esc_val, sect_bits; @@ -1084,6 +1377,11 @@ static void section_data(faacDecHandle hDecoder, ic_stream *ics, bitfile *ld) uint16_t sect_len = 0; uint8_t sect_cb_bits = 4; + /* if "faad_getbits" detects error and returns "0", "k" is never + incremented and we cannot leave the while loop */ + if ((ld->error != 0) || (ld->no_more_reading)) + return 14; + #ifdef ERROR_RESILIENCE if (hDecoder->aacSectionDataResilienceFlag) sect_cb_bits = 5; @@ -1127,6 +1425,11 @@ static void section_data(faacDecHandle hDecoder, ic_stream *ics, bitfile *ld) ics->sect_start[g][i] = k; ics->sect_end[g][i] = k + sect_len; + if (k + sect_len >= 8*15) + return 15; + if (i >= 8*15) + return 15; + for (sfb = k; sfb < k + sect_len; sfb++) ics->sfb_cb[g][sfb] = ics->sect_cb[g][i]; @@ -1146,6 +1449,8 @@ static void section_data(faacDecHandle hDecoder, ic_stream *ics, bitfile *ld) #if 0 printf("\n"); #endif + + return 0; } /* @@ -1207,8 +1512,6 @@ static uint8_t decode_scale_factors(ic_stream *ics, bitfile *ld) ics->scale_factors[g][sfb] = noise_energy; break; - case BOOKSCL: /* invalid books */ - return 3; default: /* spectral books */ /* decode scale factor */ @@ -1216,7 +1519,7 @@ static uint8_t decode_scale_factors(ic_stream *ics, bitfile *ld) if (t < 0) return 9; scale_factor += (t - 60); - if (scale_factor < 0) + if (scale_factor < 0 || scale_factor > 255) return 4; ics->scale_factors[g][sfb] = scale_factor; @@ -1231,20 +1534,32 @@ static uint8_t decode_scale_factors(ic_stream *ics, bitfile *ld) /* Table 4.4.26 */ static uint8_t scale_factor_data(faacDecHandle hDecoder, ic_stream *ics, bitfile *ld) { + uint8_t ret = 0; +#ifdef PROFILE + int64_t count = faad_get_ts(); +#endif + #ifdef ERROR_RESILIENCE if (!hDecoder->aacScalefactorDataResilienceFlag) { #endif - return decode_scale_factors(ics, ld); + ret = decode_scale_factors(ics, ld); #ifdef ERROR_RESILIENCE } else { /* In ER AAC the parameters for RVLC are seperated from the actual data that holds the scale_factors. Strangely enough, 2 parameters for HCR are put inbetween them. */ - return rvlc_scale_factor_data(ics, ld); + ret = rvlc_scale_factor_data(ics, ld); } #endif + +#ifdef PROFILE + count = faad_get_ts() - count; + hDecoder->scalefac_cycles += count; +#endif + + return ret; } /* Table 4.4.27 */ @@ -1304,10 +1619,12 @@ static void tns_data(ic_stream *ics, tns_info *tns, bitfile *ld) #ifdef LTP_DEC /* Table 4.4.28 */ -static void ltp_data(faacDecHandle hDecoder, ic_stream *ics, ltp_info *ltp, bitfile *ld) +static uint8_t ltp_data(faacDecHandle hDecoder, ic_stream *ics, ltp_info *ltp, bitfile *ld) { uint8_t sfb, w; + ltp->lag = 0; + #ifdef LD_DEC if (hDecoder->object_type == LD) { @@ -1326,6 +1643,11 @@ static void ltp_data(faacDecHandle hDecoder, ic_stream *ics, ltp_info *ltp, bitf #ifdef LD_DEC } #endif + + /* Check length of lag */ + if (ltp->lag > (hDecoder->frameLength << 1)) + return 18; + ltp->coef = (uint8_t)faad_getbits(ld, 3 DEBUGVAR(1,82,"ltp_data(): coef")); @@ -1354,6 +1676,8 @@ static void ltp_data(faacDecHandle hDecoder, ic_stream *ics, ltp_info *ltp, bitf DEBUGVAR(1,86,"ltp_data(): long_used")); } } + + return 0; } #endif @@ -1370,8 +1694,12 @@ static uint8_t spectral_data(faacDecHandle hDecoder, ic_stream *ics, bitfile *ld uint8_t result; uint16_t nshort = hDecoder->frameLength/8; +#ifdef PROFILE + int64_t count = faad_get_ts(); +#endif + sp = spectral_data; - memset(sp, 0, hDecoder->frameLength*sizeof(int16_t)); + /*memset(sp, 0, hDecoder->frameLength*sizeof(int16_t));*/ for(g = 0; g < ics->num_window_groups; g++) { @@ -1396,13 +1724,10 @@ static uint8_t spectral_data(faacDecHandle hDecoder, ic_stream *ics, bitfile *ld { sp = spectral_data + p; - if (sect_cb < FIRST_PAIR_HCB) + if ((result = huffman_spectral_data(sect_cb, ld, sp)) > 0) + return result; + if (sect_cb >= FIRST_PAIR_HCB) { - if ((result = huffman_spectral_data(sect_cb, ld, sp)) > 0) - return result; - } else { - if ((result = huffman_spectral_data(sect_cb, ld, sp)) > 0) - return result; if ((result = huffman_spectral_data(sect_cb, ld, sp+2)) > 0) return result; } @@ -1414,6 +1739,11 @@ static uint8_t spectral_data(faacDecHandle hDecoder, ic_stream *ics, bitfile *ld groups += ics->window_group_length[g]; } +#ifdef PROFILE + count = faad_get_ts() - count; + hDecoder->spectral_cycles += count; +#endif + return 0; } @@ -1443,7 +1773,7 @@ static uint16_t extension_payload(bitfile *ld, drc_info *drc, uint16_t count) } return count; case EXT_DATA_ELEMENT: - data_element_version = faad_getbits(ld, 4 + data_element_version = (uint8_t)faad_getbits(ld, 4 DEBUGVAR(1,400,"extension_payload(): data_element_version")); switch (data_element_version) { @@ -1451,7 +1781,7 @@ static uint16_t extension_payload(bitfile *ld, drc_info *drc, uint16_t count) loopCounter = 0; dataElementLength = 0; do { - dataElementLengthPart = faad_getbits(ld, 8 + dataElementLengthPart = (uint8_t)faad_getbits(ld, 8 DEBUGVAR(1,401,"extension_payload(): dataElementLengthPart")); dataElementLength += dataElementLengthPart; loopCounter++; @@ -1609,17 +1939,17 @@ void get_adif_header(adif_header *adif, bitfile *ld) adif->num_program_config_elements = (uint8_t)faad_getbits(ld, 4 DEBUGVAR(1,116,"get_adif_header(): num_program_config_elements")); - if(adif->bitstream_type == 0) - { - adif->adif_buffer_fullness = faad_getbits(ld, 20 - DEBUGVAR(1,117,"get_adif_header(): adif_buffer_fullness")); - } else { - adif->adif_buffer_fullness = 0; - } - for (i = 0; i < adif->num_program_config_elements + 1; i++) { - program_config_element(&adif->pce, ld); + if(adif->bitstream_type == 0) + { + adif->adif_buffer_fullness = faad_getbits(ld, 20 + DEBUGVAR(1,117,"get_adif_header(): adif_buffer_fullness")); + } else { + adif->adif_buffer_fullness = 0; + } + + program_config_element(&adif->pce[i], ld); } } @@ -1677,13 +2007,16 @@ static uint8_t adts_fixed_header(adts_header *adts, bitfile *ld) DEBUGVAR(1,126,"adts_fixed_header(): original")); adts->home = faad_get1bit(ld DEBUGVAR(1,127,"adts_fixed_header(): home")); -/* Removed in corrigendum 14496-3:2002 - if (adts->id == 0) + + if (adts->old_format == 1) { - adts->emphasis = (uint8_t)faad_getbits(ld, 2 - DEBUGVAR(1,128,"adts_fixed_header(): emphasis")); + /* Removed in corrigendum 14496-3:2002 */ + if (adts->id == 0) + { + adts->emphasis = (uint8_t)faad_getbits(ld, 2 + DEBUGVAR(1,128,"adts_fixed_header(): emphasis")); + } } -*/ return 0; } diff --git a/src/libfaad/syntax.h b/src/libfaad/syntax.h index b8c5b9a09..4dccee529 100644 --- a/src/libfaad/syntax.h +++ b/src/libfaad/syntax.h @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: syntax.h,v 1.5 2003/04/12 14:58:47 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: syntax.h,v 1.6 2003/12/30 02:00:11 miguelfreitas Exp $ **/ #ifndef __SYNTAX_H__ @@ -30,15 +36,34 @@ extern "C" { #include "drc.h" #include "bits.h" -#define MAIN 0 -#define LC 1 -#define SSR 2 -#define LTP 3 +#define MAIN 1 +#define LC 2 +#define SSR 3 +#define LTP 4 +#define HE_AAC 5 #define LD 23 #define ER_LC 17 #define ER_LTP 19 #define DRM_ER_LC 27 /* special object type for DRM */ +/* header types */ +#define RAW 0 +#define ADIF 1 +#define ADTS 2 + +/* SBR signalling */ +#define NO_SBR 0 +#define SBR_UPSAMPLED 1 +#define SBR_DOWNSAMPLED 2 +#define NO_SBR_UPSAMPLED 3 + +/* DRM channel definitions */ +#define DRMCH_MONO 1 +#define DRMCH_STEREO 2 +#define DRMCH_SBR_MONO 3 +#define DRMCH_SBR_LC_STEREO 4 +#define DRMCH_SBR_STEREO 5 + /* First object type that has ER */ #define ER_OBJECT_START 17 @@ -75,25 +100,65 @@ extern "C" { #define ESC_HCB 11 #define QUAD_LEN 4 #define PAIR_LEN 2 -#define BOOKSCL 12 #define NOISE_HCB 13 #define INTENSITY_HCB2 14 #define INTENSITY_HCB 15 - -int8_t GASpecificConfig(bitfile *ld, mp4AudioSpecificConfig *mp4ASC); +int8_t GASpecificConfig(bitfile *ld, mp4AudioSpecificConfig *mp4ASC, + program_config *pce); uint8_t adts_frame(adts_header *adts, bitfile *ld); void get_adif_header(adif_header *adif, bitfile *ld); - - -/* static declarations moved to avoid compiler warnings [MF] */ - +void decode_sce_lfe(faacDecHandle hDecoder, faacDecFrameInfo *hInfo, bitfile *ld, + uint8_t id_syn_ele); +void decode_cpe(faacDecHandle hDecoder, faacDecFrameInfo *hInfo, bitfile *ld, + uint8_t id_syn_ele); +void raw_data_block(faacDecHandle hDecoder, faacDecFrameInfo *hInfo, + bitfile *ld, program_config *pce, drc_info *drc); + + +/* static functions */ +static uint8_t single_lfe_channel_element(faacDecHandle hDecoder, bitfile *ld, + uint8_t channel, uint8_t *tag); +static uint8_t channel_pair_element(faacDecHandle hDecoder, bitfile *ld, + uint8_t channel, uint8_t *tag); +#ifdef COUPLING_DEC +static uint8_t coupling_channel_element(faacDecHandle hDecoder, bitfile *ld); +#endif +static uint16_t data_stream_element(faacDecHandle hDecoder, bitfile *ld); +static uint8_t program_config_element(program_config *pce, bitfile *ld); +static uint8_t fill_element(faacDecHandle hDecoder, bitfile *ld, drc_info *drc +#ifdef SBR_DEC + ,uint8_t sbr_ele +#endif + ); +static uint8_t individual_channel_stream(faacDecHandle hDecoder, element *ele, + bitfile *ld, ic_stream *ics, uint8_t scal_flag, + int16_t *spec_data); +static uint8_t ics_info(faacDecHandle hDecoder, ic_stream *ics, bitfile *ld, + uint8_t common_window); +static uint8_t section_data(faacDecHandle hDecoder, ic_stream *ics, bitfile *ld); +static uint8_t scale_factor_data(faacDecHandle hDecoder, ic_stream *ics, bitfile *ld); +static void gain_control_data(bitfile *ld, ic_stream *ics); +static uint8_t spectral_data(faacDecHandle hDecoder, ic_stream *ics, bitfile *ld, + int16_t *spectral_data); +static uint16_t extension_payload(bitfile *ld, drc_info *drc, uint16_t count); #ifdef ERROR_RESILIENCE uint8_t reordered_spectral_data(faacDecHandle hDecoder, ic_stream *ics, bitfile *ld, int16_t *spectral_data); #endif - +static uint8_t pulse_data(ic_stream *ics, pulse_info *pul, bitfile *ld); +static void tns_data(ic_stream *ics, tns_info *tns, bitfile *ld); +static uint8_t ltp_data(faacDecHandle hDecoder, ic_stream *ics, ltp_info *ltp, bitfile *ld); +static uint8_t adts_fixed_header(adts_header *adts, bitfile *ld); +static void adts_variable_header(adts_header *adts, bitfile *ld); +static void adts_error_check(adts_header *adts, bitfile *ld); +static uint8_t dynamic_range_info(bitfile *ld, drc_info *drc); +static uint8_t excluded_channels(bitfile *ld, drc_info *drc); +#ifdef SCALABLE_DEC +static int8_t aac_scalable_main_header(faacDecHandle hDecoder, ic_stream *ics1, ic_stream *ics2, + bitfile *ld, uint8_t this_layer_stereo); +#endif #ifdef __cplusplus } diff --git a/src/libfaad/tns.c b/src/libfaad/tns.c index 6609071ae..1d03c726c 100644 --- a/src/libfaad/tns.c +++ b/src/libfaad/tns.c @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: tns.c,v 1.3 2003/04/12 14:58:47 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: tns.c,v 1.4 2003/12/30 02:00:11 miguelfreitas Exp $ **/ #include "common.h" @@ -25,69 +31,38 @@ #include "syntax.h" #include "tns.h" -#ifdef FIXED_POINT -static real_t tns_coef_0_3[] = -{ - 0x0, 0x6F13013, 0xC8261BA, 0xF994E02, - 0xF03E3A3A, 0xF224C28C, 0xF5B72457, 0xFA8715E3, - 0xF90ECFED, 0xF37D9E46, 0xF066B1FE, 0xF066B1FE, - 0xF03E3A3A, 0xF224C28C, 0xF5B72457, 0xFA8715E3 -}; -static real_t tns_coef_0_4[] = -{ - 0x0, 0x3539B35, 0x681FE48, 0x9679182, - 0xBE3EBD4, 0xDDB3D74, 0xF378709, 0xFE98FCA, - 0xF011790B, 0xF09C5CB7, 0xF1AD6942, 0xF33B524A, - 0xF5388AEB, 0xF793BBDF, 0xFA385AA9, 0xFD0F5CAB -}; -static real_t tns_coef_1_3[] = -{ - 0x0, 0x6F13013, 0xF5B72457, 0xFA8715E3, - 0xF994E02, 0xC8261BA, 0xF5B72457, 0xFA8715E3, - 0xF90ECFED, 0xF37D9E46, 0xF5B72457, 0xFA8715E3, - 0xF37D9E46, 0xF90ECFED, 0xF5B72457, 0xFA8715E3 -}; -static real_t tns_coef_1_4[] = -{ - 0x0, 0x3539B35, 0x681FE48, 0x9679182, - 0xF5388AEB, 0xF793BBDF, 0xFA385AA9, 0xFD0F5CAB, - 0xFE98FCA, 0xF378709, 0xDDB3D74, 0xBE3EBD4, - 0xF5388AEB, 0xF793BBDF, 0xFA385AA9, 0xFD0F5CAB -}; -#else #ifdef _MSC_VER #pragma warning(disable:4305) #pragma warning(disable:4244) #endif static real_t tns_coef_0_3[] = { - 0.0, 0.4338837391, 0.7818314825, 0.9749279122, - -0.9848077530, -0.8660254038, -0.6427876097, -0.3420201433, - -0.4338837391, -0.7818314825, -0.9749279122, -0.9749279122, - -0.9848077530, -0.8660254038, -0.6427876097, -0.3420201433 + COEF_CONST(0.0), COEF_CONST(0.4338837391), COEF_CONST(0.7818314825), COEF_CONST(0.9749279122), + COEF_CONST(-0.9848077530), COEF_CONST(-0.8660254038), COEF_CONST(-0.6427876097), COEF_CONST(-0.3420201433), + COEF_CONST(-0.4338837391), COEF_CONST(-0.7818314825), COEF_CONST(-0.9749279122), COEF_CONST(-0.9749279122), + COEF_CONST(-0.9848077530), COEF_CONST(-0.8660254038), COEF_CONST(-0.6427876097), COEF_CONST(-0.3420201433) }; static real_t tns_coef_0_4[] = { - 0.0, 0.2079116908, 0.4067366431, 0.5877852523, - 0.7431448255, 0.8660254038, 0.9510565163, 0.9945218954, - -0.9957341763, -0.9618256432, -0.8951632914, -0.7980172273, - -0.6736956436, -0.5264321629, -0.3612416662, -0.1837495178 + COEF_CONST(0.0), COEF_CONST(0.2079116908), COEF_CONST(0.4067366431), COEF_CONST(0.5877852523), + COEF_CONST(0.7431448255), COEF_CONST(0.8660254038), COEF_CONST(0.9510565163), COEF_CONST(0.9945218954), + COEF_CONST(-0.9957341763), COEF_CONST(-0.9618256432), COEF_CONST(-0.8951632914), COEF_CONST(-0.7980172273), + COEF_CONST(-0.6736956436), COEF_CONST(-0.5264321629), COEF_CONST(-0.3612416662), COEF_CONST(-0.1837495178) }; static real_t tns_coef_1_3[] = { - 0.0, 0.4338837391, -0.6427876097, -0.3420201433, - 0.9749279122, 0.7818314825, -0.6427876097, -0.3420201433, - -0.4338837391, -0.7818314825, -0.6427876097, -0.3420201433, - -0.7818314825, -0.4338837391, -0.6427876097, -0.3420201433 + COEF_CONST(0.0), COEF_CONST(0.4338837391), COEF_CONST(-0.6427876097), COEF_CONST(-0.3420201433), + COEF_CONST(0.9749279122), COEF_CONST(0.7818314825), COEF_CONST(-0.6427876097), COEF_CONST(-0.3420201433), + COEF_CONST(-0.4338837391), COEF_CONST(-0.7818314825), COEF_CONST(-0.6427876097), COEF_CONST(-0.3420201433), + COEF_CONST(-0.7818314825), COEF_CONST(-0.4338837391), COEF_CONST(-0.6427876097), COEF_CONST(-0.3420201433) }; static real_t tns_coef_1_4[] = { - 0.0, 0.2079116908, 0.4067366431, 0.5877852523, - -0.6736956436, -0.5264321629, -0.3612416662, -0.1837495178, - 0.9945218954, 0.9510565163, 0.8660254038, 0.7431448255, - -0.6736956436, -0.5264321629, -0.3612416662, -0.1837495178 + COEF_CONST(0.0), COEF_CONST(0.2079116908), COEF_CONST(0.4067366431), COEF_CONST(0.5877852523), + COEF_CONST(-0.6736956436), COEF_CONST(-0.5264321629), COEF_CONST(-0.3612416662), COEF_CONST(-0.1837495178), + COEF_CONST(0.9945218954), COEF_CONST(0.9510565163), COEF_CONST(0.8660254038), COEF_CONST(0.7431448255), + COEF_CONST(-0.6736956436), COEF_CONST(-0.5264321629), COEF_CONST(-0.3612416662), COEF_CONST(-0.1837495178) }; -#endif /* TNS decoding for one channel and frame */ @@ -96,7 +71,8 @@ void tns_decode_frame(ic_stream *ics, tns_info *tns, uint8_t sr_index, { uint8_t w, f, tns_order; int8_t inc; - uint16_t bottom, top, start, end, size; + int16_t size; + uint16_t bottom, top, start, end; uint16_t nshort = frame_len/8; real_t lpc[TNS_MAX_ORDER+1]; @@ -118,10 +94,16 @@ void tns_decode_frame(ic_stream *ics, tns_info *tns, uint8_t sr_index, tns_decode_coef(tns_order, tns->coef_res[w]+3, tns->coef_compress[w][f], tns->coef[w][f], lpc); - start = ics->swb_offset[min(bottom, ics->max_sfb)]; - end = ics->swb_offset[min(top, ics->max_sfb)]; + start = min(bottom, max_tns_sfb(sr_index, object_type, (ics->window_sequence == EIGHT_SHORT_SEQUENCE))); + start = min(start, ics->max_sfb); + start = ics->swb_offset[start]; - if ((size = end - start) <= 0) + end = min(top, max_tns_sfb(sr_index, object_type, (ics->window_sequence == EIGHT_SHORT_SEQUENCE))); + end = min(end, ics->max_sfb); + end = ics->swb_offset[end]; + + size = end - start; + if (size <= 0) continue; if (tns->direction[w][f]) @@ -143,7 +125,8 @@ void tns_encode_frame(ic_stream *ics, tns_info *tns, uint8_t sr_index, { uint8_t w, f, tns_order; int8_t inc; - uint16_t bottom, top, start, end, size; + int16_t size; + uint16_t bottom, top, start, end; uint16_t nshort = frame_len/8; real_t lpc[TNS_MAX_ORDER+1]; @@ -165,10 +148,16 @@ void tns_encode_frame(ic_stream *ics, tns_info *tns, uint8_t sr_index, tns_decode_coef(tns_order, tns->coef_res[w]+3, tns->coef_compress[w][f], tns->coef[w][f], lpc); - start = ics->swb_offset[min(bottom, ics->max_sfb)]; - end = ics->swb_offset[min(top, ics->max_sfb)]; + start = min(bottom, max_tns_sfb(sr_index, object_type, (ics->window_sequence == EIGHT_SHORT_SEQUENCE))); + start = min(start, ics->max_sfb); + start = ics->swb_offset[start]; + + end = min(top, max_tns_sfb(sr_index, object_type, (ics->window_sequence == EIGHT_SHORT_SEQUENCE))); + end = min(end, ics->max_sfb); + end = ics->swb_offset[end]; - if ((size = end - start) <= 0) + size = end - start; + if (size <= 0) continue; if (tns->direction[w][f]) @@ -217,7 +206,7 @@ static void tns_decode_coef(uint8_t order, uint8_t coef_res_bits, uint8_t coef_c for (m = 1; m <= order; m++) { for (i = 1; i < m; i++) /* loop only while i<m */ - b[i] = a[i] + MUL_C_C(tmp2[m-1], a[m-i]); + b[i] = a[i] + MUL_C(tmp2[m-1], a[m-i]); for (i = 1; i < m; i++) /* loop only while i<m */ a[i] = b[i]; @@ -250,7 +239,7 @@ static void tns_ar_filter(real_t *spectrum, uint16_t size, int8_t inc, real_t *l y = *spectrum; for (j = 0; j < order; j++) - y -= MUL_R_C(state[j], lpc[j+1]); + y -= MUL_C(state[j], lpc[j+1]); for (j = order-1; j > 0; j--) state[j] = state[j-1]; @@ -285,7 +274,7 @@ static void tns_ma_filter(real_t *spectrum, uint16_t size, int8_t inc, real_t *l y = *spectrum; for (j = 0; j < order; j++) - y += MUL_R_C(state[j], lpc[j+1]); + y += MUL_C(state[j], lpc[j+1]); for (j = order-1; j > 0; j--) state[j] = state[j-1]; diff --git a/src/libfaad/tns.h b/src/libfaad/tns.h index 37f9c9a9d..30aef676f 100644 --- a/src/libfaad/tns.h +++ b/src/libfaad/tns.h @@ -1,6 +1,6 @@ /* -** FAAD - Freeware Advanced Audio Decoder -** Copyright (C) 2002 M. Bakker +** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding +** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -16,7 +16,13 @@ ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ** -** $Id: tns.h,v 1.3 2003/04/12 14:58:47 miguelfreitas Exp $ +** Any non-GPL usage of this software or parts of this software is strictly +** forbidden. +** +** Commercial non-GPL licensing of this software is possible. +** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. +** +** $Id: tns.h,v 1.4 2003/12/30 02:00:11 miguelfreitas Exp $ **/ #ifndef __TNS_H__ diff --git a/src/libfaad/xine_decoder.c b/src/libfaad/xine_decoder.c index 4a9e45b95..d1c856865 100644 --- a/src/libfaad/xine_decoder.c +++ b/src/libfaad/xine_decoder.c @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA * - * $Id: xine_decoder.c,v 1.24 2003/12/20 14:21:50 tmmm Exp $ + * $Id: xine_decoder.c,v 1.25 2003/12/30 02:00:11 miguelfreitas Exp $ * */ @@ -30,6 +30,7 @@ #define LOG_MODULE "faad_decoder" #define LOG_VERBOSE + /* #define LOG */ @@ -95,7 +96,7 @@ static int faad_open_dec( faad_decoder_t *this ) { if( this->faac_cfg ) { this->faac_cfg->defSampleRate = 44100; this->faac_cfg->outputFormat = FAAD_FMT_16BIT; - this->faac_cfg->defObjectType = LC; + this->faac_cfg->useOldADTSFormat = 0; faacDecSetConfiguration(this->faac_dec, this->faac_cfg); } } @@ -160,12 +161,14 @@ static void faad_decode_audio ( faad_decoder_t *this, int end_frame ) { this->size -= used; inbuf += used; } + + if( this->mp4_mode ) + this->size = 0; } - if( this->mp4_mode ) - this->size = 0; - else if( this->size ) + if( this->size ) memmove( this->buf, inbuf, this->size); + } static void faad_decode_data (audio_decoder_t *this_gen, buf_element_t *buf) { @@ -272,30 +275,29 @@ this->num_channels = 2; this->size -= used; memmove(this->buf, &this->buf[used], this->size); - } else { + } - /* open audio device as needed */ - if (!this->output_open) { - switch( this->num_channels ) { - case 1: - this->ao_cap_mode=AO_CAP_MODE_MONO; - break; - case 2: - this->ao_cap_mode=AO_CAP_MODE_STEREO; - break; - } - - this->output_open = this->stream->audio_out->open (this->stream->audio_out, - this->stream, - this->bits_per_sample, - this->rate, - this->ao_cap_mode) ; - - this->rec_audio_src_size = this->num_channels * FAAD_MIN_STREAMSIZE; + /* open audio device as needed */ + if (!this->output_open) { + switch( this->num_channels ) { + case 1: + this->ao_cap_mode=AO_CAP_MODE_MONO; + break; + case 2: + this->ao_cap_mode=AO_CAP_MODE_STEREO; + break; } - faad_decode_audio(this, buf->decoder_flags & BUF_FLAG_FRAME_END ); + this->output_open = this->stream->audio_out->open (this->stream->audio_out, + this->stream, + this->bits_per_sample, + this->rate, + this->ao_cap_mode) ; + + this->rec_audio_src_size = this->num_channels * FAAD_MIN_STREAMSIZE; } + + faad_decode_audio(this, buf->decoder_flags & BUF_FLAG_FRAME_END ); } } |