diff --git a/Workspace_msvc/lib_com.vcxproj b/Workspace_msvc/lib_com.vcxproj
index a18464d878a503ae2e6c14cdfd042800744d1248..537f7005b966660d7a7de7c8aa79a4d28576f813 100644
--- a/Workspace_msvc/lib_com.vcxproj
+++ b/Workspace_msvc/lib_com.vcxproj
@@ -160,7 +160,6 @@
-
@@ -172,19 +171,16 @@
-
-
-
@@ -278,7 +274,6 @@
-
diff --git a/Workspace_msvc/lib_com.vcxproj.filters b/Workspace_msvc/lib_com.vcxproj.filters
index 4d60b3abd8ce011126bb7b89fe9a5bfac636a699..c427c57e58624bfd3babdbbe6f68cd7b008f320a 100644
--- a/Workspace_msvc/lib_com.vcxproj.filters
+++ b/Workspace_msvc/lib_com.vcxproj.filters
@@ -10,9 +10,6 @@
common_ivas_c
-
- common_ivas_c
-
common_ivas_c
@@ -386,15 +383,11 @@
-
-
-
-
diff --git a/lib_com/est_tilt.c b/lib_com/est_tilt.c
deleted file mode 100644
index e7ff1a63da5d19126d519598afb50fbc44e97071..0000000000000000000000000000000000000000
--- a/lib_com/est_tilt.c
+++ /dev/null
@@ -1,90 +0,0 @@
-/******************************************************************************************************
-
- (C) 2022-2024 IVAS codec Public Collaboration with portions copyright Dolby International AB, Ericsson AB,
- Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD.,
- Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange,
- Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other
- contributors to this repository. All Rights Reserved.
-
- This software is protected by copyright law and by international treaties.
- The IVAS codec Public Collaboration consisting of Dolby International AB, Ericsson AB,
- Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD.,
- Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange,
- Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other
- contributors to this repository retain full ownership rights in their respective contributions in
- the software. This notice grants no license of any kind, including but not limited to patent
- license, nor is any license granted by implication, estoppel or otherwise.
-
- Contributors are required to enter into the IVAS codec Public Collaboration agreement before making
- contributions.
-
- This software is provided "AS IS", without any express or implied warranties. The software is in the
- development stage. It is intended exclusively for experts who have experience with such software and
- solely for the purpose of inspection. All implied warranties of non-infringement, merchantability
- and fitness for a particular purpose are hereby disclaimed and excluded.
-
- Any dispute, controversy or claim arising under or in relation to providing this software shall be
- submitted to and settled by the final, binding jurisdiction of the courts of Munich, Germany in
- accordance with the laws of the Federal Republic of Germany excluding its conflict of law rules and
- the United Nations Convention on Contracts on the International Sales of Goods.
-
-*******************************************************************************************************/
-
-/*====================================================================================
- EVS Codec 3GPP TS26.443 Nov 04, 2021. Version 12.14.0 / 13.10.0 / 14.6.0 / 15.4.0 / 16.3.0
- ====================================================================================*/
-
-#include
-#include "options.h"
-#include "cnst.h"
-#include "prot.h"
-#include "wmc_auto.h"
-
-/*-------------------------------------------------------------------*
- * est_tilt()
- *
- * Estimate spectral tilt based on the relative E of adaptive
- * and innovative excitations
- *-------------------------------------------------------------------*/
-
-/*! r: tilt of the code */
-float est_tilt(
- const float *adpt_exc, /* i : adaptive excitation vector */
- const float gain_pit, /* i : adaptive gain */
- const float *fixe_exc, /* i : algebraic exctitation vector */
- const float gain_code, /* i : algebraic code gain */
- float *voice_fac, /* o : voicing factor */
- const int16_t L_subfr, /* i : subframe size */
- const int16_t flag_tilt /* i : flag for special tilt */
-)
-{
- float ener, tmp, tilt_code;
-
- ener = dotp( adpt_exc, adpt_exc, L_subfr );
- ener *= gain_pit * gain_pit; /* energy of pitch excitation */
-
- tmp = dotp( fixe_exc, fixe_exc, L_subfr );
- tmp *= gain_code * gain_code; /* energy of innovative code excitation */
-
- /* find voice factor (1=voiced, -1=unvoiced) */
- *voice_fac = (float) ( ( ener - tmp ) / ( ener + tmp + 0.01f ) );
-
- /* find tilt of code for next subframe */
- if ( flag_tilt == 0 )
- {
- /*Between 0 (=unvoiced) and 0.5 (=voiced)*/
- tilt_code = (float) ( 0.25f * ( 1.0f + *voice_fac ) );
- }
- else if ( flag_tilt == 1 )
- {
- /*Between 0.25 (=unvoiced) and 0.5 (=voiced)*/
- tilt_code = (float) ( 0.25f + ( *voice_fac + 1.0f ) * 0.125f );
- }
- else
- {
- /*Between 0.28 (=unvoiced) and 0.56 (=voiced)*/
- tilt_code = (float) ( 0.28f + ( *voice_fac + 1.0f ) * 0.14f );
- }
-
- return tilt_code;
-}
diff --git a/lib_com/fine_gain_bits.c b/lib_com/fine_gain_bits.c
deleted file mode 100644
index fd9c0d49017bd7223ac3770b1597e852b3af5ce8..0000000000000000000000000000000000000000
--- a/lib_com/fine_gain_bits.c
+++ /dev/null
@@ -1,130 +0,0 @@
-/******************************************************************************************************
-
- (C) 2022-2024 IVAS codec Public Collaboration with portions copyright Dolby International AB, Ericsson AB,
- Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD.,
- Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange,
- Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other
- contributors to this repository. All Rights Reserved.
-
- This software is protected by copyright law and by international treaties.
- The IVAS codec Public Collaboration consisting of Dolby International AB, Ericsson AB,
- Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD.,
- Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange,
- Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other
- contributors to this repository retain full ownership rights in their respective contributions in
- the software. This notice grants no license of any kind, including but not limited to patent
- license, nor is any license granted by implication, estoppel or otherwise.
-
- Contributors are required to enter into the IVAS codec Public Collaboration agreement before making
- contributions.
-
- This software is provided "AS IS", without any express or implied warranties. The software is in the
- development stage. It is intended exclusively for experts who have experience with such software and
- solely for the purpose of inspection. All implied warranties of non-infringement, merchantability
- and fitness for a particular purpose are hereby disclaimed and excluded.
-
- Any dispute, controversy or claim arising under or in relation to providing this software shall be
- submitted to and settled by the final, binding jurisdiction of the courts of Munich, Germany in
- accordance with the laws of the Federal Republic of Germany excluding its conflict of law rules and
- the United Nations Convention on Contracts on the International Sales of Goods.
-
-*******************************************************************************************************/
-
-/*====================================================================================
- EVS Codec 3GPP TS26.443 Nov 04, 2021. Version 12.14.0 / 13.10.0 / 14.6.0 / 15.4.0 / 16.3.0
- ====================================================================================*/
-
-#include
-#include "options.h"
-#include "rom_com.h"
-#include "prot.h"
-#include
-#include "wmc_auto.h"
-
-#ifndef IVAS_FLOAT_FIXED
-/*--------------------------------------------------------------------------
- * subband_gain_bits()
- *
- * HQ core encoder
- *--------------------------------------------------------------------------*/
-
-static void subband_gain_bits(
- const int16_t *Rk, /* i : bit allocation per band (Q3)*/
- const int16_t N, /* i : number of bands */
- int16_t *bits, /* o : gain bits per band */
- const int16_t *sfmsize /* i : Size of bands */
-)
-{
- int16_t i, b, tot;
- int16_t bps;
-
- tot = 0;
-
- for ( i = 0; i < N; i++ )
- {
- bps = ( Rk[i] * fg_inv_tbl_fx[sfmsize[i] >> 3] ) >> 18;
- if ( ( ( sfmsize[i] * ( bps + 1 ) ) << 3 ) - Rk[i] == 0 )
- { /* correct approx. division result, to obtain exact integer division output */
- bps++;
- }
- bps = min( 7, bps );
-
- b = fine_gain_bits[bps];
- bits[i] = b;
- tot += b;
- }
-
- if ( tot == 0 )
- {
- /* If no gain bits were assigned, use one bit anyway for potential PVQ overage */
- bits[0] = 1;
- }
-
- return;
-}
-
-/*--------------------------------------------------------------------------*
- * assign_gain_bits()
- *
- * Assign gain adjustment bits and update bit budget
- *--------------------------------------------------------------------------*/
-
-/*! r: Number of assigned gain bits */
-int16_t assign_gain_bits(
- const int16_t core, /* i : HQ core */
- const int16_t BANDS, /* i : Number of bands */
- const int16_t *band_width, /* i : Sub band bandwidth */
- int16_t *Rk, /* i/o: Bit allocation/Adjusted bit alloc. (Q3) */
- int16_t *gain_bits_array, /* o : Assigned gain bits */
- int16_t *Rcalc /* o : Bit budget for shape quantizer (Q3) */
-)
-{
- int16_t gain_bits_tot;
- int16_t i;
-
- /* Allocate gain bits for every subband used, based on bitrate and bandwidth */
- if ( core == HQ_CORE )
- {
- subband_gain_bits( Rk, BANDS, gain_bits_array, band_width );
- }
- else
- {
- set_s( gain_bits_array, 0, BANDS );
- }
-
- /* Re-adjust bit budget for gain quantization */
- gain_bits_tot = 0;
- *Rcalc = 0;
- for ( i = 0; i < BANDS; i++ )
- {
- if ( Rk[i] > 0 )
- {
- Rk[i] -= gain_bits_array[i] * 8;
- gain_bits_tot += gain_bits_array[i];
- *Rcalc += Rk[i];
- }
- }
-
- return gain_bits_tot;
-}
-#endif
diff --git a/lib_com/frame_ener_fx.c b/lib_com/frame_ener_fx.c
index b6871307a427b8fcbd6aadc7f915c487fb2f024d..e9075a02497f53a2a1858bf29e13a3a85b1b99ef 100644
--- a/lib_com/frame_ener_fx.c
+++ b/lib_com/frame_ener_fx.c
@@ -47,47 +47,6 @@
* Estimation of pitch-synchronous (voiced sounds) or half-frame energy
*----------------------------------------------------------------------------------*/
-#ifndef IVAS_FLOAT_FIXED
-void fer_energy(
- const int16_t L_frame, /* i : frame length */
- const int16_t clas, /* i : frame classification */
- const float *synth, /* i : synthesized speech at Fs = 12k8 Hz */
- const float pitch, /* i : pitch period */
- float *enr, /* o : pitch-synchronous or half_frame energy */
- const int16_t offset /* i : speech pointer offset (0 or L_frame) */
-)
-{
- int16_t len;
- const float *pt_synth;
-
- if ( clas == VOICED_CLAS || clas == ONSET || clas == SIN_ONSET ) /* Voiced or Onset current frame */
- {
- len = (int16_t) ( pitch + 0.5f ); /* pitch value */
-
- pt_synth = synth;
- if ( offset != 0 )
- {
- pt_synth = synth + L_frame - len;
- }
-
- emaximum( pt_synth, len, enr ); /* pitch synchronous E */
- }
- else
- {
- pt_synth = synth;
- if ( offset != 0 )
- {
- pt_synth = synth + L_frame / 2;
- }
-
- *enr = dotp( pt_synth, pt_synth, L_frame / 2 );
- *enr /= (float) ( L_frame / 2 );
- }
- return;
-}
-#endif
-
-#ifdef IVAS_FLOAT_FIXED
void fer_energy_fx(
const Word16 L_frame, /* i : frame length */
const Word16 clas, /* i : frame classification */
@@ -143,50 +102,6 @@ void fer_energy_fx(
}
return;
}
-#endif // IVAS_FLOAT_FIXED
-
-#ifndef IVAS_FLOAT_FIXED
-/*------------------------------------------------------------------------*
- * frame_energy()
- *
- * Compute pitch-synchronous energy at the frame end
- *------------------------------------------------------------------------*/
-
-float frame_energy(
- const int16_t L_frame, /* i : length of the frame */
- const float *pitch, /* i : pitch values for each subframe */
- const float *speech, /* i : pointer to speech signal for E computation */
- const float lp_speech, /* i : long-term active speech energy average */
- float *frame_ener /* o : pitch-synchronous energy at frame end */
-)
-{
- float enern;
- const float *pt1;
- int16_t len;
- float dotProd;
-
- len = (int16_t) ( 0.5f * ( pitch[2] + pitch[3] ) + 0.5f );
- if ( len < L_SUBFR )
- {
- len *= 2;
- }
-
- pt1 = speech + L_frame - len;
-
- dotProd = dotp( pt1, pt1, len );
- if ( 0 == dotProd )
- {
- *frame_ener = MIN_LOG_VAL_60dB;
- }
- else
- {
- *frame_ener = 10.0f * (float) log10( dotProd / (float) len );
- }
- enern = *frame_ener - lp_speech;
-
- return enern;
-}
-#endif
/*----------------------------------------------------------------------------------*
* frame_ener()
diff --git a/lib_com/get_gain_fx.c b/lib_com/get_gain_fx.c
index de5f6e80df1efd3012f61d993aab59f432512ec1..be4d063e75f103c5905a7d52f8cd3cde6d4eaa9d 100644
--- a/lib_com/get_gain_fx.c
+++ b/lib_com/get_gain_fx.c
@@ -46,34 +46,6 @@
*
*----------------------------------------------------------------------------------*/
-#ifndef IVAS_FLOAT_FIXED
-/*! r: codebook gain (adaptive or fixed) */
-float get_gain_flt(
- const float x[], /* i : target signal */
- const float y[], /* i : filtered codebook excitation */
- const int16_t n, /* i : segment length */
- float *en_y /* o : energy of y (sum of y[]^2, optional) */
-)
-{
- float corr = 0.0f, ener = 1e-6f;
- int16_t i;
-
- for ( i = 0; i < n; i++ )
- {
- corr += x[i] * y[i];
- ener += y[i] * y[i];
- }
-
- if ( en_y )
- {
- *en_y = ener;
- }
-
- return ( corr / ener );
-}
-#endif
-
-#ifdef IVAS_FLOAT_FIXED
Word32 get_gain( /* output: codebook gain (adaptive or fixed) Q16 */
const Word16 x[], /* input : target signal Qx */
const Word16 y[], /* input : filtered codebook excitation Qx */
@@ -178,4 +150,3 @@ Word32 get_gain2( /* output: codebook gain (adaptive or fixed)
return Lgain;
}
-#endif
diff --git a/lib_com/gs_bitallocation.c b/lib_com/gs_bitallocation.c
deleted file mode 100644
index b787a201857b27bffa1b7d71ed757c08cf045a7d..0000000000000000000000000000000000000000
--- a/lib_com/gs_bitallocation.c
+++ /dev/null
@@ -1,1077 +0,0 @@
-/******************************************************************************************************
-
- (C) 2022-2024 IVAS codec Public Collaboration with portions copyright Dolby International AB, Ericsson AB,
- Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD.,
- Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange,
- Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other
- contributors to this repository. All Rights Reserved.
-
- This software is protected by copyright law and by international treaties.
- The IVAS codec Public Collaboration consisting of Dolby International AB, Ericsson AB,
- Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD.,
- Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange,
- Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other
- contributors to this repository retain full ownership rights in their respective contributions in
- the software. This notice grants no license of any kind, including but not limited to patent
- license, nor is any license granted by implication, estoppel or otherwise.
-
- Contributors are required to enter into the IVAS codec Public Collaboration agreement before making
- contributions.
-
- This software is provided "AS IS", without any express or implied warranties. The software is in the
- development stage. It is intended exclusively for experts who have experience with such software and
- solely for the purpose of inspection. All implied warranties of non-infringement, merchantability
- and fitness for a particular purpose are hereby disclaimed and excluded.
-
- Any dispute, controversy or claim arising under or in relation to providing this software shall be
- submitted to and settled by the final, binding jurisdiction of the courts of Munich, Germany in
- accordance with the laws of the Federal Republic of Germany excluding its conflict of law rules and
- the United Nations Convention on Contracts on the International Sales of Goods.
-
-*******************************************************************************************************/
-
-/*====================================================================================
- EVS Codec 3GPP TS26.443 Nov 04, 2021. Version 12.14.0 / 13.10.0 / 14.6.0 / 15.4.0 / 16.3.0
- ====================================================================================*/
-
-#include
-#include "options.h"
-#include
-#include "cnst.h"
-#include "rom_com.h"
-#include "prot.h"
-#include "ivas_prot.h"
-#include "wmc_auto.h"
-
-
-#ifndef IVAS_FLOAT_FIXED
-/*-------------------------------------------------------------------*
- * Local function prototypes
- *-------------------------------------------------------------------*/
-
-static float Find_bit_frac( const int16_t nb_band, const int16_t remaining_bits );
-
-static void reajust_bits( float *bits_per_bands, const int16_t st_band, const int16_t end_band, const int16_t sum_bit_in, const int16_t bit_bdgt_in );
-
-#define Q15_0_33 10922 /* 0.33 */
-#define Q18_0_1 26214 /* 0.1 */
-#define Q18_0_50 131072 /* 0.50 */
-#define Q18_0_75 196608 /* 0.75 */
-#define Q18_0_76 199229 /* 76/100 */
-#define Q18_1_0 262144 /* 1.0 */
-#define Q18_1_2 314573 /* 1.2 */
-#define Q18_112 29360128 /* 112 */
-#define Q18_DSR_NB_PULSE 1179648 /* 4.5 */
-#define Q18_1_5xDSR_NB_PULSE 1769472 /* 1.5x4.5 */
-#define Q18_2_0xDSR_NB_PULSE ( Q18_DSR_NB_PULSE << 1 ) /* 2.0x4.5 */
-
-#define Q31_0_00125 2684355 /* 0.125/100 */
-#define Q31_0_0125 26843546 /* 0.0125 */
-#define Q31_0_015 32212255 /* 0.0125 */
-#define Q31_0_02 42949673 /* 0.02 */
-#define Q31_0_17 365072220 /* 0.17 */
-#define Q31_0_23 493921239 /* 0.23 */
-
-static Word16 Find_norm_inv( const Word32 ToDivide, Word16 *e_div );
-static Word16 Find_bit_alloc_IVAS_int( const Word32 core_brate, const Word16 GSC_IVAS_mode, const Word16 Diff_len, const Word16 nb_tot_bands, const Word16 L_frame, Word16 *bit, Word16 *max_ener_band, float *ener_vec, float *bits_per_bands );
-static Word16 maximum_fx( const Word16 *vec_fx, const Word16 lvec_fx, Word16 *max_fx );
-
-/*-------------------------------------------------------------------*
- * bands_and_bit_alloc()
- *
- * AC mode (GSC) bands and bits allocation
- *-------------------------------------------------------------------*/
-
-void bands_and_bit_alloc(
- const int16_t cor_strong_limit, /* i : HF correlation */
- const int16_t noise_lev, /* i : dwn scaling factor */
- const int32_t core_brate, /* i : core bitrate */
- const int16_t Diff_len, /* i : Lenght of the difference signal (before pure spectral)*/
- const int16_t bits_used, /* i : Number of bit used before frequency Q */
- int16_t *bit, /* i/o: Number of bit allowed for frequency quantization */
- float *Ener_per_bd_iQ, /* i/o: Quantized energy vector */
- int16_t *max_ener_band, /* o : Sorted order */
- int16_t *bits_per_bands_s, /* i/o: Number of bit allowed per allowed subband (Q3) */
- int16_t *nb_subbands, /* o : Number of subband allowed */
- const float *exc_diff, /* i : Difference signal to quantize (encoder side only) */
- float *concat_in, /* o : Concatened PVQ's input vector (encoder side only) */
- int16_t *pvq_len, /* o : Number of bin covered with the PVQ */
- const int16_t coder_type, /* i : coding type */
- const int16_t bwidth, /* i : input signal bandwidth */
- const int16_t GSC_noisy_speech, /* i : GSC noisy speech flag */
- const int16_t L_frame, /* i : frame length */
- const int16_t element_mode, /* i : element mode */
- const int16_t GSC_IVAS_mode /* i : GSC IVAS mode */
-)
-{
- int16_t bandoffset, i, j, nb_bands_max, bit_new_bands, bit_tmp, st_band, nb_bands;
- float bit_fracf, etmp;
- float sum_bit;
- float ener_vec[MBANDS_GN_BITALLOC16k];
- int16_t nb_tot_bands;
- int16_t bit_index, bit_index_mem, imax;
- int16_t pos, band;
- float SWB_bit_budget;
- float bits_per_bands[MBANDS_GN_BITALLOC16k];
- float fzero_val;
-
- /* initializations */
- nb_tot_bands = 16;
- set_f( bits_per_bands, 0.0f, MBANDS_GN_BITALLOC16k );
-
- if ( L_frame == L_FRAME16k )
- {
- nb_tot_bands = MBANDS_GN_BITALLOC16k;
- }
-
- /* To adapt current energy band to PVQ freq band for sorting*/
- ener_vec[0] = Ener_per_bd_iQ[0] + Ener_per_bd_iQ[1];
- mvr2r( Ener_per_bd_iQ + 1, ener_vec, 15 );
- ener_vec[15] = ener_vec[14];
-
- if ( L_frame == L_FRAME16k )
- {
- ener_vec[16] = Ener_per_bd_iQ[16];
- ener_vec[17] = ( Ener_per_bd_iQ[16] + Ener_per_bd_iQ[17] ) * 0.5f;
- ener_vec[18] = Ener_per_bd_iQ[17];
- ener_vec[19] = Ener_per_bd_iQ[17] * 0.8f;
- }
-
- for ( i = 0; i < nb_tot_bands; i++ )
- {
- ener_vec[i] = (float) ( (int16_t) ( ener_vec[i] * 4096.f + 0.5f ) );
- }
-
- /*------------------------------------------------------------------------
- * Determination of the number of bits available to the frequency domain
- * Allocation of a maximum number of band to be encoded
- *-----------------------------------------------------------------------*/
-
- nb_bands_max = nb_tot_bands;
- bit_new_bands = 5;
-
- if ( core_brate > ACELP_16k40 && L_frame == L_FRAME16k )
- {
- bit_new_bands = 7;
- }
-
- i = 0;
- while ( i < SIZE_BRATE_INTERMED_TBL )
- {
- if ( core_brate <= brate_intermed_tbl[i] )
- {
- break;
- }
-
- if ( brate_intermed_tbl[i] == ACELP_24k40 )
- {
- break;
- }
-
- i++;
- }
-
- if ( element_mode > EVS_MONO && coder_type == AUDIO &&
- core_brate <= STEREO_GSC_BIT_RATE_ALLOC && brate_intermed_tbl[i] == ACELP_9k60 ) /* Bit allocation should be mapped to 8 kb/s instead of 9.6 kb/s in this case */
- {
- i--;
- }
-
- bit_index = BRATE2IDX( brate_intermed_tbl[i] ) * 17;
-
- bit_index_mem = bit_index;
-
- if ( ( coder_type == AUDIO || coder_type == INACTIVE ) && bwidth == NB )
- {
- if ( core_brate >= ACELP_9k60 )
- {
- *bit = (int16_t) ( core_brate * ( 1.0f / FRAMES_PER_SEC ) + 0.5f ) - bits_used - 25;
- }
- else
- {
- *bit = (int16_t) ( core_brate * ( 1.0f / FRAMES_PER_SEC ) + 0.5f ) - bits_used - 21;
- }
-
- nb_tot_bands = 10;
- }
- else
- {
- *bit = (int16_t) ( core_brate * ( 1.0f / FRAMES_PER_SEC ) + 0.5f ) - bits_used - GSC_freq_bits[bit_index];
- }
-
- if ( L_frame == L_FRAME16k )
- {
- *bit -= 8;
- }
-
- if ( coder_type == INACTIVE && core_brate <= GSC_LRES_GAINQ_LIMIT ) /* can happen only for 2nd channel inactive */
- {
- *bit += GSC_LRES_NB_NITS;
- }
-
- if ( *bit > 0 )
- {
- if ( GSC_IVAS_mode > 0 )
- {
- nb_tot_bands = Find_bit_alloc_IVAS_int( core_brate, GSC_IVAS_mode, Diff_len, nb_tot_bands, L_frame, bit, max_ener_band, ener_vec, bits_per_bands );
- nb_bands = nb_tot_bands;
- }
- else if ( GSC_noisy_speech )
- {
- SWB_bit_budget = *bit;
- nb_bands = 5;
-
- fzero_val = 0.0f;
- if ( element_mode > EVS_MONO )
- {
- fzero_val = MIN16B_FLT;
- }
-
- if ( coder_type == UNVOICED && element_mode > EVS_MONO )
- {
- nb_bands = 3;
- if ( SWB_bit_budget > 20 )
- {
- nb_bands = 5;
- }
- }
- else if ( bwidth < SWB )
- {
- nb_bands = 7;
- }
-
- st_band = nb_bands;
-
- set_f( bits_per_bands, 0, MBANDS_GN );
-
- bit_fracf = Find_bit_frac( nb_bands, (int16_t) SWB_bit_budget ); /* Supplementary bits distributed only on first bands */
-
- nb_tot_bands = nb_bands_max - 6;
-
- if ( nb_tot_bands > 16 )
- {
- nb_tot_bands = 16;
- }
-
- for ( j = 0; j < 2; j++ )
- {
- i = j;
- max_ener_band[j] = i;
- ener_vec[i] = fzero_val;
- }
-
- if ( bwidth < SWB )
- {
- if ( coder_type == UNVOICED && element_mode > EVS_MONO )
- {
- nb_tot_bands = 5;
- }
-
- for ( ; j < nb_bands; j++ )
- {
- i = maximum( ener_vec, nb_tot_bands, &etmp );
- max_ener_band[j] = i;
- ener_vec[i] = fzero_val;
- }
- }
- else
- {
- for ( ; j < nb_bands; j++ )
- {
- i = maximum( ener_vec, nb_tot_bands, &etmp );
- max_ener_band[j] = i;
- ener_vec[i] = fzero_val;
- }
- }
-
- set_f( bits_per_bands, bit_fracf, nb_bands );
- }
- else
- {
- bit_index++;
- bit_tmp = *bit - GSC_freq_bits[bit_index];
- bit_index++;
- nb_bands_max += GSC_freq_bits[bit_index];
- bit_index++;
-
- *pvq_len = 112;
- st_band = 7;
-
- if ( L_frame == L_FRAME16k && core_brate > ACELP_16k40 )
- {
- *pvq_len = 160;
- st_band = 10;
- nb_bands = *pvq_len / 16;
- bit_tmp -= 35;
- bit_new_bands = 5;
- }
-
- if ( core_brate <= ACELP_9k60 )
- {
- *pvq_len = 80;
- st_band = 5;
- if ( Diff_len == 0 )
- {
- nb_bands_max += 2;
- bit_tmp -= 13;
- }
- }
- else if ( Diff_len == 0 )
- {
- nb_bands_max += 2;
- bit_tmp -= 17;
- }
-
- nb_bands = *pvq_len / 16;
- nb_bands_max = min( nb_bands_max, MBANDS_GN_BITALLOC16k );
-
- /*------------------------------------------------------------------------
- * Adjustement of the maximum number of bands in function of the
- * dynamics of the spectrum (more or less speech like)
- *-----------------------------------------------------------------------*/
-
- if ( coder_type == INACTIVE || noise_lev >= NOISE_LEVEL_SP3 )
- {
- /* Probably classification error -> concentrate bits on LF */
- if ( L_frame == L_FRAME16k && core_brate >= ACELP_24k40 )
- {
- nb_bands_max = nb_tot_bands - 2;
- }
- else if ( core_brate >= ACELP_16k40 )
- {
- nb_bands_max = nb_bands + 2;
- }
- else if ( core_brate >= ACELP_8k00 )
- {
- nb_bands_max = nb_bands + 1;
- }
- else
- {
- nb_bands_max = nb_bands;
- }
- }
- else if ( noise_lev >= NOISE_LEVEL_SP2 || ( core_brate <= ACELP_13k20 && core_brate >= ACELP_9k60 && cor_strong_limit == 0 ) ) /* Very low dynamic, tend to speech, do not try to code HF at all */
- {
- nb_bands_max -= 2;
- }
- else if ( noise_lev >= NOISE_LEVEL_SP1 ) /* Very low dynamic, tend to speech, code less HF */
- {
- nb_bands_max -= 1;
- }
-
- if ( L_frame == L_FRAME16k )
- {
- if ( core_brate < ACELP_24k40 )
- {
- nb_bands_max -= 4;
- }
- else if ( core_brate < ACELP_32k )
- {
- if ( Diff_len > 0 || noise_lev >= NOISE_LEVEL_SP2 )
- {
- nb_bands_max -= 2;
- bit_new_bands *= 2;
- }
- }
- else if ( core_brate >= ACELP_32k )
- {
- bit_new_bands *= 2;
- }
- }
-
- if ( bwidth == NB && nb_bands_max > 10 )
- {
- nb_bands_max = 10;
- }
-
- /*------------------------------------------------------------------------
- * Find extra number of band to code according to bitrate availables
- *-----------------------------------------------------------------------*/
-
- while ( bit_tmp >= bit_new_bands && nb_bands <= nb_bands_max - 1 )
- {
- bit_tmp -= bit_new_bands;
- nb_bands++;
- }
-
- /*------------------------------------------------------------------------
- * Fractional bits to distribute on the first x bands
- *-----------------------------------------------------------------------*/
-
- if ( L_frame == L_FRAME16k && core_brate > ACELP_32k )
- {
- bit_fracf = 0;
- }
- else
- {
- bit_fracf = Find_bit_frac( st_band, bit_tmp ); /* Supplementary bits distributed only on first bands */
- }
-
- /*------------------------------------------------------------------------
- * Complete the bit allocation per frequency band
- *-----------------------------------------------------------------------*/
-
- imax = 5;
- if ( core_brate > ACELP_9k60 )
- {
- imax = 7;
- }
-
- for ( i = 0; i < imax; i++ )
- {
- bits_per_bands[i] = GSC_freq_bits[bit_index] + bit_fracf;
- bit_index++;
- }
-
- if ( L_frame == L_FRAME16k && core_brate > ACELP_16k40 )
- {
- bit_index = 0;
- i = imax - 1;
- bits_per_bands[i] += Compl_GSC_freq_bits[bit_index];
- i++;
- bit_index++;
-
- for ( ; i < 10; i++ )
- {
- bits_per_bands[i] += Compl_GSC_freq_bits[bit_index] + bit_fracf;
- bit_index++;
- }
- }
-
- if ( Diff_len == 0 )
- {
- bit_index = bit_index_mem + 10;
- for ( i = 0; i < 7; i++ )
- {
- bits_per_bands[i] += GSC_freq_bits[bit_index];
- bit_index++;
- }
- }
-
- if ( bit_fracf < 0 )
- {
- for ( j = 0; j < nb_tot_bands; j++ )
- {
- bits_per_bands[j] = max( bits_per_bands[j], 0 );
- }
- }
-
- /*--------------------------------------------------------------------------
- * Complete the bit allocation per frequency band for 16kHz high brate mode
- *--------------------------------------------------------------------------*/
-
- if ( L_frame == L_FRAME16k && core_brate > ACELP_32k )
- {
- for ( j = st_band; j < nb_bands; j++ )
- {
- bits_per_bands[j] = bit_new_bands;
- }
-
- bit_fracf = ( 1.0f / nb_bands ) * ( bit_tmp );
-
- etmp = 2.0f * bit_fracf / ( nb_bands + 1 );
- bit_fracf = etmp;
- for ( j = nb_bands - 1; j >= 0; j-- )
- {
- bits_per_bands[j] += etmp;
- etmp += bit_fracf;
- }
- }
- else
- {
- for ( j = st_band; j < nb_bands; j++ )
- {
- bits_per_bands[j] = bit_new_bands;
- }
- }
-
- /*--------------------------------------------------------------------------
- * Compute a maximum band (band offset) for the search on maximal energy
- * This is function of the spectral dynamic and the bitrate
- *--------------------------------------------------------------------------*/
-
- bandoffset = nb_tot_bands - ( nb_bands + 2 );
-
- if ( noise_lev <= NOISE_LEVEL_SP1a )
- {
- bandoffset--;
- }
- else if ( ( core_brate <= ACELP_13k20 && ( coder_type == INACTIVE || noise_lev >= NOISE_LEVEL_SP3 ) ) || ( core_brate <= ACELP_13k20 && core_brate >= ACELP_9k60 && cor_strong_limit == 0 ) )
- {
- bandoffset++;
- }
-
- if ( bandoffset < 0 )
- {
- bandoffset = 0;
- }
-
- /*--------------------------------------------------------------------------
- * Initiazed sorted vector
- * For the first x bands to be included in th final sorted vector
- * Sort the remaining bands in decrease energy order
- *--------------------------------------------------------------------------*/
-
- for ( j = 0; j < nb_tot_bands; j++ )
- {
- max_ener_band[j] = -10;
- }
-
- for ( j = 0; j < st_band; j++ )
- {
- max_ener_band[j] = j;
- ener_vec[j] = -10;
- }
-
- pos = st_band;
- for ( ; j < nb_bands; j++ )
- {
- i = maximum( ener_vec, nb_tot_bands - bandoffset, &etmp );
- if ( i > pos )
- {
- pos = i;
- }
- max_ener_band[j] = i;
- ener_vec[i] = -10;
- }
-
- /* re-allocate bits to the frames such that the highest band with allocated bits is higher than the threshold */
- if ( nb_tot_bands - bandoffset > nb_bands && ( pos > 7 && core_brate == ACELP_8k00 ) && bwidth == WB )
- {
- band = nb_tot_bands - bandoffset - nb_bands;
- for ( j = 0; j < band; j++ )
- {
- i = maximum( ener_vec, nb_tot_bands - bandoffset, &etmp );
- max_ener_band[nb_bands + j] = i;
- ener_vec[i] = -10;
- bits_per_bands[nb_bands + j] = 5;
- }
- nb_bands += band;
-
- bit_tmp = 5 * band;
- if ( band <= 2 )
- {
- for ( j = st_band - 1; j < nb_bands; j++ )
- {
- bits_per_bands[j] += 1;
- }
- bit_tmp += nb_bands - st_band + 1;
- }
-
- i = 0;
- j = 0;
- while ( bit_tmp > 0 )
- {
- bits_per_bands[j] -= 1;
-
- if ( j == st_band - 1 - i )
- {
- j = 0;
- }
- else
- {
- ++j;
- }
-
- if ( j == 0 && i < st_band - 1 )
- {
- i++;
- }
-
- bit_tmp -= 1;
- }
- }
-
- /*--------------------------------------------------------------------------
- * Bit sum verification for GSC inactive at very high rate
- * The maximum number of bits per band of length 16 is 112
- * Redistribute the overage bits if needed
- *--------------------------------------------------------------------------*/
-
- sum_bit = 0;
- j = 0;
- for ( i = 0; i < nb_bands; i++ )
- {
- if ( bits_per_bands[i] > 112 )
- {
- sum_bit += bits_per_bands[i] - 112;
- bits_per_bands[i] = 112;
- j = i + 1;
- }
-
- /* safety check for overage bit reallocation */
- else if ( bits_per_bands[i] + sum_bit / 3 > 112 )
- {
- j = i + 1;
- }
- }
-
- if ( sum_bit != 0 )
- {
- sum_bit /= ( nb_bands - j );
- for ( i = j; i < nb_bands; i++ )
- {
- bits_per_bands[i] += sum_bit;
- }
- }
- }
-
- /*--------------------------------------------------------------------------
- * second step of bit sum verification, normally sum_bit == *bit
- *--------------------------------------------------------------------------*/
-
- sum_bit = 0.00f;
- for ( i = 0; i < nb_bands; i++ )
- {
- bits_per_bands[i] = (float) floor( bits_per_bands[i] );
- sum_bit += bits_per_bands[i];
- }
-
- if ( GSC_IVAS_mode != 0 && sum_bit < *bit ) /* If we need to add bits, we are doing it on the LF */
- {
- reajust_bits( bits_per_bands, 0, nb_bands, (int16_t) sum_bit, *bit );
- }
- else
- {
- reajust_bits( bits_per_bands, nb_bands - 1, 0, (int16_t) sum_bit, *bit );
- }
-
- /*--------------------------------------------------------------------------
- * Recompute the real number/length of frequency bands to encode
- *--------------------------------------------------------------------------*/
-
- *nb_subbands = nb_bands;
- *pvq_len = *nb_subbands * 16;
-
- /*--------------------------------------------------------------------------
- * Concatenate bands (encoder only)
- *--------------------------------------------------------------------------*/
-
- if ( exc_diff != NULL )
- {
- for ( j = 0; j < nb_bands; j++ )
- {
- mvr2r( exc_diff + max_ener_band[j] * 16, concat_in + j * 16, 16 );
- }
- }
-
- set_s( bits_per_bands_s, 0, nb_tot_bands );
-
- for ( j = 0; j < nb_bands; j++ )
- {
- bits_per_bands_s[j] = ( (int16_t) bits_per_bands[j] ) << 3;
- }
- }
- else /* *bit == 0 */
- {
- set_s( bits_per_bands_s, 0, nb_tot_bands );
- *nb_subbands = 0;
- *pvq_len = 0;
- }
-
- return;
-}
-
-/*-------------------------------------------------------------------*
- * reajust_bits()
- *
- *
- *-------------------------------------------------------------------*/
-
-static void reajust_bits(
- float *bits_per_bands,
- const int16_t st_band,
- const int16_t end_band,
- const int16_t sum_bit_in,
- const int16_t bit_bdgt_in )
-{
- int16_t i, amount_to_add, incr;
- int16_t bit_bdgt, sum_bit;
-
- incr = 1;
- if ( end_band < st_band )
- {
- incr = -1;
- }
-
- if ( bit_bdgt_in < sum_bit_in )
- {
- amount_to_add = -1;
- bit_bdgt = sum_bit_in;
- sum_bit = bit_bdgt_in;
- }
- else
- {
- bit_bdgt = bit_bdgt_in;
- sum_bit = sum_bit_in;
- amount_to_add = 1;
- }
-
- i = st_band;
- while ( bit_bdgt > sum_bit )
- {
- if ( amount_to_add > 0 || ( amount_to_add < 0 && bits_per_bands[i] > 1 ) )
- {
- bits_per_bands[i] += amount_to_add;
- sum_bit += (int16_t) abs( amount_to_add );
- }
-
- i += incr;
- if ( i == end_band )
- {
- i = st_band;
- }
- }
-
- return;
-}
-
-/*-------------------------------------------------------------------*
- * Find_bit_frac()
- *
- * Computes the fraction of the remaining bit budget to allocate to the bands
- *-------------------------------------------------------------------*/
-
-static float Find_bit_frac(
- const int16_t nb_band,
- const int16_t remaining_bits )
-{
- float var_out;
- int16_t inv_bandQ15;
- int32_t L_num;
-
- inv_bandQ15 = 6553;
- if ( nb_band == 7 )
- {
- inv_bandQ15 = 4681;
- }
- else if ( nb_band == 3 )
- {
- inv_bandQ15 = 10922;
- }
- else if ( nb_band == 4 )
- {
- inv_bandQ15 = 8192;
- }
- else if ( nb_band == 5 )
- {
- inv_bandQ15 = 6536;
- }
- else if ( nb_band == 10 )
- {
- inv_bandQ15 = 3277;
- }
- else
- {
- inv_bandQ15 = (int16_t) ( ( 1.0f / nb_band ) * 32678 + 0.5f );
- }
-
- L_num = inv_bandQ15 * remaining_bits;
- L_num *= 8;
- var_out = L_num / 262144.0f;
-
- return ( var_out );
-}
-
-static Word16 Find_bit_alloc_IVAS_int( /* o : Number of band to encode */
- const Word32 core_brate, /* i : core bit rate */
- const Word16 GSC_IVAS_mode, /* i : GSC IVAS mode */
- const Word16 Diff_len, /* i : Length of the difference signal (before pure spectral)*/
- const Word16 nb_tot_bands_in, /* i : total number of band */
- const Word16 L_frame, /* i : frame length */
- Word16 *bit, /* i/o: Number of bit allowed for frequency quantization */
- Word16 *max_ener_band, /* i/o: Energy based sorted order */
- float *ener_vec_io, /* i/o: Energy per band order */
- float *bits_per_bands_o /* o : Number of bit allowed per allowed sub-band Q3 */
-)
-{
- Word32 mp, mb, nb_bands_adj, bit_adj;
- Word16 nb_pulse_per_band[MBANDS_GN_BITALLOC16k];
- Word32 SWB_bit_budget; // Q0 -> Q18
- Word16 i, j, nb_bands_max, st_band, nb_tot_bands_loc, etmp;
- Word32 sum_bit /*Q18*/, bit_fracf /*Q18*/;
- Word16 d_tmp, e_div, tmp16, ener_vec[MBANDS_GN_BITALLOC16k];
- Word32 Ltmp, etmp_32fx, bits_per_bands[MBANDS_GN_BITALLOC16k];
-
- SWB_bit_budget = *bit; // Q0
- st_band = 5;
- nb_bands_max = nb_tot_bands_in;
-
- for ( i = 0; i < MBANDS_GN; i++ )
- {
- ener_vec[i] = (short) ( ener_vec_io[i] ); /* Q12 -> Q12 */
- }
-
- if ( L_frame == L_FRAME16k )
- {
- for ( i = MBANDS_GN; i < MBANDS_GN_BITALLOC16k; i++ )
- {
- ener_vec[i] = (short) ( ener_vec_io[i] * 4096.0 + 0.5f ); /* Q0 -> Q12 */
- }
- }
-
- set_l( bits_per_bands, 0, MBANDS_GN_BITALLOC16k );
-
- /* Decide the pourcentage of bits allocated to LF (between 50-75%) depending of the temporal contribution in GSC */
- /* bit_fracf = ( -0.125f * Diff_len + 76.0f ) / 100; */
- bit_fracf = L_add( Mpy_32_32( -Q31_0_00125, L_shl( Diff_len, 18 ) ), Q18_0_76 ); /* Q18 */
-
- /* bit_fracf = check_bounds(bit_fracf, 0.50f, 0.75f); */
- bit_fracf = min( max( bit_fracf, Q18_0_50 ), Q18_0_75 );
-
- /* Adjusment of the bitrate between LF and HF base on the content type */
- /* 1 = new GSC bit alloc
- 2 = GSC bit alloc for tc frame
- 3 = more music like (should not happen often given music is coded with dft) */
-
- if ( GSC_IVAS_mode <= 3 )
- {
- nb_bands_max -= 6;
- }
-
- if ( GSC_IVAS_mode == 2 )
- {
- /* bit_fracf += 0.1f; */
- bit_fracf += Q18_0_1; /* Q18*/
- nb_bands_max -= 1;
- }
-
- if ( GSC_IVAS_mode == 3 )
- {
- /* bit_fracf -= 0.1f; */
- bit_fracf -= Q18_0_1; /* Q18*/
- nb_bands_max += 3;
- }
-
- /* First find how much we want to share between LF and HF, at low bitrate, a miminum of bits is needed in LF by limitating the number of bands*/
- /* Adjust the number of band based on the content type and bitrate */
-
- /* nb_bands_adj = 1.0f; */
- nb_bands_adj = Q18_1_0;
- if ( GSC_IVAS_mode == 1 && core_brate < GSC_L_RATE_STG )
- {
- /* nb_bands_adj = 0.0125f * SWB_bit_budget - 0.75f;*/
- nb_bands_adj = L_sub( Mpy_32_32( Q31_0_0125, L_shl( SWB_bit_budget, 18 ) ), Q18_0_75 ); // Q18
- }
- else if ( GSC_IVAS_mode != 2 && core_brate > GSC_H_RATE_STG )
- {
- /*nb_bands_adj = 0.02f * SWB_bit_budget - 1.2f;*/
- nb_bands_adj = L_sub( Mpy_32_32( Q31_0_02, L_shl( SWB_bit_budget, 18 ) ), Q18_1_2 ); // Q18
- }
- /*nb_bands_max = (int16_t)(nb_bands_max * nb_bands_adj + 0.5f);*/
-
- nb_bands_max = round_fx( Mpy_32_16_1( L_shl( nb_bands_adj, 5 ), shl( nb_bands_max, 10 - 2 ) ) ); /* Q0 */
- nb_bands_max = check_bounds_s( nb_bands_max, 5, nb_tot_bands_in );
-
- /* bit_fracf *= SWB_bit_budget;*/
- /* At this point bit_fracf has a value below 1.0 */
- bit_fracf = Mpy_32_16_1( L_shl( bit_fracf, 10 ), extract_l( L_shl( SWB_bit_budget, 5 ) ) ); /* (Q(18+10)*Q(0+5) + 1 - 16 = Q18 */
-
- /* Estimation of the number of bit used in HF */
- /* with only the first weighting The number of bits in max_ener_band[st_band-1] = 17% of bit_fracf */
- /* mb = .17f * bit_fracf;*/
- mb = Mpy_32_32( Q31_0_17, bit_fracf ); /* Q18 */
-
- /* mp = 2 * DSR_NB_PULSE;*/
- mp = Q18_2_0xDSR_NB_PULSE;
- if ( core_brate < GSC_L_RATE_STG && GSC_IVAS_mode == 3 )
- {
- /* mp = 1.5f * DSR_NB_PULSE;*/
- mp = Q18_1_5xDSR_NB_PULSE;
- }
- else if ( core_brate < GSC_L_RATE_STG )
- {
- /* mp = DSR_NB_PULSE;*/
- mp = Q18_DSR_NB_PULSE;
- }
-
- /* We want max_ener_band[st_band] <= max_ener_band[st_band-1] and max_ener_band[nb_bands_max-1] <= max_ener_band[st_band]*/
- /* We will estimate the number of bits to allocate of HF and put the remaining bits, if any, back on LF */
- /* compute the total possible number of band to be coded */
-
- /* nb_tot_bands = (int16_t)((SWB_bit_budget - bit_fracf) / (mp + (mb - mp) / 2.0f)); */
- d_tmp = Find_norm_inv( L_add( mp, mb ), &e_div );
- Ltmp = Mpy_32_16_1( L_sub( L_shl( SWB_bit_budget, 18 ), bit_fracf ), d_tmp ); /* Perform mult by 1/den */
- nb_tot_bands_loc = extract_h( L_shl( Ltmp, sub( 1, e_div ) ) ); /* adjust exponent: 1 is to take into account the / 2.0f, and e_div for the num and den of the division*/
-
- mp = min( mp, mb );
- tmp16 = sub( add( nb_tot_bands_loc, st_band ), nb_bands_max );
- if ( tmp16 > 0 )
- {
- /* bit_adj = ( ( mb + mp ) / 2 ) * ( nb_tot_bands_loc + st_band - nb_bands_max ); */
- bit_adj = Mpy_32_16_1( L_shl( L_add( mb, mp ), 5 ), shl( tmp16, 10 - 1 ) ); /* Q18+5 * Q0+10 + 1 -1 - 16 = Q18 (-1 is to cover for the /2 in the equation) */
- bit_adj = L_max( 0, bit_adj );
- nb_tot_bands_loc = nb_bands_max - st_band;
- bit_fracf += bit_adj; /* Q18 */
- }
- nb_tot_bands_loc += st_band;
-
- /* Allocate bits to LF */
- /* etmp = 0.23f; */
- etmp_32fx = Q31_0_23;
- for ( j = 0; j < st_band; j++ )
- {
- i = j;
- max_ener_band[j] = i;
- ener_vec[i] = MIN16B;
- /* bits_per_bands[j] = etmp * bit_fracf; */
- bits_per_bands[j] = Mpy_32_32( bit_fracf, etmp_32fx ); /* 18 + 31 + 1 - 32 = Q18 */
- /* etmp -= 0.015f; */
- etmp_32fx -= Q31_0_015; /* Q18 */
- }
-
- /* SWB_bit_budget -= bit_fracf; */
- SWB_bit_budget = L_sub( L_shl( SWB_bit_budget, 18 ), bit_fracf ); /* Q0->Q18 */
-
- /* Find low energy band in HF */
- set_s( nb_pulse_per_band, 2, MBANDS_GN_BITALLOC16k );
- for ( i = st_band + 2; i < nb_tot_bands_loc - 1; i++ )
- {
- if ( ener_vec[i] < ener_vec[i - 1] && ener_vec[i] < ener_vec[i + 1] ) /* i +1 and i -1 can be considered as 2 ptrs */
- {
- nb_pulse_per_band[i] = 1;
- }
- }
-
- for ( j = st_band; j < nb_tot_bands_loc; j++ )
- {
- if ( j > 6 )
- {
- i = maximum_fx( ener_vec, nb_tot_bands_loc, &etmp );
- }
- else
- {
- i = j;
- }
- max_ener_band[j] = i;
- ener_vec[i] = MIN16B;
- }
-
- /* Recompute the final bit distribution for HF */
- if ( nb_tot_bands_loc > st_band )
- {
- /* This is not bit exact because of the precision lost */
- /* mb = ( SWB_bit_budget * 2 / ( nb_tot_bands_loc - st_band ) ) - mp; */
- d_tmp = Find_norm_inv( L_deposit_h( sub( nb_tot_bands_loc, st_band ) ), &e_div );
- mb = L_sub( L_shr( Mpy_32_16_1( L_shl( SWB_bit_budget, 1 ), d_tmp ), e_div ), mp ); /* Q18 */
- /* bit_fracf = ( mb - mp ) / ( nb_tot_bands_loc - st_band ); */
- bit_fracf = L_shr( Mpy_32_16_1( L_sub( mb, mp ), d_tmp ), e_div ); /* Q18 */
-
- mb -= bit_fracf;
- /* Do the distribution */
- for ( j = st_band; j < nb_tot_bands_loc; j++ )
- {
- bits_per_bands[max_ener_band[j]] = Q18_DSR_NB_PULSE;
- if ( nb_pulse_per_band[max_ener_band[j]] > 1 )
- {
- bits_per_bands[max_ener_band[j]] = mb;
- }
- mb -= bit_fracf;
- SWB_bit_budget -= bits_per_bands[max_ener_band[j]]; // Q18
- }
- }
-
- /* Series of verification in case bit allocated != the budget */
- if ( SWB_bit_budget > 0 )
- {
- i = st_band - 1;
- while ( SWB_bit_budget > 0 )
- {
- /* bits_per_bands[i]++; */
- bits_per_bands[i] += Q18_1_0;
- /* SWB_bit_budget--; */
- SWB_bit_budget -= Q18_1_0;
- i--;
- if ( i == -1 )
- {
- i = st_band - 1;
- }
- }
- }
-
- /*nb_bands = nb_tot_bands_loc;*/
-
- sum_bit = 0;
- j = 0;
- for ( i = 0; i < nb_tot_bands_loc; i++ )
- {
- /* if (bits_per_bands[i] > 112) */
- if ( bits_per_bands[i] > Q18_112 )
- {
- /* sum_bit += bits_per_bands[i] - 112; */
- sum_bit = L_add( sum_bit, L_sub( bits_per_bands[i], Q18_112 ) );
- /* bits_per_bands[i] = 112; */
- bits_per_bands[i] = Q18_112;
- j = add( j, add( i, 1 ) );
- }
-
- /* safety check for overage bit reallocation */
- /* else if (bits_per_bands[i] + sum_bit / 3 > 112) */
- else if ( L_add( bits_per_bands[i], Mpy_32_16_1( sum_bit, Q15_0_33 ) ) > Q18_112 )
- {
- j = add( j, add( i, 1 ) );
- }
- }
-
- if ( sum_bit != 0 )
- {
- /* sum_bit /= (nb_bands - j); */
- d_tmp = Find_norm_inv( L_deposit_h( sub( nb_tot_bands_loc, j ) ), &e_div );
- sum_bit = L_shr( Mpy_32_16_1( sum_bit, d_tmp ), e_div ); /* Q18 */
- for ( i = j; i < nb_tot_bands_loc; i++ )
- {
- bits_per_bands[i] = L_add( bits_per_bands[i], sum_bit );
- }
- }
-
- for ( i = 0; i < MBANDS_GN_BITALLOC16k; i++ )
- {
- bits_per_bands_o[i] = (float) bits_per_bands[i] / 262144.0f; /* Q18 -> float */
- }
-
- return nb_tot_bands_loc;
-}
-
-/* Find normalized 1 / ToDivide */
-static Word16 Find_norm_inv(
- const Word32 ToDivide,
- Word16 *e_div )
-{
- Word16 d_tmp, e_tmp;
-
- e_tmp = norm_l( ToDivide );
- d_tmp = round_fx( L_shl( ToDivide, e_tmp ) );
- d_tmp = div_s( 16384, d_tmp ); /* 1.0 in Q14, dividend is normalize so >= 16384 as required for the division */
- *e_div = sub( 14, e_tmp );
-
- return d_tmp;
-}
-
-static Word16 maximum_fx( /* o : index of the maximum value in the input vector */
- const Word16 *vec_fx, /* i : input vector */
- const Word16 lvec_fx, /* i : length of input vector */
- Word16 *max_fx /* o : maximum value in the input vector */
-)
-{
- Word16 j, ind, tmp;
-
- ind = 0;
- move16();
- tmp = vec_fx[0];
- move16();
-
- FOR( j = 1; j < lvec_fx; j++ )
- {
- if ( GT_16( vec_fx[j], tmp ) )
- {
- ind = j;
- move16();
- }
- tmp = s_max( tmp, vec_fx[j] );
- }
- *max_fx = tmp;
- move16();
-
- return ind;
-}
-#endif
diff --git a/lib_com/gs_bitallocation_ivas_fx.c b/lib_com/gs_bitallocation_ivas_fx.c
index aa74215b04494078ebba3d25059cb45cbc0d71f9..787d562c74404faf382b0a45929405c3fe75ceed 100644
--- a/lib_com/gs_bitallocation_ivas_fx.c
+++ b/lib_com/gs_bitallocation_ivas_fx.c
@@ -1007,7 +1007,7 @@ static Word16 Find_bit_alloc_IVAS_fx( /*o: Number
/*nb_bands_max = (int16_t)(nb_bands_max * nb_bands_adj + 0.5f);*/
nb_bands_max = round_fx( Mpy_32_16_1( L_shl( nb_bands_adj, 5 ), shl( nb_bands_max, 10 - 2 ) ) ); /* Q0 */
- nb_bands_max = check_bounds_s( nb_bands_max, 5, nb_tot_bands_in );
+ nb_bands_max = check_bounds_s_fx( nb_bands_max, 5, nb_tot_bands_in );
/* bit_fracf *= SWB_bit_budget;*/
diff --git a/lib_com/gs_gains.c b/lib_com/gs_gains.c
index 7f0be1c7958577bc4994a1e5428a4c49c1cc38d8..13fdbd67ca68c7cf8f20b01fa974dea2859a4cf1 100644
--- a/lib_com/gs_gains.c
+++ b/lib_com/gs_gains.c
@@ -43,234 +43,6 @@
#include "prot_fx.h"
#include "wmc_auto.h"
-#ifndef IVAS_FLOAT_FIXED
-/*-------------------------------------------------------------------*
- * Local function prototypes
- *-------------------------------------------------------------------*/
-
-static int16_t VDQ_vec( float *Qvec_out, const float *mean_dic, const float *dic, const int16_t index, const int16_t vec_en );
-#endif
-
-/*-------------------------------------------------------------------*
- * Comp_and_apply_gain()
- *
- * Compute and apply the quantized per band gain
- *-------------------------------------------------------------------*/
-
-#ifndef IVAS_FLOAT_FIXED
-void Comp_and_apply_gain(
- float exc_diffQ[], /* i/o: Quantized excitation */
- float Ener_per_bd_iQ[], /* o : Target ener per band */
- float Ener_per_bd_yQ[], /* o : Ener per band for norm vector */
- int16_t Mbands_gn, /* i : number of bands */
- const int16_t ReUseGain /* i : Reuse the gain in Ener_per_bd_yQ */
-)
-{
- int16_t i, i_band;
- int16_t StartBin, NB_Qbins;
- float y_gain;
-
- /* Recreate excitation for local synthesis and decoder */
- StartBin = 0;
- NB_Qbins = 0;
- for ( i_band = 0; i_band < Mbands_gn; i_band++ )
- {
- StartBin += NB_Qbins;
- NB_Qbins = mfreq_bindiv_loc[i_band];
- if ( ReUseGain == 1 )
- {
- y_gain = Ener_per_bd_yQ[i_band];
- }
- else
- {
- y_gain = (float) pow( 10, ( Ener_per_bd_iQ[i_band] - Ener_per_bd_yQ[i_band] ) );
- Ener_per_bd_yQ[i_band] = y_gain;
- }
-
- for ( i = StartBin; i < NB_Qbins + StartBin; i++ )
- {
- exc_diffQ[i] *= y_gain;
- }
- }
-
- return;
-}
-#endif
-
-#ifndef IVAS_FLOAT_FIXED
-/*------------------------------------------------------------------*
- * Ener_per_band_comp()
- *
- * Compute the energy per band in log domain for quantization purposes
- * Loops are decomposed to accomodate the PVQ quantization
- *------------------------------------------------------------------*/
-
-void Ener_per_band_comp(
- const float exc_diff[], /* i : target signal */
- float y_gain4[], /* o : Energy per band to quantize */
- const int16_t Mband, /* i : Max band */
- const int16_t Eflag, /* i : flag of highest band */
- const int16_t L_frame /* i : frame length */
-)
-{
- float etmp;
- const float *pt;
- int16_t i, j;
-
- pt = exc_diff;
- for ( j = 0; j < 2; j++ )
- {
- y_gain4[j] = 0;
- etmp = 0.02f;
-
- pt = exc_diff + j * 8;
- for ( i = 0; i < 8; i++ )
- {
- etmp += ( *pt * *pt );
- pt++;
- }
-
- /* normalized to 16 bins to easy the quantization */
- y_gain4[j] = (float) log10( sqrt( 2 * etmp ) );
- }
-
- for ( j = 1; j < Mband - 2; j++ )
- {
- etmp = 0.01f;
-
- pt = exc_diff + j * 16;
- for ( i = 0; i < 16; i++ )
- {
- etmp += ( *pt * *pt );
- pt++;
- }
-
- y_gain4[j + 1] = (float) log10( sqrt( etmp ) );
- }
-
- if ( Eflag == 1 )
- {
- etmp = 0.01f;
-
- pt = exc_diff + j * 16;
- for ( i = 0; i < 32; i++ )
- {
- etmp += ( *pt * *pt );
- pt++;
- }
-
- y_gain4[j + 1] = (float) log10( sqrt( etmp / 2 ) );
- }
-
- if ( L_frame == L_FRAME16k )
- {
- etmp = 0.01f;
-
- for ( i = 0; i < 32; i++ )
- {
- etmp += ( *pt * *pt );
- pt++;
- }
-
- y_gain4[j + 2] = (float) log10( sqrt( etmp / 2 ) );
-
- for ( i = 0; i < 32; i++ )
- {
- etmp += ( *pt * *pt );
- pt++;
- }
-
- y_gain4[j + 3] = (float) log10( sqrt( etmp / 2 ) );
- }
-
- return;
-}
-#endif
-
-
-#ifndef IVAS_FLOAT_FIXED
-/*-------------------------------------------------------------------*
- * GSC_gain_DQ()
- *
- * Form the final vector after gain quantization/Dequantization
- * Common to both encoder and decoder
- *-------------------------------------------------------------------*/
-
-static void GSC_gain_DQ(
- const int16_t element_mode, /* i : element mode */
- const int16_t enc_dec, /* i : encoder/decoder flag */
- const int16_t coder_type, /* i : Coder type */
- const int16_t Mbands_gn, /* i : Number of band */
- const int32_t core_brate, /* i : Core bitrate */
- const float mean_g, /* i : Average gain */
- const float *Gain_in, /* i : Unquantized gain vector */
- float *Gain_out /* o : Level adjusted unquantized gain vector */
-)
-{
- float Gain_off;
- int16_t i;
-
- /* Gain adjustment to fit ACELP generic inactive coding gain at low rate */
- Gain_off = 0.0f;
- if ( coder_type == INACTIVE || coder_type == UNVOICED )
- {
- if ( core_brate <= ACELP_5k00 && coder_type == UNVOICED )
- {
- Gain_off = 9.f;
- }
- else if ( core_brate <= ACELP_7k20 )
- {
- Gain_off = 8.f; /* 0 dB */
- }
- else if ( core_brate <= ACELP_8k00 )
- {
- Gain_off = 6.6f; /* ~-3.3 dB */
- }
- else if ( core_brate <= ACELP_9k60 )
- {
- Gain_off = 4.8f; /* ~-2.4 dB */
- }
- else if ( core_brate <= ACELP_11k60 )
- {
- Gain_off = 3.5f; /* ~-2.4 dB */
- }
- else if ( core_brate <= ACELP_13k20 )
- {
- Gain_off = 3.0f; /* ~-2.4 dB */
- }
- }
-
- if ( coder_type != INACTIVE && coder_type != UNVOICED )
- {
- for ( i = 0; i < Mbands_gn; i++ )
- {
- Gain_out[i] = Gain_in[i] + mean_g;
- }
- }
- else
- {
- /*mimic ACELP decay of energy for low rates*/
- if ( element_mode == EVS_MONO && enc_dec == DEC )
- {
- /* This is to keep EVS mono bit-exact with the standard (there might be a small desynchronization between encoder and decoder but there is no real quality or interop. issue) */
- for ( i = 0; i < Mbands_gn; i++ )
- {
- Gain_out[i] += mean_g - i * ( Gain_off / 20.f ) / ( (float) Mbands_gn );
- }
- }
- else
- {
- for ( i = 0; i < Mbands_gn; i++ )
- {
- Gain_out[i] = Gain_in[i] + mean_g - ( i * ( Gain_off / 20.f ) / ( (float) Mbands_gn ) );
- }
- }
- }
-
- return;
-}
-#endif
-
static void GSC_gain_DQ_fx(
const Word16 element_mode, /* i : element mode */
const Word16 enc_dec, /* i : encoder/decoder flag */
@@ -362,240 +134,6 @@ static void GSC_gain_DQ_fx(
return;
}
-
-#ifndef IVAS_FLOAT_FIXED
-/*-------------------------------------------------------------------*
- * gsc_gainQ()
- *
- * Quantization of the energy per band
- *-------------------------------------------------------------------*/
-
-float gsc_gainQ(
- BSTR_ENC_HANDLE hBstr, /* i/o: encoder bitstream handle */
- const int16_t element_mode, /* i : element mode */
- const int16_t idchan, /* i : channel ID */
- const float y_gain4[], /* i : Energy per band */
- float y_gainQ[], /* o : quantized energy per band */
- const int32_t core_brate, /* i : Core rate */
- const int16_t coder_type, /* i : coding type */
- const int16_t bwidth, /* i : input signal bandwidth */
- const int16_t L_frame, /* i : frame length */
- const int16_t tdm_LRTD_flag, /* i : LRTD stereo mode flag */
- const int32_t core_brate_inp /* i : true core bitrate */
-)
-{
- float y_gain_tmp[MBANDS_GN16k], y_gain_tmp2[MBANDS_GN16k];
- int16_t i, idx_g = 0;
- float mean_4g[1], ftmp1;
- int16_t Mbands_gn = MBANDS_GN;
- float y_gain_tmp3[MBANDS_GN];
-
- if ( L_frame == L_FRAME16k )
- {
- Mbands_gn = MBANDS_GN16k;
- }
-
- mean_4g[0] = 0;
-
- if ( ( coder_type == AUDIO || coder_type == INACTIVE ) && bwidth == NB )
- {
- ftmp1 = mean( y_gain4, 10 ) - 0.6f;
- for ( i = 0; i < Mbands_gn; i++ )
- {
- if ( y_gain4[i] < ftmp1 )
- {
- y_gain_tmp2[i] = ftmp1;
- }
- else
- {
- y_gain_tmp2[i] = y_gain4[i];
- }
- }
-
- /* Quantized mean gain without clipping */
- mean_4g[0] = mean( y_gain_tmp2, 10 );
- idx_g = (int16_t) vquant( mean_4g, Gain_meanNB, mean_4g, Gain_mean_dicNB, 1, 64 );
- push_indice( hBstr, IND_MEAN_GAIN2, idx_g, 6 );
-
- for ( i = 0; i < Mbands_gn; i++ )
- {
- y_gain_tmp[i] = y_gain_tmp2[i] - mean_4g[0];
- }
-
- if ( y_gain_tmp[9] < -0.3f )
- {
- y_gain_tmp[9] = -0.3f;
- }
-
- set_f( y_gain_tmp + 10, 0.0f, MBANDS_GN - 10 );
- idx_g = (int16_t) vquant( y_gain_tmp, Mean_dic_NB, y_gain_tmp, Gain_dic1_NB, 3, 64 );
- push_indice( hBstr, IND_Y_GAIN_TMP, idx_g, 6 );
-
- if ( core_brate < ACELP_9k60 )
- {
- idx_g = vquant( y_gain_tmp + 3, Mean_dic_NB + 3, y_gain_tmp + 3, Gain_dic2_NB, 3, 32 );
- push_indice( hBstr, IND_Y_GAIN_TMP, idx_g, 5 );
-
- idx_g = vquant( y_gain_tmp + 6, Mean_dic_NB + 6, y_gain_tmp + 6, Gain_dic3_NB, 4, 16 );
- push_indice( hBstr, IND_Y_GAIN_TMP, idx_g, 4 );
- }
- else
- {
- idx_g = vquant( y_gain_tmp + 3, Mean_dic_NB + 3, y_gain_tmp + 3, Gain_dic2_NBHR, 3, 64 );
- push_indice( hBstr, IND_Y_GAIN_TMP, idx_g, 6 );
-
- idx_g = vquant( y_gain_tmp + 6, Mean_dic_NB + 6, y_gain_tmp + 6, Gain_dic3_NBHR, 4, 128 );
- push_indice( hBstr, IND_Y_GAIN_TMP, idx_g, 7 );
- }
-
- if ( core_brate <= ACELP_9k60 && coder_type == INACTIVE )
- {
- /* Some energy is needed in high band for stat_noise_uv_enc() to be functional in inactive speech */
- y_gain_tmp[10] = mean( y_gain_tmp + 6, 3 );
- y_gain_tmp[11] = mean( y_gain_tmp + 7, 3 );
- y_gain_tmp[12] = mean( y_gain_tmp + 8, 3 );
- y_gain_tmp[13] = mean( y_gain_tmp + 9, 3 );
- y_gain_tmp[14] = mean( y_gain_tmp + 10, 3 );
- y_gain_tmp[15] = mean( y_gain_tmp + 11, 3 );
- }
- else
- {
- set_f( y_gain_tmp + 10, 0, MBANDS_GN - 10 );
- }
- }
- else
- {
- ftmp1 = mean( y_gain4, 16 );
- for ( i = 0; i < Mbands_gn; i++ )
- {
- if ( y_gain4[i] < ftmp1 - 0.6f )
- {
- y_gain_tmp2[i] = ftmp1 - .6f;
- }
- else if ( y_gain4[i] > ftmp1 + 0.6f )
- {
- y_gain_tmp2[i] = ftmp1 + 0.6f;
- }
- else
- {
- y_gain_tmp2[i] = y_gain4[i];
- }
- }
-
- mean_4g[0] = mean( y_gain_tmp2, 16 );
- idx_g = vquant( mean_4g, mean_m, mean_4g, mean_gain_dic, 1, 64 );
- push_indice( hBstr, IND_MEAN_GAIN2, idx_g, 6 );
-
- /* Subtraction of the average gain */
- for ( i = 0; i < Mbands_gn; i++ )
- {
- y_gain_tmp[i] = y_gain_tmp2[i] - mean_4g[0];
- }
-
- if ( core_brate < ACELP_9k60 )
- {
- /* prediction and quantization of the average gain */
-
- /*--------------------------------------------------------------------------------------*
- * Quantization of the first 8 bands
- * Keep only 4 bands out of the last 8 bands
- *--------------------------------------------------------------------------------------*/
-
- mvr2r( y_gain_tmp, y_gain_tmp2, 8 );
-
- y_gain_tmp2[8] = y_gain_tmp[8];
- y_gain_tmp2[9] = y_gain_tmp[10];
- y_gain_tmp2[10] = y_gain_tmp[12];
- y_gain_tmp2[11] = y_gain_tmp[14];
-
- idx_g = 0;
- idx_g = vquant( y_gain_tmp2, YGain_mean_LR, y_gain_tmp2, YGain_dic1_LR, 3, 32 );
- push_indice( hBstr, IND_Y_GAIN_TMP, idx_g, 5 );
-
- if ( !( coder_type == INACTIVE && tdm_LRTD_flag == 0 && idchan == 1 ) || core_brate_inp > GSC_LRES_GAINQ_LIMIT )
- {
- idx_g = vquant( y_gain_tmp2 + 3, YGain_mean_LR + 3, y_gain_tmp2 + 3, YGain_dic2_LR, 4, 32 );
- push_indice( hBstr, IND_Y_GAIN_TMP, idx_g, 5 );
-
- /*----------------------------------------------------------------------*
- * Vector quantization of the first 8 bands + quantization of the 4 bands out of the last 8
- * Interpolation of the last 4 bands Q to create bands 8-16
- *----------------------------------------------------------------------*/
-
- idx_g = vquant( y_gain_tmp2 + 7, YGain_mean_LR + 7, y_gain_tmp2 + 7, YGain_dic3_LR, 5, 32 );
- push_indice( hBstr, IND_Y_GAIN_TMP, idx_g, 5 );
-
- set_f( y_gain_tmp2 + 12, 0, MBANDS_GN - 12 );
-
- /* Update to quantized vector */
- mvr2r( y_gain_tmp2, y_gain_tmp, 8 );
-
- mvr2r( y_gain_tmp2 + 8, y_gain_tmp3, 4 );
- set_f( y_gain_tmp + 8, 0, 8 );
- fft_rel( y_gain_tmp2 + 8, 4, 2 );
-
- mvr2r( y_gain_tmp2 + 8, y_gain_tmp + 8, 3 );
- y_gain_tmp[15] = y_gain_tmp2[11];
- ifft_rel( y_gain_tmp + 8, 8, 3 );
-
- for ( i = 8; i < 16; i++ )
- {
- y_gain_tmp[i] *= 1.41f;
- }
-
- y_gain_tmp[8] = y_gain_tmp3[0];
- y_gain_tmp[10] = y_gain_tmp3[1];
- y_gain_tmp[12] = y_gain_tmp3[2];
- y_gain_tmp[14] = y_gain_tmp3[3];
- }
- else
- {
- mvr2r( y_gain_tmp2, y_gain_tmp, 3 );
- set_f( y_gain_tmp + 3, 0.0f, MBANDS_GN16k - 3 );
- }
- }
- else
- {
- if ( L_frame == L_FRAME )
- {
- idx_g = vquant( y_gain_tmp, YG_mean16, y_gain_tmp, YG_dicMR_1, 4, 64 );
- push_indice( hBstr, IND_Y_GAIN_TMP, idx_g, 6 );
-
- idx_g = vquant( y_gain_tmp + 4, YG_mean16 + 4, y_gain_tmp + 4, YG_dicMR_2, 4, 32 );
- push_indice( hBstr, IND_Y_GAIN_TMP, idx_g, 5 );
-
- idx_g = vquant( y_gain_tmp + 8, YG_mean16 + 8, y_gain_tmp + 8, YG_dicMR_3, 4, 32 );
- push_indice( hBstr, IND_Y_GAIN_TMP, idx_g, 5 );
-
- idx_g = vquant( y_gain_tmp + 12, YG_mean16 + 12, y_gain_tmp + 12, YG_dicMR_4, 4, 16 );
- push_indice( hBstr, IND_Y_GAIN_TMP, idx_g, 4 );
- }
- else
- {
- idx_g = vquant( y_gain_tmp, YG_mean16HR, y_gain_tmp, YG_dicHR_1, 4, 128 );
- push_indice( hBstr, IND_Y_GAIN_TMP, idx_g, 7 );
-
- idx_g = vquant( y_gain_tmp + 4, YG_mean16HR + 4, y_gain_tmp + 4, YG_dicHR_2, 4, 64 );
- push_indice( hBstr, IND_Y_GAIN_TMP, idx_g, 6 );
-
- idx_g = vquant( y_gain_tmp + 8, YG_mean16HR + 8, y_gain_tmp + 8, YG_dicHR_3, 4, 64 );
- push_indice( hBstr, IND_Y_GAIN_TMP, idx_g, 6 );
-
- idx_g = vquant( y_gain_tmp + 12, YG_mean16HR_16kHz, y_gain_tmp + 12, YG_dicHR_4_16kHz, 4, 64 );
- push_indice( hBstr, IND_Y_GAIN_TMP, idx_g, 6 );
-
- idx_g = vquant( y_gain_tmp + 16, YG_meanL2G_16kHz, y_gain_tmp + 16, YG_dicL2G_16kHz, 2, 8 );
- push_indice( hBstr, IND_Y_GAIN_HF, idx_g, 3 );
- }
- }
- }
-
- GSC_gain_DQ( element_mode, ENC, coder_type, Mbands_gn, core_brate, mean_4g[0], y_gain_tmp, y_gainQ );
-
- return mean_4g[0];
-}
-#endif
-
Word16 gsc_gainQ_ivas_fx(
BSTR_ENC_HANDLE hBstr, /* i/o: encoder bitstream handle */
const Word16 element_mode, /* i : element mode */
@@ -886,203 +424,3 @@ Word16 gsc_gainQ_ivas_fx(
return mean_4g_fx[0];
}
-
-#ifndef IVAS_FLOAT_FIXED
-/*-------------------------------------------------------------------*
- * gsc_gaindec()
- *
- * Generic signal frequency band decoding and application
- *-------------------------------------------------------------------*/
-
-/*! r: average frequency gain */
-float gsc_gaindec(
- Decoder_State *st, /* i/o: decoder state structure */
- float y_gainQ[], /* o : quantized gain per band */
- const int32_t core_brate, /* i : core used */
- float old_y_gain[], /* i/o: AR gain quantizer for low rate */
- const int16_t coder_type, /* i : coding type */
- const int16_t bwidth /* i : input signal bandwidth */
-)
-{
- int16_t idx_g, i;
- float mean_4g;
- int16_t Mbands_gn = MBANDS_GN;
- float y_gain_tmp3[MBANDS_GN];
-
- if ( st->L_frame == L_FRAME16k )
- {
- Mbands_gn = MBANDS_GN16k;
- }
-
- if ( ( coder_type == AUDIO || coder_type == INACTIVE ) && bwidth == NB )
- {
- idx_g = get_next_indice( st, 6 );
- VDQ_vec( &mean_4g, Gain_meanNB, Gain_mean_dicNB, idx_g, 1 );
-
- idx_g = get_next_indice( st, 6 );
- VDQ_vec( y_gainQ, Mean_dic_NB, Gain_dic1_NB, idx_g, 3 );
-
- if ( core_brate < ACELP_9k60 )
- {
- idx_g = get_next_indice( st, 5 );
- VDQ_vec( y_gainQ + 3, Mean_dic_NB + 3, Gain_dic2_NB, idx_g, 3 );
-
- idx_g = get_next_indice( st, 4 );
- VDQ_vec( y_gainQ + 6, Mean_dic_NB + 6, Gain_dic3_NB, idx_g, 4 );
- }
- else
- {
- idx_g = get_next_indice( st, 6 );
- VDQ_vec( y_gainQ + 3, Mean_dic_NB + 3, Gain_dic2_NBHR, idx_g, 3 );
-
- idx_g = get_next_indice( st, 7 );
- VDQ_vec( y_gainQ + 6, Mean_dic_NB + 6, Gain_dic3_NBHR, idx_g, 4 );
- }
-
- if ( core_brate <= ACELP_9k60 && coder_type == INACTIVE )
- {
- /* Some energy is needed in high band for stat_noise_uv_enc to be functional in inactive speech */
- y_gainQ[10] = mean( y_gainQ + 6, 3 );
- y_gainQ[11] = mean( y_gainQ + 7, 3 );
- y_gainQ[12] = mean( y_gainQ + 8, 3 );
- y_gainQ[13] = mean( y_gainQ + 9, 3 );
- y_gainQ[14] = mean( y_gainQ + 10, 3 );
- y_gainQ[15] = mean( y_gainQ + 11, 3 );
- }
- else
- {
- set_f( y_gainQ + 10, 0, MBANDS_GN - 10 );
- }
- }
- else
- {
- idx_g = get_next_indice( st, 6 );
- VDQ_vec( &mean_4g, mean_m, mean_gain_dic, idx_g, 1 );
-
- if ( core_brate < ACELP_9k60 )
- {
- /*--------------------------------------------------------------------------------------*
- * UQ of the first 8 bands and half of the last 8 bands
- *--------------------------------------------------------------------------------------*/
-
- idx_g = get_next_indice( st, 5 );
- VDQ_vec( y_gainQ, YGain_mean_LR, YGain_dic1_LR, idx_g, 3 );
-
- if ( !( coder_type == INACTIVE && st->tdm_LRTD_flag == 0 && st->idchan == 1 ) || st->core_brate > GSC_LRES_GAINQ_LIMIT )
- {
- idx_g = get_next_indice( st, 5 );
- VDQ_vec( y_gainQ + 3, YGain_mean_LR + 3, YGain_dic2_LR, idx_g, 4 );
-
- /*----------------------------------------------------------------------*
- * Interpolation of the last 4 Q bands to create bands 8-16
- * And scaling
- *----------------------------------------------------------------------*/
-
- idx_g = get_next_indice( st, 5 );
- VDQ_vec( y_gainQ + 7, YGain_mean_LR + 7, YGain_dic3_LR, idx_g, 5 );
-
- mvr2r( y_gainQ + 8, y_gain_tmp3, 4 );
- set_f( y_gainQ + 12, 0.0f, 4 );
-
- fft_rel( y_gainQ + 8, 4, 2 );
-
- y_gainQ[15] = y_gainQ[11];
- y_gainQ[11] = 0.0f;
-
- ifft_rel( y_gainQ + 8, 8, 3 );
-
- for ( i = 8; i < 16; i++ )
- {
- y_gainQ[i] *= 1.41f;
- }
-
- /*----------------------------------------------------------------------*
- * Copy the true Q values in the specific bands
- *----------------------------------------------------------------------*/
-
- y_gainQ[8] = y_gain_tmp3[0];
- y_gainQ[10] = y_gain_tmp3[1];
- y_gainQ[12] = y_gain_tmp3[2];
- y_gainQ[14] = y_gain_tmp3[3];
- }
- else
- {
- set_f( y_gainQ + 3, 0.0f, MBANDS_GN16k - 3 );
- }
- }
- else
- {
- if ( st->L_frame == L_FRAME )
- {
- idx_g = get_next_indice( st, 6 );
- VDQ_vec( y_gainQ, YG_mean16, YG_dicMR_1, idx_g, 4 );
-
- idx_g = get_next_indice( st, 5 );
- VDQ_vec( y_gainQ + 4, YG_mean16 + 4, YG_dicMR_2, idx_g, 4 );
-
- idx_g = get_next_indice( st, 5 );
- VDQ_vec( y_gainQ + 8, YG_mean16 + 8, YG_dicMR_3, idx_g, 4 );
-
- idx_g = get_next_indice( st, 4 );
- VDQ_vec( y_gainQ + 12, YG_mean16 + 12, YG_dicMR_4, idx_g, 4 );
- }
- else
- {
- idx_g = get_next_indice( st, 7 );
- VDQ_vec( y_gainQ, YG_mean16HR, YG_dicHR_1, idx_g, 4 );
-
- idx_g = get_next_indice( st, 6 );
- VDQ_vec( y_gainQ + 4, YG_mean16HR + 4, YG_dicHR_2, idx_g, 4 );
-
- idx_g = get_next_indice( st, 6 );
- VDQ_vec( y_gainQ + 8, YG_mean16HR + 8, YG_dicHR_3, idx_g, 4 );
-
- idx_g = get_next_indice( st, 6 );
- VDQ_vec( y_gainQ + 12, YG_mean16HR_16kHz, YG_dicHR_4_16kHz, idx_g, 4 );
-
- idx_g = get_next_indice( st, 3 );
- VDQ_vec( y_gainQ + 16, YG_meanL2G_16kHz, YG_dicL2G_16kHz, idx_g, 2 );
- }
- }
- }
-
- mvr2r( y_gainQ, old_y_gain, Mbands_gn );
-
- GSC_gain_DQ( st->element_mode, DEC, coder_type, Mbands_gn, core_brate, mean_4g, y_gainQ, y_gainQ );
-
- return mean_4g;
-}
-#endif
-
-
-#ifndef IVAS_FLOAT_FIXED
-/*-------------------------------------------------------------------*
- * VDQ_vec()
- *
- * Return the dequantized vector of index
- *-------------------------------------------------------------------*/
-
-static int16_t VDQ_vec(
- float *Qvec_out, /* o : Quanitzed vector */
- const float *mean_dic, /* i : average codebook */
- const float *dic, /* i : codebook */
- const int16_t index, /* i : index of codebook*/
- const int16_t vec_en /* i : vector length */
-)
-{
- int16_t i, j;
-
- j = index * vec_en;
- for ( i = 0; i < vec_en; i++ )
- {
- Qvec_out[i] = dic[j++];
- }
-
- for ( i = 0; i < vec_en; i++ )
- {
- Qvec_out[i] += mean_dic[i];
- }
-
- return index;
-}
-#endif
diff --git a/lib_com/gs_noisefill.c b/lib_com/gs_noisefill.c
deleted file mode 100644
index c2074100a8ae534b782cb02a1ec06259e5f35361..0000000000000000000000000000000000000000
--- a/lib_com/gs_noisefill.c
+++ /dev/null
@@ -1,841 +0,0 @@
-/******************************************************************************************************
-
- (C) 2022-2024 IVAS codec Public Collaboration with portions copyright Dolby International AB, Ericsson AB,
- Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD.,
- Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange,
- Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other
- contributors to this repository. All Rights Reserved.
-
- This software is protected by copyright law and by international treaties.
- The IVAS codec Public Collaboration consisting of Dolby International AB, Ericsson AB,
- Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD.,
- Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange,
- Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other
- contributors to this repository retain full ownership rights in their respective contributions in
- the software. This notice grants no license of any kind, including but not limited to patent
- license, nor is any license granted by implication, estoppel or otherwise.
-
- Contributors are required to enter into the IVAS codec Public Collaboration agreement before making
- contributions.
-
- This software is provided "AS IS", without any express or implied warranties. The software is in the
- development stage. It is intended exclusively for experts who have experience with such software and
- solely for the purpose of inspection. All implied warranties of non-infringement, merchantability
- and fitness for a particular purpose are hereby disclaimed and excluded.
-
- Any dispute, controversy or claim arising under or in relation to providing this software shall be
- submitted to and settled by the final, binding jurisdiction of the courts of Munich, Germany in
- accordance with the laws of the Federal Republic of Germany excluding its conflict of law rules and
- the United Nations Convention on Contracts on the International Sales of Goods.
-
-*******************************************************************************************************/
-
-/*====================================================================================
- EVS Codec 3GPP TS26.443 Nov 04, 2021. Version 12.14.0 / 13.10.0 / 14.6.0 / 15.4.0 / 16.3.0
- ====================================================================================*/
-
-#include
-#include "options.h"
-#include
-#include "cnst.h"
-#include "rom_com.h"
-#include "prot.h"
-#include "wmc_auto.h"
-
-#ifndef IVAS_FLOAT_FIXED
-/*-------------------------------------------------------------------*
- * gs_noisf()
- *
- * Noise fill-in function
- *-------------------------------------------------------------------*/
-
-static void gs_noisf(
- const int16_t Start_BIN, /* i : First bin for noise fill */
- const int16_t NB_Qbins, /* i : Number of bin per band */
- const float Noise_fac, /* i : Noise level */
- const float *y_norm, /* i : Quantized pulses */
- float *exc_diffQ, /* o : Quantized pulses with noise added */
- int16_t *seed_tcx, /* i : Random generator seed */
- const int16_t coder_type /* i : coder type */
-)
-{
- float ftmp;
- int16_t i, k;
- int16_t NB_zer = NB_Qbins / 2;
-
- if ( coder_type == INACTIVE )
- {
- NB_zer = 2;
- }
-
- /*----------------------------------------------*
- * noise fill-in on unquantized subvector *
- * injected only from 1066Hz to 6400Hz. *
- *----------------------------------------------*/
-
- for ( k = Start_BIN; k < NB_Qbins + Start_BIN; k += NB_zer )
- {
- ftmp = 0.0;
- for ( i = k; i < k + NB_zer; i++ )
- {
- exc_diffQ[i] = (float) y_norm[i];
- ftmp += exc_diffQ[i] * exc_diffQ[i];
- }
-
- if ( ftmp < .5 )
- {
- for ( i = k; i < k + NB_zer; i++ )
- {
- exc_diffQ[i] += Noise_fac * ( (float) own_random( seed_tcx ) / PCM16_TO_FLT_FAC );
- }
- }
- else
- {
- /* This is added only to keep the seed in sync between different compilers */
- for ( i = k; i < k + NB_zer; i++ )
- {
- own_random( seed_tcx );
- }
- }
- }
-
- return;
-}
-
-/*-------------------------------------------------------------------*
- * EstimateNoiseLevel_inner()
- *
- * Estimate noise level from the power spectrum
- *-------------------------------------------------------------------*/
-
-static void EstimateNoiseLevel_inner(
- float *noisepb, /* o : Noise per band */
- const int32_t bitrate, /* i : Bitrate of the codec */
- const int16_t i_band, /* i : First band to compute the noise */
- const int16_t Mbands_gn /* i : number of bands */
-)
-{
- int16_t i;
- float noise_offset;
-
- noise_offset = 0.25f;
- if ( bitrate > ACELP_24k40 )
- {
- noise_offset = .2f;
- }
- else if ( bitrate >= ACELP_22k60 )
- {
- noise_offset = .3f;
- }
- else if ( bitrate >= ACELP_9k60 )
- {
- noise_offset = 0.35f;
- }
- else
- {
- noise_offset = .4f;
- }
-
- set_f( noisepb + i_band, noise_offset, Mbands_gn - i_band );
-
- for ( i = i_band; i < 5; i++ )
- {
- if ( noisepb[i] > 0.2f )
- {
- noisepb[i] = 0.2f;
- }
- }
-
- return;
-}
-
-/*-------------------------------------------------------------------*
- * EstimateNoiseLevel()
- *
- *
- *-------------------------------------------------------------------*/
-
-static void EstimateNoiseLevel(
- float *noisepb, /* o : Noise per band */
- const int32_t bitrate, /* i : Bitrate of the codec */
- const int16_t Diff_len, /* i : number of bin before cut-off frequency */
- const int16_t Mbands_gn, /* i : number of bands */
- const int16_t coder_type, /* i : coder type */
- const int16_t noise_lev, /* i : pulses dynamic */
- const int16_t pit_band_idx, /* i : bin position of the cut-off frequency */
- const int16_t last_bin, /* i : the last bin of bit allocation */
- const int16_t bwidth,
- const int16_t L_frame /* i : frame length */
-)
-{
- int16_t i_band;
-
- i_band = 0;
-
- if ( Diff_len < L_frame )
- {
- EstimateNoiseLevel_inner( noisepb, bitrate, i_band, Mbands_gn );
-
- if ( coder_type != INACTIVE )
- {
- if ( ( bitrate == ACELP_8k00 && last_bin > 8 ) && bwidth != NB )
- {
- while ( Mbands_gn > i_band )
- {
- noisepb[i_band] *= 2.0f;
- i_band++;
- }
- }
- else
- {
- while ( pit_band_idx > i_band )
- {
- noisepb[i_band] /= 2.0f;
- i_band++;
- }
- }
- }
- }
-
- if ( ( coder_type == INACTIVE || noise_lev >= NOISE_LEVEL_SP3 ) && L_frame == L_FRAME )
- {
- for ( i_band = 9; i_band < Mbands_gn; i_band++ )
- {
- noisepb[i_band] *= 1.15f;
- }
- }
- else if ( L_frame == L_FRAME16k )
- {
- if ( bitrate == ACELP_13k20 )
- {
- set_f( noisepb, .45f, Mbands_gn );
- }
-
- if ( coder_type == INACTIVE )
- {
- for ( ; i_band < Mbands_gn; i_band++ )
- {
- noisepb[i_band] = .4f;
- }
- }
- else if ( ( noise_lev <= NOISE_LEVEL_SP1 ) && bitrate > ACELP_16k40 )
- {
- for ( ; i_band < Mbands_gn - 4; i_band++ )
- {
- noisepb[i_band] *= .6f;
- }
- }
- else if ( ( noise_lev <= NOISE_LEVEL_SP2 ) && bitrate > ACELP_16k40 )
- {
- for ( ; i_band < Mbands_gn - 4; i_band++ )
- {
- noisepb[i_band] *= .8f;
- }
- }
- }
-
- return;
-}
-
-/*-------------------------------------------------------------------*
- * Apply_NoiseFill()
- *
- *
- *-------------------------------------------------------------------*/
-
-static void Apply_NoiseFill(
- float *exc_diffQ, /* i/o: Noise per band */
- int16_t *seed_tcx, /* i : Seed for noise */
- const float *noisepb, /* i : Noise per band */
- const int16_t Diff_len, /* i : number of bin before cut-off frequency */
- const int16_t Mbands_gn, /* i : number of bands */
- const int16_t coder_type, /* i : coder type */
- const int16_t *freq_nsbin_per_band /* i : bin per bands tables */
-)
-{
- int16_t StartBin, NB_Qbins, i_band;
- StartBin = 0;
- NB_Qbins = 0;
-
- for ( i_band = 0; i_band < Mbands_gn; i_band++ )
- {
- StartBin += NB_Qbins;
- NB_Qbins = freq_nsbin_per_band[i_band];
-
- if ( Diff_len < L_FRAME )
- {
- gs_noisf( StartBin, NB_Qbins, noisepb[i_band], exc_diffQ, exc_diffQ, seed_tcx, coder_type );
- }
- }
-
- return;
-}
-
-/*-------------------------------------------------------------------*
- * freq_dnw_scaling()
- *
- *
- *-------------------------------------------------------------------*/
-
-void freq_dnw_scaling(
- const int16_t cor_strong_limit, /* i : HF correlation */
- const int16_t coder_type, /* i : coder type */
- const int16_t noise_lev, /* i : Noise level */
- const int32_t core_brate, /* i : Core bitrate */
- float fy_norm[], /* i/o: Frequency quantized parameter */
- const int16_t L_frame /* i : frame length */
-)
-{
- float sc_dyn;
- int16_t start_sc, i;
-
- sc_dyn = 1.0f;
- start_sc = L_frame;
-
- if ( core_brate <= ACELP_8k00 && coder_type == INACTIVE )
- {
- sc_dyn *= .15f;
- start_sc = 64;
- }
- else if ( coder_type == INACTIVE )
- {
- sc_dyn *= .25f;
- start_sc = 80;
- }
- else
- {
- sc_dyn = (float) ( NOISE_LEVEL_SP3 - noise_lev ) / 10.0f + 0.4f;
- start_sc = 112 + ( NOISE_LEVEL_SP3 - noise_lev ) * 16;
-
- if ( noise_lev == NOISE_LEVEL_SP0 )
- {
- start_sc = L_FRAME;
- }
- }
-
- if ( L_frame == L_FRAME16k && core_brate <= ACELP_24k40 )
- {
- sc_dyn += 0.125f;
- if ( sc_dyn > 1.0f )
- {
- sc_dyn = 1.0f;
- }
- }
-
- for ( i = start_sc; i < L_frame; i++ )
- {
- fy_norm[i] *= sc_dyn;
- }
-
- if ( ( core_brate < ACELP_13k20 && cor_strong_limit == 0 ) || core_brate < ACELP_9k60 )
- {
- for ( i = 160; i < L_frame; i++ )
- {
- if ( fy_norm[i] > 1.0f )
- {
- fy_norm[i] = 1.0f;
- }
-
- if ( fy_norm[i] < -1.0f )
- {
- fy_norm[i] = -1.0f;
- }
- }
- }
- else if ( core_brate < ACELP_22k60 )
- {
- for ( i = 160; i < L_frame; i++ )
- {
- if ( fy_norm[i] > 1.5f )
- {
- fy_norm[i] = 1.5f;
- }
-
- if ( fy_norm[i] < -1.5f )
- {
- fy_norm[i] = -1.5f;
- }
- }
- }
-
- return;
-}
-
-
-/*-------------------------------------------------------------------*
- * Decreas_freqPeak()
- *
- *
- *-------------------------------------------------------------------*/
-
-static void Decreas_freqPeak(
- const float *lsf_new, /* i : ISFs at the end of the frame */
- float *exc_diffQ, /* i/o: frequency coefficients of per band */
- float thr_rat /* i : threshold of ratio between consecutive lsf_new_diff */
-)
-{
- int16_t i, j, k;
- int16_t last_bin = 0;
- int16_t pos = 0;
- float *src;
- float avrg, max_val;
- float lsf_new_diff[M];
- lsf_new_diff[0] = 0; /* prevent unitialized value */
- for ( j = 1; j < ( M - 1 ); j++ )
- {
- lsf_new_diff[j] = lsf_new[j] - lsf_new[j - 1];
- }
-
- avrg = 0.0f;
- /* This is to prevent a possible div by 0 in the '*(src) = (*src > 0) ?...'
- loop. The value of 'max' is not important because it will be mutiplied
- by 'avrg' and the result will be close to 0. The 'fabs(*src)/max'
- div by 0 error will be avoided. */
- max_val = 0.001f;
- for ( i = 160; i < L_FRAME; i++ )
- {
- if ( fabs( exc_diffQ[i] ) > max_val )
- {
- max_val = (float) fabs( exc_diffQ[i] );
- pos = i;
- }
- avrg += (float) fabs( exc_diffQ[i] );
- }
- avrg /= 96;
- last_bin = M - 1; /* When the search is false, should equate the end of the vector, not the beginning */
- for ( i = 0; i < ( M - 1 ); i++ )
- {
- if ( lsf_new[i] > 4000 )
- {
- last_bin = i;
- break;
- }
- }
-
- for ( i = last_bin; i < 14; i++ )
- {
- if ( lsf_new_diff[i] < thr_rat * lsf_new_diff[i - 1] )
- {
- src = &exc_diffQ[( i - 1 ) * 16];
- for ( j = 0; j < 2; j++ )
- {
- for ( k = 0; k < 16; k++ )
- {
- if ( fabs( *src ) > 2.0f * avrg )
- {
- *( src ) = ( *src > 0 ) ? (float) ( avrg * ( 2.0f - fabs( *src ) / max_val ) ) : (float) ( -avrg * ( 2.0f - fabs( *src ) / max_val ) );
- }
- src++;
- }
- }
- }
- }
-
- if ( fabs( exc_diffQ[pos] ) == max_val && max_val > 4.0f * avrg )
- {
- for ( i = pos - 1; i < pos + 2; i++ )
- {
- exc_diffQ[pos] *= 0.5f;
- }
- }
-
- return;
-}
-
-
-/*-------------------------------------------------------------------*
- * envelop_modify()
- *
- *
- *-------------------------------------------------------------------*/
-
-static void envelop_modify(
- float *exc_diffQ, /* i/o: frequency coefficients of per band */
- int16_t *seed_tcx, /* i : Seed for noise */
- int16_t last_bin, /* i : last bin of bit allocation */
- float *Ener_per_bd_iQ /* i : Quantized energy of targeted vector */
-)
-{
- int16_t i, j, end_band;
- float Ener, Ener1, *src;
- float weight = 1.0f;
-
- end_band = L_FRAME;
- Ener = 0.1f;
- for ( i = last_bin * 16; i < end_band; i++ )
- {
- Ener += exc_diffQ[i] * exc_diffQ[i];
- }
- Ener = (float) sqrt( ( end_band - last_bin * 16 ) / Ener );
-
- weight = 0.5f;
-
- src = &exc_diffQ[16 * last_bin];
- for ( i = last_bin; i < last_bin + 4; i++ )
- {
- Ener1 = (float) ( 0.4f * pow( 10, Ener_per_bd_iQ[i + 1] ) );
- for ( j = 0; j < 16; j++ )
- {
- *src = Ener1 * ( weight * ( *src ) * Ener + ( 1.0f - weight ) * own_random( seed_tcx ) / PCM16_TO_FLT_FAC );
- src++;
- }
- }
-
- Ener1 = (float) ( 0.4f * pow( 10, Ener_per_bd_iQ[15] ) );
-
- src = &exc_diffQ[224];
- for ( j = 0; j < 32; j++ )
- {
- *src = Ener1 * ( weight * ( *src ) * Ener + ( 1.0f - weight ) * own_random( seed_tcx ) / PCM16_TO_FLT_FAC );
- src++;
- }
-
- return;
-}
-
-/*-------------------------------------------------------------------*
- * highband_exc_dct_in()
- *
- *
- *-------------------------------------------------------------------*/
-
-void highband_exc_dct_in(
- const int32_t core_brate, /* i : core bitrate */
- const int16_t *mfreq_bindiv, /* i : bin per bands tables */
- int16_t last_bin, /* i : last bin of bit allocation */
- int16_t Diff_len, /* i : number of bin before cut-off frequency */
- int16_t noise_lev, /* i : pulses dynamic */
- int16_t pit_band_idx, /* i : bin position of the cut-off frequency */
- float *exc_diffQ, /* i : frequency coefficients of per band */
- int16_t *seed_tcx, /* i : Seed for noise */
- float *Ener_per_bd_iQ, /* i : Quantized energy of targeted vector */
- int16_t nb_subfr, /* i : Number of subframe considered */
- float *exc_dct_in, /* o : dct of residual signal */
- int16_t last_coder_type, /* i : coding type of last frame */
- int16_t *bitallocation_band, /* i : bit allocation flag of each band */
- const float *lsf_new, /* i : LSFs at the end of the frame */
- float *last_exc_dct_in, /* i : dct of residual signal of last frame */
- float *last_ener, /* i : frequency energy of last frame */
- int16_t *last_bitallocation_band, /* i : bit allocation flag of each band of last frame */
- int16_t *bitallocation_exc, /* i : flag of decoded coefficients */
- const int16_t bfi, /* i : bad frame indicator */
- const int16_t coder_type, /* i : coder type */
- const int16_t bwidth, /* i : audio bandwidth */
- float *exc_wo_nf, /* o : temporal excitation (in f domain) without noisefill */
- const int16_t GSC_noisy_speech, /* i : GSC noisy speech flag */
- float *lt_ener_per_band, /* i/o: Average per band energy */
- const int16_t L_frame, /* i : frame length */
- const int16_t element_mode, /* i : IVAS element mode */
- const int16_t GSC_IVAS_mode /* i : GSC IVAS mode */
-)
-{
- int16_t i, j;
- int16_t MAX_Bin = 0;
- int16_t last_bin_tmp;
- float noisepb[MBANDS_GN16k];
- float Ener_per_bd_yQ[MBANDS_GN16k];
- float *src, *dst, *end;
- float ener = 0.0f;
- int16_t length_bin, bwe_flag = 0;
-
- for ( j = 10; j < MBANDS_GN; j++ )
- {
- ener += (float) pow( 10, Ener_per_bd_iQ[j] );
- }
-
- if ( core_brate == ACELP_8k00 && bwidth != NB )
- {
- if ( last_coder_type != AUDIO )
- {
- *last_ener = ener;
- }
-
- if ( ( last_bin > 8 || Diff_len != 0 ) && last_coder_type == AUDIO )
- {
- MAX_Bin = 10;
- bwe_flag = 1;
- }
- else
- {
- MAX_Bin = 15;
- }
-
- last_bin_tmp = last_bin;
- if ( last_bin < MAX_Bin )
- {
- last_bin = MAX_Bin;
- }
- last_bin += 1;
- }
- else
- {
- if ( L_frame == L_FRAME16k )
- {
- last_bin = MBANDS_GN16k;
- }
- else
- {
- last_bin = MBANDS_GN;
- }
- last_bin_tmp = last_bin;
- }
-
-
- if ( bfi || core_brate < 6000 || ( core_brate < 8600 && coder_type == UNVOICED ) )
- {
- set_f( noisepb, 0.4f, MBANDS_GN );
- }
- else if ( GSC_IVAS_mode == 3 || ( GSC_IVAS_mode > 0 && GSC_noisy_speech == 1 ) )
- {
- set_f( noisepb, 0.4f, MBANDS_GN16k );
- }
- else
- {
- EstimateNoiseLevel( noisepb, core_brate, Diff_len, last_bin, coder_type, noise_lev, pit_band_idx, last_bin_tmp, bwidth, L_frame );
- }
-
- if ( exc_wo_nf != NULL )
- {
- mvr2r( exc_diffQ, exc_wo_nf, L_frame );
- }
-
- if ( GSC_IVAS_mode == 0 && GSC_noisy_speech && !bfi && element_mode <= IVAS_SCE )
- {
- set_f( noisepb, 0.1f, MBANDS_GN );
- }
-
- if ( core_brate < 6000 && coder_type <= UNVOICED )
- {
- for ( i = 0; i < L_frame; i++ )
- {
- if ( exc_diffQ[i] == 0.0f )
- {
- exc_diffQ[i] += 2.0f * noisepb[0] * ( (float) own_random( seed_tcx ) / PCM16_TO_FLT_FAC );
- }
- }
- }
- else
- {
- Apply_NoiseFill( exc_diffQ, seed_tcx, noisepb, Diff_len, last_bin, coder_type, mfreq_bindiv );
- }
-
- /*--------------------------------------------------------------------------------------*
- * Quantize average gain
- * Subtract Q averaged gain
- * VQ of remaining gain per band
- *--------------------------------------------------------------------------------------*/
-
- if ( core_brate == ACELP_8k00 && bwidth != NB )
- {
- Ener_per_band_comp( exc_diffQ, Ener_per_bd_yQ, last_bin + 1, 0, L_frame );
- }
- else
- {
- Ener_per_band_comp( exc_diffQ, Ener_per_bd_yQ, MBANDS_GN, 1, L_frame );
-
- if ( nb_subfr < 4 && L_frame < L_FRAME16k )
- {
- for ( i = L_FRAME - 16; i < L_FRAME; i++ )
- {
- exc_diffQ[i] *= ( 0.067f * i - 15.0f );
- }
- }
- }
-
- /*--------------------------------------------------------------------------------------*
- * Check potential energy excitation overshoot
- *--------------------------------------------------------------------------------------*/
-
- if ( bfi )
- {
- if ( GSC_noisy_speech == 0 && coder_type > UNVOICED ) /* Here coder_type == last_coder_type because of the bfi */
- {
- for ( i = 0; i < last_bin; i++ )
- {
- Ener_per_bd_iQ[i] = min( Ener_per_bd_iQ[i], ( lt_ener_per_band[i] - 0.0376f ) - Ener_per_bd_yQ[i] );
- lt_ener_per_band[i] -= 0.0188f;
- }
- for ( ; i < MBANDS_GN; i++ )
- {
- Ener_per_bd_iQ[i] = min( Ener_per_bd_iQ[i], ( lt_ener_per_band[i] - 0.0376f ) );
- lt_ener_per_band[i] -= 0.0188f;
- }
- }
- else
- {
- for ( i = 0; i < last_bin; i++ )
- {
- Ener_per_bd_iQ[i] = min( Ener_per_bd_iQ[i], ( lt_ener_per_band[i] + 0.3f ) - Ener_per_bd_yQ[i] );
- lt_ener_per_band[i] -= 0.0188f;
- }
- for ( ; i < MBANDS_GN; i++ )
- {
- Ener_per_bd_iQ[i] = min( Ener_per_bd_iQ[i], ( lt_ener_per_band[i] + 0.3f ) );
- lt_ener_per_band[i] -= 0.0188f;
- }
- }
- }
-
- /*--------------------------------------------------------------------------------------*
- * Apply decoded gain onto the difference signal
- *--------------------------------------------------------------------------------------*/
-
- if ( GSC_IVAS_mode >= 1 )
- {
- float scale_factLF = 0.9f;
- float scale_factHF = 0.9f;
-
- if ( GSC_IVAS_mode == 1 && GSC_noisy_speech == 0 )
- {
- scale_factHF = 0.8f;
- }
- else if ( GSC_IVAS_mode == 2 || GSC_noisy_speech == 1 )
- {
- scale_factHF = 0.71f;
- }
- else if ( GSC_IVAS_mode == 3 )
- {
- scale_factHF = 0.9f;
- }
- for ( i = 0; i < pit_band_idx * 16; i++ )
- {
- exc_diffQ[i] *= scale_factLF;
- }
- for ( ; i < L_frame; i++ )
- {
- exc_diffQ[i] *= scale_factHF;
- }
- }
- else if ( GSC_noisy_speech )
- {
- float scale_fact = 0.9f;
-
- if ( element_mode == IVAS_CPE_TD )
- {
- if ( coder_type == INACTIVE )
- {
- scale_fact = 1.0f;
- }
- else
- {
- scale_fact = 0.95f;
- }
- }
- else if ( element_mode > IVAS_SCE )
- {
- scale_fact = 0.71f;
- }
-
- for ( i = 0; i < L_frame; i++ )
- {
- exc_diffQ[i] *= scale_fact;
- }
- }
-
- if ( GSC_noisy_speech && element_mode > IVAS_SCE && core_brate < ACELP_7k20 )
- {
- for ( i = 80; i < L_frame; i++ )
- {
- exc_diffQ[i] *= ( +0.0024f * (float) i + 1.192f );
- }
- }
-
- Comp_and_apply_gain( exc_diffQ, Ener_per_bd_iQ, Ener_per_bd_yQ, last_bin, 0 );
-
- if ( exc_wo_nf != NULL )
- {
- Comp_and_apply_gain( exc_wo_nf, Ener_per_bd_iQ, Ener_per_bd_yQ, last_bin, 1 );
-
- v_add( exc_dct_in, exc_wo_nf, exc_wo_nf, L_frame );
- }
-
- /*--------------------------------------------------------------------------------------*
- * add the correction layer to the LF bins,
- * and add the quantized pulses or the noise for the higher part of the spectrum
- * (non valuable temporal content already zeroed)
- * DC is Zeroed
- *--------------------------------------------------------------------------------------*/
-
- v_add( exc_dct_in, exc_diffQ, exc_dct_in, L_frame );
-
- if ( core_brate == ACELP_8k00 && bwidth != NB )
- {
- if ( bwe_flag == 1 )
- {
- last_bin -= 1;
- src = &exc_diffQ[L_FRAME - 1];
- dst = &exc_dct_in[MAX_Bin * 16 - 1];
- end = &exc_diffQ[last_bin * 16 - 1];
-
- while ( src > end )
- {
- *src-- = *dst--;
- }
-
- if ( ( bitallocation_exc[0] != 0 || bitallocation_exc[1] != 0 ) && core_brate == ACELP_8k00 )
- {
- exc_diffQ[160] = 0.0f;
- }
-
- envelop_modify( exc_diffQ, seed_tcx, last_bin, Ener_per_bd_iQ );
-
- mvr2r( &exc_diffQ[last_bin * 16], &exc_dct_in[last_bin * 16], L_FRAME - last_bin * 16 );
- }
-
- if ( nb_subfr < 4 )
- {
- for ( i = L_FRAME - 16; i < L_FRAME; i++ )
- {
- exc_dct_in[i] *= ( 0.067f * i - 15.f );
- }
- }
-
- if ( ener < 2 * ( *last_ener ) && ener > 0.5f * ( *last_ener ) )
- {
- length_bin = 6;
- if ( last_coder_type != AUDIO )
- {
- set_s( last_bitallocation_band, 0, 6 );
- mvr2r( &exc_dct_in[( 4 + length_bin ) * 16], &last_exc_dct_in[( 4 + length_bin ) * 16], length_bin * 16 );
- }
-
- for ( i = 4; i < ( 4 + length_bin ); i++ )
- {
- if ( !( bitallocation_band[i] == 0 && last_bitallocation_band[i - 4] == 0 ) )
- {
- src = &exc_dct_in[( i + length_bin ) * 16];
- dst = &last_exc_dct_in[( i + length_bin ) * 16];
- for ( j = 0; j < 16; j++ )
- {
- if ( fabs( *src ) > 3.0f * fabs( *dst ) )
- {
- *src = ( *src > 0 ) ? (float) ( 0.5f * ( *src + fabs( *dst ) ) ) : (float) ( 0.5f * ( *src - fabs( *dst ) ) );
- }
- else if ( fabs( *dst ) > 3.0f * fabs( *src ) )
- {
- *src = ( *src > 0 ) ? (float) ( 0.7f * ( *src ) + 0.3f * fabs( *dst ) ) : (float) ( 0.7f * ( *src ) - 0.3f * fabs( *dst ) );
- }
- src++;
- dst++;
- }
- }
- }
- }
-
- if ( bwe_flag == 1 )
- {
- Decreas_freqPeak( lsf_new, exc_dct_in, 0.3f );
- }
- else
- {
- Decreas_freqPeak( lsf_new, exc_dct_in, 0.5f );
- }
- }
-
- mvr2r( &exc_dct_in[64], &last_exc_dct_in[64], L_frame - 64 );
- mvs2s( &bitallocation_band[4], last_bitallocation_band, 6 );
- *last_ener = ener;
-
- return;
-}
-#endif
diff --git a/lib_com/gs_preech_fx.c b/lib_com/gs_preech_fx.c
index 9e3c73a1da2e84dd7c680344dd1801376993160c..548cba204f55601d6cfc57deb9ea5944478db8bf 100644
--- a/lib_com/gs_preech_fx.c
+++ b/lib_com/gs_preech_fx.c
@@ -48,106 +48,10 @@
*-------------------------------------------------------------------*/
#define ATT_LENGHT16k 80
-#ifndef IVAS_FLOAT_FIXED
-#define INV_L_FRAME16k ( 1.0f / L_FRAME16k )
-#endif
#define ATT_LENGHT 64
#define ATT_SEG_LEN ( L_FRAME / ATT_LENGHT )
-#ifndef IVAS_FLOAT_FIXED
-#define INV_ATT_SEG_LEN ( 1.0f / ATT_SEG_LEN )
-#define INV_L_FRAME ( 1.0f / L_FRAME )
-#endif
-
-#ifndef IVAS_FLOAT_FIXED
-/*-------------------------------------------------------------------*
- * pre_echo_att()
- *
- * Attenuation of the pre-echo when encoder specifies an attack
- *-------------------------------------------------------------------*/
-
-void pre_echo_att(
- float *Last_frame_ener, /* i/o: Energy of the last frame */
- float *exc, /* i/o: Excitation of the current frame */
- const int16_t attack_flag, /* i : attack flag (GSC or TC) */
- const int16_t last_coder_type, /* i : Last coder type */
- const int16_t L_frame /* i : frame length */
-)
-{
- float etmp;
- float etmp1;
- float finc[ATT_LENGHT16k], ratio_float, inv_l_frame;
- int16_t att_len;
- int16_t attack_pos, i;
-
- if ( attack_flag > 0 && last_coder_type == AUDIO )
- {
- /*-------------------------------------------------------------------------*
- * Find where the onset (attack) occurs by computing the energy per section
- * The inverse weighting aims to favor the first maxima in case of
- * gradual onset
- *-------------------------------------------------------------------------*/
-
- att_len = ATT_LENGHT;
- if ( L_frame == L_FRAME16k )
- {
- att_len = ATT_LENGHT16k;
- }
- for ( i = 0; i < att_len; i++ )
- {
- finc[i] = sum2_f( exc + i * ATT_SEG_LEN, ATT_SEG_LEN ) * ( (float) ( att_len - i ) / ( att_len ) );
- }
- etmp = -1;
- attack_pos = maximum( finc, att_len, &etmp );
-
- /* Scaled the maximum energy and allowed 6 dB increase*/
- etmp *= INV_ATT_SEG_LEN;
- etmp1 = etmp;
- *Last_frame_ener *= 4.0f;
-
- /* If the maximum normalized energy > last frame energy + 6dB */
- if ( etmp > *Last_frame_ener && attack_pos > 0 )
- {
- /* Find the average energy before the attack */
- etmp = sum_f( finc, attack_pos ) + 0.01f;
- etmp /= ( attack_pos * ATT_SEG_LEN );
-
- /* Find the correction factor and apply it before the attack */
- ratio_float = (float) sqrt( *Last_frame_ener / etmp );
-
-
- /* Pre-echo atttenuation should never increase the energy */
- ratio_float = min( ratio_float, 1.0f );
- for ( i = 0; i < attack_pos * ATT_SEG_LEN; i++ )
- {
- exc[i] *= ratio_float;
- }
- }
- *Last_frame_ener = etmp1;
- }
- else
- {
- /*-------------------------------------------------------*
- * In normal cases, just compute the energy of the frame
- *-------------------------------------------------------*/
-
- etmp = sum2_f( exc, L_frame ) + 0.01f;
- inv_l_frame = INV_L_FRAME;
- if ( L_frame == L_FRAME16k )
- {
- inv_l_frame = INV_L_FRAME16k;
- }
- etmp *= inv_l_frame;
- *Last_frame_ener = etmp;
- }
-
- return;
-}
-#endif
-
-#ifdef IVAS_FLOAT_FIXED
-#ifdef IVAS_FLOAT_FIXED
void pre_echo_att_fx(
Word32 *Last_frame_ener_fx, /* i/o: Energy of the last frame 2*Q_new+1*/
Word16 *exc_fx, /* i/o: Excitation of the current frame Q_new*/
@@ -271,7 +175,6 @@ void pre_echo_att_fx(
return;
}
-#endif
void pre_echo_att_ivas_fx(
@@ -398,4 +301,3 @@ void pre_echo_att_ivas_fx(
return;
}
-#endif
diff --git a/lib_com/hp50_fx.c b/lib_com/hp50_fx.c
index 92dad39ffdc11f79e851eb676935bd8042837e72..78e358a80881101ca146b9e16c50d2452ec748bf 100644
--- a/lib_com/hp50_fx.c
+++ b/lib_com/hp50_fx.c
@@ -51,90 +51,8 @@
* void
*/
-#ifndef IVAS_FLOAT_FIXED
-void hp20_flt(
- Float32 signal[],
- const Word16 lg,
- Float32 mem[],
- const Word32 Fs )
-{
- Word16 i;
- Float32 x0, x1, x2, y0, y1, y2;
- Float32 a1, a2, b1, b2;
-
- y1 = mem[0];
- y2 = mem[1];
- x0 = mem[2];
- x1 = mem[3];
-
- if ( Fs == 8000 )
- {
- /* hp filter 20Hz at 3dB for 8000KHz input sampling rate
- [b,a] = butter(2, 20.0/4000.0, 'high');
- b = [0.988954248067140 -1.977908496134280 0.988954248067140]
- a =[1.000000000000000 -1.977786483776764 0.978030508491796]*/
- a1 = 1.977786483776764f;
- a2 = -0.978030508491796f;
- b1 = -1.977908496134280f;
- b2 = 0.988954248067140f;
- }
- else if ( Fs == 16000 )
- {
- /* hp filter 20Hz at 3dB for 16000KHz sampling rate
- [b,a] = butter(2, 20.0/8000.0, 'high');
- b =[ 0.994461788958195 -1.988923577916390 0.994461788958195]
- a =[1.000000000000000 -1.988892905899653 0.988954249933127] */
- a1 = 1.988892905899653f;
- a2 = -0.988954249933127f;
- b1 = -1.988923577916390f;
- b2 = 0.994461788958195f;
- }
- else if ( Fs == 32000 )
- {
- /* hp filter 20Hz at 3dB for 32000KHz sampling rate
- [b,a] = butter(2, 20.0/16000.0, 'high');
- b =[0.997227049904470 -1.994454099808940 0.997227049904470]
- a =[1.000000000000000 -1.994446410541927 0.994461789075954]*/
- a1 = 1.994446410541927f;
- a2 = -0.994461789075954f;
- b1 = -1.994454099808940f;
- b2 = 0.997227049904470f;
- }
- else
- {
- /* hp filter 20Hz at 3dB for 48000KHz sampling rate
- [b,a] = butter(2, 20.0/24000.0, 'high');
- b =[ 0.998150511190452 -1.996301022380904 0.998150511190452]
- a =[1.000000000000000 -1.996297601769122 0.996304442992686]*/
- a1 = 1.996297601769122f;
- a2 = -0.996304442992686f;
- b1 = -1.996301022380904f;
- b2 = 0.998150511190452f;
- }
-
- for ( i = 0; i < lg; i++ )
- {
- x2 = x1;
- x1 = x0;
- x0 = signal[i];
- y0 = ( y1 * a1 ) + ( y2 * a2 ) + ( x0 * b2 ) + ( x1 * b1 ) + ( x2 * b2 );
- signal[i] = y0;
- y2 = y1;
- y1 = y0;
- }
-
- mem[0] = ( ( y1 > 1e-10 ) | ( y1 < -1e-10 ) ) ? y1 : 0;
- mem[1] = ( ( y2 > 1e-10 ) | ( y2 < -1e-10 ) ) ? y2 : 0;
- mem[2] = ( ( x0 > 1e-10 ) | ( x0 < -1e-10 ) ) ? x0 : 0;
- mem[3] = ( ( x1 > 1e-10 ) | ( x1 < -1e-10 ) ) ? x1 : 0;
-
- return;
-}
-#endif
-
#define HP20_COEFF_SCALE ( 2 )
-#ifdef IVAS_FLOAT_FIXED
/*
* hp20
*
@@ -797,4 +715,3 @@ void hp20_fx_32(
return;
}
#endif
-#endif
diff --git a/lib_com/ivas_fb_mixer.c b/lib_com/ivas_fb_mixer.c
index 44135df2f48931e4c6bdedf0e95380cd8e605abf..bfa5a7bb92e82a590ff7d93a1296ae3cc4f6d67f 100644
--- a/lib_com/ivas_fb_mixer.c
+++ b/lib_com/ivas_fb_mixer.c
@@ -743,6 +743,7 @@ void ivas_fb_mixer_process_fx(
const Word32 *pFilterbank_bin_to_band_re_fx;
const Word32 *pFilterbank_bin_to_band_im_fx;
+ Word16 q_pMdft_out_fx[2];
Word32 *pMdft_out_fx[2];
Word32 *pOut_fr_re_fx, *pOut_fr_im_fx;
Word16 q_pOut_fr_fx = 31;
@@ -837,11 +838,17 @@ void ivas_fb_mixer_process_fx(
move16();
}
}
+ Word16 scale = sub( s_min( L_norm_arr( pOut_fr_re_fx, frame_len ), L_norm_arr( pOut_fr_im_fx, frame_len ) ), find_guarded_bits_fx( shl( frame_len, 1 ) ) );
+ scale_sig32( pOut_fr_re_fx, frame_len, scale );
+ scale_sig32( pOut_fr_im_fx, frame_len, scale );
ivas_imdft_fx( pOut_fr_re_fx, pOut_fr_im_fx, pMdft_out_fx[hist], frame_len );
+ q_pMdft_out_fx[hist] = add( q_pOut_fr_fx, scale );
+ move16();
}
-
+ scale_sig32( pMdft_out_fx[0], shl( frame_len, 1 ), sub( s_min( q_pMdft_out_fx[0], q_pMdft_out_fx[1] ), q_pMdft_out_fx[0] ) );
+ scale_sig32( pMdft_out_fx[1], shl( frame_len, 1 ), sub( s_min( q_pMdft_out_fx[0], q_pMdft_out_fx[1] ), q_pMdft_out_fx[1] ) );
ivas_fb_mixer_cross_fading_fx( hFbMixer, ppOut_pcm_fx, pMdft_out_fx[0], pMdft_out_fx[1], ch, frame_len, frame_len );
- q_ppOut_pcm_fx[ch] = q_pOut_fr_fx;
+ q_ppOut_pcm_fx[ch] = s_min( q_pMdft_out_fx[0], q_pMdft_out_fx[1] );
move16();
}
@@ -853,7 +860,6 @@ void ivas_fb_mixer_process_fx(
*
*
*-----------------------------------------------------------------------------------------*/
-#ifdef IVAS_FLOAT_FIXED
void ivas_fb_mixer_get_in_out_mapping_fx(
const IVAS_FB_CFG *fb_cfg, /* i : FB config. handle */
Word16 in_out_mixer_map[IVAS_MAX_FB_MIXER_OUT_CH][IVAS_MAX_SPAR_FB_MIXER_IN_CH] /* i/o: mixing mapping */
@@ -887,7 +893,6 @@ void ivas_fb_mixer_get_in_out_mapping_fx(
return;
}
-#endif
/*-----------------------------------------------------------------------------------------*
* Function ivas_calculate_abs_fr()
diff --git a/lib_com/ivas_ism_com.c b/lib_com/ivas_ism_com.c
index 283f79cf18527eae065088750e430f2e1472ff30..1dd7f0f8784132b4f3c550fc6d28041dc2058e00 100644
--- a/lib_com/ivas_ism_com.c
+++ b/lib_com/ivas_ism_com.c
@@ -49,13 +49,7 @@
* Local constants
*-----------------------------------------------------------------------*/
-#define BITS_ISM_INACTIVE ( BRATE_ISM_INACTIVE / FRAMES_PER_SEC )
-
-#ifndef IVAS_FLOAT_FIXED
-#define BETA_ISM_LOW_IMP 0.6f
-#define BETA_ISM_MEDIUM_IMP 0.8f
-#endif
-
+#define BITS_ISM_INACTIVE ( BRATE_ISM_INACTIVE / FRAMES_PER_SEC )
#define BETA_ISM_LOW_IMP_Q31 ( 1288490189 ) // 0.6 in Q31
#define BETA_ISM_MEDIUM_IMP_Q31 ( 1717986918 ) // 0.8 in Q31
#define BETA_ISM_MEDIUM_IMP_BY_8_Q31 ( 214748365 ) // 0.8 in Q29
diff --git a/lib_com/ivas_prot.h b/lib_com/ivas_prot.h
index 46eb5f12a6aae256f1dc4d5f98fa79375d42d06b..87ddacd3d5494909772f56bcee578bd6c4f5187d 100644
--- a/lib_com/ivas_prot.h
+++ b/lib_com/ivas_prot.h
@@ -286,20 +286,6 @@ ivas_error pre_proc_ivas(
Word16 *Q_new
);
/*! r: number of clipped samples */
-uint32_t ivas_syn_output(
- float *synth[], /* i/o: float synthesis signal */
- const int16_t output_frame, /* i : output frame length (one channel) */
- const int16_t n_channels, /* i : number of output channels */
- int16_t *synth_out /* o : integer 16 bits synthesis signal */
-);
-
-void ivas_syn_output_f(
- float *synth[], /* i/o: float synthesis signal */
- const int16_t output_frame, /* i : output frame length (one channel) */
- const int16_t n_channels, /* i : number of output channels */
- float *synth_out /* o : integer 16 bits synthesis signal */
-);
-
void ivas_initialize_handles_enc(
Encoder_Struct *st_ivas /* i/o: IVAS encoder structure */
);
@@ -654,11 +640,6 @@ void TonalMdctConceal_whiten_noise_shape_ivas(
const TONALMDCTCONC_NOISE_SHAPE_WHITENING_MODE
);
-
-float rand_triangular_signed(
- int16_t *seed );
-
-
void dtx_read_padding_bits(
DEC_CORE_HANDLE st,
const int16_t num_bits
@@ -945,18 +926,6 @@ void update_last_metadata(
const int16_t updt_flag[] /* i : last metadata update flag */
);
-#ifndef IVAS_FLOAT_FIXED
-void ivas_get_ism_sid_quan_bitbudget(
- const int16_t nchan_ism, /* i : number of objects */
- int16_t *nBits_azimuth, /* o : number of Q bits for azimuth */
- int16_t *nBits_elevation, /* o : number of Q bits for elevation */
- float *q_step, /* o : quantization step */
- float *q_step_border, /* o : quantization step at the border */
- int16_t *nBits_coh, /* o : number of Q bits for coherence */
- int16_t *nBits_sce_id /* o : number of Q bits for sce_id_dtx */
-);
-#endif
-
void ivas_ism_dtx_limit_noise_energy_for_near_silence(
SCE_DEC_HANDLE hSCE[], /* i/o: SCE decoder structures */
const int16_t sce_id_dtx, /* i : SCE DTX ID */
@@ -1993,28 +1962,6 @@ void convert_coeffs_to_higher_res(
const int16_t len /* i : length of subframes */
);
-#ifndef IVAS_FLOAT_FIXED
-void sns_compute_scf(
- float spectrum[],
- const PsychoacousticParameters *pPsychParams,
- const int16_t L_frame,
- float *scf
-);
-
-void sns_interpolate_scalefactors(
- float *scf_int, /* o : interpolated scalefactors for spectrum shaping */
- const float *scf, /* i : sns scalefactors as derived from the signal or read from the bitstream */
- int16_t encoder_side /* i : flag, if scalefactors have to be inverted */
-);
-
-void sns_shape_spectrum(
- float spectrum[], /* i/o: spectrum to be shaped */
- const PsychoacousticParameters *pPsychParams, /* i : psychoacoustic parameters used to get the frequency bands */
- const float *scf_int, /* i : already interpolated SNS scalefactors */
- const int16_t L_frame /* i : frame length */
-);
-#endif
-
int16_t quantize_sns(
float sns_in[CPE_CHANNELS][NB_DIV][M],
float snsQ_out[CPE_CHANNELS][NB_DIV][M],
@@ -2186,112 +2133,13 @@ void dtx_enc_init(
* Framework general prototypes
*----------------------------------------------------------------------------------*/
-void mvr2r_inc(
- const float x[], /* i : input vector */
- const int16_t x_inc, /* i : increment for vector x[] */
- float y[], /* o : output vector */
- const int16_t y_inc, /* i : increment for vector y[] */
- const int16_t n /* i : vector size */
-);
-
-void v_add_inc(
- const float x1[], /* i : Input vector 1 */
- const int16_t x_inc, /* i : Increment for input vector 1 */
- const float x2[], /* i : Input vector 2 */
- const int16_t x2_inc, /* i : Increment for input vector 2 */
- float y[], /* o : Output vector that contains vector 1 + vector 2 */
- const int16_t y_inc, /* i : increment for vector y[] */
- const int16_t N /* i : Vector length */
-);
-
-void v_mult_inc(
- const float x1[], /* i : Input vector 1 */
- const int16_t x1_inc, /* i : Increment for input vector 1 */
- const float x2[], /* i : Input vector 2 */
- const int16_t x2_inc, /* i : Increment for input vector 1 */
- float y[], /* o : Output vector that contains vector 1 .* vector 2 */
- const int16_t y_inc, /* i : increment for vector y[] */
- const int16_t N /* i : Vector length */
-);
-
-void v_addc(
- const float x[], /* i : Input vector */
- const float c, /* i : Constant */
- float y[], /* o : Output vector that contains c*x */
- const int16_t N /* i : Vector length */
-);
-
-void v_min(
- const float x1[], /* i : Input vector 1 */
- const float x2[], /* i : Input vector 2 */
- float y[], /* o : Output vector that contains vector 1 .* vector 2 */
- const int16_t N /* i : Vector length */
-);
-
-void v_sqrt(
- const float x[], /* i : Input vector */
- float y[], /* o : Output vector that contains sqrt(x) */
- const int16_t N /* i : Vector length */
-);
-
-/*! r: sum abs of all vector elements */
-float sumAbs(
- const float *vec, /* i : input vector */
- const int16_t lvec /* i : length of input vector */
-);
-
void mvc2c(
const uint8_t x[], /* i : input vector */
uint8_t y[], /* o : output vector */
const int16_t n /* i : vector size */
);
-/*! r: the dot product x'*A*A'*x */
-float dot_product_cholesky(
- const float *x, /* i : vector x */
- const float *A, /* i : Cholesky matrix A */
- const int16_t N /* i : vector & matrix size */
-);
-
-void v_mult_mat(
- float *y, /* o : the product x*A */
- const float *x, /* i : vector x */
- const float *A, /* i : matrix A */
- const int16_t N, /* i : number of rows */
- const int16_t C /* i : number of columns */
-);
-
-/*! r: log(sum(exp(X)) of the input array X */
-float logsumexp(
- const float X[], /* i : input array X */
- const int16_t N /* i : number of elements in array X */
-);
-
-/*! r: mapped output value */
-float lin_interp(
- const float x, /* i : the value to be mapped */
- const float x1, /* i : source range interval: low end */
- const float y1, /* i : source range interval: high end */
- const float x2, /* i : target range interval: low */
- const float y2, /* i : target range interval: high */
- const int16_t flag_sat /* i : flag to indicate whether to apply saturation */
-);
-
/*! r: Adjusted value */
-float check_bounds(
- const float value, /* i : Input value */
- const float low, /* i : Low limit */
- const float high /* i : High limit */
-);
-
-/*! r: Adjusted value */
-int16_t check_bounds_s(
- const int16_t value, /* i : Input value */
- const int16_t low, /* i : Low limit */
- const int16_t high /* i : High limit */
-);
-
-
ivas_error stereo_memory_dec(
const int32_t ivas_total_brate, /* i : IVAS total bitrate */
CPE_DEC_HANDLE hCPE, /* i : CPE decoder structure */
@@ -2380,15 +2228,6 @@ void write_mct_bitstream(
const int16_t nchan /* i : number of channels */
);
-#ifndef IVAS_FLOAT_FIXED
-void splitAvailableBitsMCT(
- void **sts, /* i/o: encoder/decoder state structure */
- const int16_t total_bits, /* i : total number of available bits */
- const int16_t split_ratio[MCT_MAX_CHANNELS], /* i : ratio for splitting the bits */
- const int16_t enc_dec, /* i : encoder or decoder flag */
- const int16_t nchan /* i : number of channels */
-);
-#else
void splitAvailableBitsMCT_fx(
void **sts, /* i/o: encoder/decoder state structure */
const Word16 total_bits, /* i : total number of available bits */
@@ -2396,7 +2235,6 @@ void splitAvailableBitsMCT_fx(
const Word16 enc_dec, /* i : encoder or decoder flag */
const Word16 nchan /* i : number of channels */
);
-#endif
void getChannelEnergies(
Encoder_State **sts, /* i : Encoder state structure */
@@ -2488,14 +2326,6 @@ void mctStereoIGF_dec(
const int16_t bfi /* i : bad frame flag */
);
-#ifndef IVAS_FLOAT_FIXED
-void ivas_mdct_tcx10_bit_distribution(
- int16_t target_bitsTCX10[NB_DIV], /* o : target bit distribution */
- const int16_t bits_frame_channel, /* i : bits frame channel */
- const int16_t nTnsBitsTCX10[NB_DIV] /* i : TNS bits */
-);
-#endif
-
void enc_prm_igf_mdct(
Encoder_State *st, /* i : Encoder state handle */
BSTR_ENC_HANDLE hBstr /* i/o: Bitstream handle */
@@ -2524,21 +2354,12 @@ ivas_error ivas_qmetadata_enc_encode_hr_384_512(
const int16_t bits_sp_coh
);
-#ifndef IVAS_FLOAT_FIXED
void deindex_sph_idx(
const uint16_t sphIndex, /* i : Spherical index */
const SPHERICAL_GRID_DATA *gridData, /* i : Prepared spherical grid */
float *theta, /* o : Elevation */
float *phi /* o : Azimuth */
);
-#else
-void deindex_sph_idx_fx(
- const UWord16 sphIndex, /* i : Spherical index */
- const SPHERICAL_GRID_DATA *gridData, /* i : Prepared spherical grid */
- Word32 *theta_fx, /* o : Elevation Q22*/
- Word32 *phi_fx /* o : Azimuth Q22 */
-);
-#endif
/*! r: output index for direction */
uint16_t index_theta_phi_16(
@@ -2609,14 +2430,6 @@ void ivas_qmetadata_azimuth_elevation_to_direction_vector(
float *dv /* o : direction vector */
);
-#ifndef IVAS_FLOAT_FIXED
-void ivas_qmetadata_direction_vector_to_azimuth_elevation(
- const float *dv, /* i : direction vector */
- float *az, /* o : azimuth */
- float *el /* o : elevation */
-);
-#endif
-
ivas_error only_reduce_bits_direction(
int16_t *reduce_bits_out,
IVAS_QDIRECTION *q_direction, /* i/o: quantized direction structure */
@@ -2653,32 +2466,6 @@ int16_t quantize_direction2D(
const MC_LS_SETUP mc_format /* i : channel format if in MC-mode */
);
-#ifndef IVAS_FLOAT_FIXED
-/*! r :companded azimuth value */
-float companding_azimuth(
- const float azi, /* i : input azimuth value */
- const MC_LS_SETUP mc_format, /* i : input channel format */
- const int16_t theta_flag, /* i : zero/non zero elevation flag */
- const int16_t direction /* i : direction of companding (direct or inverse)*/
-);
-
-/*! r: index azimuth */
-int16_t quantize_phi_chan_lbr(
- const float phi, /* i : azimuth value */
- float *phi_hat, /* o : quantized azimuth */
- const int16_t n /* i : azimuth codebook size */
-);
-
-/*! r: index azimuth */
-int16_t quantize_phi_chan_compand(
- float phi, /* i : azimuth value */
- float *phi_hat, /* o : quantized azimuth */
- const int16_t n, /* i : azimuth codebook size */
- const int16_t theta_flag, /* i : flag signaling high elevation */
- const MC_LS_SETUP mc_format /* i : channel format if in MC-mode */
-);
-#endif
-
void quantize_direction_frame2D(
IVAS_QDIRECTION *q_direction, /* i/o: quantized direction structure */
float azimuth_orig[MASA_MAXIMUM_CODING_SUBBANDS][MAX_PARAM_SPATIAL_SUBFRAMES], /* i : input azimuth values */
@@ -3018,63 +2805,6 @@ UWord16 ivas_param_mc_get_configuration_index_fx(
const Word32 ivas_total_brate /* i : IVAS total bitrate */
);
-int16_t matrix_product(
- const float *X, /* i : left hand matrix */
- const int16_t rowsX, /* i : number of rows of the left hand matrix */
- const int16_t colsX, /* i : number of columns of the left hand matrix */
- const int16_t transpX, /* i : flag indicating the transposition of the left hand matrix prior to the multiplication */
- const float *Y, /* i : right hand matrix */
- const int16_t rowsY, /* i : number of rows of the right hand matrix */
- const int16_t colsY, /* i : number of columns of the right hand matrix */
- const int16_t transpY, /* i : flag indicating the transposition of the right hand matrix prior to the multiplication */
- float *Z /* o : resulting matrix after the matrix multiplication */
-);
-
-
-int16_t matrix_diag_product(
- const float *X, /* i : left hand matrix */
- const int16_t rowsX, /* i : number of rows of the left hand matrix */
- const int16_t colsX, /* i : number of columns of the left hand matrix */
- const int16_t transpX, /* i : flag indicating the transposition of the left hand matrix prior to the multiplication */
- const float *Y, /* i : right hand diagonal matrix as vector containing the diagonal elements */
- const int16_t entriesY, /* i : number of entries in the diagonal */
- float *Z /* o : resulting matrix after the matrix multiplication */
-);
-
-int16_t diag_matrix_product(
- const float *Y, /* i : left hand diagonal matrix as vector containing the diagonal elements */
- const int16_t entriesY, /* i : length of the diagonal of the left hand matrix */
- const float *X, /* i : right hand matrix */
- const int16_t rowsX, /* i : number of rows of the right hand matrix */
- const int16_t colsX, /* i : number of columns of the right hand matrix */
- const int16_t transpX, /* i : flag indicating the transposition of the right hand matrix prior to the multiplication */
- float *Z /* o : resulting matrix after the matrix multiplication */
-);
-
-int16_t matrix_product_diag(
- const float *X, /* i : left hand matrix */
- const int16_t rowsX, /* i : number of rows of the left hand matrix */
- const int16_t colsX, /* i : number of columns of the left hand matrix */
- const int16_t transpX, /* i : flag indicating the transposition of the left hand matrix prior to the multiplication */
- const float *Y, /* i : right hand matrix */
- const int16_t rowsY, /* i : number of rows of the right hand matrix */
- const int16_t colsY, /* i : number of columns of the right hand matrix */
- const int16_t transpY, /* i : flag indicating the transposition of the right hand matrix prior to the multiplication */
- float *Z /* o : resulting matrix after the matrix multiplication */
-);
-
-void cmplx_matrix_square(
- const float *realX, /* i : real part of the matrix */
- const float *imagX, /* i : imaginary part of the matrix */
- const int16_t mRows, /* i : number of rows of the matrix */
- const int16_t nCols, /* i : number of columns of the matrix */
- float *realZ, /* o : real part of the resulting matrix */
- float *imagZ /* o : imaginary part of the resulting matrix */
-);
-
-
-
-
ivas_error ivas_dirac_dec_output_synthesis_cov_open(
DIRAC_OUTPUT_SYNTHESIS_PARAMS *h_dirac_output_synthesis_params, /* i/o: handle for the covariance synthesis parameters */
DIRAC_OUTPUT_SYNTHESIS_COV_STATE *h_dirac_output_synthesis_state, /* i/o: handle for the covariance synthesis state */
@@ -3609,74 +3339,6 @@ void ivas_pca_dec(
float *pcm_out[] /* o : output audio channels */
);
-#ifndef IVAS_FLOAT_FIXED
-/* PCA utilities */
-void eye_matrix(
- float *mat,
- const int16_t n,
- const float d
-);
-
-void cov_subfr(
- float **ptr_sig,
- float *r,
- const int16_t n_channels,
- const int16_t len
-);
-
-void eig_qr(
- const float *A,
- const int16_t num_iter,
- float *EV, float *Vals,
- const int16_t n
-);
-
-void exhst_4x4(
- float *cost_mtx,
- int16_t *path,
- const int16_t maximize
-);
-
-float mat_det4(
- const float *m
-);
-
-/* quaternion utilities */
-void mat2dquat(
- const float *a,
- float *ql,
- float *qr
-);
-
-void dquat2mat(
- const float *ql,
- const float *qr,
- float *m
-);
-
-void quat_shortestpath(
- const float *q00,
- float *q01,
- const float *q10,
- float *q11
-);
-
-void pca_interp_preproc(
- const float *prev_ql,
- const float *prev_qr,
- const float *ql,
- const float *qr,
- const int16_t len,
- float *ql_interp,
- float *qr_interp
-);
-
-void pca_enc_s3(
- float *q,
- int32_t *index
-);
-#endif
-
void pca_dec_s3(
const int32_t index,
float *q
@@ -3917,14 +3579,6 @@ int16_t calculate_brate_limit_flag(
const int16_t nchan_ism /* i : number of objects */
);
-#ifndef IVAS_FLOAT_FIXED
-void ivas_get_stereo_panning_gains(
- const float aziDeg,
- const float eleDeg,
- float panningGains[2]
-);
-#endif
-
void ivas_masa_set_coding_config(
MASA_CODEC_CONFIG* config, /* i/o: MASA coding config structure */
int16_t* band_mapping, /* o : Band mapping used */
@@ -3949,19 +3603,10 @@ void masa_compensate_two_dir_energy_ratio_index(
const int16_t hodirac_flag /* i : flag to indicate HO-DirAC mode */
);
-#ifndef IVAS_FLOAT_FIXED
-void ivas_set_qmetadata_maxbit_req(
- IVAS_QMETADATA_HANDLE hQMetaData, /* o : qmetadata structure where the requirement value is set */
- const IVAS_FORMAT ivas_format /* i : IVAS format */
-);
-#else
void ivas_set_qmetadata_maxbit_req_fx(
IVAS_QMETADATA_HANDLE hQMetaData, /* o : qmetadata structure where the requirement value is set */
const IVAS_FORMAT ivas_format /* i : IVAS format */
);
-#endif
-
-
void masa_sample_rate_band_correction(
MASA_CODEC_CONFIG *config, /* i/o: MASA codec config */
@@ -4061,12 +3706,6 @@ void panning_wrap_angles(
float *ele_wrapped /* o : wrapped elevation component */
);
-void v_sort_ind(
- float *x, /* i/o: Vector to be sorted */
- int16_t *idx, /* o : Original index positions */
- const int16_t len /* i : vector length */
-);
-
/*----------------------------------------------------------------------------------*
* LS Renderer prototypes
*----------------------------------------------------------------------------------*/
@@ -4155,22 +3794,6 @@ void ivas_mcmasa_dmx_modify_fx(
const Word16 n_chnls_dmx_new /* i : number of downmix channels in the target format Q0*/
);
-void v_multc_acc(
- const float x[], /* i : Input vector */
- const float c, /* i : Constant */
- float y[], /* o : Output vector that contains y + c*x */
- const int16_t N /* i : Vector length */
-);
-
-void lls_interp_n(
- float x[], /* i/o: input/output vector */
- const int16_t N, /* i : length of the input vector */
- float *a, /* o : calculated slope */
- float *b, /* o : calculated offset */
- const int16_t upd /* i : use 1 to update x[] with the interpolated output*/
-);
-
-
ivas_error ivas_mono_dmx_renderer_open(
Decoder_Struct *st_ivas /* i/o: IVAS decoder structure */
);
diff --git a/lib_com/ivas_rom_com.c b/lib_com/ivas_rom_com.c
index a86f2913c2aecf07b420bf450b9106eab8b7d9a4..5a864835cf67f9c253d74e680c78ae94eb14a267 100644
--- a/lib_com/ivas_rom_com.c
+++ b/lib_com/ivas_rom_com.c
@@ -464,25 +464,6 @@ const UWord16 ECSQ_tab_inverse[1 + ECSQ_SEGMENT_SIZE] =
};
-/*-------------------------------------------------------------------------
- * Stereo ICA analysis ROM tables
- *------------------------------------------------------------------------*/
-const float ica_sincInterp2[2*SINC_ORDER1+1] =
-{
- 0.0f,-0.002323f,0.0f, 0.003486f, 0.0f,-0.005865f,0.0f, 0.009735f, 0.0f,-0.015447f,0.0f, 0.023503f,
- 0.0f,-0.034727f,0.0f, 0.050649f, 0.0f,-0.074578f,0.0f, 0.115220f, 0.0f,-0.204776f,0.0f, 0.634114f,
- 1.0f, 0.634114f,0.0f,-0.204776f, 0.0f, 0.115220f,0.0f,-0.074578f, 0.0f, 0.050649f,0.0f,-0.034727f,
- 0.0f, 0.023503f,0.0f,-0.015447f, 0.0f, 0.009735f,0.0f,-0.005865f, 0.0f, 0.003486f,0.0f,-0.002323f, 0.0f
-};
-const float ica_sincInterp4[2*SINC_ORDER1+1] =
-{
- 0.0f,-0.003285f,-0.005537f,-0.004930f, 0.0f, 0.008295f, 0.015189f, 0.013767f, 0.0f,-0.021845f,-0.038282f,-0.033239f,
- 0.0f, 0.049111f, 0.083913f, 0.071628f, 0.0f,-0.105469f,-0.183615f,-0.162946f, 0.0f, 0.289597f, 0.626641f, 0.896773f,
- 1.0f, 0.896773f, 0.626641f, 0.289597f, 0.0f,-0.162946f,-0.183615f,-0.105469f, 0.0f, 0.071628f, 0.083913f, 0.049111f,
- 0.0f,-0.033239f,-0.038282f,-0.021845f, 0.0f, 0.013767f, 0.015189f, 0.008295f, 0.0f,-0.004930f,-0.005537f,-0.003285f, 0.0f
-};
-
-
const Word16 tdm_bit_allc_tbl[5][6] =
{
/* IC -- UC -- GC -- TM --AC */
@@ -494,41 +475,6 @@ const Word16 tdm_bit_allc_tbl[5][6] =
};
-const float tdm_LSF_MEAN_PRED_QNT[M] =
-{
- 391.31345F, 608.50453F, 968.00585F, 1354.23965F, 1709.71084F, 2080.49872F, 2450.64009F, 2796.96588F,
- 3196.19608F, 3554.17092F, 3915.02370F, 4283.81121F, 4707.59835F, 5109.79026F, 5526.44936F, 5903.42625F
-};
-
-const float tdm_LSF_MEAN_PRED_QNT_IN[M] =
-{
- 288.540f, 535.469f, 899.738f, 1342.313f, 1730.736f, 2107.070f, 2491.455f, 2859.828f, 3239.279f, 3625.673f, 3992.540f, 4356.748f, 4752.356f, 5153.685f, 5567.107f, 5972.623f,
-};
-const float tdm_LSF_MEAN_PRED_QNT_OUT[M] =
-{
- 286.414f, 522.366f, 887.297f, 1347.961f, 1725.604f, 2102.356f, 2511.703f, 2853.093f, 3211.319f, 3612.072f, 3970.889f, 4327.774f, 4732.423f, 5154.984f, 5572.849f, 5964.332f,
-};
-
-const float tdm_PRED_QNT_fixed_beta_prd_diag_3[15 + 16 + 15] =
-{
- 0.7040f, 0.1203f,
- -0.1119f, 0.7340f, 0.1803f,
- 0.0253f, 0.6702f, 0.1901f,
- -0.1847f, 0.7892f, 0.3010f,
- -0.0418f, 0.8716f, 0.1837f,
- 0.0033f, 0.6915f, 0.2394f,
- 0.0213f, 0.6728f, 0.2441f,
- 0.0705f, 0.7549f, 0.1983f,
- 0.0752f, 0.7152f, 0.2173f,
- 0.0886f, 0.6163f, 0.3067f,
- 0.0217f, 0.8121f, 0.2021f,
- 0.1584f, 0.7311f, 0.1746f,
- 0.1204f, 0.7296f, 0.1978f,
- 0.1231f, 0.7502f, 0.1234f,
- 0.1709f, 0.6372f, 0.1060f,
- 0.1193f, 0.6574f,
-};
-
const Word16 fast_FCB_bits_2sfr[] = {8, 14, 18, 20, 24, 128/*stop value*/};
const Word16 fast_FCB_rates_2sfr[] = {/*16*50,*/ (8+14)*50, 28*50, 32*50, 34*50, 36*50, 38*50, 40*50, 42*50, 44*50, 48*50};
@@ -2534,22 +2480,22 @@ const Word16 mcmasa_bits[IVAS_NUM_ACTIVE_BRATES] =
50, 70, 80, 120, 140, 160, 220, 256, 288, 432, 528, 832, 1024, MASA_MAX_BITS
};
-const uint8_t masa_nbands[IVAS_NUM_ACTIVE_BRATES] =
+const UWord8 masa_nbands[IVAS_NUM_ACTIVE_BRATES] =
{
5, 5, 5, 5, 5, 5, 5, 5, 8, 12, 18, 24, 24, 24
};
-const uint8_t masa_joined_nbands[IVAS_NUM_ACTIVE_BRATES] =
+const UWord8 masa_joined_nbands[IVAS_NUM_ACTIVE_BRATES] =
{
5, 5, 5, 8, 12, 12, 12, 18, 18, 18, 18, 24, 24, 24
};
-const uint8_t masa_twodir_bands[IVAS_NUM_ACTIVE_BRATES] =
+const UWord8 masa_twodir_bands[IVAS_NUM_ACTIVE_BRATES] =
{
0, 0, 0, 0, 0, 1, 1, 1, 3, 4, 6, 6, 9, 24
};
-const uint8_t masa_twodir_bands_joined[IVAS_NUM_ACTIVE_BRATES] =
+const UWord8 masa_twodir_bands_joined[IVAS_NUM_ACTIVE_BRATES] =
{
0, 0, 0, 0, 0, 2, 2, 3, 4, 6, 8, 9, 12, MASA_MAXIMUM_TWO_DIR_BANDS
};
@@ -2646,291 +2592,6 @@ const Word16 dirac_gains_P_idx[16] =
-1, 1, 0, 1, 4, 3, 2, 3, 4, 8, 7, 6, 5, 6, 7, 8
};
-const float dirac_gains_norm_term[9] =
-{
- 1.000000e+00f, 7.071068e-01f, 1.000000e+00f, 4.082483e-01f, 2.041242e-01f, 1.000000e+00f, 2.886751e-01f, 9.128709e-02f, 3.726780e-02f
-};
-
-const float dirac_gains_Pnm[91][9] =
-{
- {-1.000000e+00f,-0.000000e+00f,1.000000e+00f,-0.000000e+00f,0.000000e+00f,-1.000000e+00f,-0.000000e+00f,0.000000e+00f,-0.000000e+00f},
- {-9.998477e-01f,1.745221e-02f,9.995431e-01f,-5.234867e-02f,9.137391e-04f,-9.990864e-01f,1.046734e-01f,-4.568000e-03f,7.973384e-05f},
- {-9.993909e-01f,3.489930e-02f,9.981732e-01f,-1.046341e-01f,3.653884e-03f,-9.963478e-01f,2.090770e-01f,-1.825829e-02f,6.375900e-04f},
- {-9.986295e-01f,5.233614e-02f,9.958913e-01f,-1.567932e-01f,8.217215e-03f,-9.917910e-01f,3.129416e-01f,-4.102976e-02f,2.150287e-03f},
- {-9.975641e-01f,6.975590e-02f,9.927012e-01f,-2.087579e-01f,1.459766e-02f,-9.854290e-01f,4.159897e-01f,-7.281048e-02f,5.091363e-03f},
- {-9.961947e-01f,8.715547e-02f,9.886059e-01f,-2.604715e-01f,2.278823e-02f,-9.772766e-01f,5.179674e-01f,-1.135075e-01f,9.930593e-03f},
- {-9.945220e-01f,1.045284e-01f,9.836106e-01f,-3.118673e-01f,3.277856e-02f,-9.673560e-01f,6.186047e-01f,-1.629950e-01f,1.713145e-02f},
- {-9.925461e-01f,1.218695e-01f,9.777218e-01f,-3.628832e-01f,4.455650e-02f,-9.556924e-01f,7.176415e-01f,-2.211219e-01f,2.715038e-02f},
- {-9.902681e-01f,1.391732e-01f,9.709461e-01f,-4.134564e-01f,5.810756e-02f,-9.423163e-01f,8.148217e-01f,-2.877103e-01f,4.043508e-02f},
- {-9.876884e-01f,1.564343e-01f,9.632925e-01f,-4.635251e-01f,7.341509e-02f,-9.272624e-01f,9.098945e-01f,-3.625562e-01f,5.742321e-02f},
- {-9.848077e-01f,1.736484e-01f,9.547693e-01f,-5.130307e-01f,9.046126e-02f,-9.105685e-01f,1.002619e+00f,-4.454347e-01f,7.854224e-02f},
- {-9.816272e-01f,1.908091e-01f,9.453878e-01f,-5.619103e-01f,1.092244e-01f,-8.922793e-01f,1.092752e+00f,-5.360881e-01f,1.042050e-01f},
- {-9.781475e-01f,2.079115e-01f,9.351591e-01f,-6.101044e-01f,1.296816e-01f,-8.724410e-01f,1.180063e+00f,-6.342387e-01f,1.348115e-01f},
- {-9.743701e-01f,2.249510e-01f,9.240957e-01f,-6.575567e-01f,1.518089e-01f,-8.511051e-01f,1.264332e+00f,-7.395903e-01f,1.707479e-01f},
- {-9.702957e-01f,2.419219e-01f,9.122107e-01f,-7.042075e-01f,1.755787e-01f,-8.283265e-01f,1.345341e+00f,-8.518162e-01f,2.123816e-01f},
- {-9.659258e-01f,2.588191e-01f,8.995191e-01f,-7.500002e-01f,2.009620e-01f,-8.041639e-01f,1.422883e+00f,-9.705719e-01f,2.600640e-01f},
- {-9.612616e-01f,2.756374e-01f,8.860360e-01f,-7.948789e-01f,2.279279e-01f,-7.786796e-01f,1.496760e+00f,-1.095492e+00f,3.141272e-01f},
- {-9.563048e-01f,2.923716e-01f,8.717782e-01f,-8.387891e-01f,2.564435e-01f,-7.519395e-01f,1.566788e+00f,-1.226191e+00f,3.748840e-01f},
- {-9.510565e-01f,3.090171e-01f,8.567626e-01f,-8.816782e-01f,2.864747e-01f,-7.240118e-01f,1.632789e+00f,-1.362268e+00f,4.426280e-01f},
- {-9.455186e-01f,3.255681e-01f,8.410082e-01f,-9.234920e-01f,3.179837e-01f,-6.949692e-01f,1.694595e+00f,-1.503298e+00f,5.176268e-01f},
- {-9.396926e-01f,3.420202e-01f,8.245332e-01f,-9.641815e-01f,3.509334e-01f,-6.648846e-01f,1.752055e+00f,-1.648848e+00f,6.001316e-01f},
- {-9.335804e-01f,3.583678e-01f,8.073587e-01f,-1.003696e+00f,3.852825e-01f,-6.338369e-01f,1.805025e+00f,-1.798461e+00f,6.903643e-01f},
- {-9.271840e-01f,3.746064e-01f,7.895051e-01f,-1.041987e+00f,4.209899e-01f,-6.019047e-01f,1.853375e+00f,-1.951675e+00f,7.885275e-01f},
- {-9.205049e-01f,3.907311e-01f,7.709939e-01f,-1.079010e+00f,4.580124e-01f,-5.691693e-01f,1.896987e+00f,-2.108013e+00f,8.947984e-01f},
- {-9.135456e-01f,4.067366e-01f,7.518480e-01f,-1.114717e+00f,4.963039e-01f,-5.357154e-01f,1.935757e+00f,-2.266981e+00f,1.009325e+00f},
- {-9.063079e-01f,4.226184e-01f,7.320906e-01f,-1.149067e+00f,5.358188e-01f,-5.016273e-01f,1.969593e+00f,-2.428084e+00f,1.132234e+00f},
- {-8.987941e-01f,4.383712e-01f,7.117461e-01f,-1.182016e+00f,5.765077e-01f,-4.669925e-01f,1.998415e+00f,-2.590808e+00f,1.263622e+00f},
- {-8.910065e-01f,4.539906e-01f,6.908387e-01f,-1.213526e+00f,6.183225e-01f,-4.318987e-01f,2.022162e+00f,-2.754647e+00f,1.403563e+00f},
- {-8.829476e-01f,4.694716e-01f,6.693946e-01f,-1.243556e+00f,6.612108e-01f,-3.964354e-01f,2.040781e+00f,-2.919073e+00f,1.552099e+00f},
- {-8.746198e-01f,4.848095e-01f,6.474397e-01f,-1.272072e+00f,7.051207e-01f,-3.606927e-01f,2.054234e+00f,-3.083563e+00f,1.709246e+00f},
- {-8.660253e-01f,5.000000e-01f,6.250001e-01f,-1.299038e+00f,7.500000e-01f,-3.247595e-01f,2.062500e+00f,-3.247595e+00f,1.875000e+00f},
- {-8.571672e-01f,5.150381e-01f,6.021037e-01f,-1.324421e+00f,7.957926e-01f,-2.887278e-01f,2.065570e+00f,-3.410637e+00f,2.049318e+00f},
- {-8.480480e-01f,5.299194e-01f,5.787782e-01f,-1.348191e+00f,8.424437e-01f,-2.526874e-01f,2.063448e+00f,-3.572164e+00f,2.232136e+00f},
- {-8.386706e-01f,5.446391e-01f,5.550525e-01f,-1.370318e+00f,8.898951e-01f,-2.167299e-01f,2.056155e+00f,-3.731644e+00f,2.423358e+00f},
- {-8.290377e-01f,5.591928e-01f,5.309552e-01f,-1.390776e+00f,9.380897e-01f,-1.809446e-01f,2.043725e+00f,-3.888559e+00f,2.622865e+00f},
- {-8.191521e-01f,5.735765e-01f,5.065152e-01f,-1.409539e+00f,9.869699e-01f,-1.454202e-01f,2.026202e+00f,-4.042392e+00f,2.830513e+00f},
- {-8.090171e-01f,5.877852e-01f,4.817629e-01f,-1.426585e+00f,1.036474e+00f,-1.102460e-01f,2.003651e+00f,-4.192627e+00f,3.046121e+00f},
- {-7.986355e-01f,6.018150e-01f,4.567280e-01f,-1.441893e+00f,1.086544e+00f,-7.550830e-02f,1.976144e+00f,-4.338763e+00f,3.269493e+00f},
- {-7.880108e-01f,6.156614e-01f,4.314414e-01f,-1.455444e+00f,1.137117e+00f,-4.129366e-02f,1.943771e+00f,-4.480302e+00f,3.500396e+00f},
- {-7.771459e-01f,6.293205e-01f,4.059335e-01f,-1.467221e+00f,1.188133e+00f,-7.685401e-03f,1.906632e+00f,-4.616763e+00f,3.738582e+00f},
- {-7.660444e-01f,6.427876e-01f,3.802360e-01f,-1.477211e+00f,1.239528e+00f,2.523343e-02f,1.864843e+00f,-4.747667e+00f,3.983766e+00f},
- {-7.547096e-01f,6.560589e-01f,3.543800e-01f,-1.485402e+00f,1.291240e+00f,5.738307e-02f,1.818529e+00f,-4.872555e+00f,4.235647e+00f},
- {-7.431449e-01f,6.691306e-01f,3.283964e-01f,-1.491783e+00f,1.343207e+00f,8.868646e-02f,1.767831e+00f,-4.990988e+00f,4.493906e+00f},
- {-7.313538e-01f,6.819984e-01f,3.023174e-01f,-1.496346e+00f,1.395365e+00f,1.190676e-01f,1.712898e+00f,-5.102528e+00f,4.758184e+00f},
- {-7.193397e-01f,6.946585e-01f,2.761744e-01f,-1.499086e+00f,1.447651e+00f,1.484544e-01f,1.653893e+00f,-5.206765e+00f,5.028115e+00f},
- {-7.071068e-01f,7.071068e-01f,2.500000e-01f,-1.500000e+00f,1.500000e+00f,1.767767e-01f,1.590990e+00f,-5.303301e+00f,5.303301e+00f},
- {-6.946585e-01f,7.193397e-01f,2.238256e-01f,-1.499086e+00f,1.552349e+00f,2.039685e-01f,1.524373e+00f,-5.391762e+00f,5.583331e+00f},
- {-6.819984e-01f,7.313538e-01f,1.976825e-01f,-1.496346e+00f,1.604635e+00f,2.299670e-01f,1.454233e+00f,-5.471792e+00f,5.867779e+00f},
- {-6.691307e-01f,7.431448e-01f,1.716038e-01f,-1.491783e+00f,1.656792e+00f,2.547115e-01f,1.380777e+00f,-5.543053e+00f,6.156183e+00f},
- {-6.560589e-01f,7.547096e-01f,1.456200e-01f,-1.485402e+00f,1.708760e+00f,2.781472e-01f,1.304214e+00f,-5.605237e+00f,6.448089e+00f},
- {-6.427876e-01f,7.660444e-01f,1.197639e-01f,-1.477212e+00f,1.760472e+00f,3.002205e-01f,1.224767e+00f,-5.658049e+00f,6.743000e+00f},
- {-6.293203e-01f,7.771461e-01f,9.406608e-02f,-1.467221e+00f,1.811868e+00f,3.208840e-01f,1.142662e+00f,-5.701226e+00f,7.040430e+00f},
- {-6.156614e-01f,7.880108e-01f,6.855855e-02f,-1.455444e+00f,1.862883e+00f,3.400929e-01f,1.058135e+00f,-5.734527e+00f,7.339859e+00f},
- {-6.018151e-01f,7.986354e-01f,4.327216e-02f,-1.441893e+00f,1.913455e+00f,3.578070e-01f,9.714287e-01f,-5.757732e+00f,7.640767e+00f},
- {-5.877852e-01f,8.090171e-01f,1.823708e-02f,-1.426585e+00f,1.963526e+00f,3.739910e-01f,8.827875e-01f,-5.770657e+00f,7.942629e+00f},
- {-5.735764e-01f,8.191520e-01f,-6.515074e-03f,-1.409539e+00f,2.013030e+00f,3.886124e-01f,7.924678e-01f,-5.773133e+00f,8.244888e+00f},
- {-5.591928e-01f,8.290376e-01f,-3.095508e-02f,-1.390776e+00f,2.061910e+00f,4.016449e-01f,7.007229e-01f,-5.765026e+00f,8.547005e+00f},
- {-5.446391e-01f,8.386706e-01f,-5.505246e-02f,-1.370318e+00f,2.110105e+00f,4.130656e-01f,6.078163e-01f,-5.746228e+00f,8.848414e+00f},
- {-5.299193e-01f,8.480480e-01f,-7.877823e-02f,-1.348191e+00f,2.157557e+00f,4.228564e-01f,5.140093e-01f,-5.716654e+00f,9.148557e+00f},
- {-5.150380e-01f,8.571674e-01f,-1.021038e-01f,-1.324421e+00f,2.204208e+00f,4.310043e-01f,4.195672e-01f,-5.676254e+00f,9.446875e+00f},
- {-5.000001e-01f,8.660253e-01f,-1.249999e-01f,-1.299038e+00f,2.250000e+00f,4.375000e-01f,3.247599e-01f,-5.625000e+00f,9.742785e+00f},
- {-4.848095e-01f,8.746197e-01f,-1.474395e-01f,-1.272072e+00f,2.294879e+00f,4.423398e-01f,2.298521e-01f,-5.562896e+00f,1.003573e+01f},
- {-4.694715e-01f,8.829476e-01f,-1.693947e-01f,-1.243556e+00f,2.338789e+00f,4.455244e-01f,1.351145e-01f,-5.489975e+00f,1.032514e+01f},
- {-4.539906e-01f,8.910065e-01f,-1.908388e-01f,-1.213526e+00f,2.381678e+00f,4.470587e-01f,4.081347e-02f,-5.406296e+00f,1.061045e+01f},
- {-4.383711e-01f,8.987940e-01f,-2.117461e-01f,-1.182016e+00f,2.423492e+00f,4.469530e-01f,-5.278682e-02f,-5.311945e+00f,1.089110e+01f},
- {-4.226183e-01f,9.063078e-01f,-2.320906e-01f,-1.149067e+00f,2.464181e+00f,4.452218e-01f,-1.454199e-01f,-5.207041e+00f,1.116653e+01f},
- {-4.067367e-01f,9.135454e-01f,-2.518479e-01f,-1.114717e+00f,2.503696e+00f,4.418841e-01f,-2.368270e-01f,-5.091725e+00f,1.143620e+01f},
- {-3.907311e-01f,9.205048e-01f,-2.709937e-01f,-1.079010e+00f,2.541987e+00f,4.369636e-01f,-3.267503e-01f,-4.966168e+00f,1.169956e+01f},
- {-3.746066e-01f,9.271839e-01f,-2.895049e-01f,-1.041988e+00f,2.579010e+00f,4.304885e-01f,-4.149371e-01f,-4.830570e+00f,1.195608e+01f},
- {-3.583679e-01f,9.335804e-01f,-3.073587e-01f,-1.003696e+00f,2.614717e+00f,4.224911e-01f,-5.011396e-01f,-4.685155e+00f,1.220525e+01f},
- {-3.420201e-01f,9.396927e-01f,-3.245333e-01f,-9.641814e-01f,2.649067e+00f,4.130083e-01f,-5.851153e-01f,-4.530170e+00f,1.244654e+01f},
- {-3.255681e-01f,9.455186e-01f,-3.410081e-01f,-9.234920e-01f,2.682016e+00f,4.020810e-01f,-6.666291e-01f,-4.365895e+00f,1.267948e+01f},
- {-3.090170e-01f,9.510564e-01f,-3.567626e-01f,-8.816779e-01f,2.713525e+00f,3.897543e-01f,-7.454509e-01f,-4.192628e+00f,1.290358e+01f},
- {-2.923717e-01f,9.563047e-01f,-3.717781e-01f,-8.387894e-01f,2.743556e+00f,3.760769e-01f,-8.213612e-01f,-4.010692e+00f,1.311838e+01f},
- {-2.756374e-01f,9.612617e-01f,-3.860361e-01f,-7.948790e-01f,2.772072e+00f,3.611015e-01f,-8.941467e-01f,-3.820433e+00f,1.332343e+01f},
- {-2.588190e-01f,9.659258e-01f,-3.995190e-01f,-7.499999e-01f,2.799038e+00f,3.448846e-01f,-9.636030e-01f,-3.622222e+00f,1.351832e+01f},
- {-2.419219e-01f,9.702957e-01f,-4.122107e-01f,-7.042072e-01f,2.824421e+00f,3.274858e-01f,-1.029536e+00f,-3.416446e+00f,1.370262e+01f},
- {-2.249510e-01f,9.743701e-01f,-4.240956e-01f,-6.575566e-01f,2.848191e+00f,3.089685e-01f,-1.091760e+00f,-3.203517e+00f,1.387596e+01f},
- {-2.079118e-01f,9.781476e-01f,-4.351591e-01f,-6.101051e-01f,2.870318e+00f,2.893990e-01f,-1.150101e+00f,-2.983865e+00f,1.403797e+01f},
- {-1.908090e-01f,9.816272e-01f,-4.453879e-01f,-5.619099e-01f,2.890776e+00f,2.688461e-01f,-1.204397e+00f,-2.757931e+00f,1.418832e+01f},
- {-1.736482e-01f,9.848077e-01f,-4.547695e-01f,-5.130303e-01f,2.909539e+00f,2.473820e-01f,-1.254495e+00f,-2.526181e+00f,1.432668e+01f},
- {-1.564344e-01f,9.876883e-01f,-4.632923e-01f,-4.635254e-01f,2.926584e+00f,2.250811e-01f,-1.300254e+00f,-2.289093e+00f,1.445277e+01f},
- {-1.391731e-01f,9.902681e-01f,-4.709463e-01f,-4.134560e-01f,2.941893e+00f,2.020205e-01f,-1.341547e+00f,-2.047161e+00f,1.456631e+01f},
- {-1.218693e-01f,9.925461e-01f,-4.777218e-01f,-3.628827e-01f,2.955444e+00f,1.782789e-01f,-1.378258e+00f,-1.800889e+00f,1.466707e+01f},
- {-1.045285e-01f,9.945219e-01f,-4.836107e-01f,-3.118677e-01f,2.967221e+00f,1.539375e-01f,-1.410285e+00f,-1.550796e+00f,1.475483e+01f},
- {-8.715577e-02f,9.961947e-01f,-4.886058e-01f,-2.604724e-01f,2.977212e+00f,1.290786e-01f,-1.437538e+00f,-1.297406e+00f,1.482941e+01f},
- {-6.975648e-02f,9.975641e-01f,-4.927011e-01f,-2.087597e-01f,2.985402e+00f,1.037861e-01f,-1.459940e+00f,-1.041256e+00f,1.489065e+01f},
- {-5.233594e-02f,9.986295e-01f,-4.958915e-01f,-1.567926e-01f,2.991783e+00f,7.814553e-02f,-1.477429e+00f,-7.828888e-01f,1.493841e+01f},
- {-3.489946e-02f,9.993909e-01f,-4.981730e-01f,-1.046346e-01f,2.996346e+00f,5.224292e-02f,-1.489957e+00f,-5.228543e-01f,1.497260e+01f},
- {-1.745235e-02f,9.998478e-01f,-4.995431e-01f,-5.234908e-02f,2.999086e+00f,2.616524e-02f,-1.497488e+00f,-2.617055e-01f,1.499315e+01f},
- {-4.371139e-08f,1.000000e+00f,-5.000000e-01f,-1.311342e-07f,3.000000e+00f,6.556709e-08f,-1.500000e+00f,-6.556709e-07f,1.500000e+01f}
-};
-
-const float dirac_gains_trg_term[181][2] =
-{
- {-1.000000e+00f,8.742278e-08f},
- {-9.998477e-01f,-1.745246e-02f},
- {-9.993908e-01f,-3.489945e-02f},
- {-9.986295e-01f,-5.233605e-02f},
- {-9.975641e-01f,-6.975647e-02f},
- {-9.961947e-01f,-8.715564e-02f},
- {-9.945219e-01f,-1.045285e-01f},
- {-9.925461e-01f,-1.218693e-01f},
- {-9.902681e-01f,-1.391732e-01f},
- {-9.876884e-01f,-1.564344e-01f},
- {-9.848077e-01f,-1.736483e-01f},
- {-9.816272e-01f,-1.908090e-01f},
- {-9.781476e-01f,-2.079116e-01f},
- {-9.743701e-01f,-2.249511e-01f},
- {-9.702957e-01f,-2.419219e-01f},
- {-9.659258e-01f,-2.588191e-01f},
- {-9.612617e-01f,-2.756374e-01f},
- {-9.563048e-01f,-2.923716e-01f},
- {-9.510565e-01f,-3.090170e-01f},
- {-9.455186e-01f,-3.255681e-01f},
- {-9.396926e-01f,-3.420202e-01f},
- {-9.335805e-01f,-3.583679e-01f},
- {-9.271839e-01f,-3.746065e-01f},
- {-9.205049e-01f,-3.907312e-01f},
- {-9.135455e-01f,-4.067366e-01f},
- {-9.063078e-01f,-4.226183e-01f},
- {-8.987941e-01f,-4.383711e-01f},
- {-8.910065e-01f,-4.539906e-01f},
- {-8.829476e-01f,-4.694716e-01f},
- {-8.746198e-01f,-4.848095e-01f},
- {-8.660254e-01f,-5.000001e-01f},
- {-8.571673e-01f,-5.150380e-01f},
- {-8.480480e-01f,-5.299193e-01f},
- {-8.386706e-01f,-5.446390e-01f},
- {-8.290377e-01f,-5.591928e-01f},
- {-8.191521e-01f,-5.735765e-01f},
- {-8.090171e-01f,-5.877852e-01f},
- {-7.986355e-01f,-6.018151e-01f},
- {-7.880108e-01f,-6.156614e-01f},
- {-7.771459e-01f,-6.293205e-01f},
- {-7.660444e-01f,-6.427876e-01f},
- {-7.547097e-01f,-6.560590e-01f},
- {-7.431448e-01f,-6.691306e-01f},
- {-7.313537e-01f,-6.819983e-01f},
- {-7.193397e-01f,-6.946585e-01f},
- {-7.071068e-01f,-7.071068e-01f},
- {-6.946585e-01f,-7.193397e-01f},
- {-6.819983e-01f,-7.313537e-01f},
- {-6.691307e-01f,-7.431448e-01f},
- {-6.560590e-01f,-7.547097e-01f},
- {-6.427876e-01f,-7.660444e-01f},
- {-6.293203e-01f,-7.771460e-01f},
- {-6.156614e-01f,-7.880108e-01f},
- {-6.018151e-01f,-7.986355e-01f},
- {-5.877852e-01f,-8.090170e-01f},
- {-5.735765e-01f,-8.191520e-01f},
- {-5.591928e-01f,-8.290376e-01f},
- {-5.446391e-01f,-8.386706e-01f},
- {-5.299193e-01f,-8.480480e-01f},
- {-5.150380e-01f,-8.571673e-01f},
- {-5.000001e-01f,-8.660254e-01f},
- {-4.848095e-01f,-8.746197e-01f},
- {-4.694716e-01f,-8.829476e-01f},
- {-4.539906e-01f,-8.910065e-01f},
- {-4.383711e-01f,-8.987941e-01f},
- {-4.226183e-01f,-9.063078e-01f},
- {-4.067367e-01f,-9.135454e-01f},
- {-3.907312e-01f,-9.205049e-01f},
- {-3.746066e-01f,-9.271839e-01f},
- {-3.583679e-01f,-9.335805e-01f},
- {-3.420201e-01f,-9.396926e-01f},
- {-3.255681e-01f,-9.455186e-01f},
- {-3.090170e-01f,-9.510565e-01f},
- {-2.923717e-01f,-9.563047e-01f},
- {-2.756374e-01f,-9.612617e-01f},
- {-2.588190e-01f,-9.659258e-01f},
- {-2.419219e-01f,-9.702957e-01f},
- {-2.249510e-01f,-9.743701e-01f},
- {-2.079117e-01f,-9.781476e-01f},
- {-1.908090e-01f,-9.816272e-01f},
- {-1.736482e-01f,-9.848077e-01f},
- {-1.564344e-01f,-9.876884e-01f},
- {-1.391731e-01f,-9.902681e-01f},
- {-1.218693e-01f,-9.925461e-01f},
- {-1.045285e-01f,-9.945219e-01f},
- {-8.715577e-02f,-9.961947e-01f},
- {-6.975648e-02f,-9.975641e-01f},
- {-5.233594e-02f,-9.986295e-01f},
- {-3.489946e-02f,-9.993908e-01f},
- {-1.745235e-02f,-9.998477e-01f},
- {-4.371139e-08f,-1.000000e+00f},
- {1.745238e-02f,-9.998477e-01f},
- {3.489950e-02f,-9.993908e-01f},
- {5.233597e-02f,-9.986295e-01f},
- {6.975651e-02f,-9.975641e-01f},
- {8.715580e-02f,-9.961947e-01f},
- {1.045284e-01f,-9.945219e-01f},
- {1.218693e-01f,-9.925461e-01f},
- {1.391731e-01f,-9.902681e-01f},
- {1.564345e-01f,-9.876884e-01f},
- {1.736482e-01f,-9.848077e-01f},
- {1.908089e-01f,-9.816272e-01f},
- {2.079117e-01f,-9.781476e-01f},
- {2.249510e-01f,-9.743701e-01f},
- {2.419219e-01f,-9.702957e-01f},
- {2.588191e-01f,-9.659258e-01f},
- {2.756374e-01f,-9.612617e-01f},
- {2.923717e-01f,-9.563048e-01f},
- {3.090170e-01f,-9.510565e-01f},
- {3.255681e-01f,-9.455186e-01f},
- {3.420202e-01f,-9.396926e-01f},
- {3.583680e-01f,-9.335804e-01f},
- {3.746066e-01f,-9.271839e-01f},
- {3.907311e-01f,-9.205049e-01f},
- {4.067366e-01f,-9.135455e-01f},
- {4.226182e-01f,-9.063078e-01f},
- {4.383712e-01f,-8.987941e-01f},
- {4.539905e-01f,-8.910065e-01f},
- {4.694716e-01f,-8.829476e-01f},
- {4.848096e-01f,-8.746197e-01f},
- {5.000000e-01f,-8.660254e-01f},
- {5.150381e-01f,-8.571673e-01f},
- {5.299193e-01f,-8.480481e-01f},
- {5.446390e-01f,-8.386706e-01f},
- {5.591929e-01f,-8.290375e-01f},
- {5.735765e-01f,-8.191521e-01f},
- {5.877852e-01f,-8.090170e-01f},
- {6.018150e-01f,-7.986355e-01f},
- {6.156615e-01f,-7.880107e-01f},
- {6.293204e-01f,-7.771460e-01f},
- {6.427876e-01f,-7.660444e-01f},
- {6.560590e-01f,-7.547095e-01f},
- {6.691306e-01f,-7.431449e-01f},
- {6.819984e-01f,-7.313537e-01f},
- {6.946584e-01f,-7.193398e-01f},
- {7.071068e-01f,-7.071068e-01f},
- {7.193398e-01f,-6.946584e-01f},
- {7.313537e-01f,-6.819983e-01f},
- {7.431448e-01f,-6.691306e-01f},
- {7.547096e-01f,-6.560590e-01f},
- {7.660444e-01f,-6.427876e-01f},
- {7.771460e-01f,-6.293204e-01f},
- {7.880108e-01f,-6.156615e-01f},
- {7.986355e-01f,-6.018150e-01f},
- {8.090170e-01f,-5.877852e-01f},
- {8.191521e-01f,-5.735765e-01f},
- {8.290376e-01f,-5.591929e-01f},
- {8.386706e-01f,-5.446391e-01f},
- {8.480481e-01f,-5.299193e-01f},
- {8.571673e-01f,-5.150381e-01f},
- {8.660254e-01f,-5.000000e-01f},
- {8.746197e-01f,-4.848096e-01f},
- {8.829476e-01f,-4.694716e-01f},
- {8.910065e-01f,-4.539905e-01f},
- {8.987941e-01f,-4.383712e-01f},
- {9.063078e-01f,-4.226183e-01f},
- {9.135454e-01f,-4.067366e-01f},
- {9.205049e-01f,-3.907311e-01f},
- {9.271839e-01f,-3.746066e-01f},
- {9.335804e-01f,-3.583679e-01f},
- {9.396926e-01f,-3.420201e-01f},
- {9.455186e-01f,-3.255681e-01f},
- {9.510565e-01f,-3.090170e-01f},
- {9.563048e-01f,-2.923717e-01f},
- {9.612617e-01f,-2.756374e-01f},
- {9.659258e-01f,-2.588190e-01f},
- {9.702957e-01f,-2.419219e-01f},
- {9.743701e-01f,-2.249510e-01f},
- {9.781476e-01f,-2.079117e-01f},
- {9.816272e-01f,-1.908090e-01f},
- {9.848077e-01f,-1.736482e-01f},
- {9.876884e-01f,-1.564345e-01f},
- {9.902681e-01f,-1.391731e-01f},
- {9.925461e-01f,-1.218693e-01f},
- {9.945219e-01f,-1.045285e-01f},
- {9.961947e-01f,-8.715574e-02f},
- {9.975641e-01f,-6.975647e-02f},
- {9.986295e-01f,-5.233596e-02f},
- {9.993908e-01f,-3.489950e-02f},
- {9.998477e-01f,-1.745241e-02f},
- {1.000000e+00f,0.000000e+00f}
-};
-
/*----------------------------------------------------------------------------------*
* FB ROM tables
*----------------------------------------------------------------------------------*/
diff --git a/lib_com/ivas_rom_com.h b/lib_com/ivas_rom_com.h
index 662dc81a9ba23ba6696e520d350c227b0139c1eb..b58e183ebda207962993ac3a75678cbc2ef4ce1d 100644
--- a/lib_com/ivas_rom_com.h
+++ b/lib_com/ivas_rom_com.h
@@ -78,8 +78,6 @@ extern const UWord16 ECSQ_tab_inverse[1 + ECSQ_SEGMENT_SIZE];
/*----------------------------------------------------------------------------------*
* Stereo ICA ROM tables
*----------------------------------------------------------------------------------*/
-extern const float ica_sincInterp4[];
-extern const float ica_sincInterp2[];
extern const Word16 tdm_bit_allc_tbl[5][6];
/* LSFs Intra-frame prediction tables */
@@ -100,11 +98,6 @@ extern const Word16 tdm_LSF_MEAN_PRED_QNT_fx[M];
extern const Word16 tdm_PRED_QNT_fixed_beta_prd_diag_3_fx[15 + 16 + 15];
-extern const float tdm_LSF_MEAN_PRED_QNT_OUT[M];
-extern const float tdm_LSF_MEAN_PRED_QNT_IN[M];
-extern const float tdm_LSF_MEAN_PRED_QNT[M];
-extern const float tdm_PRED_QNT_fixed_beta_prd_diag_3[15 + 16 + 15];
-
extern const Word16 fast_FCB_bits_2sfr[];
extern const Word16 fast_FCB_rates_2sfr[];
@@ -288,9 +281,6 @@ extern const ivas_lfe_freq_models ivas_str_lfe_freq_models;
extern const Word16 ivas_lfe_lpf_delay_Q15[2];
extern const Word16 dirac_gains_P_idx[16];
-extern const float dirac_gains_norm_term[9];
-extern const float dirac_gains_Pnm[91][9];
-extern const float dirac_gains_trg_term[181][2];
/*------------------------------------------------------------------------------------------*
* FB ROM tables
diff --git a/lib_com/ivas_sns_com.c b/lib_com/ivas_sns_com.c
deleted file mode 100644
index cf7ec8348361a485a60ddd8a89fc2d73ea07ee41..0000000000000000000000000000000000000000
--- a/lib_com/ivas_sns_com.c
+++ /dev/null
@@ -1,295 +0,0 @@
-/******************************************************************************************************
-
- (C) 2022-2024 IVAS codec Public Collaboration with portions copyright Dolby International AB, Ericsson AB,
- Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD.,
- Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange,
- Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other
- contributors to this repository. All Rights Reserved.
-
- This software is protected by copyright law and by international treaties.
- The IVAS codec Public Collaboration consisting of Dolby International AB, Ericsson AB,
- Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD.,
- Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange,
- Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other
- contributors to this repository retain full ownership rights in their respective contributions in
- the software. This notice grants no license of any kind, including but not limited to patent
- license, nor is any license granted by implication, estoppel or otherwise.
-
- Contributors are required to enter into the IVAS codec Public Collaboration agreement before making
- contributions.
-
- This software is provided "AS IS", without any express or implied warranties. The software is in the
- development stage. It is intended exclusively for experts who have experience with such software and
- solely for the purpose of inspection. All implied warranties of non-infringement, merchantability
- and fitness for a particular purpose are hereby disclaimed and excluded.
-
- Any dispute, controversy or claim arising under or in relation to providing this software shall be
- submitted to and settled by the final, binding jurisdiction of the courts of Munich, Germany in
- accordance with the laws of the Federal Republic of Germany excluding its conflict of law rules and
- the United Nations Convention on Contracts on the International Sales of Goods.
-
-*******************************************************************************************************/
-
-#include
-#include "options.h"
-#include "cnst.h"
-#include "prot.h"
-#include "ivas_prot.h"
-#include "rom_com.h"
-#include "ivas_rom_com.h"
-#include
-#include
-#include "wmc_auto.h"
-
-#ifndef IVAS_FLOAT_FIXED
-/*-------------------------------------------------------------------
- * sns_compute_scf()
- *
- *
- *-------------------------------------------------------------------*/
-
-void sns_compute_scf(
- float spectrum[],
- const PsychoacousticParameters *pPsychParams,
- const int16_t L_frame,
- float *scf )
-{
- int16_t i, n, k;
- float x[FDNS_NPTS], xs[FDNS_NPTS], sum, mean, xl4[SNS_NPTS], nf, xl[FDNS_NPTS];
- float tilt;
- const uint8_t nBands = pPsychParams->nBands;
- const uint8_t *bandLengths = pPsychParams->bandLengths;
- int8_t bw = 0;
-
-
- const float w_0 = 1.0f / 12.0f;
- const float w_1 = 2.0f / 12.0f;
- const float w_2 = 0.25f; /* 3.0f / 12.0f */
- const float w_3 = w_2;
- const float w_4 = w_1;
- const float w_5 = w_0;
-
- const float scale_log = INV_LOG_2 * 0.5f;
-
- assert( nBands == FDNS_NPTS );
-
- set_f( x, 0.0f, FDNS_NPTS );
-
- if ( bandLengths == NULL )
- {
- bw = (int8_t) ( L_frame / nBands );
- /* Energy per band */
- k = 0;
- for ( i = 0; i < nBands; ++i )
- {
- x[i] = 0.0f;
- for ( n = 0; n < bw; ++n, ++k )
- {
- x[i] += spectrum[k];
- }
- x[i] /= bw;
- }
- }
- else
- {
- /* Energy per band */
- k = 0;
- for ( i = 0; i < nBands; ++i )
- {
- x[i] = 0.0f;
- for ( n = 0; n < bandLengths[i]; ++n, ++k )
- {
- x[i] += spectrum[k];
- }
- x[i] /= bandLengths[i];
- }
- }
-
- /* Smoothing */
- xs[0] = 0.75f * x[0] + 0.25f * x[1];
-
- for ( i = 1; i < FDNS_NPTS - 1; i++ )
- {
- xs[i] = 0.5f * x[i] + 0.25f * x[i - 1] + 0.25f * x[i + 1];
- }
-
- xs[FDNS_NPTS - 1] = 0.75f * x[FDNS_NPTS - 1] + 0.25f * x[FDNS_NPTS - 2];
-
- /* Pre-emphasis */
- switch ( L_frame )
- {
- case L_FRAME16k:
- tilt = 19.f;
- break;
- case L_FRAME25_6k:
- tilt = 22.f;
- break;
- case L_FRAME32k:
- tilt = 23.5f;
- break;
- default:
- tilt = 0.f;
- assert( !"illegal frame length in sns_compute_scf" );
- }
-
- for ( i = 0; i < FDNS_NPTS; i++ )
- {
- xs[i] = xs[i] * powf( 10.0f, (float) i * (float) tilt / ( (float) FDNS_NPTS - 1.0f ) / 10.0f );
- }
-
- /* Noise floor at -40dB */
- sum = sum_f( xs, FDNS_NPTS );
- mean = sum / FDNS_NPTS;
-
- nf = mean * powf( 10.0f, -4.0f );
- nf = max( nf, powf( 2.0f, -32.0f ) );
-
-
- for ( i = 0; i < FDNS_NPTS; i++ )
- {
- if ( xs[i] < nf )
- {
- xs[i] = nf;
- }
- }
-
- /* Log-domain */
- for ( i = 0; i < FDNS_NPTS; i++ )
- {
- xl[i] = logf( xs[i] ) * scale_log;
- }
-
- /* Downsampling */
- xl4[0] = w_0 * xl[0] +
- w_1 * xl[0] +
- w_2 * xl[1] +
- w_3 * xl[2] +
- w_4 * xl[3] +
- w_5 * xl[4];
-
-
- for ( n = 1; n < SNS_NPTS - 1; n++ )
- {
- int16_t n4 = 4 * n;
- xl4[n] = w_0 * xl[n4 - 1] +
- w_1 * xl[n4] +
- w_2 * xl[n4 + 1] +
- w_3 * xl[n4 + 2] +
- w_4 * xl[n4 + 3] +
- w_5 * xl[n4 + 4];
- }
-
- xl4[SNS_NPTS - 1] = w_0 * xl[FDNS_NPTS - 5] +
- w_1 * xl[FDNS_NPTS - 4] +
- w_2 * xl[FDNS_NPTS - 3] +
- w_3 * xl[FDNS_NPTS - 2] +
- w_4 * xl[FDNS_NPTS - 1] +
- w_5 * xl[FDNS_NPTS - 1];
-
- /* Remove mean and scaling */
- sum = sum_f( xl4, SNS_NPTS );
- mean = sum / SNS_NPTS;
-
- for ( i = 0; i < SNS_NPTS; i++ )
- {
- scf[i] = 0.85f * ( xl4[i] - mean );
- }
-
- return;
-}
-
-/*-------------------------------------------------------------------
- * sns_interpolate_scalefactors()
- *
- *
- *-------------------------------------------------------------------*/
-
-void sns_interpolate_scalefactors(
- float *scf_int, /* o : interpolated scalefactors for spectrum shaping*/
- const float *scf, /* i : sns scalefactors as derived from the signal or read from the bitstream */
- int16_t encoder_side /* i : flag, if scalefactors have to be inverted */
-)
-{
- int16_t n;
-
- /* Interpolation */
- scf_int[0] = scf[0];
- scf_int[1] = scf[0];
-
- for ( n = 0; n <= M - 2; n++ )
- {
- scf_int[n * 4 + 2] = scf[n] + ( scf[n + 1] - scf[n] ) / 8.f;
- scf_int[n * 4 + 3] = scf[n] + 3.f * ( scf[n + 1] - scf[n] ) / 8.f;
- scf_int[n * 4 + 4] = scf[n] + 5.f * ( scf[n + 1] - scf[n] ) / 8.f;
- scf_int[n * 4 + 5] = scf[n] + 7.f * ( scf[n + 1] - scf[n] ) / 8.f;
- }
-
- scf_int[FDNS_NPTS - 2] = scf[M - 1] + ( scf[M - 1] - scf[M - 2] ) / 8.f;
- scf_int[FDNS_NPTS - 1] = scf[M - 1] + 3.f * ( scf[M - 1] - scf[M - 2] ) / 8.f;
-
- /* Inversion at encoder-side */
- if ( encoder_side == ENC )
- {
- for ( n = 0; n < FDNS_NPTS; n++ )
- {
- scf_int[n] = -scf_int[n];
- }
- }
-
- /* Linear domain */
- for ( n = 0; n < FDNS_NPTS; n++ )
- {
- scf_int[n] = powf( 2.f, scf_int[n] );
- }
-
- return;
-}
-
-
-/*-------------------------------------------------------------------
- * sns_shape_spectrum()
- *
- *
- *-------------------------------------------------------------------*/
-
-void sns_shape_spectrum(
- float spectrum[], /* i/o: spectrum to be shaped */
- const PsychoacousticParameters *pPsychParams, /* i : psychoacoustic parameters used to get the frequency bands */
- const float *scf_int, /* i : already interpolated SNS scalefactors */
- const int16_t L_frame /* i : frame length */
-)
-{
- int16_t i, n, k, bw;
- const uint8_t nBands = pPsychParams->nBands;
- const uint8_t *bandLengths = pPsychParams->bandLengths;
-
- if ( bandLengths == NULL )
- {
- bw = L_frame / nBands;
-
- /* Shape spectrum */
- k = 0;
- for ( i = 0; i < nBands; ++i )
- {
- for ( n = 0; n < bw; ++n, ++k )
- {
- spectrum[k] *= scf_int[i];
- }
- }
- }
- else
- {
- /* Shape spectrum */
- k = 0;
- for ( i = 0; i < nBands; ++i )
- {
- for ( n = 0; n < bandLengths[i]; ++n, ++k )
- {
- spectrum[k] *= scf_int[i];
- }
- }
- }
-
- return;
-}
-#endif
diff --git a/lib_com/ivas_tools.c b/lib_com/ivas_tools.c
index 943d0062051932db768e7e1f5c60d8806a0e9cd0..5f5bd26d5355d38f0f4ab7f8a7f1eb6667a136c5 100644
--- a/lib_com/ivas_tools.c
+++ b/lib_com/ivas_tools.c
@@ -51,24 +51,6 @@
* sum of absolute values
* ---------------------------------------------------------------*/
-/*! r: sum abs of all vector elements */
-float sumAbs(
- const float *vec, /* i : input vector */
- const int16_t lvec /* i : length of input vector */
-)
-{
- int16_t i;
- float tmp;
-
- tmp = 0.0f;
- for ( i = 0; i < lvec; i++ )
- {
- tmp += fabsf( vec[i] );
- }
-
- return tmp;
-}
-
Word32 sumAbs_fx(
const Word32 *vec, /* i : input vector Qx*/
const Word16 lvec /* i : length of input vector Q0*/
@@ -94,31 +76,33 @@ Word32 sumAbs_fx(
*---------------------------------------------------------------------*/
void mvc2c(
- const uint8_t x[], /* i : input vector */
- uint8_t y[], /* o : output vector */
- const int16_t n /* i : vector size */
+ const UWord8 x[], /* i : input vector */
+ UWord8 y[], /* o : output vector */
+ const Word16 n /* i : vector size */
)
{
- int16_t i;
+ Word16 i;
- if ( n <= 0 )
+ IF( n <= 0 )
{
/* no need to transfer vectors with size 0 */
return;
}
- if ( y < x )
+ IF( y < x )
{
- for ( i = 0; i < n; i++ )
+ FOR( i = 0; i < n; i++ )
{
y[i] = x[i];
+ move16();
}
}
- else
+ ELSE
{
- for ( i = n - 1; i >= 0; i-- )
+ FOR( i = n - 1; i >= 0; i-- )
{
y[i] = x[i];
+ move16();
}
}
@@ -134,34 +118,6 @@ void mvc2c(
*-------------------------------------------------------------------*/
/*! r: number of clipped samples */
-uint32_t ivas_syn_output(
- float *synth[], /* i/o: float synthesis signal */
- const int16_t output_frame, /* i : output frame length (one channel) */
- const int16_t n_channels, /* i : number of output channels */
- int16_t *synth_out /* o : integer 16 bits synthesis signal */
-)
-{
- int16_t i, n;
- int16_t synth_loc[MAX_JBM_L_FRAME48k];
- uint32_t noClipping = 0;
-
- /*-----------------------------------------------------------------*
- * float to integer conversion with saturation control
- *-----------------------------------------------------------------*/
-
- for ( n = 0; n < n_channels; n++ )
- {
- noClipping += mvr2s( synth[n], synth_loc, output_frame );
-
- for ( i = 0; i < output_frame; i++ )
- {
- synth_out[i * n_channels + n] = synth_loc[i];
- }
- }
-
- return noClipping;
-}
-
UWord32 ivas_syn_output_fx(
Word32 *synth[], /* i/o: float synthesis signal q_synth*/
const Word16 q_synth,
@@ -204,30 +160,6 @@ UWord32 ivas_syn_output_fx(
*-------------------------------------------------------------------*/
/*! r: number of clipped samples */
-void ivas_syn_output_f(
- float *synth[], /* i/o: float synthesis signal */
- const int16_t output_frame, /* i : output frame length (one channel) */
- const int16_t n_channels, /* i : number of output channels */
- float *synth_out /* o : integer 16 bits synthesis signal */
-)
-{
- int16_t i, n;
-
- /*-----------------------------------------------------------------*
- * float to integer conversion with saturation control
- *-----------------------------------------------------------------*/
-
- for ( n = 0; n < n_channels; n++ )
- {
- for ( i = 0; i < output_frame; i++ )
- {
- synth_out[i * n_channels + n] = synth[n][i];
- }
- }
-
- return;
-}
-
void ivas_syn_output_f_fx(
Word32 *synth[], /* i/o: float synthesis signal Q11*/
const Word16 output_frame, /* i : output frame length (one channel) Q0*/
@@ -288,8 +220,8 @@ void mvr2r_inc_fixed_one(
y_fx[iy] = x_fx[ix]; /*Q29*/
move32();
- ix = add( ix, x_inc );
- iy = add( iy, y_inc );
+ ix = ix + x_inc;
+ iy = iy + y_inc;
}
}
ELSE
@@ -301,8 +233,8 @@ void mvr2r_inc_fixed_one(
y_fx[iy] = x_fx[ix]; /*Q29*/
move32();
- ix = sub( ix, x_inc );
- iy = sub( iy, y_inc );
+ ix = ix - x_inc;
+ iy = iy - y_inc;
}
}
@@ -338,8 +270,8 @@ void mvr2r_inc_fixed(
y_fx[iy] = x_fx[ix]; /*Q29*/
move32();
- ix = add( ix, x_inc );
- iy = add( iy, y_inc );
+ ix = ix + x_inc;
+ iy = iy + y_inc;
}
}
ELSE
@@ -351,52 +283,8 @@ void mvr2r_inc_fixed(
y_fx[iy] = x_fx[ix]; /*Q29*/
move32();
- ix = sub( ix, x_inc );
- iy = sub( iy, y_inc );
- }
- }
-
- return;
-}
-
-void mvr2r_inc(
- const float x[], /* i : input vector */
- const int16_t x_inc, /* i : increment for vector x[] */
- float y[], /* o : output vector */
- const int16_t y_inc, /* i : increment for vector y[] */
- const int16_t n /* i : vector size */
-)
-{
- int16_t i;
- int16_t ix;
- int16_t iy;
-
- if ( n <= 0 )
- {
- /* cannot transfer vectors with size 0 */
- return;
- }
-
- if ( y < x )
- {
- ix = 0;
- iy = 0;
- for ( i = 0; i < n; i++ )
- {
- y[iy] = x[ix];
- ix += x_inc;
- iy += y_inc;
- }
- }
- else
- {
- ix = ( n - 1 ) * x_inc;
- iy = ( n - 1 ) * y_inc;
- for ( i = n - 1; i >= 0; i-- )
- {
- y[iy] = x[ix];
- ix -= x_inc;
- iy -= y_inc;
+ ix = ix - x_inc;
+ iy = iy - y_inc;
}
}
@@ -409,32 +297,6 @@ void mvr2r_inc(
* Addition of two vectors sample by sample with explicit increments
*-------------------------------------------------------------------*/
-void v_add_inc(
- const float x1[], /* i : Input vector 1 */
- const int16_t x_inc, /* i : Increment for input vector 1 */
- const float x2[], /* i : Input vector 2 */
- const int16_t x2_inc, /* i : Increment for input vector 2 */
- float y[], /* o : Output vector that contains vector 1 + vector 2 */
- const int16_t y_inc, /* i : increment for vector y[] */
- const int16_t N /* i : Vector length */
-)
-{
- int16_t i;
- int16_t ix1 = 0;
- int16_t ix2 = 0;
- int16_t iy = 0;
-
- for ( i = 0; i < N; i++ )
- {
- y[iy] = x1[ix1] + x2[ix2];
- ix1 += x_inc;
- ix2 += x2_inc;
- iy += y_inc;
- }
-
- return;
-}
-
// for same q//
void v_add_inc_fx(
const Word32 x1[], /* i : Input vector 1 Qx*/
@@ -540,38 +402,6 @@ void v_mult_inc_fixed(
return;
}
-/*-------------------------------------------------------------------*
- * v_mult_inc()
- *
- * Multiplication of two vectors with explicit increments
- *-------------------------------------------------------------------*/
-
-void v_mult_inc(
- const float x1[], /* i : Input vector 1 */
- const int16_t x1_inc, /* i : Increment for input vector 1 */
- const float x2[], /* i : Input vector 2 */
- const int16_t x2_inc, /* i : Increment for input vector 1 */
- float y[], /* o : Output vector that contains vector 1 .* vector 2 */
- const int16_t y_inc, /* i : increment for vector y[i] */
- const int16_t N /* i : Vector length */
-)
-{
- int16_t i;
- int16_t ix1 = 0;
- int16_t ix2 = 0;
- int16_t iy = 0;
-
- for ( i = 0; i < N; i++ )
- {
- y[iy] = x1[ix1] * x2[ix2];
- ix1 += x1_inc;
- ix2 += x2_inc;
- iy += y_inc;
- }
-
- return;
-}
-
/*-------------------------------------------------------------------*
* v_addc_fx()
*
@@ -618,23 +448,6 @@ void v_addc_fixed(
return;
}
-void v_addc(
- const float x[], /* i : Input vector */
- const float c, /* i : Constant */
- float y[], /* o : Output vector that contains c*x */
- const int16_t N /* i : Vector length */
-)
-{
- int16_t i;
-
- for ( i = 0; i < N; i++ )
- {
- y[i] = c + x[i];
- }
-
- return;
-}
-
/*-------------------------------------------------------------------*
* v_min_fx()
*
@@ -693,29 +506,6 @@ void v_min_fx(
return;
}
-/*-------------------------------------------------------------------*
- * v_min()
- *
- * minimum of two vectors
- *-------------------------------------------------------------------*/
-
-void v_min(
- const float x1[], /* i : Input vector 1 */
- const float x2[], /* i : Input vector 2 */
- float y[], /* o : Output vector that contains vector 1 .* vector 2 */
- const int16_t N /* i : Vector length */
-)
-{
- int16_t i;
-
- for ( i = 0; i < N; i++ )
- {
- y[i] = ( x1[i] < x2[i] ) ? x1[i] : x2[i];
- }
-
- return;
-}
-
/*-------------------------------------------------------------------*
* v_sqrt()
@@ -740,23 +530,6 @@ void v_sqrt_fx(
return;
}
-void v_sqrt(
- const float x[], /* i : Input vector */
- float y[], /* o : Output vector that contains sqrt(x) */
- const int16_t N /* i : Vector length */
-)
-{
- int16_t i;
-
- for ( i = 0; i < N; i++ )
- {
- y[i] = sqrtf( x[i] );
- }
-
- return;
-}
-
-
/*-------------------------------------------------------------------*
* v_sub_s()
*
@@ -800,24 +573,6 @@ void v_sub32_fx(
return;
}
-void v_sub_s(
- const int16_t x1[], /* i : Input vector 1 */
- const int16_t x2[], /* i : Input vector 2 */
- int16_t y[], /* o : Output vector that contains vector 1 - vector 2 */
- const int16_t N /* i : Vector length */
-)
-{
- int16_t i;
-
- for ( i = 0; i < N; i++ )
- {
- y[i] = x1[i] - x2[i];
- }
-
- return;
-}
-
-
/*---------------------------------------------------------------------*
* dot_product_cholesky()
*
@@ -827,34 +582,6 @@ void v_sub_s(
*---------------------------------------------------------------------*/
/*! r: the dot product x'*A*A'*x */
-float dot_product_cholesky(
- const float *x, /* i : vector x */
- const float *A, /* i : Cholesky matrix A */
- const int16_t N /* i : vector & matrix size */
-)
-{
- int16_t i, j;
- float suma, tmp_sum;
- const float *pt_x, *pt_A;
-
- pt_A = A;
- suma = 0;
-
- for ( i = 0; i < N; i++ )
- {
- tmp_sum = 0;
- pt_x = x;
- for ( j = 0; j <= i; j++ )
- {
- float mul = *pt_x++ * *pt_A++;
- tmp_sum += mul;
- }
-
- suma += tmp_sum * tmp_sum;
- }
-
- return suma;
-}
Word32 dot_product_cholesky_fixed(
const Word32 *x, /* i : vector x Q31 - exp_x*/
const Word32 *A, /* i : Cholesky matrix A Q31 - exp_A*/
@@ -1024,47 +751,6 @@ void v_mult_mat_fx(
return;
}
-/*---------------------------------------------------------------------*
- * v_mult_mat()
- *
- * Multiplication of row vector x by matrix A, where x has size Nr and
- * A has size Nr x Nc ans it is stored column-wise in memory.
- * The resulting row vector y has size Nc
- *---------------------------------------------------------------------*/
-
-void v_mult_mat(
- float *y, /* o : the product x*A */
- const float *x, /* i : vector x */
- const float *A, /* i : matrix A */
- const int16_t Nr, /* i : number of rows */
- const int16_t Nc /* i : number of columns */
-)
-{
- int16_t i, j;
-
- const float *pt_x, *pt_A;
- float tmp_y[MAX_V_MULT_MAT];
- float *pt_y;
-
- pt_y = tmp_y;
- pt_A = A;
-
- for ( i = 0; i < Nc; i++ )
- {
- pt_x = x;
- *pt_y = 0;
- for ( j = 0; j < Nr; j++ )
- {
- *pt_y += ( *pt_x++ ) * ( *pt_A++ );
- }
- pt_y++;
- }
-
- mvr2r( tmp_y, y, Nc );
-
- return;
-}
-
/*---------------------------------------------------------------------*
* logsumexp()
@@ -1073,32 +759,6 @@ void v_mult_mat(
*---------------------------------------------------------------------*/
/*! r: log(sum(exp(x)) of the input array x */
-float logsumexp(
- const float x[], /* i : input array x */
- const int16_t N /* i : number of elements in array x */
-)
-{
- float max_exp;
- float sum;
- int16_t i;
-
- max_exp = x[0];
- sum = 0;
- for ( i = 1; i < N; i++ )
- {
- if ( x[i] > max_exp )
- {
- max_exp = x[i];
- }
- }
-
- for ( i = 0; i < N; i++ )
- {
- sum += expf( x[i] - max_exp );
- }
-
- return logf( sum ) + max_exp;
-}
Word32 logsumexp_fx(
const Word32 x[], /* i : input array x Q31 - x_e*/
const Word16 x_e,
@@ -1188,76 +848,13 @@ Word32 lin_interp32_fx(
return temp32; /*Q_io*/
}
-/*! r: mapped output value */
-float lin_interp(
- const float x, /* i : the value to be mapped */
- const float x1, /* i : source range interval: low end */
- const float y1, /* i : source range interval: high end */
- const float x2, /* i : target range interval: low */
- const float y2, /* i : target range interval: high */
- const int16_t flag_sat /* i : flag to indicate whether to apply saturation */
-)
-{
- if ( x2 - x1 == 0 )
- {
- return y1;
- }
- else if ( flag_sat )
- {
- if ( x >= max( x1, x2 ) )
- {
- return x1 > x2 ? y1 : y2;
- }
- else if ( x <= min( x1, x2 ) )
- {
- return x1 < x2 ? y1 : y2;
- }
- }
-
- return y1 + ( x - x1 ) * ( y2 - y1 ) / ( x2 - x1 );
-}
-
-
/*-------------------------------------------------------------------*
- * check_bounds()
+ * check_bounds_s_fx()
*
* Ensure the input value is within the given limits
*-------------------------------------------------------------------*/
/*! r: Adjusted value */
-float check_bounds(
- const float value, /* i : Input value */
- const float low, /* i : Low limit */
- const float high /* i : High limit */
-)
-{
- float value_adj;
-
- value_adj = min( max( value, low ), high );
-
- return value_adj;
-}
-
-
-/*-------------------------------------------------------------------*
- * check_bounds_s()
- *
- * Ensure the input value is within the given limits
- *-------------------------------------------------------------------*/
-
-/*! r: Adjusted value */
-int16_t check_bounds_s(
- const int16_t value, /* i : Input value */
- const int16_t low, /* i : Low limit */
- const int16_t high /* i : High limit */
-)
-{
- int16_t value_adj;
-
- value_adj = min( max( value, low ), high );
-
- return value_adj;
-}
Word16 check_bounds_s_fx(
const Word16 value, /* i : Input value Q0*/
const Word16 low, /* i : Low limit Q0*/
@@ -1302,105 +899,6 @@ Word32 check_bounds_l(
* comput the matrix product of two matrices (Z=X*Y)
*---------------------------------------------------------------------*/
-/*! r: success or failure */
-int16_t matrix_product(
- const float *X, /* i : left hand matrix */
- const int16_t rowsX, /* i : number of rows of the left hand matrix */
- const int16_t colsX, /* i : number of columns of the left hand matrix */
- const int16_t transpX, /* i : flag indicating the transposition of the left hand matrix prior to the multiplication */
- const float *Y, /* i : right hand matrix */
- const int16_t rowsY, /* i : number of rows of the right hand matrix */
- const int16_t colsY, /* i : number of columns of the right hand matrix */
- const int16_t transpY, /* i : flag indicating the transposition of the right hand matrix prior to the multiplication */
- float *Z /* o : resulting matrix after the matrix multiplication */
-)
-{
- int16_t i, j, k;
- float *Zp = Z;
-
- /* Processing */
- if ( transpX == 1 && transpY == 0 ) /* We use X transpose */
- {
- if ( rowsX != rowsY )
- {
- return EXIT_FAILURE;
- }
- for ( j = 0; j < colsY; ++j )
- {
- for ( i = 0; i < colsX; ++i )
- {
- ( *Zp ) = 0.0f;
- for ( k = 0; k < rowsX; ++k )
- {
- ( *Zp ) += X[k + i * rowsX] * Y[k + j * rowsY];
- }
- Zp++;
- }
- }
- }
- else if ( transpX == 0 && transpY == 1 ) /* We use Y transpose */
- {
- if ( colsX != colsY )
- {
- return EXIT_FAILURE;
- }
- for ( j = 0; j < rowsY; ++j )
- {
- for ( i = 0; i < rowsX; ++i )
- {
- ( *Zp ) = 0.0f;
- for ( k = 0; k < colsX; ++k )
- {
- ( *Zp ) += X[i + k * rowsX] * Y[j + k * rowsY];
- }
- Zp++;
- }
- }
- }
- else if ( transpX == 1 && transpY == 1 ) /* We use both transpose */
- {
- if ( rowsX != colsY )
- {
- return EXIT_FAILURE;
- }
- for ( j = 0; j < rowsY; ++j )
- {
- for ( i = 0; i < colsX; ++i )
- {
- ( *Zp ) = 0.0f;
- for ( k = 0; k < colsX; ++k )
- {
- ( *Zp ) += X[k + i * rowsX] * Y[j + k * rowsY];
- }
-
- Zp++;
- }
- }
- }
- else /* Regular case */
- {
- if ( colsX != rowsY )
- {
- return EXIT_FAILURE;
- }
-
- for ( j = 0; j < colsY; ++j )
- {
- for ( i = 0; i < rowsX; ++i )
- {
- ( *Zp ) = 0.0f;
- for ( k = 0; k < colsX; ++k )
- {
- ( *Zp ) += X[i + k * rowsX] * Y[k + j * rowsY];
- }
- Zp++;
- }
- }
- }
-
- return EXIT_SUCCESS;
-}
-
Word16 matrix_product_mant_exp_fx(
const Word32 *X_fx, /* i : left hand matrix Q31 - X_fx_e*/
const Word16 X_fx_e, /* i : left hand matrix */
@@ -1992,60 +1490,6 @@ Word16 matrix_product_mant_exp(
}
-/*---------------------------------------------------------------------*
- * matrix_diag_product
- *
- * compute the product of a matrix with a diagonal of a matrix (Z=X*diag(Y))
- *---------------------------------------------------------------------*/
-
-/*! r: success or failure */
-int16_t matrix_diag_product(
- const float *X, /* i : left hand matrix */
- const int16_t rowsX, /* i : number of rows of the left hand matrix */
- const int16_t colsX, /* i : number of columns of the left hand matrix */
- const int16_t transpX, /* i : flag indicating the transposition of the left hand matrix prior to the multiplication */
- const float *Y, /* i : right hand diagonal matrix as vector containing the diagonal elements */
- const int16_t entriesY, /* i : number of entries in the diagonal */
- float *Z /* o : resulting matrix after the matrix multiplication */
-)
-{
- int16_t i, j;
- float *Zp = Z;
-
- /* Processing */
- if ( transpX == 1 ) /* We use X transpose */
- {
- if ( rowsX != entriesY )
- {
- return EXIT_FAILURE;
- }
- for ( j = 0; j < entriesY; ++j )
- {
- for ( i = 0; i < colsX; ++i )
- {
- *( Zp++ ) = X[j + i * rowsX] * Y[j];
- }
- }
- }
- else /* Regular case */
- {
- if ( colsX != entriesY )
- {
- return EXIT_FAILURE;
- }
-
- for ( j = 0; j < entriesY; ++j )
- {
- for ( i = 0; i < rowsX; ++i )
- {
- *( Zp++ ) = *( X++ ) * Y[j];
- }
- }
- }
-
- return EXIT_SUCCESS;
-}
-
Word16 matrix_diag_product_fx(
const Word32 *X, /* i : left hand matrix Q31 - X_e*/
Word16 X_e,
@@ -2227,60 +1671,6 @@ Word16 diag_matrix_product_fx(
return EXIT_SUCCESS;
}
-
-/*---------------------------------------------------------------------*
- * diag_matrix_product()
- *
- * compute the matrix product of a diagonal matrix X with a full matrix Y (Z=diag(Y)*X)
- *---------------------------------------------------------------------*/
-
-/*! r: success or failure */
-int16_t diag_matrix_product(
- const float *Y, /* i : left hand diagonal matrix as vector containing the diagonal elements */
- const int16_t entriesY, /* i : length of the diagonal of the left hand matrix */
- const float *X, /* i : right hand matrix */
- const int16_t rowsX, /* i : number of rows of the right hand matrix */
- const int16_t colsX, /* i : number of columns of the right hand matrix */
- const int16_t transpX, /* i : flag indicating the transposition of the right hand matrix prior to the multiplication */
- float *Z /* o : resulting matrix after the matrix multiplication */
-)
-{
- int16_t i, j;
- float *Zp = Z;
-
- /* Processing */
- if ( transpX == 1 ) /* We use X transpose */
- {
- if ( colsX != entriesY )
- {
- return EXIT_FAILURE;
- }
- for ( i = 0; i < rowsX; ++i )
- {
- for ( j = 0; j < entriesY; ++j )
- {
- *( Zp++ ) = X[i + j * rowsX] * Y[j];
- }
- }
- }
- else /* Regular case */
- {
- if ( rowsX != entriesY )
- {
- return EXIT_FAILURE;
- }
- for ( i = 0; i < colsX; ++i )
- {
- for ( j = 0; j < entriesY; ++j )
- {
- *( Zp++ ) = *( X++ ) * Y[j];
- }
- }
- }
-
- return EXIT_SUCCESS;
-}
-
Word16 matrix_product_diag_fx(
const Word32 *X, /* i : left hand matrix Q31 - X_e*/
Word16 X_e,
@@ -2401,96 +1791,6 @@ Word16 matrix_product_diag_fx(
* compute only the main diagonal of X*Y (Z=diag(X*Y))
*---------------------------------------------------------------------*/
-/*! r: success or failure */
-int16_t matrix_product_diag(
- const float *X, /* i : left hand matrix */
- const int16_t rowsX, /* i : number of rows of the left hand matrix */
- const int16_t colsX, /* i : number of columns of the left hand matrix */
- const int16_t transpX, /* i : flag indicating the transposition of the left hand matrix prior to the multiplication */
- const float *Y, /* i : right hand matrix */
- const int16_t rowsY, /* i : number of rows of the right hand matrix */
- const int16_t colsY, /* i : number of columns of the right hand matrix */
- const int16_t transpY, /* i : flag indicating the transposition of the right hand matrix prior to the multiplication */
- float *Z /* o : resulting matrix after the matrix multiplication */
-)
-{
- int16_t j, k;
- float *Zp = Z;
-
- /* Processing */
- if ( transpX == 1 && transpY == 0 ) /* We use X transpose */
- {
- if ( rowsX != rowsY )
- {
- return EXIT_FAILURE;
- }
-
- for ( j = 0; j < colsY; ++j )
- {
- ( *Zp ) = 0.0f;
- for ( k = 0; k < rowsX; ++k )
- {
- ( *Zp ) += X[k + j * rowsX] * Y[k + j * rowsY];
- }
- Zp++;
- }
- }
- else if ( transpX == 0 && transpY == 1 ) /* We use Y transpose */
- {
- if ( colsX != colsY )
- {
- return EXIT_FAILURE;
- }
- for ( j = 0; j < rowsY; ++j )
- {
- ( *Zp ) = 0.0f;
- for ( k = 0; k < colsX; ++k )
- {
- ( *Zp ) += X[j + k * rowsX] * Y[j + k * rowsY];
- }
- Zp++;
- }
- }
- else if ( transpX == 1 && transpY == 1 ) /* We use both transpose */
- {
- if ( rowsX != colsY )
- {
- return EXIT_FAILURE;
- }
-
- for ( j = 0; j < rowsY; ++j )
- {
-
- ( *Zp ) = 0.0f;
- for ( k = 0; k < colsX; ++k )
- {
- ( *Zp ) += X[k + j * rowsX] * Y[j + k * rowsY];
- }
-
- Zp++;
- }
- }
- else /* Regular case */
- {
- if ( colsX != rowsY )
- {
- return EXIT_FAILURE;
- }
-
- for ( j = 0; j < colsY; ++j )
- {
- ( *Zp ) = 0.0f;
- for ( k = 0; k < colsX; ++k )
- {
- ( *Zp ) += X[j + k * rowsX] * Y[k + j * rowsY];
- }
- Zp++;
- }
- }
-
- return EXIT_SUCCESS;
-}
-
void cmplx_matrix_square_fx(
const Word32 *realX, /* i : real part of the matrix Q31 - input_exp*/
const Word32 *imagX, /* i : imaginary part of the matrix Q31 - input_exp*/
@@ -2560,87 +1860,6 @@ void cmplx_matrix_square_fx(
}
-/*---------------------------------------------------------------------*
- * cmplx_matrix_square()
- *
- * compute the square of a complex matrix (Z=X*X)
- *---------------------------------------------------------------------*/
-
-/*! r: success or failure */
-void cmplx_matrix_square(
- const float *realX, /* i : real part of the matrix */
- const float *imagX, /* i : imaginary part of the matrix */
- const int16_t mRows, /* i : number of rows of the matrix */
- const int16_t nCols, /* i : number of columns of the matrix */
- float *realZ, /* o : real part of the resulting matrix */
- float *imagZ /* o : imaginary part of the resulting matrix */
-)
-{
- int16_t i, j, k;
- float *realZp, *imagZp;
- const float *p_real1, *p_real2, *p_imag1, *p_imag2;
-
- /* resulting matrix is hermitean, we only need to calc the upper triangle */
- /* we assume transposition needed */
-
- /* column*column = column/column */
- for ( i = 0; i < nCols; i++ )
- {
- for ( j = i; j < nCols; j++ )
- {
- p_real1 = realX + i * mRows;
- p_imag1 = imagX + i * mRows;
- p_real2 = realX + j * mRows;
- p_imag2 = imagX + j * mRows;
- realZp = realZ + ( i + nCols * j );
- imagZp = imagZ + ( i + nCols * j );
- *( realZp ) = 0.0f;
- *( imagZp ) = 0.0f;
-
- for ( k = 0; k < mRows; k++ )
- {
- *( imagZp ) += *( p_real1 ) * ( *( p_imag2 ) ) - ( *( p_real2 ) ) * ( *( p_imag1 ) );
- *( realZp ) += *( p_real1++ ) * ( *( p_real2++ ) ) + *( p_imag1++ ) * ( *( p_imag2++ ) );
- }
- }
- }
-
- /* fill lower triangle */
- for ( i = 1; i < nCols; i++ )
- {
- for ( j = 0; j < i; j++ )
- {
- realZ[i + nCols * j] = realZ[j + nCols * i];
- imagZ[i + nCols * j] = imagZ[j + nCols * i];
- }
- }
-
- return;
-}
-
-/*-------------------------------------------------------------------*
- * v_multc_acc()
- *
- * Multiplication of vector by constant, accumulate to the output
- *-------------------------------------------------------------------*/
-
-void v_multc_acc(
- const float x[], /* i : Input vector */
- const float c, /* i : Constant */
- float y[], /* o : Output vector that contains y + c*x */
- const int16_t N /* i : Vector length */
-)
-{
- int16_t i;
-
- for ( i = 0; i < N; i++ )
- {
- y[i] += c * x[i];
- }
-
- return;
-}
-
void v_multc_acc_32_16(
const Word32 x[], /* i : Input vector Qx*/
const Word16 c, /* i : Constant Q31*/
@@ -2685,51 +1904,6 @@ void v_multc_acc_32_32(
* the interpolated vector is return as x[], if requested
*---------------------------------------------------------------------*/
-
-void lls_interp_n(
- float x[], /* i/o: input/output vector */
- const int16_t N, /* i : length of the input vector */
- float *a, /* o : calculated slope */
- float *b, /* o : calculated offset */
- const int16_t upd /* i : use 1 to update x[] with the interpolated output */
-)
-{
- int16_t i;
- const float n_i[11] = { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10 };
- const float one_by_n[11] = { 0, 1, 0.5f, 0.333f, 0.25f, 0.2f, 0.1666f, 0.14286f, 0.125f, 0.111111f, 0.1f };
- const float sum_i[12] = { 0, 0, 1, 3, 6, 10, 15, 21, 28, 36, 45, 55 };
- const float sum_ii[12] = { 0, 0, 1, 5, 14, 30, 55, 91, 140, 204, 285, 385 };
- float sum_x, sum_ix, slope, offset;
-
- assert( N > 0 && N <= 10 );
-
- sum_x = sum_f( x, N );
- sum_ix = dotp( x, n_i, N );
-
- slope = ( N * sum_ix - sum_i[N] * sum_x ) / ( N * sum_ii[N] - sum_i[N] * sum_i[N] );
- offset = ( sum_x - slope * sum_i[N] ) * one_by_n[N];
-
- if ( upd )
- {
- for ( i = 0; i < N; i++ )
- {
- x[i] = slope * i + offset;
- }
- }
-
- if ( a != NULL )
- {
- *a = slope;
- }
-
- if ( b != NULL )
- {
- *b = offset;
- }
-
- return;
-}
-
void lls_interp_n_fx(
Word16 x_fx[], /* i/o: input/output vector Q15*/
const Word16 N, /* i : length of the input vector Q0*/
@@ -3032,44 +2206,6 @@ void panning_wrap_angles_fx(
}
}
-/*-------------------------------------------------------------------------*
- * v_sort_ind()
- *
- * Sort a float array
- * (modified version of v_sort() to return an index array)
- *-------------------------------------------------------------------------*/
-
-void v_sort_ind(
- float *x, /* i/o: Vector to be sorted */
- int16_t *idx, /* o : Original index positions */
- const int16_t len /* i : vector length */
-)
-{
- int16_t i, j;
- float tempr;
- int16_t tempi;
-
- for ( i = 0; i < len; i++ )
- {
- idx[i] = i;
- }
-
- for ( i = len - 2; i >= 0; i-- )
- {
- tempr = x[i];
- tempi = idx[i];
- for ( j = i + 1; ( j < len ) && ( tempr > x[j] ); j++ )
- {
- x[j - 1] = x[j];
- idx[j - 1] = idx[j];
- }
- x[j - 1] = tempr;
- idx[j - 1] = tempi;
- }
-
- return;
-}
-
/*-------------------------------------------------------------------------*
* v_sort_ind_fixed()
*
@@ -3204,23 +2340,6 @@ Word16 is_SIDrate(
* generate a random value with a triangular pdf in [-0.5, 0.5]
*-------------------------------------------------------------------*/
-float rand_triangular_signed(
- int16_t *seed )
-{
- float rand_val;
- rand_val = own_random( seed ) * OUTMAX_INV;
- if ( rand_val <= 0.0f )
- {
- /* rand_val in [-1, 0] */
- return 0.5f * sqrtf( rand_val + 1.0f ) - 0.5f;
- }
- else
- {
- /* rand_val in (0, 1) */
- return 0.5f - 0.5f * sqrtf( 1.0f - rand_val );
- }
-}
-
Word16 rand_triangular_signed_fx(
Word16 *seed, /*Q0*/
Word16 *exp_fac )
diff --git a/lib_com/prot.h b/lib_com/prot.h
index 2246bc0403bad1b77896ed83d1b26a880deb61e1..c55786ae4d8aafbb747c9a1e264bde1b661aa8f3 100644
--- a/lib_com/prot.h
+++ b/lib_com/prot.h
@@ -337,13 +337,6 @@ void v_multc(
const int16_t N /* i : Vector length */
);
-void v_sub_s(
- const int16_t x1[], /* i : Input vector 1 */
- const int16_t x2[], /* i : Input vector 2 */
- int16_t y[], /* o : Output vector that contains vector 1 - vector 2 */
- const int16_t N /* i : Vector length */
-);
-
/*! r: index of the winning codeword */
int16_t squant(
const float x, /* i : scalar value to quantize */
@@ -863,17 +856,6 @@ void deemph(
float *mem /* i/o: memory (y[-1]) */
);
-/*! r: tilt of the code */
-float est_tilt(
- const float *adpt_exc, /* i : adaptive excitation vector */
- const float gain_pit, /* i : adaptive gain */
- const float *fixe_exc, /* i : algebraic exctitation vector */
- const float gain_code, /* i : algebraic code gain */
- float *voice_fac, /* o : voicing factor */
- const int16_t L_subfr, /* i : subframe size */
- const int16_t flag_tilt /* i : flag for special tilt */
-);
-
void weight_a(
const float *a, /* i : LP filter coefficients */
float *ap, /* o : weighted LP filter coefficients */
@@ -1242,16 +1224,6 @@ void stat_noise_uv_mod(
const int16_t bwidth /* i : audio bandwidth */
);
-#ifndef IVAS_FLOAT_FIXED
-void pre_echo_att(
- float *Last_frame_ener, /* i/o: Energy of the last frame */
- float *exc, /* i/o: Excitation of the current frame */
- const int16_t attack_flag, /* i : attack flag (GSC or TC) */
- const int16_t last_coder_type, /* i : Last coder type */
- const int16_t L_frame /* i : frame length */
-);
-#endif
-
void limit_band_noise_level_calc(
const int16_t *wnorm, /* i : reordered norm of sub-vectors */
int16_t *limit, /* o : highest band of bit allocation */
@@ -1569,18 +1541,6 @@ void enforce_zero_for_min_envelope(
const int16_t *sfm_end /* i : Sub band end indices */
);
-#ifndef IVAS_FLOAT_FIXED
-/*! r: Number of assigned gain bits */
-int16_t assign_gain_bits(
- const int16_t core, /* i : HQ core */
- const int16_t BANDS, /* i : Number of bands */
- const int16_t *band_width, /* i : Sub band bandwidth */
- int16_t *Rk, /* i/o: Bit allocation/Adjusted bit alloc. (Q3) */
- int16_t *gain_bits_array, /* o : Assigned gain bits */
- int16_t *Rcalc /* o : Bit budget for shape quantizer (Q3) */
-);
-#endif
-
void apply_envelope(
const float *coeff, /* i/o: Coded/noisefilled normalized spectrum */
const int16_t *norm, /* i : Envelope */
@@ -2905,16 +2865,6 @@ float gsc_gainQ(
const int32_t core_brate_inp /* i : true core brate */
);
-#ifndef IVAS_FLOAT_FIXED
-void Ener_per_band_comp(
- const float exc_diff[], /* i : gain per band */
- float y_gain4[], /* o : gain per band to quantize */
- const int16_t Mband, /* i : Max band */
- const int16_t Eflag, /* i : flag of highest band */
- const int16_t L_frame /* i : frame length */
-);
-#endif
-
void Comp_and_apply_gain(
float exc_diffQ[], /* i/o: gain per band */
float Ener_per_bd_iQ[], /* o : Quant Ener per band */
@@ -2923,30 +2873,6 @@ void Comp_and_apply_gain(
const int16_t ReUseGain /* i : Reuse the gain in Ener_per_bd_yQ */
);
-#ifndef IVAS_FLOAT_FIXED
-void bands_and_bit_alloc(
- const int16_t cor_strong_limit, /* i : HF correlation */
- const int16_t noise_lev, /* i : dwn scaling factor */
- const int32_t core_brate, /* i : core bitrate */
- const int16_t Diff_len, /* i : Lenght of the difference signal (before pure spectral)*/
- const int16_t bits_used, /* i : Number of bit used before frequency Q */
- int16_t *bit, /* i/o: Number of bit allowed for frequency quantization */
- float *ener_vec, /* i/o: Quantized energy vector */
- int16_t *max_ener_band, /* o : Sorted order */
- int16_t *bits_per_bands_s, /* i/o: Number of bit allowed per allowed subband (Q3) */
- int16_t *nb_subbands, /* o : Number of subband allowed */
- const float *exc_diff, /* i : Difference signal to quantize (encoder side only) */
- float *concat_in, /* o : Concatened PVQ's input vector (encoder side only) */
- int16_t *pvq_len, /* o : Number of bin covered with the PVQ */
- const int16_t coder_type, /* i : coding type */
- const int16_t bwidth, /* i : input signal bandwidth */
- const int16_t GSC_noisy_speech, /* i : GSC noisy speech flag */
- const int16_t L_frame, /* i : frame length */
- const int16_t element_mode, /* i : element mode */
- const int16_t GSC_IVAS_mode /* i : GSC IVAS mode */
-);
-#endif
-
void bands_and_bit_alloc_ivas_fx(
const Word16 cor_strong_limit, /* i : HF correlation */
const Word16 noise_lev, /* i : dwn scaling factor */
@@ -2969,29 +2895,6 @@ void bands_and_bit_alloc_ivas_fx(
const Word16 GSC_IVAS_mode /* i : GSC IVAS mode */
);
-#ifndef IVAS_FLOAT_FIXED
-/*! r: average frequency gain */
-float gsc_gaindec(
- Decoder_State *st, /* i/o: decoder state structure */
- float y_gainQ[], /* o : quantized gain per band */
- const int32_t core_brate, /* i : core used */
- float old_y_gain[], /* i/o: AR gain quantizer for low rate */
- const int16_t coder_type, /* i : coding type */
- const int16_t bwidth /* i : input signal bandwidth */
-);
-#endif
-
-#ifndef IVAS_FLOAT_FIXED
-void freq_dnw_scaling(
- const int16_t cor_strong_limit, /* i : HF correlation */
- const int16_t coder_type, /* i : coder type */
- const int16_t noise_lev, /* i : Noise level */
- const int32_t core_brate, /* i : Core bitrate */
- float fy_norm[], /* i/o: Frequency quantized parameter */
- const int16_t L_frame /* i : frame length */
-);
-#endif
-
void GSC_dec_init_ivas(
GSC_DEC_HANDLE hGSCDec /* i/o: GSC data handle */
);
@@ -3042,38 +2945,6 @@ void dec_pit_exc(
const float tdm_Pri_pitch_buf[] /* i : primary channel pitch buffer */
);
-#ifndef IVAS_FLOAT_FIXED
-void highband_exc_dct_in(
- const int32_t core_brate, /* i : core bitrate */
- const int16_t *mfreq_bindiv_loc, /* i : bin per bands tables */
- int16_t last_bin, /* i : last bin of bit allocation */
- int16_t Diff_len, /* i : number of bin before cut-off frequency */
- int16_t noise_lev, /* i : pulses dynamic */
- int16_t pit_band_idx, /* i : bin position of the cut-off frequency */
- float *exc_diffQ, /* i : frequency coefficients of per band */
- int16_t *seed_tcx, /* i : Seed for noise */
- float *Ener_per_bd_iQ, /* i : Quantized energy of targeted vector */
- int16_t nb_subfr, /* i : Number of subframe considered */
- float *exc_dct_in, /* o : dct of residual signal */
- int16_t last_coder_type, /* i : coding type of last frame */
- int16_t *bitallocation_band, /* i : bit allocation flag of each band */
- const float *lsf_new, /* i : ISFs at the end of the frame */
- float *last_exc_dct_in, /* i : dct of residual signal of last frame */
- float *last_ener, /* i : frequency energy of last frame */
- int16_t *last_bitallocation_band, /* i : bit allocation flag of each band of last frame */
- int16_t *bitallocation_exc, /* i : flag of decoded coefficients */
- const int16_t bfi, /* i : bad frame indicator */
- const int16_t coder_type, /* i : coder type */
- const int16_t bwidth, /* i : audio bandwidth */
- float *exc_wo_nf, /* o : excitation (in f domain) without noisefill */
- const int16_t GSC_noisy_speech, /* i : GSC noisy speech flag */
- float *lt_ener_per_band_fx, /* i/o: Average per band energy */
- const int16_t L_frame, /* i : frame length */
- const int16_t element_mode, /* i : IVAS element moden */
- const int16_t GSC_IVAS_mode /* i : GSC IVAS mode */
-);
-#endif
-
void music_postfilt_init_flt(
MUSIC_POSTFILT_HANDLE hMusicPF /* i/o: LD music postfilter handle */
);
@@ -5795,14 +5666,6 @@ void adapt_lag_wind_fx(
const int32_t sr_core /* i : core sampling rate */
);
-#ifndef IVAS_FLOAT_FIXED
-void hp20_flt(
- Float32 signal[],
- const Word16 lg,
- Float32 mem[],
- const Word32 Fs );
-#endif
-
void init_coder_ace_plus(
Encoder_State *st, /* i : Encoder state handle */
const int32_t last_total_brate, /* i : last total bitrate */
@@ -5945,16 +5808,6 @@ void core_signal_analysis_high_bitrate(
const int16_t vad_hover_flag /* i : VAD hangover flag */
);
-#ifndef IVAS_FLOAT_FIXED
-/*! r: codebook gain (adaptive or fixed) */
-float get_gain_flt(
- const float x[], /* i : target signal */
- const float y[], /* i : filtered codebook excitation */
- const int16_t n, /* i : segment length */
- float *en_y /* o : energy of y (sum of y[]^2, optional) */
-);
-#endif
-
void encode_acelp_gains(
const float *code,
const int16_t gains_mode,
@@ -8022,17 +7875,6 @@ float Damping_fact_flt(
const int16_t core /* i : current core: ACELP = 0, TCX20 = 1, TCX10 = 2 */
);
-#ifndef IVAS_FLOAT_FIXED
-void fer_energy(
- const int16_t L_frame, /* i : frame length */
- const int16_t clas, /* i : frame classification */
- const float synth[], /* i : synthesized speech at Fs = 12k8 Hz */
- const float pitch, /* i : pitch period */
- float *enr, /* o : pitch-synchronous or half_frame energy */
- const int16_t useOffset /* i : speech pointer offset (0 or L_FRAME) */
-);
-#endif
-
float getLevelSynDeemph(
const float h1Init[], /* i : input value or vector to be processed */
const float A[], /* i : LPC coefficients */
diff --git a/lib_com/rom_com.c b/lib_com/rom_com.c
index 254c3df9d9e36baa5af8afd2bd3a7a6cde2d59e2..612e30bdf6d5a833984683cc135d7797466c2f83 100644
--- a/lib_com/rom_com.c
+++ b/lib_com/rom_com.c
@@ -475,12 +475,6 @@ const Word16 ACELP_CDK_BITS[ACELP_FIXED_CDK_NB] =
* Perceptual critical bands
*----------------------------------------------------------------------------------*/
-const float crit_bands[] =
-{
- 100.0f, 200.0f, 300.0f, 400.0f, 510.0f, 630.0f, 770.0f, 920.0f, 1080.0f, 1270.0f, 1480.0f,
- 1720.0f, 2000.0f, 2320.0f, 2700.0f, 3150.0f, 3700.0f, 4400.0f, 5300.0f, 6350.0f, 7700.0f,
- 9500.0f, 12000.0f, 15500.0f, 40000.0f
-};
const Word32 crit_bands_fx[] =//Q0
{
100, 200, 300, 400, 510, 630, 770, 920, 1080, 1270, 1480,
@@ -793,138 +787,6 @@ const Word16 assym_window_16k_fx[L_LP_16k] = /*Q15*/
2756, 2720, 2690, 2665, 2646, 2632, 2624, 2621
};
-/* LAGW_STRONG */
-const float lag_window_8k_flt[17] =
-{
- 1.0001f,
- 0.998890285694f, 0.995568526105f, 0.990056789412f, 0.982391584471f,
- 0.972623458067f, 0.960816439805f, 0.947047343167f, 0.931404933402f,
- 0.913988974871f, 0.894909172129f, 0.874284020465f, 0.852239582728f,
- 0.828908210054f, 0.804427224606f, 0.778937582562f, 0.752582535421f
-};
-
-const float lag_window_12k8_flt[NUM_LAGW_STRENGTHS][17] =
-{
- /* LAGW_WEAK */
- {
- 1.0001f,
- 0.999951809733f, 0.999807252867f, 0.999566371195f, 0.999229234349f,
- 0.998795939769f, 0.998266612656f, 0.997641405905f, 0.996920500042f,
- 0.996104103128f, 0.995192450664f, 0.994185805476f, 0.993084457589f,
- 0.991888724088f, 0.990598948965f, 0.989215502956f, 0.987738783362f
- },
- /* LAGW_MEDIUM */
- {
- 1.0001f,
- 0.999807252867f, 0.999229234349f, 0.998266612656f, 0.996920500042f,
- 0.995192450664f, 0.993084457589f, 0.990598948965f, 0.987738783362f,
- 0.984507244288f, 0.980908033914f, 0.976945266001f, 0.972623458067f,
- 0.967947522806f, 0.962922758784f, 0.957554840431f, 0.951849807369f
- },
- /* LAGW_STRONG */
- {
- 1.0001f,
- 0.999566371183f, 0.998266612613f, 0.996104103033f, 0.993084457421f,
- 0.989215493202f, 0.984507262707f, 0.978971838951f, 0.972623467445f,
- 0.965478420258f, 0.957554817200f, 0.948872864246f, 0.939454317093f,
- 0.929322779179f, 0.918503403664f, 0.907022833824f, 0.894909143448f
- }
-};
-
-const float lag_window_16k_flt[NUM_LAGW_STRENGTHS][17] =
-{
- /* LAGW_WEAK */
- {
- 1.0001f,
- 0.999969157962f, 0.999876637555f, 0.999722455899f, 0.999506641521f,
- 0.999229234349f, 0.998890285694f, 0.998489858239f, 0.998028026020f,
- 0.997504874399f, 0.996920500042f, 0.996275010885f, 0.995568526105f,
- 0.994801176082f, 0.993973102356f, 0.993084457589f, 0.992135405511f
- },
- /* LAGW_MEDIUM */
- {
- 1.0001f,
- 0.999876637555f, 0.999506641521f, 0.998890285694f, 0.998028026020f,
- 0.996920500042f, 0.995568526105f, 0.993973102356f, 0.992135405511f,
- 0.990056789412f, 0.987738783362f, 0.985183090250f, 0.982391584471f,
- 0.979366309628f, 0.976109476043f, 0.972623458067f, 0.968910791191f
- },
- /* LAGW_STRONG */
- {
- 1.0001f,
- 0.999722455899f, 0.998890285694f, 0.997504874399f, 0.995568526105f,
- 0.993084457589f, 0.990056789412f, 0.986490534533f, 0.982391584471f,
- 0.977766693093f, 0.972623458067f, 0.966970300068f, 0.960816439805f,
- 0.954171872966f, 0.947047343167f, 0.939454313017f, 0.931404933402f
- }
-};
-
-const float lag_window_25k6_flt[NUM_LAGW_STRENGTHS][17] =
-{
- /* LAGW_WEAK */
- {
- 1.0001f,
- 0.999987952216f, 0.999951809733f, 0.999891575166f, 0.999807252867f,
- 0.999698848932f, 0.999566371195f, 0.999409829230f, 0.999229234349f,
- 0.999024599601f, 0.998795939769f, 0.998543271372f, 0.998266612656f,
- 0.997965983599f, 0.997641405905f, 0.997292903003f, 0.996920500042f
- },
- /* LAGW_MEDIUM */
- {
- 1.0001f,
- 0.999951809733f, 0.999807252867f, 0.999566371195f, 0.999229234349f,
- 0.998795939769f, 0.998266612656f, 0.997641405905f, 0.996920500042f,
- 0.996104103128f, 0.995192450664f, 0.994185805476f, 0.993084457589f,
- 0.991888724088f, 0.990598948965f, 0.989215502956f, 0.987738783362f
- },
- /* LAGW_STRONG */
- {
- 1.0001f,
- 0.999891579151f, 0.999566376209f, 0.999024569988f, 0.998266637325f,
- 0.997292876244f, 0.996104121208f, 0.994700968266f, 0.993084430695f,
- 0.991255581379f, 0.989215493202f, 0.986965596676f, 0.984507262707f,
- 0.981842100620f, 0.978971838951f, 0.975898265839f, 0.972623467445f
- }
-};
-
-const float lag_window_32k_flt[NUM_LAGW_STRENGTHS][17] =
-{
- /* LAGW_WEAK */
- {
- 1.0001f,
- 0.999992289401f, 0.999969157962f, 0.999930606752f, 0.999876637555f,
- 0.999807252867f, 0.999722455899f, 0.999622250572f, 0.999506641521f,
- 0.999375634094f, 0.999229234349f, 0.999067449055f, 0.998890285694f,
- 0.998697752455f, 0.998489858239f, 0.998266612656f, 0.998028026020f
- },
- /* LAGW_MEDIUM */
- {
- 1.0001f,
- 0.999969157962f, 0.999876637555f, 0.999722455899f, 0.999506641521f,
- 0.999229234349f, 0.998890285694f, 0.998489858239f, 0.998028026020f,
- 0.997504874399f, 0.996920500042f, 0.996275010885f, 0.995568526105f,
- 0.994801176082f, 0.993973102356f, 0.993084457589f, 0.992135405511f
- },
- /* LAGW_STRONG */
- {
- 1.0001f,
- 0.999930606752f, 0.999722455899f, 0.999375634094f, 0.998890285694f,
- 0.998266612656f, 0.997504874399f, 0.996605387628f, 0.995568526105f,
- 0.994394720400f, 0.993084457589f, 0.991638280913f, 0.990056789412f,
- 0.988340637503f, 0.986490534533f, 0.984507244288f, 0.982391584471f
- }
-};
-
-/* LAGW_STRONG */
-const float lag_window_48k_flt[17] =
-{
- 1.0001f,
- 0.999969157962f, 0.999876637555f, 0.999722455899f, 0.999506641521f,
- 0.999229234349f, 0.998890285694f, 0.998489858239f, 0.998028026020f,
- 0.997504874399f, 0.996920500042f, 0.996275010885f, 0.995568526105f,
- 0.994801176082f, 0.993973102356f, 0.993084457589f, 0.992135405511f
-};
-
const Word16 lag_window_8k[2][16] = /* LAGW_STRONG Q15*/
{
/* h */ { 32728, 32619, 32438, 32187, 31867, 31480, 31029, 30517, 29946, 29321, 28645, 27923, 27158, 26356, 25521, 24658 },
@@ -1103,44 +965,6 @@ const Word16 grid40_fx[(GRID40_POINTS - 1) / 2 - 1] =
* Sinus & Cosinus - table for the FFT and IFFT of 256 points,
* dimension of the table = 161
*----------------------------------------------------------------------------------*/
-
-const float sincos_t[161] =
-{
- 0.0f,
- 0.0245412290096282960f, 0.0490676760673522950f, 0.0735645666718482970f, 0.0980171412229537960f, 0.1224106773734092700f,
- 0.1467304676771163900f, 0.1709618866443634000f, 0.1950903236865997300f, 0.2191012352705001800f, 0.2429801821708679200f,
- 0.2667127549648284900f, 0.2902846634387970000f, 0.3136817514896392800f, 0.3368898630142211900f, 0.3598950505256652800f,
- 0.3826834261417388900f, 0.4052413105964660600f, 0.4275550842285156300f, 0.4496113359928131100f, 0.4713967442512512200f,
- 0.4928981959819793700f, 0.5141027569770813000f, 0.5349976420402526900f, 0.5555702447891235400f, 0.5758081674575805700f,
- 0.5956993103027343800f, 0.6152315735816955600f, 0.6343932747840881300f, 0.6531728506088256800f, 0.6715589761734008800f,
- 0.6895405650138855000f, 0.7071067690849304200f, 0.7242470979690551800f, 0.7409511208534240700f, 0.7572088241577148400f,
- 0.7730104327201843300f, 0.7883464097976684600f, 0.8032075166702270500f, 0.8175848126411438000f, 0.8314695954322814900f,
- 0.8448535799980163600f, 0.8577286005020141600f, 0.8700869679450988800f, 0.8819212913513183600f, 0.8932242989540100100f,
- 0.9039893150329589800f, 0.9142097830772399900f, 0.9238795042037963900f, 0.9329928159713745100f, 0.9415440559387207000f,
- 0.9495281577110290500f, 0.9569403529167175300f, 0.9637760519981384300f, 0.9700312614440918000f, 0.9757021069526672400f,
- 0.9807852506637573200f, 0.9852776527404785200f, 0.9891765117645263700f, 0.9924795627593994100f, 0.9951847195625305200f,
- 0.9972904324531555200f, 0.9987954497337341300f, 0.9996988177299499500f, 1.0000000000000000000f, 0.9996988177299499500f,
- 0.9987954497337341300f, 0.9972904324531555200f, 0.9951847195625305200f, 0.9924795627593994100f, 0.9891765117645263700f,
- 0.9852776527404785200f, 0.9807852506637573200f, 0.9757021069526672400f, 0.9700312614440918000f, 0.9637760519981384300f,
- 0.9569403529167175300f, 0.9495281577110290500f, 0.9415440559387207000f, 0.9329928159713745100f, 0.9238795042037963900f,
- 0.9142097830772399900f, 0.9039893150329589800f, 0.8932242989540100100f, 0.8819212913513183600f, 0.8700869679450988800f,
- 0.8577286005020141600f, 0.8448535799980163600f, 0.8314695954322814900f, 0.8175848126411438000f, 0.8032075166702270500f,
- 0.7883464097976684600f, 0.7730104327201843300f, 0.7572088241577148400f, 0.7409511208534240700f, 0.7242470979690551800f,
- 0.7071067690849304200f, 0.6895405650138855000f, 0.6715589761734008800f, 0.6531728506088256800f, 0.6343932747840881300f,
- 0.6152315735816955600f, 0.5956993103027343800f, 0.5758081674575805700f, 0.5555702447891235400f, 0.5349976420402526900f,
- 0.5141027569770813000f, 0.4928981959819793700f, 0.4713967442512512200f, 0.4496113359928131100f, 0.4275550842285156300f,
- 0.4052413105964660600f, 0.3826834261417388900f, 0.3598950505256652800f, 0.3368898630142211900f, 0.3136817514896392800f,
- 0.2902846634387970000f, 0.2667127549648284900f, 0.2429801821708679200f, 0.2191012352705001800f, 0.1950903236865997300f,
- 0.1709618866443634000f, 0.1467304676771163900f, 0.1224106773734092700f, 0.0980171412229537960f, 0.0735645666718482970f,
- 0.0490676723420619960f, 0.0245412290096282960f, -0.00000000041020686847303978f, -0.0245412290096282960f, -0.0490676760673522950f,
- -0.0735645666718482970f, -0.0980171412229537960f, -0.1224106773734092700f, -0.1467304676771163900f, -0.1709618866443634000f,
- -0.1950903236865997300f, -0.2191012352705001800f, -0.2429801821708679200f, -0.2667127549648284900f, -0.2902846634387970000f,
- -0.3136817514896392800f, -0.3368898630142211900f, -0.3598950505256652800f, -0.3826834261417388900f, -0.4052413105964660600f,
- -0.4275550842285156300f, -0.4496113359928131100f, -0.4713967442512512200f, -0.4928981959819793700f, -0.5141027569770813000f,
- -0.5349976420402526900f, -0.5555702447891235400f, -0.5758081674575805700f, -0.5956993103027343800f, -0.6152315735816955600f,
- -0.6343932747840881300f, -0.6531728506088256800f, -0.6715589761734008800f, -0.6895405650138855000f, -0.7071067690849304200f
-};
-
const Word16 sincos_t_fx[161] =
{
/*Q15 */
@@ -2116,7 +1940,7 @@ const PulseConfig PulseConfTable[] =
/* Number of pulses & positions to the number of unique states that can be achieved with those pulses */
-const uint32_t pulsestostates[17][9] =
+const UWord32 pulsestostates[17][9] =
{
{ 0, 0, 0, 0, 0, 0, 0, 0, 0},
{ 2, 2, 2, 2, 2, 2, 2, 2, 2},
@@ -11603,7 +11427,7 @@ const Word16 BitsVQ_p[]=
}; // Q0
-const int16_t predmode_tab_float[][6] =
+const Word16 predmode_tab_float[][6] =
{
{1,1,2,2,0,2},
{1,1,2,2,0,2},
@@ -12189,58 +12013,6 @@ const Word16 *const Quantizers_fx[] = { SVNB_SN1_fx, SVNB_SN2_fx, GETRNB_SN1_fx,
const Word16 *const Quantizers_p_fx[] = { IAA_MA1_fx, UVD_MA1_fx, UVD_MA2_fx, UVWB_MA3_fx, GESVNB_AR1_fx, GESVNB_AR2_fx, GESVWB_AR1_fx, GESVWB_AR2_fx,
GEWB2_MA1_fx,GEWB_MA1_fx, AUWB2_MA1_fx, SVWB2_AR1_fx, SVWB2_AR2_fx
};//Qlog2(2.56)
-const float vals[NO_LEADERS][MAX_NO_VALS]=
-{
- {1.0f, 0.0f, 0.0f, 0.0f},
- {0.5f, 0.0f, 0.0f, 0.0f},
- {1.0f, 0.0f, 0.0f, 0.0f},
- {2.0f, 0.0f, 0.0f, 0.0f},
- {1.5f, 0.5f, 0.0f, 0.0f},
- {1.0f, 0.0f, 0.0f, 0.0f},
- {2.0f, 1.0f, 0.0f, 0.0f},
- {1.5f, 0.5f, 0.0f, 0.0f},
- {1.0f, 0.0f, 0.0f, 0.0f},
- {2.0f, 1.0f, 0.0f, 0.0f},
- {2.0f, 0.0f, 0.0f, 0.0f},
- {1.5f, 0.5f, 0.0f, 0.0f},
- {2.5f, 0.5f, 0.0f, 0.0f},
- {2.0f, 1.0f, 0.0f, 0.0f},
- {2.0f, 1.0f, 0.0f, 0.0f},
- {3.0f, 1.0f, 0.0f, 0.0f},
- {1.5f, 0.5f, 0.0f, 0.0f},
- {2.5f, 1.5f, 0.5f, 0.0f},
- {2.0f, 1.0f, 0.0f, 0.0f},
- {2.0f, 0.0f, 0.0f, 0.0f},
- {3.0f, 1.0f, 0.0f, 0.0f},
- {1.5f, 0.5f, 0.0f, 0.0f},
- {2.5f, 1.5f, 0.5f, 0.0f},
- {2.0f, 1.0f, 0.0f, 0.0f},
- {2.0f, 1.0f, 0.0f, 0.0f},
- {3.0f, 1.0f, 0.0f, 0.0f},
- {3.0f, 2.0f, 1.0f, 0.0f},
- {1.5f, 0.5f, 0.0f, 0.0f},
- {2.5f, 1.5f, 0.5f, 0.0f},
- {2.5f, 0.5f, 0.0f, 0.0f},
- {3.5f, 0.5f, 0.0f, 0.0f},
- {2.0f, 1.0f, 0.0f, 0.0f},
- {2.0f, 0.0f, 0.0f, 0.0f},
- {3.0f, 1.0f, 0.0f, 0.0f},
- {3.0f, 2.0f, 1.0f, 0.0f},
- {4.0f, 0.0f, 0.0f, 0.0f},
- {1.5f, 0.5f, 0.0f, 0.0f},
- {2.5f, 1.5f, 0.5f, 0.0f},
- {2.5f, 1.5f, 0.5f, 0.0f},
- {3.5f, 1.5f, 0.5f, 0.0f},
- {2.0f, 1.0f, 0.0f, 0.0f},
- {3.0f, 2.0f, 1.0f, 0.0f},
- {3.0f, 2.0f, 1.0f, 0.0f},
- {3.0f, 0.0f, 0.0f, 0.0f},
- {4.0f, 1.0f, 0.0f, 0.0f},
- {1.5f, 0.0f, 0.0f, 0.0f},
- {2.5f, 1.5f, 0.5f, 0.0f},
- {2.5f, 1.5f, 0.5f, 0.0f},
- {3.5f, 1.5f, 0.5f, 0.0f}
-};
const Word16 vals_fx[NO_LEADERS][MAX_NO_VALS] = /*Q1 */
{
@@ -12486,449 +12258,6 @@ const Word16 pl_par[] = /* 1 if even number of signs */
0, 0, 0, 0, -1, 1, -1, 1, 0, 0, 0, 0, 0, 1, -1, 1, -1
}; // Q0
-const float scales[][MAX_NO_SCALES*2]= /* 2 subvectors */
-{
- {1.528f, 0.000f, 0.000f, 1.532f, 0.000f, 0.000f, }, /* 14 */
- {1.605f, 0.000f, 0.000f, 1.532f, 0.000f, 0.000f, }, /* 15 */
- {1.275f, 2.458f, 0.000f, 1.532f, 0.000f, 0.000f, }, /* 18 */
- {1.275f, 2.458f, 0.000f, 1.631f, 0.000f, 0.000f, }, /* 19 */
- {1.057f, 1.794f, 2.896f, 1.154f, 1.860f, 3.067f, }, /* 25 */
- {0.927f, 1.458f, 2.317f, 1.033f, 1.791f, 3.440f, }, /* 28*/ /* mode 0 UV WB*/
-
- {1.284f, 2.676f, 0.000f, 1.451f, 0.000f, 0.000f, }, /* 18 */
- {1.368f, 0.000f, 0.000f, 1.401f, 2.477f, 0.000f, }, /* 19 */
- {0.861f, 1.243f, 1.818f, 1.228f, 2.226f, 10.307f, }, /* 24 */
- {1.072f, 1.934f, 3.633f, 1.221f, 2.938f, 10.723f, }, /* 25 */
- {0.899f, 1.417f, 0.677f, 1.033f, 1.837f, 10.893f, }, /* 29 */
- {0.830f, 1.323f, 0.629f, 0.911f, 1.585f, 10.088f, }, /* 32 */ /* mode 1 UV NB*/
- {1.573f, 0.000f, 0.000f, 1.656f, 0.000f, 0.000f, }, /* 17 */
- {1.239f, 2.404f, 0.000f, 1.556f, 0.000f, 0.000f, }, /* 18 */
- {1.375f, 2.065f, 3.124f, 1.795f, 0.000f, 0.000f, }, /* (18.745) 19 */
- {1.375f, 2.065f, 3.124f, 1.901f, 0.000f, 0.000f, }, /* (19.838) 20 */
- {1.055f, 1.700f, 4.439f, 1.656f, 0.000f, 0.000f, }, /* 21 */
- {1.250f, 2.404f, 4.132f, 1.355f, 2.361f, 0.000f, }, /* 22 */
- {1.246f, 1.857f, 2.744f, 1.500f, 2.704f, 0.000f, }, /* (22.959) 23 */
- {1.243f, 2.054f, 3.638f, 1.577f, 0.000f, 0.000f, }, /* (23.949) 24 */
- {1.056f, 1.785f, 4.523f, 1.318f, 2.586f, 0.000f, }, /* 25 */
- {0.996f, 1.505f, 3.355f, 1.185f, 1.776f, 2.728f, },
- {0.929f, 1.387f, 3.357f, 1.080f, 1.701f, 2.885f, },
- {0.922f, 1.493f, 3.369f, 1.080f, 1.701f, 2.885f, },
- {0.922f, 1.493f, 3.369f, 1.066f, 1.694f, 3.135f, },
- {0.922f, 1.493f, 3.369f, 0.962f, 1.550f, 3.946f, }, /* 30 */
- {1.286f, 0.906f, 2.422f, 1.124f, 1.698f, 2.482f, }, /* (30.994) 31 */
- {0.746f, 1.108f, 2.869f, 0.959f, 1.481f, 3.907f, }, /* 32 */
- {0.770f, 1.194f, 2.823f, 0.907f, 1.402f, 2.116f, }, /* 33*/
- {0.748f, 1.103f, 2.866f, 1.182f, 0.811f, 3.332f, }, /* 34*/
- {0.765f, 1.132f, 1.844f, 1.242f, 1.893f, 0.922f, }, /* (34.981) 35 */
- {0.766f, 1.133f, 1.846f, 1.066f, 1.641f, 0.813f, }, /* (35.998) 36 */
- {0.677f, 0.963f, 2.127f, 0.726f, 1.082f, 2.204f, }, /* 37*/ /* mode 2 V WB*/
-
- {1.639f, 0.000f, 0.000f, 1.218f, 2.161f, 0.000f, }, /* 17 */
- {1.286f, 2.446f, 0.000f, 1.410f, 0.000f, 0.000f, }, /* 18 */
- {1.086f, 1.728f, 3.758f, 1.218f, 2.161f, 0.000f, }, /* 22 */
- {1.035f, 1.575f, 4.815f, 1.218f, 2.161f, 0.000f, }, /* 23 */
- {0.964f, 1.533f, 4.942f, 1.218f, 2.161f, 0.000f, }, /* 24 */
- {0.841f, 1.198f, 1.982f, 1.218f, 2.161f, 0.000f, }, /* 25 */
- {0.898f, 1.298f, 2.184f, 1.216f, 2.664f, 0.000f, }, /* 27 */
- {0.841f, 1.237f, 2.237f, 0.995f, 1.657f, 2.836f, }, /* 29 */
- {0.697f, 0.981f, 2.043f, 0.935f, 1.505f, 0.659f, }, /* 34 */
- {0.669f, 0.909f, 1.328f, 0.985f, 0.654f, 1.911f, }, /* 37 */ /* mode 3 V NB*/
-
- {1.212f, 1.897f, 0.000f, 0.000f, 0.000f, 0.000f, }, /* 12 (11.883) */
- {1.160f, 1.869f, 3.406f, 0.000f, 0.000f, 0.000f, }, /* (12.997) 13 */
- {1.658f, 0.000f, 0.000f, 1.896f, 0.000f, 0.000f, }, /* (13.640) 14 */
- {1.740f, 0.000f, 0.000f, 1.896f, 0.000f, 0.000f, }, /* (14.733) 15 */
- {1.634f, 0.000f, 0.000f, 1.669f, 0.000f, 0.000f, }, /* 16 (15.826) */
- {1.740f, 0.000f, 0.000f, 2.016f, 0.000f, 0.000f, }, /* (15.826) 16 */
- {1.377f, 2.548f, 0.000f, 1.896f, 0.000f, 0.000f, }, /* (17.479) 18 */
- {1.288f, 2.423f, 0.000f, 1.669f, 0.000f, 0.000f, }, /* 19 (18.572) */
- {1.212f, 1.897f, 0.000f, 1.669f, 0.000f, 0.000f, }, /* 20 (19.796) */
- {1.083f, 1.766f, 3.175f, 1.669f, 0.000f, 0.000f, }, /* 21 (20.910) */
- {1.037f, 1.609f, 4.228f, 1.669f, 0.000f, 0.000f, }, /* 22 (21.776) */
- {1.095f, 1.659f, 2.716f, 1.315f, 2.506f, 0.000f, }, /* 23 (22.959) */
- {1.166f, 1.965f, 3.654f, 1.686f, 0.000f, 0.000f, }, /* (23.949) 24 */
- {0.941f, 1.386f, 2.221f, 1.315f, 2.506f, 0.000f, }, /* 25 (24.992) */
- {0.908f, 1.306f, 1.901f, 1.320f, 2.623f, 0.000f, }, /* 26 (25.904) */
- {1.075f, 1.767f, 0.790f, 1.320f, 2.623f, 0.000f, }, /* 27 (26.829) */
- {1.022f, 1.531f, 0.759f, 1.110f, 1.755f, 2.594f, }, /* 28 (27.989) */
- {1.075f, 1.767f, 0.790f, 1.093f, 1.902f, 3.014f, }, /* 29 (28.984) */
- {0.893f, 1.472f, 0.675f, 1.103f, 1.770f, 2.842f, }, /* 30 (29.980) */
- {0.910f, 1.548f, 0.685f, 1.032f, 1.651f, 2.513f, }, /* 31 (30.966) */
- {0.826f, 1.256f, 0.632f, 0.981f, 1.542f, 2.217f, }, /* 32 (31.995) */ /* G WB*/
-
- {1.184f, 1.810f, 2.761f, 0.000f, 0.000f, 0.000f, }, /* 12 (11.925) */
- {1.611f, 0.000f, 0.000f, 1.618f, 0.000f, 0.000f, }, /* 16 (15.826) */
- {1.184f, 1.810f, 2.761f, 1.550f, 0.000f, 0.000f, }, /* 19 (18.745) */
- {1.184f, 1.810f, 2.761f, 1.618f, 0.000f, 0.000f, }, /* 20 (19.838) */
- {1.063f, 1.737f, 2.985f, 1.618f, 0.000f, 0.000f, }, /* 21 (20.910) */
- {1.078f, 1.825f, 3.162f, 1.469f, 2.249f, 0.000f, }, /* 22 (21.985) */
- {1.375f, 0.915f, 2.082f, 1.469f, 2.249f, 0.000f, }, /* 23 (22.815) */
- {0.960f, 1.423f, 0.700f, 1.310f, 2.132f, 0.000f, }, /* 25 (24.996) */
- {1.124f, 0.794f, 1.902f, 1.283f, 2.302f, 0.000f, }, /* 26 (25.993) */
- {1.077f, 1.727f, 0.767f, 1.250f, 1.951f, 2.981f, }, /* 27 (26.954) */
- {0.933f, 1.471f, 0.685f, 1.250f, 1.951f, 2.981f, }, /* 28 (27.992) */
- {0.927f, 1.600f, 0.674f, 1.154f, 1.776f, 2.854f, }, /* 29 (28.996) */
- {1.047f, 0.722f, 1.785f, 1.056f, 1.642f, 2.701f, }, /* 30 (29.988) */
- {0.971f, 0.688f, 1.509f, 1.043f, 1.730f, 2.931f, }, /* 31 (30.962) */
- {0.919f, 0.662f, 1.367f, 1.057f, 1.808f, 3.069f, }, /* 32 (31.987) */ /* G NB*/
-
- {1.617f, 0.000f, 0.000f, 1.657f, 0.000f, 0.000f, }, /* 17 */
- {1.275f, 2.298f, 0.000f, 1.563f, 0.000f, 0.000f, }, /* 18 */
- {1.377f, 2.548f, 0.000f, 2.016f, 0.000f, 0.000f, }, /* (18.572) 19 */ /* from GEWB */
- {1.299f, 2.019f, 0.000f, 2.016f, 0.000f, 0.000f, }, /* (19.796) 20 */
- {1.308f, 2.354f, 0.000f, 1.387f, 0.000f, 0.000f, }, /* 21 */
- {1.291f, 2.418f, 0.000f, 1.355f, 2.443f, 0.000f, }, /* 22 */
- {1.173f, 1.767f, 2.796f, 1.588f, 3.028f, 0.000f, }, /* (22.959) 23 */ /* from GEWB */
- {1.079f, 1.769f, 3.012f, 1.387f, 0.000f, 0.000f, }, /* 24 */
- {1.079f, 1.769f, 3.012f, 1.325f, 2.555f, 0.000f, }, /* 25 */
- {0.973f, 1.392f, 2.014f, 1.593f, 3.183f, 0.000f, }, /* (25.904) 26 */ /* from GEWB */
- {1.149f, 1.873f, 0.848f, 1.593f, 3.183f, 0.000f, }, /* (26.829) 27 */
- {0.897f, 1.340f, 2.604f, 1.070f, 1.689f, 2.527f, }, /* 28 */
- {1.149f, 1.873f, 0.848f, 1.319f, 2.288f, 3.687f, }, /* (28.984) 29 */ /* from GEWB */
- {0.897f, 1.340f, 2.604f, 0.939f, 1.454f, 2.083f, }, /* 30 */
- {0.905f, 1.327f, 2.599f, 1.109f, 0.777f, 1.705f, },
- {0.762f, 1.101f, 2.359f, 0.939f, 1.454f, 2.083f, },
- {0.794f, 1.226f, 3.180f, 1.109f, 0.777f, 1.705f, }, /* 33 */ /* mode 6 T WB */
-
- {1.629f, 0.000f, 0.000f, 1.191f, 2.211f, 0.000f, }, /* 17 */
- {1.277f, 2.557f, 0.000f, 1.367f, 0.000f, 0.000f, }, /* 18 */
- {1.082f, 1.761f, 3.929f, 1.191f, 2.211f, 0.000f, }, /* 22 */
- {1.018f, 1.535f, 2.808f, 1.191f, 2.211f, 0.000f, }, /* 23 */
- {0.944f, 1.477f, 2.763f, 1.191f, 2.211f, 0.000f, }, /* 24 */
- {0.910f, 1.744f, 3.317f, 1.191f, 2.211f, 0.000f, }, /* 25 */
- {0.920f, 1.648f, 3.068f, 0.969f, 1.683f, 3.953f, }, /* 28 */
- {0.739f, 1.111f, 2.694f, 0.879f, 1.411f, 2.305f, }, /* 31 */
- {0.709f, 1.032f, 2.717f, 0.810f, 1.245f, 1.824f, }, /* 32*/ /* mode 7 T NB*/
-
- {0.758f, 1.116f, 1.964f, 2.021f, 0.798f, 1.219f, }, /* 31 */
- {0.699f, 1.034f, 1.978f, 2.021f, 0.798f, 1.219f, }, /* 32 */ /* mode 8 G 16k */
-
- {0.726f, 1.050f, 1.845f, 1.355f, 0.860f, 2.205f, }, /* 32 (31.998) */
- {0.677f, 0.997f, 1.669f, 1.355f, 0.860f, 2.205f, }, /* 33 (32.983) mode 9 T16k */
-
- {1.646f, 0.000f, 0.000f, 1.254f, 2.459f, 0.000f, }, /* 17 */
- {1.480f, 2.941f, 0.000f, 1.823f, 0.000f, 0.000f, }, /* (17.479) 18 */
- {1.368f, 2.297f, 0.000f, 1.823f, 0.000f, 0.000f, }, /* (18.703) 19 */
- {1.368f, 2.297f, 0.000f, 1.985f, 0.000f, 0.000f, }, /* (19.796) 20 */
- {1.073f, 1.863f, 3.231f, 1.678f, 0.000f, 0.000f, }, /* 21 */
- {1.073f, 1.863f, 3.231f, 1.254f, 2.459f, 0.000f, }, /* 22 */
- {1.056f, 1.577f, 2.467f, 1.806f, 2.990f, 0.000f, }, /* (22.917) 23 */
- {1.130f, 1.818f, 0.836f, 1.985f, 0.000f, 0.000f, }, /* (23.978) 24 */
- {0.951f, 1.492f, 2.496f, 1.255f, 2.971f, 0.000f, }, /* 25 */
- {1.148f, 1.841f, 0.813f, 1.255f, 2.971f, 0.000f, }, /* 26 */
- {1.148f, 0.809f, 1.920f, 1.530f, 2.736f, 0.000f, }, /* (26.953) 27 */
- {1.206f, 0.851f, 2.180f, 1.513f, 3.176f, 0.000f, }, /* (27.992) 28 */
- {0.804f, 1.200f, 1.976f, 1.504f, 3.210f, 0.000f, }, /* (28.992) 29 */
- {1.141f, 0.806f, 1.915f, 1.973f, 1.166f, 3.713f, }, /* (29.976) 30 */
- {1.118f, 0.778f, 2.026f, 1.239f, 2.139f, 3.775f, }, /* (30.963) 31 */
- {0.770f, 1.134f, 1.915f, 1.231f, 2.298f, 3.880f, }, /* (31.995) 32 */
- {1.025f, 0.709f, 1.731f, 1.231f, 2.298f, 3.880f, }, /* (32.996) 33 */
- {0.967f, 0.713f, 1.653f, 1.840f, 1.100f, 2.829f, }, /* (33.994) 34 */
- {0.989f, 0.698f, 1.601f, 1.086f, 1.964f, 2.882f, }, /* (34.954) 35 */
- {0.602f, 0.869f, 1.418f, 1.264f, 0.764f, 2.218f}, /* 36 */ /* mode 10 AUDIO_WB LVQ bitrate 15-36 + 4 + 1*/
-
- {0.853f, 1.769f, 4.425f, 1.000f, 1.000f, 1.000f}, /* 17 */
- {1.011f, 1.663f, 4.403f, 1.578f, 0.000f, 0.000f}, /* 21 */
- {1.011f, 1.663f, 4.403f, 1.202f, 2.424f, 0.000f}, /* 22 */
- {0.881f, 1.618f, 4.136f, 1.202f, 2.424f, 0.000f}, /* 25 */
- {0.847f, 1.791f, 4.466f, 1.202f, 2.424f, 0.000f}, /* 26 */
- {0.670f, 1.112f, 2.389f, 1.202f, 2.424f, 0.000f}, /* 28 */ /* mode 11 AUDIO_NB */
-
- {1.131f, 1.815f, 0.796f, 1.265f, 2.794f, 0.000f, }, /* 26 */
- {0.570f, 0.804f, 1.197f, 1.162f, 1.949f, 0.728f, }, /* 36*/ /* mode 12 AUDIO_WB 16k bitrate 15-36 + 4 + 1*/
-
- {1.045f, 1.586f, 3.754f, 1.669f, 0.000f, 0.000f, }, /* 22 (21.776) */
- {1.100f, 1.604f, 2.295f, 1.334f, 2.423f, 0.000f, }, /* (22.959) 23 */
- {1.091f, 1.752f, 3.164f, 1.407f, 0.000f, 0.000f, }, /* (23.949) 24 */
- {1.091f, 1.752f, 3.164f, 1.346f, 2.525f, 0.000f, }, /* (24.889) 25 */
- {1.091f, 1.752f, 3.164f, 1.089f, 1.684f, 2.523f, }, /* (25.821) 26 */
- {0.940f, 1.349f, 1.903f, 1.199f, 1.790f, 2.564f, }, /* (26.982) 27 */
- {0.880f, 1.280f, 2.824f, 1.099f, 1.735f, 0.000f, }, /* 28 (27.994) */
- {0.831f, 1.215f, 2.927f, 1.089f, 1.708f, 2.479f, }, /* 29 (28.996) */
- {0.870f, 1.327f, 2.906f, 1.066f, 1.719f, 2.676f, }, /* 30 (29.991) */
- {0.765f, 3.115f, 1.818f, 1.123f, 2.309f, 4.775f, }, /* (30.985) 31 */
- {0.772f, 1.122f, 2.351f, 1.446f, 0.944f, 2.072f, }, /* 32 (31.992) */
- {0.701f, 0.977f, 1.738f, 0.947f, 1.453f, 2.082f, }, /* 33 (32.993) */
- {0.719f, 1.021f, 1.701f, 1.119f, 0.794f, 1.696f, }, /* 34 (33.968) */
- {0.839f, 0.640f, 1.522f, 1.118f, 1.697f, 0.796f, }, /* (34.968) 35 */
- {0.839f, 0.640f, 1.522f, 0.961f, 1.469f, 0.707f, }, /* (35.990) 36 */
- {0.640f, 0.884f, 1.732f, 0.755f, 1.090f, 1.548f, }, /* 37 (36.995) */ /* VOICED 16k */
- /* 5sf */
- {1.218f, 0.796f, 2.283f, 1.290f, 3.325f, 0.000f, }, /* 25 (24.980) */
- {1.590f, 0.835f, 4.436f, 1.097f, 3.070f, 0.000f, }, /* 25 (24.974) */
- {0.994f, 2.617f, 0.000f, 1.091f, 2.233f, 3.457f, }, /* 25 (24.852) */
- {0.887f, 1.573f, 3.543f, 1.088f, 1.827f, 3.067f, }, /* 25 (24.994) */
- {0.837f, 1.238f, 1.903f, 1.298f, 2.797f, 0.000f, }, /* 25 (24.996) */
- {1.138f, 2.826f, 0.000f, 1.106f, 2.796f, 4.391f, }, /* 25 (24.671) */
-
- /* 4sf */
- {0.941f, 1.931f, 4.473f, 0.681f, 1.266f, 2.328f, }, /* 25 (24.936) */
- {1.352f, 4.332f, 0.000f, 0.820f, 1.545f, 4.175f, }, /* 25 (24.955) */
- {1.343f, 3.607f, 0.000f, 0.859f, 1.453f, 2.590f, }, /* 25 (24.853) */
- {1.208f, 2.740f, 0.000f, 0.759f, 1.240f, 2.182f, }, /* 25 (24.881) */
- {1.123f, 2.736f, 0.000f, 0.874f, 1.498f, 2.586f, }, /* 25 (24.939) */
- {0.919f, 2.471f, 0.000f, 0.615f, 1.072f, 2.096f, }, /* 25 (24.996) */
- {1.548f, 4.508f, 0.000f, 0.825f, 2.178f, 4.305f, }, /* 25 (24.310) */
- {1.217f, 2.898f, 0.000f, 0.737f, 1.217f, 1.930f, }, /* 25 (24.955) */
- {0.976f, 2.190f, 5.716f, 1.506f, 0.642f, 4.211f, }, /* 25 (24.984) */
- {1.107f, 2.595f, 0.000f, 1.302f, 0.604f, 0.880f, }, /* 25 (24.866) */
-};
-
-const float scales_p[][MAX_NO_SCALES*2]= /* 2 subvectors 20 modes */
-{
- {1.464f, 2.374f, 0.000f, 0.000f, 0.000f, 0.000f, }, /* 9 (8.464) */
- {1.284f, 2.159f, 0.000f, 0.000f, 0.000f, 0.000f, }, /* (8.910) 9 */
- {1.245f, 2.590f, 0.000f, 0.000f, 0.000f, 0.000f, }, /* (10.659) 11 */
- {1.142f, 1.858f, 2.927f, 0.000f, 0.000f, 0.000f, }, /* (11.925) 12 */
- {1.038f, 1.837f, 3.009f, 0.000f, 0.000f, 0.000f, }, /* (12.997) 13 */
- {1.515f, 0.000f, 0.000f, 1.540f, 0.000f, 0.000f, }, /* (13.640) 14 */
- {1.584f, 0.000f, 0.000f, 1.540f, 0.000f, 0.000f, }, /* (14.733) 15 */
- {1.584f, 0.000f, 0.000f, 1.620f, 0.000f, 0.000f, }, /* (15.826) 16 */
- {1.284f, 2.159f, 0.000f, 1.620f, 0.000f, 0.000f, }, /* (16.823) 17 */
- {1.245f, 2.590f, 0.000f, 1.540f, 0.000f, 0.000f, }, /* (17.479) 18 */
- {1.265f, 2.564f, 0.000f, 1.638f, 0.000f, 0.000f, }, /* 19 (18.572) */
- {1.142f, 1.858f, 2.927f, 1.620f, 0.000f, 0.000f, }, /* (19.838) 20 */
- {1.038f, 1.837f, 3.009f, 1.620f, 0.000f, 0.000f, }, /* (20.910) 21 */
- {0.988f, 1.661f, 2.539f, 1.620f, 0.000f, 0.000f, }, /* (21.776) 22 */
- {1.063f, 1.703f, 2.805f, 1.294f, 2.353f, 0.000f, }, /* 23 (22.959) */
- {1.063f, 1.917f, 3.063f, 1.365f, 0.000f, 0.000f, }, /* 24 (23.949) */
- {0.914f, 1.412f, 2.223f, 1.294f, 2.353f, 0.000f, }, /* 25 (24.992) */
- {0.900f, 1.410f, 2.254f, 1.298f, 2.413f, 0.000f, }, /* (25.718) 26 */
- {0.882f, 1.401f, 2.402f, 1.313f, 2.441f, 0.000f, }, /* 27 (26.902) */
- {1.356f, 0.867f, 2.377f, 1.070f, 1.686f, 2.546f, }, /* 28 (27.996) */
- {0.846f, 1.348f, 2.546f, 1.076f, 1.742f, 2.658f, }, /* 29 (28.937) */
- {0.845f, 1.379f, 2.566f, 1.019f, 1.577f, 2.443f, }, /* 30 (29.954) */
- {0.756f, 1.189f, 2.799f, 1.084f, 1.804f, 2.758f, }, /* 31 (30.978) */
- {0.755f, 1.218f, 2.821f, 0.944f, 1.433f, 1.973f, }, /* 32 (31.978) */
- {0.745f, 1.197f, 2.898f, 1.242f, 0.843f, 1.952f, }, /* (32.988) 33 */
- {0.724f, 1.235f, 2.942f, 1.255f, 0.848f, 2.000f, }, /* 34 (33.975) */
- {0.687f, 1.113f, 2.338f, 0.853f, 1.328f, 1.944f, }, /* 35 (34.975) */
- {0.648f, 1.029f, 1.836f, 0.854f, 1.356f, 1.961f, }, /* 36 (35.889) */
- {0.607f, 0.934f, 1.517f, 0.783f, 1.213f, 1.534f, }, /* (36.996) 37 */
- {0.599f, 0.905f, 1.529f, 0.731f, 1.111f, 1.500f, }, /* (37.993) 38 */
- {0.648f, 1.029f, 1.836f, 0.687f, 1.058f, 1.900f, }, /* 39 (38.488) */ /* V WB*/
-
- {1.613f, 0.000f, 0.000f, 0.000f, 0.000f, 0.000f, }, /* 8 (7.913) */
- {1.267f, 2.475f, 0.000f, 1.619f, 0.000f, 0.000f, }, /* 19 (18.572) */
- {1.014f, 1.630f, 2.464f, 1.285f, 2.151f, 0.000f, }, /* 23 (22.773) */
- {0.893f, 1.390f, 2.314f, 1.465f, 2.299f, 0.000f, }, /* 24 (23.999) */
- {0.930f, 1.401f, 2.150f, 1.280f, 2.254f, 0.000f, }, /* 25 (24.992) */
- {0.893f, 1.390f, 2.314f, 1.276f, 2.206f, 2.984f, }, /* 27 (26.962) */
- {0.893f, 1.390f, 2.314f, 1.036f, 1.646f, 2.471f, }, /* 28 (27.835) */
- {0.857f, 1.337f, 2.464f, 1.043f, 1.730f, 2.625f, }, /* 29 (28.937) */
- {0.765f, 1.219f, 1.553f, 1.036f, 1.646f, 2.471f, }, /* 30 (29.969) */
- {0.789f, 1.328f, 1.652f, 1.052f, 1.784f, 2.706f, }, /* 31 (30.952) */
- {0.764f, 1.224f, 1.555f, 0.920f, 1.443f, 2.035f, }, /* 32 (31.978) */
- {0.663f, 1.061f, 1.238f, 1.379f, 0.898f, 1.951f, }, /* 34 (33.992) */
- {0.673f, 1.104f, 1.306f, 1.259f, 0.828f, 1.954f, }, /* 35 (35.000) */
- {0.666f, 1.071f, 1.249f, 0.803f, 1.241f, 1.729f, }, /* 36 (35.980) */
- {0.658f, 1.039f, 1.214f, 0.950f, 0.651f, 1.429f, }, /* 39 (38.512) */ /* V NB*/
-
- {1.600f, 0.000f, 0.000f, 1.553f, 0.000f, 0.000f, }, /* 15 (14.733) */
- {1.306f, 2.427f, 0.000f, 1.580f, 0.000f, 0.000f, }, /* (15.730) 16 */
- {1.306f, 2.427f, 0.000f, 1.676f, 0.000f, 0.000f, }, /* (16.823) 17 */
- {1.250f, 2.894f, 0.000f, 1.580f, 0.000f, 0.000f, }, /* (17.479) 18 */
- {1.134f, 1.986f, 3.295f, 1.553f, 0.000f, 0.000f, }, /* 19 (18.745) */
- {1.143f, 2.052f, 3.345f, 1.676f, 0.000f, 0.000f, }, /* (19.838) 20 */
- {1.044f, 2.031f, 3.487f, 1.676f, 0.000f, 0.000f, }, /* (20.910) 21 */
- {0.987f, 1.788f, 2.659f, 1.647f, 0.000f, 0.000f, }, /* 22 (21.776) */
- {0.899f, 1.602f, 2.579f, 1.647f, 0.000f, 0.000f, }, /* 23 (22.791) */
- {0.797f, 1.294f, 2.140f, 1.647f, 0.000f, 0.000f, }, /* 24 (23.999) */
- {0.797f, 1.294f, 2.140f, 1.335f, 2.225f, 0.000f, }, /* 25 (24.996) */
- {0.741f, 1.151f, 1.816f, 1.335f, 2.225f, 0.000f, }, /* 26 (25.934) */
- {0.980f, 1.702f, 0.706f, 1.317f, 2.628f, 0.000f, }, /* (26.887) 27 */
- {0.797f, 1.294f, 2.140f, 1.186f, 1.932f, 0.000f, }, /* 28 (27.969) */
- {0.741f, 1.151f, 1.816f, 1.164f, 1.823f, 2.769f, }, /* 29 (28.996) */
- {0.708f, 1.126f, 1.953f, 1.076f, 1.730f, 2.777f, }, /* 30 (29.988) */
- {0.660f, 1.049f, 1.571f, 1.076f, 1.730f, 2.777f, }, /* 31 (30.931) */
- {0.662f, 1.026f, 1.554f, 1.074f, 1.913f, 3.022f, }, /* 32 (31.987) */
- {0.660f, 1.049f, 1.571f, 1.439f, 0.926f, 2.131f, }, /* 33 (32.982) */
- {0.630f, 0.966f, 1.522f, 1.312f, 0.881f, 2.207f, }, /* 34 (33.967) */
- {0.617f, 0.921f, 1.447f, 1.032f, 1.549f, 0.756f, }, /* 35 (34.994) */ /* G WB*/
-
- {1.595f, 0.000f, 0.000f, 1.502f, 0.000f, 0.000f, }, /* 15 (14.733) */
- {1.123f, 1.946f, 3.732f, 1.502f, 0.000f, 0.000f, }, /* 19 (18.792) */
- {1.033f, 2.075f, 4.339f, 1.419f, 2.446f, 0.000f, }, /* 22 (21.985) */
- {0.985f, 1.793f, 5.965f, 1.281f, 2.324f, 0.000f, }, /* 23 (22.773) */
- {0.881f, 1.606f, 6.995f, 1.419f, 2.446f, 0.000f, }, /* 24 (23.932) */
- {0.844f, 1.582f, 7.020f, 1.281f, 2.324f, 0.000f, }, /* 25 (24.955) */
- {0.789f, 1.520f, 7.203f, 1.281f, 2.324f, 0.000f, }, /* 26 (25.991) */
- {0.869f, 1.547f, 6.995f, 1.030f, 1.754f, 3.102f, }, /* 28 (27.979) */
- {0.817f, 1.492f, 7.120f, 1.030f, 1.754f, 3.102f, }, /* 29 (28.878) */
- {0.755f, 1.382f, 7.133f, 1.030f, 1.754f, 3.102f, }, /* 30 (29.954) */
- {0.706f, 1.315f, 7.225f, 1.030f, 1.754f, 3.102f, }, /* 31 (30.893) */
- {0.689f, 1.296f, 7.290f, 1.016f, 1.875f, 3.239f, }, /* 32 (31.963) */
- {0.698f, 1.275f, 7.209f, 0.914f, 1.548f, 2.433f, }, /* 33 (32.997) */
- {0.679f, 1.315f, 7.290f, 1.229f, 1.845f, 0.813f, }, /* 34 (33.986) */
- {0.679f, 1.315f, 7.290f, 1.188f, 0.772f, 1.955f, }, /* 35 (34.952) */ /* G NB*/
-
- {1.011f, 1.777f, 2.760f, 1.614f, 0.000f, 0.000f, }, /* 21 */
- {0.964f, 1.580f, 3.996f, 1.729f, 0.000f, 0.000f, }, /* (21.776) 22 */
- {0.878f, 1.440f, 2.289f, 1.729f, 0.000f, 0.000f, }, /* (22.784) 23 */
- {0.852f, 1.643f, 2.429f, 1.729f, 0.000f, 0.000f, }, /* (23.980) 24 */
- {0.853f, 1.382f, 2.066f, 1.245f, 2.679f, 0.000f, }, /* 25 */
- { 1.207f, 0.778f, 2.208f, 1.245f, 2.679f, 0.000f, }, /* 26 */
- {0.804f, 1.354f, 2.647f, 1.408f, 2.615f, 0.000f, }, /* (26.931) 27 */
- {0.782f, 1.254f, 2.799f, 1.378f, 2.708f, 0.000f, }, /* (27.977) 28 */
- { 1.207f, 0.778f, 2.208f, 1.013f, 1.832f, 3.053f, }, /* 29 */
- {1.207f, 0.778f, 2.208f, 1.420f, 0.872f, 2.330f, }, /* 30 */
- {0.683f, 1.016f, 1.788f, 1.126f, 1.886f, 2.924f, }, /* (30.993) 31 */
- {0.627f, 0.917f, 1.448f, 1.126f, 1.886f, 2.924f, }, /* (31.998) 32 */
- {0.658f, 1.028f, 1.557f, 1.482f, 0.975f, 2.147f, }, /* (32.996) 33 */
- {0.794f, 0.580f, 1.331f, 1.482f, 0.975f, 2.147f, }, /* (33.994) 34 */
- {0.823f, 0.592f, 1.323f, 1.346f, 0.895f, 2.308f, }, /* (34.999) 35 */
- {1.098f, 0.738f, 0.555f, 0.869f, 1.290f, 1.862f, }, /* (35.984) 36 */
- {0.758f, 1.111f, 0.550f, 0.871f, 1.367f, 1.906f, }, /* (36.969) 37 */
- {0.551f, 0.766f, 1.116f, 0.791f, 1.201f, 1.663f, }, /* (37.971) 38 */
- {0.551f, 0.766f, 1.116f, 0.963f, 0.697f, 1.323f, }, /* (38.973) 39 */
- {0.525f, 0.770f, 1.073f, 0.815f, 1.237f, 0.567f,}, /* 40 */ /* mode 7 AUDIO_WB 19-40 + 0 + 1 */
-
- {1.070f, 1.791f, 3.903f, 1.599f, 0.000f, 0.000f}, /* 21 */
- {0.820f, 1.217f, 2.089f, 1.255f, 2.290f, 0.000f}, /* 25 */
- {0.780f, 1.169f, 2.495f, 1.255f, 2.290f, 0.000f}, /* 26 */
- {1.075f, 0.723f, 2.361f, 1.110f, 1.961f, 3.491f}, /* 30 */
- {0.691f, 1.029f, 2.337f, 1.034f, 1.791f, 4.004f}, /* 31 */
- {0.671f, 1.076f, 2.606f, 0.955f, 1.547f, 2.514f}, /* 32 */ /*mode 8 AUDIO_NB */
-
- {1.184f, 0.776f, 2.117f, 1.057f, 1.670f, 0.674f,}, /* 30 */
- {0.946f, 1.448f, 2.723f, 1.394f, 2.645f, 4.581f, }, /* (30.967) 31 */
- {0.948f, 1.454f, 2.723f, 1.970f, 1.174f, 3.484f, }, /* (31.990) 32 */
- {0.885f, 1.406f, 2.763f, 1.970f, 1.174f, 3.484f, }, /* (32.979) 33 */
- {1.245f, 0.842f, 2.378f, 1.999f, 1.168f, 3.682f, }, /* (33.989) 34 */
- {0.870f, 1.346f, 2.814f, 1.744f, 1.058f, 2.897f, }, /* (34.991) 35 */
- {0.827f, 1.219f, 2.176f, 1.588f, 2.600f, 0.995f, }, /* (35.990) 36 */
- {0.817f, 1.186f, 1.992f, 1.593f, 0.974f, 2.619f, }, /* (36.986) 37 */
- {0.822f, 1.205f, 2.099f, 1.464f, 0.904f, 2.398f, }, /* (37.982) 38 */
- {0.822f, 1.205f, 2.099f, 2.053f, 0.837f, 1.359f, }, /* (38.995) 39 */
- {0.521f, 0.747f, 1.033f, 0.796f, 1.333f, 0.542f,}, /* 40 */ /* mode 9 AUDIO_WB 16k 30-40 + 5 MA pred for WB2 (AV: not used?)*/
-
- {1.679f, 0.000f, 0.000f, 1.282f, 2.471f, 0.000f, }, /* 17 (16.823) */
- {1.088f, 1.849f, 3.195f, 1.687f, 0.000f, 0.000f, }, /* 21 (20.910) */
- {1.088f, 1.849f, 3.195f, 1.282f, 2.471f, 0.000f, }, /* 22 (21.907) */
- {1.126f, 1.689f, 0.790f, 1.282f, 2.471f, 0.000f, }, /* 25 (24.863) */
- {0.930f, 1.382f, 0.682f, 1.282f, 2.471f, 0.000f, }, /* 26 (25.921) */
- {1.115f, 0.794f, 1.852f, 1.281f, 3.033f, 0.000f, }, /* 27 (26.837) */
- {0.840f, 1.376f, 0.623f, 0.800f, 1.416f, 4.260f, }, /* 36 (35.998) */ /* INACTIVE NB */
-
- {0.801f, 1.148f, 1.802f, 0.000f, 0.000f, 0.000f, }, /* 17 (16.932) */
- {1.344f, 2.627f, 0.000f, 1.574f, 0.000f, 0.000f, }, /* (17.479) 18 */
- {1.260f, 2.045f, 0.000f, 1.574f, 0.000f, 0.000f, }, /* (18.703) 19 */
- {1.260f, 2.045f, 0.000f, 1.675f, 0.000f, 0.000f, }, /* (19.796) 20 */
- {1.089f, 1.812f, 3.172f, 1.677f, 0.000f, 0.000f, }, /* 21 (20.910) */
- {1.089f, 1.904f, 3.221f, 1.521f, 2.635f, 0.000f, }, /* 22 (21.985) */
- {0.963f, 1.440f, 2.117f, 1.675f, 0.000f, 0.000f, }, /* (22.934) 23 */
- {0.963f, 1.440f, 2.117f, 1.302f, 2.410f, 0.000f, }, /* (23.931) 24 */
- {0.845f, 1.212f, 1.934f, 1.313f, 2.419f, 0.000f, }, /* 25 (24.845) */
- {0.779f, 1.095f, 1.700f, 1.313f, 2.419f, 0.000f, }, /* 26 (25.999) */
- {0.723f, 1.015f, 1.664f, 1.313f, 2.419f, 0.000f, }, /* 27 (26.981) */
- {1.009f, 1.667f, 0.752f, 1.307f, 3.021f, 0.000f, }, /* (27.988) 28 */
- {1.005f, 1.647f, 0.749f, 1.064f, 1.871f, 3.348f, }, /* (28.936) 29 */
- {0.895f, 1.490f, 0.682f, 1.064f, 1.871f, 3.348f, }, /* (29.855) 30 */
- {0.787f, 1.272f, 0.608f, 1.064f, 1.871f, 3.348f, }, /* (30.968) 31 */
- {0.861f, 0.648f, 1.459f, 1.064f, 1.871f, 3.348f, }, /* (31.943) 32 */
- {0.829f, 0.631f, 1.337f, 1.059f, 2.032f, 3.428f, }, /* (32.999) 33 */
- {0.861f, 0.648f, 1.459f, 1.541f, 0.920f, 2.511f, }, /* (33.994) 34 */
- {0.848f, 0.633f, 1.358f, 1.408f, 0.879f, 2.711f, }, /* (34.989) 35 */
- {0.893f, 0.652f, 1.438f, 1.076f, 0.720f, 1.794f, }, /* 36 (35.929) */ /* INACTIVE WB*/
-
- {1.359f, 2.306f, 0.000f, 1.669f, 0.000f, 0.000f, }, /* 17 (16.823) */
- {1.077f, 1.927f, 3.546f, 1.669f, 0.000f, 0.000f, }, /* 21 (20.910) */
- {1.077f, 2.032f, 3.578f, 1.429f, 2.711f, 0.000f, }, /* 22 (21.985) */
- {0.833f, 1.253f, 2.105f, 1.283f, 2.556f, 0.000f, }, /* 25 (24.845) */
- {0.776f, 1.152f, 1.858f, 1.283f, 2.556f, 0.000f, }, /* 26 (25.934) */
- {0.719f, 1.066f, 1.732f, 1.283f, 2.556f, 0.000f, }, /* 27 (26.914) */
- {0.941f, 0.651f, 1.565f, 0.722f, 1.190f, 1.940f, }, /* 36 (35.915) */ /* INACTIVE 16k*/
-
- {1.292f, 2.479f, 0.000f, 1.541f, 0.000f, 0.000f, }, /* 18 (17.479) */
- {1.202f, 1.903f, 0.000f, 1.541f, 0.000f, 0.000f, }, /* 19 (18.703) */
- {1.028f, 1.641f, 2.455f, 1.648f, 0.000f, 0.000f, }, /* 22 (21.776) */
- {1.247f, 0.878f, 2.329f, 1.648f, 0.000f, 0.000f, }, /* 23 (22.791) */
- {0.863f, 1.358f, 2.522f, 1.648f, 0.000f, 0.000f, }, /* 24 (23.999) */
- {0.817f, 1.222f, 2.010f, 1.074f, 1.785f, 2.733f, }, /* 29 (28.966) */
- {0.815f, 0.612f, 1.281f, 1.055f, 1.724f, 2.952f, }, /* 32 (31.990) */ /* UNVOICED NB */
- {1.545f, 0.000f, 0.000f, 1.548f, 0.000f, 0.000f, }, /* 14 (13.640) */
- {1.640f, 0.000f, 0.000f, 1.548f, 0.000f, 0.000f, }, /* 15 (14.733) */
- {1.330f, 0.000f, 0.000f, 1.597f, 0.000f, 0.000f, }, /* (15.826) 16 */
- {1.235f, 2.316f, 0.000f, 1.597f, 0.000f, 0.000f, }, /* (16.376) 17 */
- {1.287f, 2.749f, 0.000f, 1.548f, 0.000f, 0.000f, }, /* 18 (17.479) */
- {1.287f, 2.749f, 0.000f, 1.654f, 0.000f, 0.000f, }, /* 19 (18.572) */
- {1.190f, 2.026f, 0.000f, 1.654f, 0.000f, 0.000f, }, /* 20 (19.796) */
- {0.952f, 1.674f, 2.762f, 1.597f, 0.000f, 0.000f, }, /* (20.910) 21 */
- {0.918f, 1.571f, 3.210f, 1.597f, 0.000f, 0.000f, }, /* (21.776) 22 */
- {1.256f, 0.792f, 2.078f, 1.597f, 0.000f, 0.000f, }, /* (22.784) 23 */
- {0.757f, 1.203f, 1.874f, 1.597f, 0.000f, 0.000f, }, /* (23.999) 24 */
- {0.931f, 1.458f, 2.450f, 1.294f, 2.742f, 0.000f, }, /* 25 (24.992) */
- {1.117f, 0.736f, 1.875f, 1.251f, 2.567f, 0.000f, }, /* (25.993) 26 */
- {0.772f, 1.236f, 1.921f, 1.251f, 2.567f, 0.000f, }, /* (26.883) 27 */
- {0.877f, 1.396f, 2.737f, 1.081f, 1.816f, 3.360f, }, /* 28 (27.996) */ /* UNVOICED WB*/
-
- {1.131f, 1.636f, 0.000f, 1.371f, 0.000f, 0.000f, }, /* 24 (23.818) */
- {0.892f, 1.592f, 3.424f, 1.298f, 3.206f, 0.000f, }, /* (24.961) 25 */
- {0.875f, 1.547f, 3.459f, 1.285f, 2.899f, 4.150f, }, /* (25.964) 26 */
- {0.846f, 1.650f, 3.307f, 1.275f, 2.446f, 4.005f, }, /* (26.946) 27 */
- {0.808f, 3.069f, 1.716f, 1.275f, 2.446f, 4.005f, }, /* (27.856) 28 */
- {0.765f, 3.128f, 1.823f, 1.275f, 2.446f, 4.005f, }, /* (28.977) 29 */
- {0.934f, 1.277f, 0.728f,1.157f, 1.697f, 0.000f, }, /* 30 (29.992) */
- {0.833f, 1.162f, 0.658f,1.151f, 1.687f, 0.000f, }, /* 31 (30.998) */
- {0.751f, 1.032f, 0.598f,1.151f, 1.687f, 0.000f, }, /* 32 (31.987) */
- {0.759f, 3.138f, 1.845f, 0.922f, 1.508f, 3.110f, }, /* (32.975) 33 */
- {0.709f, 1.005f, 0.570f, 1.060f, 1.772f, 2.719f, }, /* 34 (33.994) */
- {0.746f, 1.001f, 0.601f,1.004f, 1.803f, 2.892f, }, /* 35 (35.000) */
- {0.743f, 1.000f, 0.599f,0.936f, 1.861f, 2.874f, }, /* 36 (35.994) */
- {0.750f, 3.170f, 1.925f, 0.737f, 1.423f, 2.687f, } , /* (36.977) 37 */
- {0.750f, 3.170f, 1.925f, 0.659f, 1.059f, 1.975f, }, /* (37.984) 38 */
- {0.775f, 0.614f, 1.037f, 0.796f, 1.304f, 1.905f, }, /* 39 (38.301) */ /* VOICED 16k */
-
- {0.894f, 1.339f, 2.549f, 1.308f, 2.601f, 0.000f, }, /* 26 (25.917) */
- {0.832f, 1.254f, 1.937f, 1.307f, 2.614f, 0.000f, }, /* (26.887) 27 */
- {0.832f, 1.232f, 1.916f, 1.158f, 1.977f, 0.000f, }, /* (27.974) 28 */
- {0.825f, 1.260f, 1.993f, 1.023f, 1.739f, 2.796f, }, /* (28.910) 29 */
- {0.750f, 1.114f, 1.563f, 1.045f, 1.802f, 2.681f, }, /* (29.976) 30 */
- {0.692f, 1.000f, 1.431f, 1.023f, 1.739f, 2.796f, }, /* (30.956) 31 */
- {0.720f, 1.012f, 1.598f, 1.512f, 0.926f, 2.137f, }, /* 32 (31.980) */
- {0.681f, 0.973f, 1.649f, 1.381f, 0.876f, 2.129f, }, /* 33 (32.990) */
- {0.684f, 0.964f, 1.640f, 1.168f, 1.776f, 0.787f, }, /* 34 (33.974) */
- {0.668f, 0.935f, 1.551f, 1.016f, 1.518f, 0.712f, }, /* 35 (34.989) */
- {0.659f, 0.911f, 1.425f, 1.337f, 0.889f, 0.642f, }, /* 36 (35.988) */
- {0.659f, 0.911f, 1.425f, 0.839f, 1.287f, 0.607f, }, /* 37 (36.989) */ /* GENERIC 16k*/
-
- {1.633f, 0.000f, 0.000f, 1.687f, 0.000f, 0.000f, }, /* 16 (15.826) */
- {1.691f, 0.000f, 0.000f, 1.674f, 0.000f, 0.000f, }, /* (15.826) 16 */
- {1.328f, 2.564f, 0.000f, 1.553f, 0.000f, 0.000f, }, /* (17.479) 18 */
- {1.250f, 1.992f, 0.000f, 1.553f, 0.000f, 0.000f, }, /* (18.703) 19 */
- {1.250f, 1.992f, 0.000f, 1.674f, 0.000f, 0.000f, }, /* (19.796) 20 */
- {1.076f, 1.790f, 2.942f, 1.687f, 0.000f, 0.000f, }, /* 21 (20.910) */
- {1.066f, 1.683f, 4.077f, 1.674f, 0.000f, 0.000f, }, /* (21.776) 22 */
- {1.280f, 0.911f, 2.477f, 1.674f, 0.000f, 0.000f, }, /* (22.791) 23 */
- {0.834f, 1.229f, 1.890f, 1.687f, 0.000f, 0.000f, }, /* 24 (23.999) */
- {0.938f, 1.404f, 2.153f, 1.306f, 2.630f, 0.000f, }, /* 25 (24.992) */
- {1.340f, 0.886f, 2.320f, 1.306f, 2.630f, 0.000f, }, /* 26 (25.917) */
- {0.833f, 1.250f, 1.908f, 1.306f, 2.630f, 0.000f, }, /* 27 (26.883) */
- {0.833f, 1.213f, 1.873f, 1.125f, 1.839f, 2.819f, }, /* 28 (27.901) */
- {0.854f, 1.267f, 1.828f, 1.044f, 1.760f, 2.882f, }, /* (28.937) 29 */
- {0.765f, 1.162f, 1.690f, 1.024f, 1.738f, 2.838f, }, /* 30 (29.916) */
- {0.725f, 1.050f, 1.791f, 1.480f, 0.922f, 3.104f, }, /* 31 (30.993) */
- {0.712f, 1.012f, 1.549f, 1.494f, 0.903f, 3.364f, }, /* 32 (31.980) */
- {0.659f, 0.927f, 1.357f, 1.494f, 0.903f, 3.364f, }, /* 33 (32.958) */
- {0.822f, 0.614f, 1.288f, 0.910f, 1.509f, 2.255f, }, /* 34 (33.987) */
- {0.841f, 0.624f, 1.278f, 1.161f, 0.762f, 1.808f, }, /* 35 (34.994) */
- {0.838f, 0.622f, 1.266f, 1.080f, 0.711f, 1.710f, }, /* 36 (35.968) */
- {0.832f, 0.619f, 1.275f, 0.938f, 1.430f, 0.644f, }, /* 37 (36.971) */ /* GENERIC 12.8k MA*/
-
- {0.884f, 1.349f, 2.570f, 1.314f, 2.609f, 0.000f, }, /* 26 (25.917) */
- {0.981f, 1.473f, 2.784f, 1.690f, 3.342f, 0.000f, }, /* (26.981) 27 */
- {0.965f, 1.514f, 2.686f, 1.409f, 2.485f, 3.946f, }, /* (27.989) 28 */
- {0.976f, 1.457f, 2.663f, 2.151f, 1.271f, 4.176f, }, /* (28.976) 29 */
- {0.991f, 1.504f, 3.086f, 2.486f, 1.315f, 4.530f, }, /* (29.968) 30 */
- {0.946f, 1.448f, 2.723f, 1.394f, 2.645f, 4.581f, }, /* (30.967) 31 */
- {0.711f, 1.018f, 1.615f, 1.482f, 0.921f, 3.431f, }, /* 32 (31.980) */
- {0.679f, 0.974f, 1.659f, 0.948f, 1.549f, 3.448f, }, /* 33 (32.995) */
- {0.831f, 0.618f, 1.481f, 0.933f, 1.514f, 2.310f, }, /* 34 (33.993) */
- {0.816f, 0.610f, 1.402f, 1.426f, 0.877f, 2.265f, }, /* 35 (34.992) */
- {0.787f, 1.257f, 0.596f, 0.859f, 1.447f, 2.431f, }, /* 36 (35.997) */
- {0.787f, 1.257f, 0.596f, 1.106f, 0.735f, 1.659f, }, /* 37 (36.961) */ /* AUDIO 16k */
-};
-
const Word16 scales_fx[][6] =//Q11
{
{3129, 0, 0, 3138, 0, 0, }, /* 14 */
@@ -13238,45 +12567,6 @@ const Word16 scales_p_fx[][6] =
};
-/* An 16-by-34 matrix in Scale = 20.48f */
-const float sigma_MSLVQ[][16] =
-{
- { 1.0f }, /* IA NB */
- { 1.0f }, /* UV NB */
- {41.8457031f, 43.9453125f, 62.5976563f, 72.3632813f, 78.7597656f, 82.4707031f, 85.4492188f, 86.5722656f, 86.6210938f, 84.9121094f, 85.2050781f, 105.5664063f, 127.8320313f, 68.6523438f, 25.7324219f, 16.9433594f }, /* V NB */
- {48.9257813f, 50.5859375f, 71.0449219f, 72.4609375f, 74.5117188f, 77.8808594f, 79.5898438f, 80.8105469f, 79.9804688f, 74.5117188f, 70.0683594f, 88.7207031f, 119.1406250f, 102.0019531f, 37.1093750f, 25.0976563f }, /* G NB */
- {48.2421875f, 48.0468750f, 68.7500000f, 76.9531250f, 80.9570313f, 85.1562500f, 89.0625000f, 91.8457031f, 90.4296875f, 85.2050781f, 81.5917969f, 106.2988281f, 133.6425781f, 84.3750000f, 34.7656250f, 26.6113281f }, /* T NB */
- {85.5957031f, 82.9101563f, 99.5605469f, 105.9570313f, 106.6406250f, 106.8847656f, 101.6601563f, 99.5605469f, 97.7050781f, 97.0703125f, 97.1191406f, 117.8710938f, 128.1738281f, 153.9550781f, 33.1542969f, 14.5996094f },/* AU NB*/
- { 1.0f },
- { 1.0f }, /* UV WB*/
- {44.2382813f, 52.1972656f, 85.7910156f, 98.6816406f, 101.7089844f, 107.2753906f, 106.9824219f, 112.0605469f, 118.8476563f, 126.3183594f, 125.4882813f, 126.8554688f, 136.3281250f, 136.7675781f, 146.9726563f, 129.7851563f }, /* V WB */
- {61.8164063f, 69.8730469f, 94.6289063f, 97.0214844f, 96.0449219f, 101.3671875f, 100.5371094f, 104.3945313f, 108.5937500f, 106.9824219f, 107.9101563f, 112.8417969f, 120.7519531f, 120.6542969f, 122.0214844f, 119.6289063f }, /* G WB */
- {56.8847656f, 56.9335938f, 86.7187500f, 100.1953125f, 101.9042969f, 108.5449219f, 113.4765625f, 117.9199219f, 124.1699219f, 122.1679688f, 126.3183594f, 137.4023438f, 153.9550781f, 158.8867188f, 161.9140625f, 155.9570313f }, /* T WB */
- {84.8632813f, 88.6230469f, 112.0605469f, 118.3593750f, 123.3886719f, 121.0937500f, 115.4785156f, 118.7011719f, 118.5058594f, 119.0429688f, 123.9257813f, 127.6855469f, 138.5742188f, 125.2441406f, 118.9941406f, 109.0332031f },/* AU WB */
- { 1.0f },
- { 1.0f },
- {75.2441406f, 84.3261719f, 110.6933594f, 125.0000000f, 134.0332031f, 140.3808594f, 146.6308594f, 159.5214844f, 161.3281250f, 173.9746094f, 186.9628906f, 190.9667969f, 196.2402344f, 181.9335938f, 177.9785156f, 187.2070313f }, /* VO 16k */
- {89.6972656f, 92.9687500f, 122.0703125f, 129.0527344f, 130.4687500f, 128.3691406f, 132.5683594f, 139.2578125f, 137.9882813f, 139.9902344f, 152.8320313f, 157.3730469f, 172.4121094f, 179.4433594f, 147.9980469f, 194.1894531f }, /* G 16k */
- {90.3320313f, 108.3496094f, 118.7500000f, 125.7324219f, 135.7421875f, 137.9882813f, 143.0175781f, 145.1660156f, 145.8007813f, 155.1757813f, 171.2402344f, 176.1230469f, 165.4785156f, 161.3769531f, 148.6816406f, 174.4140625f }, /* T 16k */
- {103.1250000f, 112.3046875f, 142.3339844f, 150.6347656f, 150.0488281f, 145.8496094f, 149.3164063f, 145.8496094f, 153.5156250f, 157.3242188f, 175.0000000f, 170.9960938f, 157.4707031f, 168.1152344f, 156.5917969f, 229.0527344f },/* AU 16k */
- {87.5488281f, 116.4062500f, 102.3925781f, 103.1738281f, 100.8789063f, 95.2636719f, 101.7578125f, 110.5468750f, 122.2167969f, 115.2343750f, 107.2753906f, 108.8378906f, 101.7089844f, 111.5722656f, 111.6699219f, 155.9570313f },
- {160.5957031f, 122.6074219f, 117.4804688f, 129.7363281f, 130.9570313f, 133.8378906f, 139.1601563f, 159.9121094f, 168.0664063f, 161.3281250f, 141.9433594f, 142.1386719f, 132.0312500f, 129.8828125f, 122.9980469f, 160.9863281f },
- {53.2226563f, 105.1757813f, 133.9355469f, 143.3593750f, 158.2031250f, 168.1640625f, 160.5957031f, 164.4042969f, 173.4863281f, 182.0800781f, 170.0683594f, 165.3320313f, 128.1738281f, 96.5332031f, 91.9433594f, 93.7988281f },
- {69.5312500f, 169.0429688f, 118.9453125f, 104.6875000f, 100.7812500f, 98.3398438f, 98.8281250f, 95.9472656f, 97.8027344f, 97.6562500f, 95.8496094f, 99.8046875f, 94.3847656f, 106.5917969f, 117.1386719f, 144.7265625f },
- {136.1816406f, 130.5175781f, 130.9082031f, 133.3007813f, 131.3476563f, 129.1992188f, 133.8867188f, 166.1621094f, 197.0703125f, 281.9824219f, 305.7617188f, 255.8105469f, 392.7734375f, 336.6699219f, 135.2050781f, 96.7773438f },
- {123.0957031f, 119.6777344f, 126.3183594f, 119.5800781f, 117.3339844f, 108.4472656f, 107.9101563f, 112.2070313f, 148.2910156f, 153.9550781f, 127.6367188f, 129.9316406f, 132.5683594f, 149.3164063f, 144.6777344f, 244.6289063f },
- {92.3339844f, 97.5097656f, 94.0917969f, 90.2832031f, 94.1894531f, 95.8007813f, 92.8710938f, 86.4746094f, 83.8867188f, 74.1699219f, 70.8984375f, 69.3847656f, 71.5332031f, 167.2851563f, 71.8750000f, 21.5820313f },
- {44.0429688f, 73.9257813f, 140.6738281f, 121.8750000f, 129.5410156f, 127.3437500f, 115.7226563f, 104.8339844f, 106.2500000f, 110.0097656f, 125.0000000f, 107.5195313f, 85.6445313f, 79.2968750f, 69.9218750f, 55.9570313f },
- {106.4453125f, 99.4140625f, 95.6542969f, 92.7246094f, 94.3359375f, 92.0898438f, 83.6914063f, 84.7167969f, 87.1582031f, 101.6113281f, 91.1621094f, 75.3417969f, 73.0957031f, 71.5332031f, 68.0175781f, 63.7207031f },
- {43.3105469f, 125.5371094f, 107.4707031f, 85.4003906f, 83.1542969f, 80.7617188f, 78.8574219f, 80.0781250f, 80.1269531f, 88.0859375f, 93.2128906f, 81.3964844f, 74.8535156f, 73.0957031f, 65.8203125f, 59.3750000f },
- {149.6093750f, 127.3925781f, 117.1875000f, 111.9628906f, 113.4277344f, 113.8671875f, 107.8125000f, 97.9492188f, 100.7324219f, 113.5253906f, 167.9687500f, 203.4667969f, 154.9804688f, 119.1894531f, 107.1289063f, 104.8828125f },
- {59.5214844f, 86.2792969f, 106.0058594f, 113.7207031f, 134.4726563f, 120.9960938f, 120.4589844f, 100.4882813f, 98.5839844f, 100.0488281f, 132.3730469f, 191.8457031f, 194.7753906f, 77.8320313f, 70.0195313f, 41.9433594f },
- {88.2812500f, 92.3828125f, 92.1386719f, 93.5546875f, 97.6074219f, 92.7734375f, 89.0625000f, 87.2070313f, 88.8671875f, 94.1406250f, 121.5820313f, 121.9238281f, 116.7968750f, 122.1191406f, 164.5996094f, 140.4296875f },
- {86.2792969f, 92.8710938f, 83.5937500f, 86.0839844f, 95.8984375f, 95.2148438f, 90.5273438f, 86.5234375f, 82.1289063f, 81.3964844f, 77.9785156f, 89.4042969f, 143.7011719f, 168.3593750f, 41.5039063f, 27.6855469f },
- {97.1679688f, 101.0253906f, 104.3945313f, 110.4003906f, 108.7890625f, 107.4707031f, 97.8515625f, 92.6757813f, 79.1503906f, 81.6406250f, 77.1972656f, 108.8867188f, 212.2070313f, 198.8281250f, 47.4609375f, 35.3515625f },
- {74.8535156f, 97.3632813f, 100.1464844f, 91.6992188f, 90.3808594f, 89.6484375f, 83.2031250f, 84.0820313f, 81.9335938f, 96.4355469f, 110.9863281f, 92.6757813f, 83.4960938f, 82.1289063f, 77.8808594f, 70.8984375f}
-};
-
const Word16 sigma_MSLVQ_fx[][16] =
{//Qlog2(2.56)
{3},
@@ -13354,29 +12644,6 @@ const Word16 inv_sigma_MSLVQ_fx[][16] =//Q15
{438, 337, 327, 357, 363, 365, 394, 390, 400, 340, 295, 354, 392, 399, 421, 462},
};
-/* An 16-by-19 matrix in Scale = 20.48f */
-const float sigma_p[][16] =
-{
- {59.3261719f, 63.9160156f, 69.7753906f, 66.3574219f, 67.3339844f, 68.5546875f, 66.6015625f, 66.0156250f, 66.0156250f, 67.9687500f, 68.2617188f, 84.3261719f, 96.5820313f, 118.6523438f, 44.0917969f, 43.1152344f }, /* IA NB */
- {51.2207031f, 66.6015625f, 69.3847656f, 68.6035156f, 67.9199219f, 69.6289063f, 69.6777344f, 69.5800781f, 52.5878906f, 64.9902344f, 65.3808594f, 68.7500000f, 71.4355469f, 77.0507813f, 77.9296875f, 80.3222656f }, /* U NB */
- {32.7148438f, 34.9121094f, 47.0703125f, 55.6152344f, 60.1562500f, 68.3105469f, 71.8261719f, 72.7539063f, 73.8281250f, 70.8984375f, 69.4335938f, 77.1972656f, 95.8007813f, 74.3164063f, 20.8984375f, 10.9375000f }, /* V NB */
- {53.8085938f, 61.3281250f, 78.1738281f, 75.8789063f, 73.7792969f, 81.3964844f, 80.7128906f, 80.5664063f, 83.6914063f, 77.0996094f, 72.5097656f, 86.6210938f, 121.6796875f, 117.7734375f, 40.0390625f, 16.8945313f },/* G NB */
- {1.0f }, /* T NB */
- {57.0312500f, 64.5996094f, 71.4355469f, 75.8789063f, 77.0507813f, 79.0039063f, 74.5117188f, 74.2187500f, 72.9492188f, 72.8515625f, 66.9433594f, 73.9257813f, 109.6191406f, 121.5332031f, 23.7792969f, 13.3789063f }, /* AU NB */
- {55.4687500f, 65.6738281f, 71.8261719f, 71.6308594f, 73.0468750f, 74.3164063f, 73.0957031f, 73.4863281f, 73.8769531f, 75.2441406f, 78.0761719f, 82.6171875f, 90.1367188f, 95.8496094f, 66.0644531f, 68.9941406f }, /* IA WB */
- {67.9687500f, 64.0625000f, 65.8203125f, 76.9531250f, 117.1875000f, 145.5078125f, 77.6855469f, 23.2421875f, 81.0546875f, 81.1035156f, 81.4453125f, 85.0585938f, 90.0878906f, 95.8984375f, 92.3828125f, 90.7226563f }, /* U WB */
- {35.6933594f, 39.4042969f, 57.3242188f, 64.6484375f, 68.0175781f, 76.2695313f, 80.7128906f, 82.0800781f, 85.1562500f, 89.6484375f, 89.9414063f, 95.3613281f, 104.7363281f, 106.0546875f, 105.2734375f, 97.8515625f }, /* V WB */
- {61.4257813f, 75.1464844f, 88.4277344f, 82.1777344f, 82.4218750f, 89.1601563f, 89.2578125f, 94.1894531f, 95.5566406f, 95.9472656f, 97.0703125f, 102.6367188f, 107.2265625f, 107.3730469f, 105.4199219f, 98.1933594f },/* G WB */
- {1.0f },/* T WB */
- {51.1230469f, 62.5976563f, 71.5820313f, 75.5371094f, 78.9550781f, 79.9804688f, 79.4433594f, 82.9101563f, 82.6171875f, 83.1054688f, 84.8632813f, 86.1328125f, 89.5996094f, 83.6914063f, 79.3945313f, 78.2226563f }, /* AU WB */
- {72.9980469f, 86.2792969f, 90.0878906f, 89.5996094f, 92.4316406f, 90.5273438f, 90.5273438f, 92.1386719f, 97.3632813f, 101.3671875f, 111.7675781f, 110.8398438f, 97.5585938f, 93.1640625f, 92.8710938f, 115.7226563f },/* IA 16k */
- {1.0f },/* U 16k */
- {49.714f, 67.480f, 88.315f, 84.931f, 102.979f, 99.871f, 113.361f, 115.387f, 115.951f, 126.902f, 130.543f, 127.340f, 117.813f, 113.104f, 107.586f, 99.412f }, /* V 16k */
- {96.8261719f, 117.3339844f, 132.5683594f, 134.4726563f, 140.7226563f, 136.8652344f, 141.6992188f, 141.1132813f, 143.8964844f, 152.6367188f, 168.5058594f, 169.1406250f, 158.4960938f, 156.1523438f, 147.4609375f, 182.4707031f },/* G 16k */
- {1.0f },/* T 16k */
- {55.1269531f, 70.3613281f, 83.1054688f, 87.2070313f, 90.5273438f, 91.4550781f, 94.7265625f, 93.6035156f, 97.6074219f, 98.7304688f, 104.6875000f, 99.6582031f, 95.6054688f, 91.6503906f, 88.4765625f, 78.2226563f, },/* NOT USED ! AU 16k */
- {69.5312500f, 80.1757813f, 101.3183594f, 100.9277344f, 106.4941406f, 111.1816406f, 107.6171875f, 112.9882813f, 116.6992188f, 117.1875000f, 120.9472656f, 125.0976563f, 130.7617188f, 128.7109375f, 123.3886719f, 104.9316406f} /* G WB for MA*/
-};
/* An 16-by-19 matrix in Scale = 32768.00f */
const Word16 inv_sigma_p_fx[][16] =//Q15
{
@@ -14221,7 +13488,7 @@ const Word16 offset_in_lvq_mode_SN_fx[][21] =
{0}, /*{0,0,0,0,0,0,0,0,0,0,1} */ /* A 16k */
};
-const int16_t offset_in_lvq_mode_pred[][32] =
+const Word16 offset_in_lvq_mode_pred[][32] =
{
{0,0,0,0,1,2,2,2,3,4,5,5,5,5,5,5,5,5,5,6}, /* I NB */
{0,1,1,1,2,3,4,4,4,4,4,5,5,5,6}, /* UV NB */
@@ -16810,15 +16077,6 @@ const Word16 subf_norm_groups[4][11] =
{6,7,14,15,19,23,27,31,35,39,43}
}; // Q0
-const float gain_att[MAX_P_ATT] =
-{
- 0.4794745f, 0.5910453f, 0.6647078f, 0.7245839f, 0.7598486f, 0.7912783f, 0.8165831f, 0.8396713f,
- 0.8562786f, 0.8716393f, 0.8848335f, 0.8971617f, 0.9061614f, 0.9146075f, 0.9220175f, 0.9290045f,
- 0.9344148f, 0.9395265f, 0.9440797f, 0.9484073f, 0.9518549f, 0.9551361f, 0.9581067f, 0.9609474f,
- 0.9632704f, 0.9654923f, 0.9675346f, 0.9694900f, 0.9711209f, 0.9726879f, 0.9741332f, 0.9755263f,
- 0.9767067f, 0.9778463f, 0.9789108f, 0.9799438f, 0.9808353f, 0.9816967f, 0.9825032f, 0.9832868f
-};
-
const Word16 gain_att_fx[40] = /* Q=15 */
{
15711, 19367, 21781, 23743, 24899, 25929, 26758, 27514,
@@ -16833,24 +16091,12 @@ const Word16 stab_trans_fx[10] = /* Q15 */
16384, 11381, 7232, 4292, 2433,
1341, 728, 391, 209, 112
};
-const float stab_trans[L_STAB_TBL] =
-{
- 0.500000f, 0.347332f, 0.220704f, 0.130976f, 0.074252f,
- 0.040937f, 0.022211f, 0.011944f, 0.006392f, 0.003412f
-};
-
-const float env_stab_tp[2][2] =
-{
- {0.999f, 0.5f},
- {0.001f, 0.5f}
-};
const Word16 env_stab_tp_fx[2][2] = /* Q15 */
{
{32735, 16384},
{33, 16384}
};
-const float att_step[NB_G] = { 4.0000000f, 2.0000000f, 1.3333333f, 1.0000000f};
const Word16 att_step_fx[4] = /* Q=13 */
{
@@ -17168,7 +16414,7 @@ const UWord8 hBitsMinus1_N36[8]=
{
7, 49, 90, 127, 160, 191, 220, 247
}; // Q0
-const uint8_t hBitsMinus1_N37[8]=
+const UWord8 hBitsMinus1_N37[8]=
{
7, 49, 91, 128, 162, 193, 222, 249
}; // Q0
@@ -17248,7 +16494,7 @@ const UWord8 hBitsMinus1_N56[7]=
{
6, 54, 100, 142, 181, 217, 250
}; // Q0
-const uint8_t hBitsMinus1_N57[7]=
+const UWord8 hBitsMinus1_N57[7]=
{
6, 54, 101, 143, 181, 218, 252
};
@@ -17498,18 +16744,6 @@ const Word16 gsc_sfm_end[MBANDS_GN] = {16, 32, 48, 64, 80, 96, 112, 128, 144, 16
const Word16 gsc_sfm_size[MBANDS_GN] = {16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16}; // Q0
-const float sm_table[] =
-{
- 1.0f, 0.9804f, 0.9607f, 0.9411f, 0.9215f, 0.902f, 0.8825f, 0.863f,
- 0.8436f, 0.8242f, 0.8049f, 0.7857f, 0.7666f, 0.7475f, 0.7286f, 0.7097f, 0.691f, 0.6724f,
- 0.6539f, 0.6355f, 0.6173f, 0.5993f, 0.5813f, 0.5636f, 0.546f, 0.5286f, 0.5114f, 0.4943f,
- 0.4775f, 0.4609f, 0.4444f, 0.4282f, 0.4122f, 0.3964f, 0.3809f, 0.3656f, 0.3506f, 0.3357f,
- 0.3212f, 0.3069f, 0.2929f, 0.2791f, 0.2657f, 0.2525f, 0.2396f, 0.227f, 0.2147f, 0.2027f,
- 0.191f, 0.1796f, 0.1685f, 0.1578f, 0.1474f, 0.1373f, 0.1275f, 0.1181f, 0.109f, 0.1003f,
- 0.0919f, 0.0838f, 0.0761f, 0.0688f, 0.0618f, 0.0552f, 0.0489f, 0.0431f, 0.0375f, 0.0324f,
- 0.0276f, 0.0232f, 0.0192f, 0.0156f, 0.0123f, 0.0094f, 0.0069f, 0.0048f, 0.0031f, 0.0017f,
- 0.0008f, 0.0002f
-};
const Word16 sm_table_fx[] =
{
32767, 32126, 31480, 30838, 30196, 29557, 28918, 28279, 27643, 27007,
@@ -17587,28 +16821,10 @@ const Word16 Compl_GSC_freq_bits[] =
5, 10, 10, 10 /* bitrate > ACELP_16k40 && FS = 16kHz */
}; // Q0
-const float mfreq_loc[] =
-{
- 175.0f, 375.0f, 775.0f, 1175.0f, 1575.0f, 1975.0f, 2375.0f, 2775.0f, 3175.0f, 3575.0f, 3975.0f,
- 4375.0f, 4775.0f, 5175.0f, 5575.0f, 6375.0f, 7175.0f, 7975.0f
-};
-
const Word16 mfreq_bindiv_loc[] = { 8, 8, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 32, 32, 32 }; // Q0
-const float mean_gp[] = { 0.5853f };
const Word16 mean_gp_fx[] = { 9590 }; /*Q14*/
-const float dic_gp[] =
-{
- -0.5847f, -0.4695f, -0.3897f, -0.2731f,
- -0.1986f, -0.1244f, -0.0492f, -0.005f,
- 0.0631f, 0.1379f, 0.211f, 0.2859f,
- 0.3229f, 0.3994f, 0.5217f, 0.6135f,
- -0.5471f, -0.5089f, -0.4285f, -0.3512f,
- -0.3124f, -0.235f, -0.162f, -0.0872f,
- 0.0249f, 0.1013f, 0.1741f, 0.2485f,
- 0.361f, 0.4376f, 0.4776f, 0.5645f
-};
const Word16 dic_gp_fx[] = /*Q14*/
{
-9580, -7692, -6385, -4474, -3254, -2038, -806, -82,
@@ -17616,32 +16832,11 @@ const Word16 dic_gp_fx[] = /*Q14*/
-8964, -8338, -7021, -5754, -5118, -3850, -2654, -1429,
408, 1660, 2852, 4071, 5915, 7170, 7825, 9249
};
-const float Gain_meanNB[] = { 2.4052f };
const Word16 Gain_meanNB_fx[] =
{
9852,
};/* Q12 */
-const float Gain_mean_dicNB[] =
-{
- -0.3197f, -0.2272f, -0.1386f, -0.0966f,
- -0.0132f, 0.1970f, 0.2865f, 0.3743f,
- 0.4640f, 0.5108f, 0.5581f, 0.6086f,
- 0.6588f, 0.7642f, 0.7101f, 0.0698f,
- -0.1827f, 0.2418f, 0.1540f, -0.2733f,
- -0.4144f, -0.5162f, -0.6806f, -1.3182f,
- -2.4026f, -0.4643f, -0.7983f, -1.9470f,
- -1.8160f, -1.6910f, -1.7558f, -0.5677f,
- -0.3673f, -0.6224f, -0.7379f, -0.8624f,
- -0.9321f, -1.0098f, -1.1600f, -1.2380f,
- -1.4052f, -1.4876f, -2.1967f, -1.5599f,
- -2.1399f, -2.3041f, 0.8225f, 0.9564f,
- 0.8835f, 1.1436f, -2.0176f, 1.0387f,
- -1.0822f, -1.6264f, -2.2534f, -1.8746f,
- 1.4304f, 0.0288f, 0.1116f, -0.0553f,
- 0.4192f, 0.3303f, -2.0750f,
- -2.3558f,
-};
const Word16 Gain_mean_dicNB_fx[1 * 64] = /*Q12 */
{
-1309, -931, -568, -396, -54, 807, 1174, 1533,
@@ -17653,142 +16848,13 @@ const Word16 Gain_mean_dicNB_fx[1 * 64] = /*Q12 */
3619, 4684, -8264, 4255, -4433, -6662, -9230, -7678,
5859, 118, 457, -227, 1717, 1353, -8499, -9649
};
-const float Mean_dic_NB[] =
-{
- -0.1084f, -0.0243f, -0.0292f, -0.0091f,
- 0.0061f, 0.0171f, 0.0362f, 0.0153f,
- 0.0416f, 0.0558f,
-};
+
const Word16 Mean_dic_NB_fx[1 * 10] = /*Q12 */
{
-444, -100, -120, -37, 25,
70, 148, 63, 170, 229
};
-const float Gain_dic1_NB[] =
-{
- -0.1479f, -0.0224f, 0.0013f,
- -0.4797f, 0.0718f, 0.1627f,
- -0.1073f, 0.0291f, 0.1613f,
- -0.0258f, 0.0652f, 0.0264f,
- -0.2961f, 0.0842f, -0.0332f,
- -0.3053f, 0.1508f, 0.1381f,
- -0.4650f, -0.1832f, 0.1581f,
- -0.2546f, -0.0879f, -0.1215f,
- -0.0043f, -0.0785f, 0.0235f,
- 0.0816f, 0.0283f, -0.0604f,
- -0.4709f, 0.1612f, 0.0056f,
- -0.4504f, 0.2876f, 0.1183f,
- -0.0440f, 0.2040f, 0.0408f,
- -0.4619f, -0.2252f, -0.0783f,
- 0.1016f, -0.1067f, -0.0839f,
- 0.1452f, -0.1337f, 0.0386f,
- -0.0648f, -0.1970f, -0.0826f,
- -0.2599f, -0.2477f, -0.0048f,
- -0.1528f, 0.1452f, -0.0814f,
- -0.1389f, 0.2661f, 0.1590f,
- 0.0066f, 0.1432f, -0.0809f,
- -0.0450f, -0.0207f, -0.1229f,
- -0.4643f, -0.4412f, 0.0796f,
- -0.4543f, -0.0387f, -0.2415f,
- -0.1626f, 0.0349f, -0.2839f,
- -0.4194f, 0.2517f, -0.1816f,
- 0.2068f, 0.0736f, -0.0144f,
- 0.1757f, -0.2445f, -0.0527f,
- 0.3370f, -0.2115f, -0.2366f,
- 0.1961f, -0.0010f, -0.1484f,
- 0.0568f, 0.0997f, -0.2436f,
- 0.3561f, 0.0213f, 0.0641f,
- 0.0842f, -0.1502f, -0.2506f,
- 0.2140f, -0.0362f, -0.0016f,
- 0.0165f, -0.2625f, 0.0660f,
- 0.1958f, 0.0804f, 0.1159f,
- -0.4695f, -0.0308f, -0.0092f,
- 0.3114f, -0.1023f, -0.0851f,
- 0.0979f, 0.2260f, 0.1403f,
- 0.2066f, -0.0569f, 0.1335f,
- 0.1691f, -0.4590f, 0.0869f,
- -0.0883f, -0.4109f, -0.0535f,
- 0.0565f, -0.0827f, 0.1460f,
- 0.2996f, -0.1503f, 0.0652f,
- 0.2724f, 0.0221f, -0.3213f,
- -0.1344f, -0.1588f, 0.1293f,
- 0.1083f, 0.0079f, 0.0442f,
- -0.0937f, 0.2946f, -0.1892f,
- -0.2424f, 0.2840f, 0.0099f,
- 0.1915f, -0.2486f, 0.1314f,
- 0.1551f, 0.1553f, -0.1036f,
- 0.3353f, -0.3337f, 0.0364f,
- 0.3521f, 0.0979f, -0.1083f,
- 0.2671f, 0.2169f, 0.0300f,
- 0.2135f, 0.2717f, -0.2642f,
- -0.1578f, -0.2715f, -0.2692f,
- 0.1316f, -0.3985f, -0.1668f,
- 0.0981f, 0.1393f, 0.0241f,
- -0.4342f, -0.4417f, -0.2072f,
- -0.1788f, -0.4128f, 0.1708f,
- -0.1655f, 0.1284f, 0.0670f,
- 0.0782f, 0.2996f, -0.0288f,
- -0.2984f, -0.0440f, 0.1108f,
- 0.0423f, 0.0853f, 0.1295f,
-};
-
-const float Gain_dic2_NB[] =
-{
- 0.0069f, 0.0000f, -0.0160f,
- -0.1361f, 0.0009f, 0.0504f,
- 0.0686f, -0.1568f, 0.0088f,
- -0.1019f, 0.0198f, -0.1206f,
- -0.0927f, 0.1671f, 0.1099f,
- 0.1272f, -0.3770f, 0.0631f,
- -0.2733f, 0.1496f, -0.2809f,
- 0.1256f, 0.0058f, 0.1945f,
- 0.0714f, -0.0204f, -0.1284f,
- 0.0723f, 0.1021f, -0.0563f,
- -0.1024f, -0.0165f, 0.2383f,
- 0.0004f, -0.0753f, 0.0971f,
- -0.1114f, -0.2459f, 0.0641f,
- -0.2982f, -0.0906f, 0.1089f,
- -0.0539f, -0.0952f, -0.0441f,
- -0.2955f, 0.1435f, 0.1833f,
- -0.2669f, 0.1288f, -0.0425f,
- 0.1440f, 0.0907f, -0.3104f,
- -0.0192f, -0.0612f, -0.3029f,
- -0.2480f, -0.1188f, -0.1250f,
- 0.1324f, 0.1419f, 0.0826f,
- -0.0648f, 0.1114f, -0.0257f,
- 0.1196f, -0.0173f, 0.0218f,
- 0.0103f, 0.0574f, 0.0926f,
- 0.0076f, 0.2916f, -0.0493f,
- 0.0422f, -0.2048f, 0.2074f,
- -0.0113f, 0.1221f, -0.1958f,
- 0.0371f, 0.2279f, 0.2620f,
- 0.2392f, 0.0843f, -0.0641f,
- 0.1969f, -0.1415f, -0.1273f,
- -0.0055f, -0.2421f, -0.1429f,
- 0.2138f, -0.1407f, 0.1003f,
-};
-
-const float Gain_dic3_NB[] =
-{
- -0.0039f, 0.0159f, -0.0553f, 0.0027f,
- -0.0523f, 0.1349f, 0.0894f, 0.0451f,
- 0.0334f, -0.0825f, -0.0732f, -0.1526f,
- -0.0298f, 0.0199f, 0.1314f, -0.1946f,
- 0.0391f, 0.0695f, -0.2694f, 0.0085f,
- -0.1451f, 0.0762f, -0.0925f, -0.1033f,
- 0.0412f, -0.1568f, -0.0964f, 0.0887f,
- 0.0856f, -0.2846f, 0.1538f, -0.0637f,
- -0.2905f, 0.0529f, 0.1016f, 0.0456f,
- -0.1409f, 0.0596f, -0.1553f, 0.2095f,
- 0.1415f, 0.1177f, -0.0536f, 0.1551f,
- 0.1159f, -0.0458f, 0.0909f, 0.0066f,
- -0.0159f, -0.0901f, 0.1231f, 0.2221f,
- -0.1032f, -0.1080f, 0.0302f, -0.0098f,
- 0.1173f, 0.1404f, -0.0101f, -0.1590f,
- 0.1665f, 0.1661f, 0.2222f, 0.1193f,
-};
-
const Word16 Gain_dic1_NB_fx[3 * 64] = /*Q12 */
{
-606, -92, 5,
@@ -17913,206 +16979,6 @@ const Word16 Gain_dic3_NB_fx[4 * 16] = /*Q12 */
682, 680, 910, 489
};
-const float Gain_dic2_NBHR[] =
-{
- 0.0070f, 0.0001f, -0.0229f,
- -0.1476f, -0.0493f, -0.0424f,
- 0.0791f, -0.0927f, -0.0399f,
- -0.0308f, -0.0735f, -0.0748f,
- -0.0704f, 0.0302f, 0.0273f,
- -0.0211f, 0.1279f, -0.0281f,
- 0.0572f, 0.0045f, -0.1133f,
- -0.0134f, -0.0686f, 0.0436f,
- 0.0393f, 0.1088f, 0.1543f,
- 0.0893f, -0.0201f, 0.0237f,
- 0.0556f, -0.2804f, 0.0660f,
- 0.0715f, 0.0698f, -0.0348f,
- -0.0301f, -0.0085f, -0.2187f,
- -0.1319f, -0.1649f, 0.0427f,
- 0.0807f, -0.1180f, -0.1678f,
- -0.1901f, 0.0498f, -0.1630f,
- -0.1202f, 0.1876f, -0.1245f,
- -0.2966f, -0.1514f, -0.1179f,
- 0.1663f, -0.0185f, -0.0722f,
- -0.1638f, 0.0966f, -0.0110f,
- -0.1854f, 0.0728f, 0.1377f,
- -0.0693f, 0.1437f, 0.0784f,
- -0.3336f, -0.1445f, 0.1210f,
- -0.1093f, -0.1429f, -0.1739f,
- 0.0029f, -0.1845f, -0.0220f,
- 0.1253f, 0.0407f, -0.2262f,
- -0.2861f, 0.2587f, -0.2925f,
- -0.1164f, 0.1825f, 0.2457f,
- 0.0103f, 0.0251f, 0.3118f,
- -0.2296f, 0.2562f, 0.0336f,
- -0.2257f, -0.0035f, -0.3586f,
- 0.1669f, 0.1657f, -0.3857f,
- 0.1019f, -0.0912f, -0.3838f,
- 0.1482f, 0.0660f, 0.0626f,
- 0.1384f, 0.1899f, 0.2057f,
- 0.3452f, -0.0544f, -0.1323f,
- 0.0236f, 0.0488f, 0.0614f,
- 0.0541f, 0.2623f, -0.1335f,
- -0.1744f, -0.0697f, 0.2553f,
- 0.0943f, -0.1671f, 0.2403f,
- 0.0826f, 0.1646f, 0.0282f,
- -0.0668f, 0.0418f, -0.0898f,
- 0.1419f, -0.4567f, 0.0836f,
- 0.0229f, 0.1079f, -0.1457f,
- -0.0715f, -0.2943f, 0.2078f,
- -0.0311f, 0.1224f, -0.3045f,
- 0.0428f, 0.4151f, 0.3314f,
- -0.0059f, 0.2989f, 0.0695f,
- 0.1725f, -0.2325f, -0.0715f,
- 0.1631f, 0.1202f, -0.0993f,
- 0.2841f, 0.1833f, 0.0490f,
- 0.0929f, -0.1452f, 0.0702f,
- -0.3833f, 0.1174f, -0.1297f,
- -0.1458f, -0.0391f, 0.0797f,
- -0.1412f, -0.3200f, -0.0097f,
- -0.0287f, -0.1278f, 0.1406f,
- -0.3695f, 0.1286f, 0.1848f,
- -0.0450f, 0.0097f, 0.1487f,
- -0.2966f, 0.0239f, 0.0167f,
- -0.0159f, -0.3233f, -0.2040f,
- 0.2004f, -0.0729f, 0.0498f,
- 0.1943f, 0.0051f, 0.2050f,
- 0.0757f, -0.0325f, 0.1324f,
- 0.2545f, -0.2377f, 0.1312f,
-};
-
-const float Gain_dic3_NBHR[] =
-{
- 0.0715f, 0.0018f, -0.0493f, -0.0232f,
- 0.1305f, 0.0268f, 0.1323f, -0.1251f,
- -0.1410f, 0.0158f, -0.1367f, -0.0843f,
- 0.0502f, 0.0811f, 0.0024f, -0.1302f,
- -0.0186f, 0.0869f, -0.0034f, 0.0203f,
- 0.0363f, -0.0908f, -0.0475f, -0.1196f,
- -0.1168f, -0.0588f, -0.0135f, 0.0275f,
- -0.0716f, -0.1147f, -0.1479f, 0.0151f,
- 0.1947f, -0.3535f, 0.1525f, -0.2753f,
- 0.0423f, 0.1132f, -0.4115f, -0.0120f,
- -0.0956f, -0.0720f, -0.0388f, -0.1134f,
- -0.1746f, 0.1026f, -0.0357f, -0.2402f,
- -0.0087f, 0.0068f, -0.1182f, 0.0290f,
- 0.1152f, 0.0665f, -0.1780f, -0.0283f,
- 0.0167f, -0.0212f, -0.1534f, -0.1048f,
- 0.1047f, -0.2240f, -0.0385f, -0.0466f,
- -0.1331f, 0.0561f, -0.1063f, 0.0637f,
- -0.0312f, 0.0037f, -0.1930f, 0.1494f,
- 0.0655f, -0.0945f, -0.3072f, 0.0248f,
- 0.0922f, 0.0580f, 0.0735f, 0.0007f,
- -0.1207f, 0.0363f, 0.0319f, -0.0303f,
- 0.1547f, -0.0751f, 0.0242f, 0.0058f,
- 0.1397f, 0.1735f, 0.1842f, -0.2776f,
- -0.2707f, 0.0977f, 0.2668f, 0.0901f,
- -0.2028f, -0.1033f, 0.3865f, 0.2659f,
- -0.0203f, 0.0380f, -0.0256f, 0.2631f,
- -0.2270f, 0.1163f, 0.0372f, 0.0927f,
- 0.1894f, 0.2838f, 0.1924f, -0.0104f,
- 0.0680f, 0.0122f, 0.0997f, 0.1458f,
- 0.1162f, 0.1180f, 0.0179f, 0.1828f,
- 0.2204f, 0.1676f, 0.0196f, -0.1003f,
- 0.0476f, -0.1876f, 0.0683f, 0.0840f,
- -0.0641f, -0.2440f, -0.0112f, -0.0693f,
- -0.0161f, 0.0641f, 0.0769f, -0.3024f,
- 0.1061f, 0.1410f, -0.0572f, -0.2854f,
- 0.0487f, -0.4075f, 0.0459f, 0.0278f,
- -0.0140f, 0.1022f, -0.1243f, -0.1545f,
- 0.0240f, -0.0290f, 0.0314f, -0.1991f,
- -0.0383f, -0.0890f, -0.0607f, 0.1311f,
- 0.0164f, -0.1524f, 0.0296f, 0.2814f,
- 0.3526f, 0.0346f, -0.1425f, 0.0093f,
- 0.2652f, -0.0205f, 0.0395f, 0.2426f,
- 0.0958f, -0.0937f, -0.0302f, 0.1301f,
- 0.0615f, 0.0446f, -0.2835f, -0.2160f,
- -0.1053f, -0.2025f, 0.0248f, 0.1055f,
- -0.1728f, 0.2409f, -0.2493f, -0.1572f,
- -0.0157f, 0.0293f, -0.4112f, 0.2406f,
- 0.0512f, -0.1206f, -0.2211f, 0.3179f,
- 0.0121f, -0.0455f, 0.0431f, 0.0451f,
- -0.0626f, 0.2130f, -0.2451f, 0.0946f,
- 0.1376f, -0.0196f, -0.1657f, 0.1258f,
- -0.1862f, -0.0097f, -0.2866f, 0.0556f,
- -0.2513f, 0.0485f, -0.0144f, -0.0726f,
- 0.0073f, -0.0115f, 0.0484f, -0.0645f,
- -0.0966f, -0.3504f, 0.2229f, -0.2486f,
- -0.0344f, 0.2348f, 0.0088f, 0.1117f,
- 0.0088f, -0.0947f, 0.1894f, -0.2441f,
- -0.0181f, 0.1194f, 0.2775f, 0.0341f,
- -0.2369f, -0.1871f, 0.1625f, -0.0285f,
- 0.0220f, 0.1462f, 0.4066f, 0.3429f,
- -0.0763f, -0.1673f, -0.1866f, -0.1501f,
- 0.1374f, -0.1128f, -0.1530f, -0.1874f,
- 0.1933f, 0.1366f, -0.3527f, 0.1357f,
- -0.1419f, 0.1760f, -0.1364f, 0.2775f,
- -0.1707f, -0.0667f, 0.0668f, -0.2065f,
- 0.2295f, -0.1684f, 0.1824f, -0.0617f,
- -0.0431f, -0.1322f, 0.3309f, -0.0529f,
- -0.1430f, 0.1042f, 0.2921f, -0.2119f,
- 0.0358f, 0.1299f, -0.1342f, 0.0989f,
- 0.0631f, 0.1654f, -0.0598f, -0.0405f,
- 0.1884f, 0.2592f, -0.0807f, 0.1176f,
- 0.0948f, 0.4565f, -0.1406f, 0.3869f,
- 0.1129f, 0.2113f, 0.1108f, 0.2958f,
- 0.1392f, 0.1289f, -0.1663f, 0.3001f,
- -0.0943f, 0.1483f, 0.1463f, 0.2112f,
- -0.0376f, -0.0049f, -0.0515f, -0.0564f,
- 0.0234f, 0.1798f, 0.0996f, -0.0633f,
- 0.1864f, -0.3743f, 0.2672f, 0.0607f,
- 0.1720f, -0.2764f, 0.4289f, -0.2641f,
- 0.0758f, -0.1174f, 0.0803f, -0.0964f,
- 0.0473f, -0.1906f, 0.0144f, -0.2328f,
- -0.2278f, -0.2336f, -0.0060f, 0.4555f,
- -0.2079f, -0.0547f, -0.1176f, 0.2006f,
- -0.3511f, 0.1197f, 0.0539f, 0.3127f,
- 0.0956f, 0.1653f, 0.1317f, 0.0846f,
- 0.2158f, -0.1499f, 0.4502f, 0.1656f,
- -0.1886f, 0.1181f, -0.2266f, 0.6047f,
- -0.0670f, -0.1125f, 0.0923f, -0.0642f,
- -0.0690f, -0.0762f, 0.1423f, 0.0834f,
- 0.1107f, -0.3762f, 0.0924f, 0.3090f,
- 0.1900f, 0.2673f, 0.3150f, 0.2012f,
- -0.2339f, -0.1082f, -0.0508f, -0.0173f,
- 0.2405f, -0.2444f, -0.0301f, 0.1156f,
- 0.0136f, -0.2449f, -0.1253f, 0.1158f,
- -0.0633f, 0.3504f, 0.2381f, 0.0768f,
- -0.0143f, -0.0412f, 0.1767f, 0.2347f,
- -0.0512f, 0.2515f, 0.0832f, -0.2386f,
- 0.2573f, 0.7121f, -0.0018f, -0.2141f,
- -0.2079f, -0.0557f, 0.0805f, 0.1525f,
- 0.0022f, -0.1280f, -0.0237f, -0.0035f,
- 0.0038f, -0.0122f, 0.1163f, 0.5874f,
- 0.0644f, -0.0581f, 0.1875f, 0.0136f,
- 0.0457f, 0.0263f, -0.0413f, 0.1088f,
- 0.1644f, 0.0582f, 0.2423f, 0.1638f,
- -0.0532f, 0.0697f, 0.1184f, 0.0443f,
- 0.1633f, -0.1285f, 0.1561f, 0.1394f,
- 0.1586f, 0.0050f, -0.0458f, -0.1260f,
- 0.2517f, 0.0403f, 0.1285f, 0.0333f,
- -0.0813f, 0.0750f, 0.0248f, -0.1389f,
- -0.0383f, 0.0755f, -0.2281f, -0.0295f,
- -0.0820f, 0.0345f, 0.0096f, 0.1308f,
- 0.1616f, 0.0888f, -0.0324f, 0.0543f,
- -0.3135f, 0.1556f, -0.1552f, 0.0187f,
- 0.3031f, 0.2066f, 0.1139f, 0.1557f,
- 0.2055f, 0.0801f, 0.3248f, -0.0781f,
- 0.0372f, -0.2464f, 0.1343f, -0.0524f,
- -0.1885f, 0.0032f, 0.1451f, -0.0297f,
- 0.0820f, -0.1000f, -0.1336f, -0.0005f,
- 0.2121f, -0.0259f, 0.0784f, -0.2882f,
- 0.1259f, 0.3045f, -0.2021f, -0.1408f,
- -0.1636f, 0.2132f, 0.0897f, -0.0322f,
- -0.1013f, 0.1537f, -0.0700f, -0.0400f,
- -0.0256f, 0.0338f, 0.1603f, -0.1077f,
- -0.0390f, -0.2649f, 0.2294f, 0.1718f,
- -0.0313f, -0.0166f, -0.0901f, -0.2568f,
- -0.3501f, 0.1449f, 0.1334f, -0.1623f,
- -0.4515f, 0.0182f, 0.0428f, 0.0424f,
- -0.3133f, 0.1780f, -0.3883f, 0.2519f,
-};
-
const Word16 Gain_dic2_NBHR_fx[3 * 64] = /*Q12 */
{
29, 0, -94,
@@ -18313,177 +17179,11 @@ const Word16 Gain_dic3_NBHR_fx[4 * 128] = /*Q12 */
-1283, 729, -1590, 1032
};
-const float YG_mean16[] =
-{
- -0.0968f, -0.0468f, -0.0409f, -0.0332f,
- -0.0147f, -0.0042f, 0.0111f, 0.0096f,
- 0.0293f, 0.0198f, 0.0219f, 0.0164f,
- 0.0358f, 0.0083f, 0.0398f, 0.0448f,
-};
const Word16 YG_mean16_fx[1 * 16] = /*Q12 */
{
-396, -192, -168, -136, -60, -17, 45, 39,
120, 81, 90, 67, 147, 34, 163, 184
};
-const float YG_dicMR_1[] =
-{
- -0.4588f, 0.2016f, 0.1315f, -0.0513f,
- -0.0294f, 0.0652f, -0.0335f, -0.0347f,
- -0.1948f, -0.1154f, 0.1059f, 0.0594f,
- 0.0724f, -0.2188f, 0.0901f, 0.0750f,
- -0.4597f, -0.3254f, 0.1015f, 0.1244f,
- -0.4774f, -0.1611f, -0.1151f, 0.0548f,
- -0.2210f, -0.1962f, -0.1262f, 0.1056f,
- -0.2346f, 0.0050f, -0.0631f, -0.0547f,
- 0.0510f, 0.2386f, -0.0519f, -0.0042f,
- 0.1308f, -0.0595f, 0.0388f, 0.0238f,
- -0.0647f, 0.1891f, 0.1005f, -0.0799f,
- 0.0823f, -0.0955f, -0.0579f, -0.1152f,
- -0.4790f, -0.4482f, -0.1689f, 0.1149f,
- 0.1525f, 0.0422f, -0.1130f, -0.0037f,
- -0.2356f, 0.0643f, 0.0151f, 0.1466f,
- -0.1910f, 0.2170f, -0.1056f, 0.0514f,
- -0.4373f, 0.2081f, -0.1106f, -0.1895f,
- -0.0445f, -0.0433f, -0.2631f, 0.0195f,
- -0.0889f, 0.0855f, 0.0683f, 0.0715f,
- -0.2201f, 0.2731f, 0.0719f, -0.2914f,
- 0.0038f, 0.1073f, -0.0835f, 0.1121f,
- -0.4455f, -0.3868f, -0.3375f, -0.1949f,
- 0.1764f, 0.0140f, -0.3015f, -0.1613f,
- 0.2167f, -0.3999f, 0.0677f, 0.0572f,
- 0.0831f, 0.0842f, 0.0345f, -0.1490f,
- 0.3124f, -0.0055f, 0.0042f, 0.0352f,
- -0.1561f, -0.2081f, -0.1269f, -0.1350f,
- 0.2519f, 0.2059f, 0.0364f, 0.1061f,
- 0.1418f, 0.1911f, 0.1266f, -0.0479f,
- 0.1115f, 0.2308f, 0.1216f, -0.3146f,
- -0.4631f, -0.0101f, 0.1038f, 0.1255f,
- 0.1921f, 0.0393f, 0.1236f, 0.0941f,
- -0.1365f, 0.2635f, 0.0780f, 0.1258f,
- 0.1220f, 0.0830f, 0.0146f, 0.0258f,
- 0.0614f, -0.2434f, -0.2840f, -0.2344f,
- 0.0638f, -0.3144f, -0.1540f, 0.0817f,
- 0.3029f, -0.1514f, -0.0944f, -0.1617f,
- 0.0407f, 0.0474f, 0.1163f, 0.0163f,
- 0.2027f, -0.0636f, 0.1049f, -0.2933f,
- -0.1169f, -0.0300f, 0.0174f, -0.2837f,
- 0.0550f, -0.3618f, 0.0322f, -0.1958f,
- 0.1659f, 0.1862f, -0.2466f, 0.1048f,
- 0.0488f, -0.0304f, 0.0638f, 0.1441f,
- 0.1882f, -0.1807f, -0.0447f, 0.0559f,
- -0.4542f, -0.0850f, 0.0678f, -0.1340f,
- -0.4317f, 0.2362f, 0.0687f, 0.1451f,
- -0.4217f, -0.4143f, 0.0213f, -0.1866f,
- 0.2853f, 0.1540f, -0.0279f, -0.1151f,
- -0.3994f, -0.0247f, -0.3232f, -0.0221f,
- 0.2004f, -0.1819f, 0.1119f, -0.0644f,
- 0.2475f, -0.1406f, 0.0951f, 0.1147f,
- 0.2541f, -0.1261f, -0.2486f, 0.0897f,
- 0.2016f, 0.0042f, 0.1040f, -0.0797f,
- -0.1140f, -0.4007f, 0.0491f, 0.0794f,
- -0.4653f, 0.1045f, -0.0824f, 0.0541f,
- -0.2492f, 0.1539f, 0.1023f, -0.0183f,
- -0.0211f, -0.0926f, -0.0495f, 0.0572f,
- 0.1609f, 0.1286f, -0.1199f, -0.3680f,
- -0.1378f, -0.4261f, -0.2389f, -0.0422f,
- -0.4306f, -0.1056f, -0.1813f, -0.2662f,
- 0.0590f, 0.1732f, 0.0657f, 0.1213f,
- 0.1749f, 0.0180f, -0.0507f, 0.1508f,
- -0.0724f, 0.1574f, -0.2109f, -0.1965f,
- -0.0112f, -0.0797f, 0.1006f, -0.0723f,
-};
-
-const float YG_dicMR_2[] =
-{
- 0.0228f, 0.0529f, -0.0298f, 0.0091f,
- -0.0032f, -0.0203f, 0.0257f, -0.1199f,
- -0.0972f, -0.1446f, 0.0973f, -0.0390f,
- 0.1325f, -0.0197f, -0.1147f, 0.0997f,
- 0.0963f, -0.1539f, -0.0230f, -0.0630f,
- -0.1623f, 0.0325f, -0.0331f, -0.0305f,
- 0.0970f, -0.0857f, 0.1538f, -0.0361f,
- -0.2846f, 0.0992f, -0.2111f, 0.1353f,
- -0.0333f, -0.0737f, -0.0642f, 0.0198f,
- -0.1646f, -0.1605f, -0.1393f, -0.1688f,
- -0.0503f, 0.0930f, -0.1707f, 0.0298f,
- 0.0665f, -0.3677f, 0.0868f, 0.0036f,
- 0.1102f, -0.2346f, 0.1557f, -0.2765f,
- 0.0772f, -0.1922f, 0.0404f, 0.1428f,
- 0.0762f, -0.0352f, 0.0451f, 0.0668f,
- 0.0095f, -0.1723f, -0.2433f, 0.0611f,
- -0.2235f, -0.2127f, -0.0279f, 0.1118f,
- -0.2035f, 0.0849f, 0.0888f, -0.2901f,
- 0.1098f, 0.1764f, -0.0625f, 0.1007f,
- 0.0902f, 0.1143f, -0.3346f, 0.1015f,
- 0.0841f, 0.0401f, 0.0707f, -0.2672f,
- 0.1622f, 0.0297f, 0.0082f, -0.0532f,
- 0.1355f, 0.0621f, 0.1365f, 0.2015f,
- 0.0762f, 0.1201f, 0.1211f, -0.0066f,
- -0.0974f, 0.0770f, 0.1685f, -0.0806f,
- -0.1118f, 0.1734f, 0.0503f, 0.1013f,
- 0.0709f, 0.0217f, -0.1615f, -0.1139f,
- -0.0176f, 0.1448f, -0.0264f, -0.1122f,
- -0.0531f, 0.0113f, 0.0778f, 0.0461f,
- -0.3335f, 0.0486f, 0.0892f, 0.0152f,
- -0.1348f, -0.0405f, 0.1884f, 0.2103f,
- -0.0387f, 0.0294f, -0.0525f, 0.1893f,
-};
-
-const float YG_dicMR_3[] =
-{
- -0.0251f, -0.0350f, -0.0207f, -0.0047f,
- -0.0986f, 0.0444f, -0.1942f, 0.0205f,
- 0.0972f, -0.1449f, -0.0134f, -0.0624f,
- 0.0691f, 0.0313f, -0.1153f, 0.0682f,
- -0.0600f, -0.1532f, 0.0686f, 0.0726f,
- -0.2082f, 0.1143f, 0.0874f, -0.2235f,
- 0.0664f, 0.0363f, 0.0510f, -0.1081f,
- -0.0409f, -0.1231f, 0.1104f, -0.1281f,
- 0.1524f, -0.1042f, 0.1901f, 0.0286f,
- 0.2634f, 0.0987f, -0.0240f, 0.0196f,
- 0.0332f, 0.0404f, 0.0347f, -0.3404f,
- 0.1252f, -0.1383f, -0.0367f, 0.2006f,
- 0.0302f, 0.1576f, 0.0487f, 0.0664f,
- -0.0403f, -0.1715f, -0.1502f, 0.0404f,
- 0.0814f, 0.1978f, -0.1116f, 0.2533f,
- -0.0878f, 0.0256f, -0.0268f, 0.1310f,
- -0.0548f, 0.0305f, 0.1372f, -0.0063f,
- 0.1706f, -0.2698f, 0.1976f, -0.3231f,
- -0.3001f, 0.2054f, -0.1872f, 0.1393f,
- -0.0756f, 0.1066f, -0.0278f, -0.0562f,
- -0.2551f, 0.1538f, 0.1377f, 0.0787f,
- 0.0689f, 0.2857f, -0.1765f, -0.0746f,
- -0.0800f, -0.0604f, -0.0612f, -0.1461f,
- 0.0864f, 0.0811f, -0.3889f, 0.1219f,
- 0.0810f, -0.0055f, 0.0534f, 0.0743f,
- 0.0794f, -0.3690f, 0.0922f, 0.0731f,
- -0.0230f, -0.0132f, 0.1657f, 0.2333f,
- 0.1238f, 0.2026f, 0.2103f, -0.1805f,
- -0.2186f, -0.0329f, 0.0040f, -0.0083f,
- 0.1654f, 0.1588f, 0.2346f, 0.1744f,
- 0.1993f, -0.1624f, -0.4251f, -0.1638f,
- 0.0670f, 0.0227f, -0.1506f, -0.1057f,
-};
-
-const float YG_dicMR_4[] =
-{
- -0.0398f, -0.0108f, -0.0263f, 0.0079f,
- 0.1358f, 0.0373f, 0.0281f, 0.0293f,
- 0.1507f, 0.1997f, 0.1958f, 0.1756f,
- -0.1560f, -0.1623f, 0.0297f, 0.1620f,
- 0.0863f, -0.1354f, -0.0860f, -0.0209f,
- -0.2836f, 0.2034f, -0.2525f, 0.0796f,
- -0.1247f, -0.0991f, -0.1167f, -0.1276f,
- 0.1198f, -0.3596f, 0.0987f, -0.0051f,
- 0.0362f, 0.0702f, -0.0111f, -0.1328f,
- -0.0148f, 0.0420f, -0.1931f, -0.0108f,
- 0.1745f, -0.1095f, 0.2103f, 0.1230f,
- -0.0264f, 0.0641f, 0.1489f, 0.0289f,
- 0.2348f, 0.2016f, -0.2473f, -0.0091f,
- -0.0077f, -0.1208f, 0.0883f, -0.0523f,
- -0.0091f, 0.1614f, -0.0183f, 0.0706f,
- -0.2039f, 0.0593f, 0.0207f, -0.0256f,
-};
const Word16 YG_dicMR_1_fx[4 * 64] = /*Q12 */
{
@@ -18643,30 +17343,11 @@ const Word16 YG_dicMR_4_fx[4 * 16] = /*Q12 */
};
-const float mean_m[] = { 2.8717f };
const Word16 mean_m_fx[1 * 1] = /*Q12 */
{
11762
};
-const float mean_gain_dic[] =
-{
- -0.1804f, -0.1267f, -0.0185f, 0.0358f,
- 0.1402f, 0.1903f, 0.2399f, 0.2894f,
- 0.3379f, 0.3858f, 0.4356f, 0.4857f,
- 0.5380f, 0.6452f, 0.6992f, 0.5914f,
- 0.0885f, -0.0721f, -0.2922f, -0.4726f,
- -0.6732f, -2.8699f, -2.0059f, 0.7528f,
- 0.8083f, -0.3501f, -0.4106f, -0.8156f,
- -2.2665f, -2.2112f, -2.1036f, -1.9001f,
- -1.7967f, -1.7001f, -1.6094f, -1.5218f,
- -1.3355f, -1.2328f, -1.1354f, -0.9654f,
- -0.6031f, -0.2352f, -0.5368f, -0.7426f,
- -0.8894f, -1.0479f, -1.4292f, -2.4899f,
- 1.0016f, 0.8661f, 1.0718f, 1.1517f,
- 0.9318f, -2.5695f, -2.8128f, -2.3365f,
- -2.4168f, -2.2389f, -2.6467f, -2.7259f,
- 1.3428f, 1.2399f, 1.4988f, 1.7072f,
-};
+
const Word16 mean_gain_dic_fx[1 * 64] =
{
-739, -519, -76, 147, 574, 779, 983, 1185,
@@ -18678,124 +17359,12 @@ const Word16 mean_gain_dic_fx[1 * 64] =
4103, 3548, 4390, 4717, 3817, -10525, -11521, -9570,
-9899, -9171, -10841, -11165, 5500, 5079, 6139, 6993
}; /* Q12 */
-const float YGain_mean_LR[] =
-{
- -0.0940f, -0.0435f, -0.0348f, -0.0284f,
- -0.0113f, -0.0029f, 0.0156f, 0.0123f,
- 0.0288f, 0.0167f, 0.0324f, 0.0369f,
-};
+
const Word16 YGain_mean_LR_fx[1 * 12] =/* Q12 */
{
-385, -178, -143, -116, -46, -12,
64, 50, 118, 68, 133, 151
};
-const float YGain_dic1_LR[] =
-{
- -0.4660f, 0.0389f, -0.0220f,
- -0.0378f, 0.1016f, -0.0036f,
- -0.0241f, -0.0205f, 0.0967f,
- -0.4472f, -0.2070f, -0.0781f,
- -0.1901f, 0.2501f, 0.0111f,
- -0.4541f, -0.4299f, 0.0666f,
- 0.0197f, -0.0832f, -0.0755f,
- -0.1999f, -0.0008f, -0.0770f,
- 0.1179f, 0.0525f, -0.0474f,
- 0.0591f, 0.2288f, -0.0186f,
- -0.4468f, -0.4279f, -0.2691f,
- -0.3880f, 0.2118f, -0.1605f,
- -0.2224f, 0.0950f, 0.1028f,
- -0.4478f, 0.2234f, 0.0952f,
- -0.0352f, 0.1378f, -0.2121f,
- 0.2143f, -0.3769f, 0.0736f,
- 0.1089f, 0.0811f, 0.0917f,
- -0.1318f, -0.2008f, -0.2444f,
- 0.1339f, -0.0469f, 0.0567f,
- 0.2245f, -0.1437f, -0.0427f,
- 0.2121f, 0.1750f, -0.1378f,
- 0.1945f, -0.0252f, -0.2556f,
- -0.0819f, -0.4228f, -0.0453f,
- -0.4492f, -0.0842f, 0.1383f,
- 0.2943f, 0.0266f, 0.0106f,
- 0.2405f, -0.1113f, 0.1391f,
- 0.1588f, -0.2987f, -0.2134f,
- 0.2265f, 0.1837f, 0.0951f,
- -0.0302f, 0.2034f, 0.1404f,
- -0.4421f, -0.0608f, -0.2788f,
- -0.1736f, -0.1872f, 0.0451f,
- 0.0840f, -0.2138f, 0.0652f,
-};
-
-const float YGain_dic2_LR[] =
-{
- -0.0718f, -0.0178f, -0.0101f, 0.0026f,
- 0.0675f, 0.0806f, -0.3212f, 0.0423f,
- 0.0064f, -0.1738f, 0.0211f, 0.0003f,
- -0.2054f, -0.1316f, 0.0600f, -0.1170f,
- 0.0105f, -0.0505f, 0.1732f, 0.0282f,
- 0.0254f, -0.0482f, 0.0554f, -0.1338f,
- 0.0638f, -0.0556f, 0.0402f, 0.1480f,
- 0.1496f, 0.0983f, -0.0297f, -0.1025f,
- 0.0034f, 0.0444f, -0.1327f, -0.1633f,
- -0.1793f, 0.0958f, -0.1200f, -0.0319f,
- -0.3214f, 0.0670f, 0.0283f, 0.0808f,
- -0.3269f, 0.1307f, -0.3079f, 0.1485f,
- -0.0844f, 0.0677f, -0.1040f, 0.1779f,
- -0.2606f, -0.2042f, -0.1393f, 0.0948f,
- 0.1570f, 0.1228f, 0.1182f, 0.1300f,
- -0.0362f, 0.1092f, 0.0294f, -0.0957f,
- -0.1465f, 0.0641f, 0.1266f, -0.0182f,
- 0.1676f, -0.0844f, 0.0926f, 0.0055f,
- 0.0318f, 0.0583f, 0.0917f, -0.3336f,
- 0.0165f, 0.1601f, -0.0881f, 0.0224f,
- 0.1485f, 0.0699f, -0.0988f, 0.1190f,
- -0.2517f, 0.1238f, 0.1276f, -0.2371f,
- 0.0124f, -0.0108f, -0.1272f, 0.0421f,
- -0.1400f, -0.1221f, 0.0972f, 0.1542f,
- 0.0587f, 0.0358f, 0.0254f, 0.0125f,
- -0.0780f, -0.1659f, -0.2174f, -0.0971f,
- -0.0475f, 0.1229f, 0.0746f, 0.1120f,
- 0.0819f, 0.0898f, 0.1615f, -0.0950f,
- 0.0923f, -0.1925f, -0.1311f, 0.1660f,
- 0.1057f, -0.2756f, 0.1153f, -0.2155f,
- 0.1153f, -0.0761f, -0.0735f, -0.0506f,
- 0.0922f, -0.3286f, 0.1058f, 0.0996f,
-};
-
-const float YGain_dic3_LR[] =
-{
- -0.0810f, -0.0466f, -0.0299f, -0.1110f, -0.0512f,
- 0.0888f, -0.0116f, -0.1622f, 0.0996f, 0.0549f,
- -0.1406f, -0.0835f, 0.0897f, 0.0128f, 0.0658f,
- -0.0958f, -0.0384f, -0.0188f, 0.1526f, -0.0546f,
- -0.0446f, -0.1591f, -0.0990f, 0.0242f, 0.0650f,
- 0.0059f, 0.0158f, 0.0180f, 0.1281f, 0.1497f,
- -0.1966f, 0.0746f, -0.0936f, -0.0051f, 0.0602f,
- 0.0038f, 0.0325f, -0.1016f, -0.0009f, -0.1385f,
- 0.0718f, -0.1831f, 0.1082f, -0.0897f, 0.0557f,
- 0.1308f, 0.1992f, 0.1872f, 0.1371f, 0.1449f,
- -0.0131f, 0.0489f, -0.2706f, -0.1422f, 0.0554f,
- 0.0300f, -0.0106f, 0.1011f, -0.0918f, -0.1585f,
- 0.1445f, -0.1593f, -0.1646f, -0.0943f, -0.0868f,
- 0.0244f, -0.0142f, -0.0110f, -0.0264f, 0.0251f,
- -0.1774f, -0.0473f, -0.2856f, 0.2274f, 0.2675f,
- 0.1251f, 0.1851f, -0.1073f, -0.1877f, -0.2566f,
- 0.0885f, 0.1921f, -0.0673f, -0.0339f, 0.0364f,
- -0.0533f, 0.0944f, 0.1116f, -0.1010f, 0.0646f,
- -0.0492f, 0.1618f, -0.2695f, 0.2154f, -0.0825f,
- -0.0139f, 0.0988f, 0.0656f, 0.0628f, -0.0539f,
- 0.0817f, 0.2109f, 0.2841f, -0.1492f, -0.1509f,
- 0.3113f, 0.1205f, -0.4354f, 0.0290f, 0.2983f,
- 0.1837f, 0.0186f, 0.0660f, 0.0179f, -0.0140f,
- 0.0917f, -0.3063f, 0.0353f, 0.1767f, 0.1473f,
- -0.2414f, 0.1508f, 0.1609f, 0.1647f, 0.1367f,
- 0.0313f, -0.0359f, -0.0337f, -0.0899f, 0.2352f,
- 0.0341f, -0.0414f, 0.2115f, 0.1313f, 0.0311f,
- 0.0299f, -0.1503f, 0.0406f, 0.0575f, -0.0966f,
- 0.0914f, 0.0680f, 0.0994f, 0.1587f, -0.3097f,
- -0.2103f, 0.1496f, -0.1844f, -0.3256f, -0.2372f,
- -0.2251f, 0.0767f, 0.1015f, -0.0279f, -0.1582f,
- 0.0647f, 0.0207f, 0.0148f, -0.2710f, 0.0109f,
-};
const Word16 YGain_dic1_LR_fx[3 * 32] = /*Q12 */
{
@@ -18905,14 +17474,6 @@ const Word16 YGain_dic3_LR_fx[5 * 32] = /*Q12 */
265, 85, 61, -1110, 45
};
-const float YG_mean16HR[] =
-{
- -0.0968f, -0.0468f, -0.0409f, -0.0332f,
- -0.0147f, -0.0042f, 0.0111f, 0.0096f,
- 0.0293f, 0.0198f, 0.0219f, 0.0164f,
- 0.0358f, 0.0083f, 0.0398f, 0.0448f,
-};
-
const Word16 YG_mean16HR_fx[] =
{
//Q12
@@ -18922,138 +17483,6 @@ const Word16 YG_mean16HR_fx[] =
146, 33, 163, 183,
};
-const float YG_dicHR_1[] =
-{
- -0.4774f, 0.1006f, 0.0327f, 0.0080f,
- -0.0832f, 0.0217f, -0.0103f, 0.0049f,
- -0.2440f, 0.0768f, -0.0353f, 0.1115f,
- -0.1048f, -0.0464f, 0.0456f, 0.1336f,
- -0.2582f, 0.0393f, 0.0595f, -0.0481f,
- -0.0114f, -0.0198f, -0.1200f, -0.0546f,
- 0.0351f, 0.2409f, -0.0276f, 0.0037f,
- 0.0699f, -0.0765f, 0.0189f, 0.0008f,
- 0.0610f, -0.3055f, 0.0930f, 0.0745f,
- -0.4662f, -0.0631f, 0.1176f, 0.0212f,
- 0.2203f, 0.0146f, 0.0104f, -0.0456f,
- -0.4809f, -0.2422f, -0.0819f, 0.0545f,
- -0.4672f, -0.0398f, -0.1137f, -0.0410f,
- -0.1970f, 0.2933f, 0.0060f, 0.1176f,
- -0.1377f, -0.4744f, 0.0520f, 0.0928f,
- -0.0293f, -0.1688f, -0.0396f, 0.0339f,
- -0.2359f, 0.2464f, 0.1067f, -0.1134f,
- 0.1061f, 0.0360f, 0.0452f, 0.0388f,
- -0.4747f, -0.0325f, -0.0765f, 0.1470f,
- -0.2514f, 0.0578f, -0.1495f, -0.0912f,
- -0.1831f, -0.1396f, -0.2463f, -0.0975f,
- 0.1628f, -0.2331f, -0.0273f, 0.0217f,
- 0.0455f, -0.0040f, -0.0425f, 0.0827f,
- -0.0575f, -0.0769f, 0.0984f, -0.0597f,
- 0.0696f, 0.0327f, 0.0209f, -0.0854f,
- -0.4838f, -0.3677f, -0.3150f, 0.0826f,
- -0.4827f, -0.4701f, -0.0899f, 0.2140f,
- -0.4713f, 0.0627f, 0.1106f, 0.1629f,
- -0.4600f, 0.0633f, -0.0302f, -0.1902f,
- -0.1985f, 0.2655f, -0.1455f, -0.2476f,
- 0.0968f, 0.0162f, -0.2139f, 0.1007f,
- -0.1328f, 0.2215f, -0.1605f, 0.0736f,
- -0.1185f, 0.1496f, 0.1259f, 0.1897f,
- -0.0884f, 0.1026f, 0.1019f, -0.1266f,
- -0.4284f, 0.3193f, 0.0159f, -0.2937f,
- -0.1511f, 0.1722f, -0.0139f, -0.0138f,
- -0.4732f, 0.2455f, 0.1371f, 0.0145f,
- 0.0152f, 0.1274f, -0.1076f, 0.0780f,
- -0.4338f, 0.2469f, -0.0683f, -0.0405f,
- 0.1364f, 0.0873f, -0.1085f, -0.0116f,
- 0.1958f, -0.4880f, 0.0765f, 0.0780f,
- -0.4573f, -0.2017f, -0.4130f, -0.2389f,
- -0.1437f, -0.0720f, -0.0801f, -0.2493f,
- -0.0224f, 0.1254f, -0.0705f, -0.1295f,
- -0.4750f, -0.4797f, -0.0855f, -0.0717f,
- -0.0751f, -0.2582f, 0.0497f, -0.1541f,
- 0.0231f, -0.4184f, -0.1340f, -0.0153f,
- 0.1505f, -0.0029f, -0.1247f, -0.1905f,
- 0.1667f, -0.3843f, 0.0636f, -0.1079f,
- 0.1239f, -0.1901f, 0.1275f, -0.0215f,
- 0.3226f, -0.1551f, -0.1057f, -0.1512f,
- 0.0901f, -0.1502f, -0.0820f, -0.4019f,
- 0.2507f, -0.1398f, 0.0648f, -0.0626f,
- 0.1902f, 0.0312f, -0.0379f, 0.0871f,
- -0.1130f, -0.0441f, -0.1557f, 0.0990f,
- 0.3247f, 0.2615f, 0.1327f, 0.1916f,
- 0.1061f, -0.1145f, 0.0293f, -0.1419f,
- 0.3159f, -0.1299f, 0.0148f, 0.0922f,
- 0.0156f, -0.3151f, -0.0822f, 0.1729f,
- 0.1848f, 0.0104f, 0.1008f, 0.1483f,
- 0.1787f, 0.2451f, 0.1461f, -0.3391f,
- -0.4440f, -0.4068f, 0.1336f, 0.0454f,
- -0.4677f, -0.1959f, 0.1186f, 0.1927f,
- 0.2215f, 0.1068f, 0.1111f, 0.0264f,
- 0.1240f, -0.0250f, 0.1399f, -0.0267f,
- 0.2534f, -0.3155f, -0.1689f, 0.1250f,
- 0.3487f, 0.0389f, 0.0050f, 0.0662f,
- 0.0273f, -0.2017f, -0.1483f, -0.1375f,
- -0.1520f, -0.3243f, -0.3398f, -0.2442f,
- -0.0039f, 0.2672f, 0.0828f, -0.1671f,
- 0.1096f, 0.1931f, -0.1074f, -0.3950f,
- -0.4310f, -0.2304f, -0.1606f, -0.1649f,
- 0.0262f, -0.2040f, -0.2784f, 0.0590f,
- 0.0081f, 0.0298f, 0.1270f, 0.0592f,
- 0.0475f, 0.0499f, 0.0766f, -0.2637f,
- 0.3194f, 0.1340f, -0.1736f, -0.2076f,
- 0.3712f, 0.1159f, 0.0816f, -0.1261f,
- 0.2666f, -0.0103f, 0.0849f, -0.3768f,
- 0.2682f, -0.0535f, 0.1662f, 0.0341f,
- 0.2089f, -0.2186f, 0.1498f, -0.2405f,
- -0.3982f, -0.3785f, 0.1317f, -0.3119f,
- 0.1642f, 0.2211f, -0.2583f, 0.1052f,
- 0.1357f, 0.1610f, -0.0094f, 0.1101f,
- -0.2731f, -0.0130f, 0.1309f, 0.1191f,
- 0.1376f, -0.1186f, -0.0500f, 0.1589f,
- -0.1657f, -0.2271f, 0.1148f, 0.1038f,
- 0.2881f, -0.0634f, -0.2417f, 0.0781f,
- 0.2425f, 0.0780f, -0.0886f, 0.2261f,
- 0.1911f, -0.0621f, -0.3533f, -0.1305f,
- -0.4753f, 0.2355f, 0.0210f, 0.1508f,
- -0.4033f, 0.1776f, -0.1987f, 0.1256f,
- -0.1350f, 0.0966f, 0.1276f, 0.0305f,
- -0.4175f, 0.1414f, 0.2031f, -0.1324f,
- 0.0085f, 0.1132f, 0.0351f, 0.0005f,
- -0.4254f, -0.0507f, -0.1569f, -0.3704f,
- -0.4804f, -0.1808f, 0.0665f, -0.1480f,
- 0.1621f, 0.1638f, 0.0143f, -0.1516f,
- 0.0561f, 0.0670f, 0.0299f, 0.1654f,
- 0.0160f, 0.2794f, 0.0060f, 0.1692f,
- -0.3377f, 0.2591f, 0.1540f, 0.2183f,
- 0.1311f, 0.1317f, 0.0259f, -0.0077f,
- 0.2639f, 0.1890f, -0.0654f, 0.0164f,
- 0.0867f, 0.1267f, 0.1488f, -0.0822f,
- 0.1899f, -0.1796f, 0.1008f, 0.1346f,
- 0.0535f, -0.1037f, 0.0958f, 0.1103f,
- -0.1326f, -0.4661f, -0.0463f, -0.2278f,
- -0.2291f, -0.0436f, 0.1196f, -0.2462f,
- -0.1829f, -0.2971f, -0.1075f, -0.0384f,
- 0.1663f, -0.0868f, -0.1033f, -0.0047f,
- 0.0731f, 0.2571f, -0.2231f, -0.1236f,
- -0.0632f, 0.0881f, -0.3559f, -0.0095f,
- -0.0645f, 0.2361f, 0.1268f, 0.0144f,
- -0.1754f, -0.4094f, -0.2893f, 0.0454f,
- 0.1811f, -0.0769f, 0.0451f, 0.0513f,
- -0.4348f, -0.0747f, -0.3173f, 0.0408f,
- -0.4670f, -0.4717f, -0.3156f, -0.2369f,
- -0.2484f, -0.1271f, -0.0235f, -0.0333f,
- -0.4466f, 0.1222f, -0.3039f, -0.1527f,
- -0.2543f, -0.1933f, -0.1126f, 0.1443f,
- 0.1729f, -0.3386f, -0.2632f, -0.2335f,
- 0.0828f, 0.1555f, 0.1244f, 0.0997f,
- -0.0321f, 0.0260f, -0.2937f, -0.2730f,
- 0.1999f, 0.0046f, 0.1166f, -0.1652f,
- 0.1631f, 0.2872f, 0.1031f, -0.0089f,
- 0.2623f, -0.3076f, 0.1038f, 0.0652f,
- -0.0688f, 0.1318f, 0.0077f, 0.1051f,
- -0.2922f, 0.1846f, 0.0826f, 0.0577f,
- -0.1389f, 0.2515f, 0.1029f, -0.3880f,
-};
-
const Word16 YG_dicHR_1_fx[] =
{
//Q12
@@ -19186,73 +17615,6 @@ const Word16 YG_dicHR_1_fx[] =
-1196, 756, 338, 236,
-568, 1030, 421, -1589,
};
-const float YG_dicHR_2[] =
-{
- 0.0357f, -0.0180f, -0.0164f, -0.0247f,
- -0.0028f, 0.0807f, -0.0430f, -0.1487f,
- -0.0693f, -0.0078f, -0.0931f, -0.0468f,
- -0.0510f, -0.0198f, 0.0348f, 0.0573f,
- 0.0345f, -0.0919f, -0.0162f, -0.1579f,
- 0.1387f, -0.0093f, -0.1048f, 0.0391f,
- 0.0406f, 0.2031f, 0.0219f, -0.0253f,
- 0.0684f, -0.2153f, -0.0724f, -0.0201f,
- -0.0288f, -0.0010f, 0.0831f, -0.2336f,
- 0.0699f, -0.0333f, -0.1658f, -0.1001f,
- 0.0345f, 0.0443f, -0.0483f, 0.1249f,
- -0.1674f, 0.1583f, 0.0602f, -0.0893f,
- 0.1526f, -0.1636f, 0.1444f, 0.0464f,
- -0.0019f, -0.0723f, -0.1110f, 0.0575f,
- 0.2052f, 0.0309f, 0.1594f, 0.2598f,
- -0.1046f, -0.1393f, -0.0044f, -0.0189f,
- -0.0728f, -0.2377f, 0.1556f, 0.0930f,
- -0.1890f, -0.0078f, -0.0813f, -0.2203f,
- -0.3685f, 0.0409f, 0.1152f, -0.0903f,
- 0.1053f, -0.3510f, 0.0303f, 0.1491f,
- -0.2241f, 0.1248f, 0.1267f, -0.3634f,
- -0.0239f, 0.0640f, -0.2129f, 0.0604f,
- 0.1341f, -0.0406f, 0.1471f, -0.1442f,
- 0.1574f, -0.2515f, 0.1945f, -0.3124f,
- 0.1283f, -0.0092f, 0.0518f, 0.0483f,
- 0.0345f, 0.0844f, 0.0477f, 0.0517f,
- 0.0223f, -0.0175f, 0.1646f, 0.0546f,
- -0.3280f, -0.2203f, -0.0068f, 0.0572f,
- -0.1142f, -0.2396f, -0.1043f, 0.1771f,
- 0.0430f, -0.1288f, 0.0208f, 0.0672f,
- -0.1597f, -0.2099f, 0.1155f, -0.2132f,
- 0.1640f, -0.1117f, -0.0797f, 0.1813f,
- 0.1707f, 0.1498f, -0.0192f, 0.1117f,
- -0.1191f, 0.1235f, 0.0566f, 0.1413f,
- -0.0476f, 0.2265f, -0.1205f, 0.1293f,
- 0.1551f, 0.1354f, -0.2239f, 0.1299f,
- -0.1354f, -0.0030f, -0.0768f, 0.1492f,
- 0.0422f, 0.1630f, 0.1301f, -0.2134f,
- 0.1451f, 0.0660f, -0.0068f, -0.0923f,
- 0.0948f, -0.1294f, -0.3191f, 0.0669f,
- 0.1581f, 0.1102f, 0.1638f, 0.0059f,
- 0.1820f, -0.1148f, 0.0020f, -0.0635f,
- -0.1771f, -0.0715f, -0.2487f, -0.0080f,
- 0.0234f, 0.0451f, 0.0808f, -0.0684f,
- -0.1860f, -0.0331f, 0.1349f, 0.0612f,
- -0.1014f, -0.0008f, 0.0482f, -0.0750f,
- 0.0347f, 0.1714f, 0.1427f, 0.1845f,
- 0.1100f, 0.1455f, -0.2468f, -0.1282f,
- -0.1112f, -0.2792f, -0.1894f, -0.1562f,
- 0.0557f, 0.1211f, -0.4094f, 0.0976f,
- 0.0201f, 0.0593f, -0.1301f, 0.2984f,
- 0.0306f, -0.0523f, 0.0779f, 0.1963f,
- -0.0715f, 0.0928f, -0.0309f, 0.0172f,
- 0.0235f, -0.1172f, 0.0995f, -0.0633f,
- -0.1553f, -0.0363f, 0.2174f, 0.3030f,
- 0.0521f, 0.0987f, -0.0934f, -0.0018f,
- -0.0770f, 0.1243f, 0.1613f, 0.0150f,
- 0.1233f, 0.0046f, 0.0082f, -0.3383f,
- -0.1388f, 0.1750f, -0.1521f, -0.0827f,
- -0.1075f, 0.0095f, 0.2374f, -0.1111f,
- -0.3469f, 0.1407f, -0.2749f, 0.1633f,
- -0.3396f, 0.1176f, 0.0561f, 0.1449f,
- 0.0819f, -0.3576f, 0.1050f, -0.0916f,
- -0.2243f, 0.0304f, -0.0379f, 0.0084f,
-};
const Word16 YG_dicHR_2_fx[] =
{
@@ -19323,74 +17685,6 @@ const Word16 YG_dicHR_2_fx[] =
-918, 124, -155, 34,
};
-const float YG_dicHR_3[] =
-{
- -0.0426f, -0.0202f, -0.0387f, -0.0030f,
- 0.0380f, -0.0984f, 0.0280f, -0.0324f,
- 0.0460f, 0.0006f, -0.0566f, -0.1148f,
- 0.1094f, -0.0542f, -0.1462f, -0.0253f,
- -0.0863f, 0.0744f, -0.2866f, 0.1026f,
- -0.0105f, -0.0188f, -0.1303f, 0.0944f,
- 0.1286f, -0.0140f, 0.0879f, -0.0605f,
- -0.2045f, -0.0537f, -0.0840f, 0.0103f,
- -0.0578f, 0.0215f, -0.1623f, -0.0552f,
- -0.2976f, 0.0162f, 0.0885f, -0.1293f,
- -0.0974f, 0.1213f, -0.0734f, 0.0731f,
- 0.0520f, 0.1242f, -0.1272f, 0.0196f,
- -0.0653f, -0.1276f, 0.0112f, 0.0700f,
- -0.0159f, -0.2792f, 0.0376f, -0.0414f,
- 0.1771f, -0.3623f, 0.2157f, -0.3563f,
- 0.0022f, -0.0268f, 0.0817f, -0.1837f,
- -0.0095f, 0.2102f, -0.0056f, -0.0815f,
- -0.1191f, 0.0831f, 0.0495f, -0.3733f,
- -0.0854f, 0.0945f, 0.1575f, -0.1134f,
- -0.0259f, 0.0180f, 0.0416f, 0.1044f,
- 0.0441f, 0.0938f, -0.0713f, 0.2415f,
- 0.0436f, -0.1234f, 0.1509f, 0.0916f,
- 0.1176f, 0.1316f, -0.4339f, 0.2564f,
- 0.1662f, -0.1935f, 0.0160f, 0.0334f,
- -0.3389f, 0.1950f, -0.2663f, 0.1638f,
- -0.0921f, -0.1238f, -0.0341f, -0.1417f,
- 0.0737f, 0.1500f, 0.0476f, 0.0958f,
- -0.0533f, -0.2820f, 0.0834f, 0.2038f,
- 0.0826f, -0.2616f, -0.2874f, 0.1644f,
- -0.0993f, 0.0460f, -0.0225f, -0.1335f,
- -0.0142f, -0.1604f, 0.1888f, -0.1319f,
- 0.1126f, 0.1585f, 0.2053f, -0.0266f,
- -0.1893f, -0.0861f, 0.1514f, 0.0570f,
- -0.0954f, 0.1628f, 0.1468f, 0.1070f,
- -0.0964f, 0.3893f, -0.0730f, 0.2465f,
- 0.0898f, 0.1094f, 0.0711f, -0.2164f,
- 0.1926f, 0.0187f, 0.1170f, 0.1297f,
- -0.0188f, -0.1601f, -0.1222f, -0.0035f,
- 0.1257f, -0.4262f, 0.1214f, 0.0531f,
- 0.2209f, -0.2352f, 0.1540f, 0.3080f,
- 0.1894f, 0.0548f, -0.1943f, 0.1270f,
- 0.0712f, -0.1064f, -0.0275f, 0.1659f,
- 0.1207f, 0.3370f, -0.2487f, -0.0456f,
- -0.0185f, 0.0212f, 0.1785f, 0.2561f,
- 0.0161f, 0.0183f, 0.1507f, 0.0244f,
- 0.1251f, -0.0114f, 0.1731f, -0.3995f,
- -0.2262f, 0.3021f, 0.2663f, -0.1984f,
- 0.0100f, 0.0727f, 0.0237f, -0.0320f,
- 0.1602f, 0.1882f, 0.2873f, 0.2248f,
- 0.3206f, -0.1423f, -0.4473f, -0.2229f,
- 0.1197f, -0.1583f, -0.0106f, -0.1966f,
- -0.1098f, -0.2154f, -0.3597f, -0.1705f,
- 0.2511f, 0.1028f, -0.0370f, -0.0707f,
- 0.2659f, 0.2704f, -0.0354f, 0.1857f,
- 0.0461f, 0.0873f, -0.1559f, -0.2509f,
- -0.0824f, -0.0513f, 0.0733f, -0.0475f,
- 0.0781f, 0.0546f, -0.3875f, -0.0158f,
- 0.2374f, 0.3380f, 0.1919f, -0.2505f,
- 0.2268f, -0.1145f, 0.2727f, -0.0484f,
- -0.3637f, 0.1569f, 0.0659f, 0.0942f,
- -0.1531f, 0.0612f, 0.0375f, 0.0123f,
- -0.2213f, 0.1497f, -0.1265f, -0.1066f,
- 0.0926f, 0.0044f, -0.0167f, 0.0533f,
- -0.1584f, -0.0208f, -0.0269f, 0.1868f,
-};
-
const Word16 YG_dicHR_3_fx[] =
{
//Q12
@@ -19460,85 +17754,12 @@ const Word16 YG_dicHR_3_fx[] =
-648, -85, -110, 765,
};
-const float YG_mean16HR_16kHz[] =
-{
- 0.0837f, 0.0372f, 0.0912f, 0.0878f,
-};
-
const Word16 YG_mean16HR_16kHz_fx[] =
{
//Q12
342, 152, 373, 359
};
-const float YG_dicHR_4_16kHz[] =
-{
- 0.0336f, 0.0267f, 0.0526f, 0.0053f,
- 0.0802f, -0.0065f, 0.1313f, -0.0660f,
- -0.0335f, -0.2078f, -0.0942f, -0.1717f,
- -0.1312f, -0.0199f, -0.0596f, -0.0058f,
- -0.0426f, -0.1039f, -0.0428f, -0.0858f,
- 0.2103f, 0.2687f, 0.1701f, 0.1402f,
- -0.0368f, -0.0036f, -0.0953f, -0.0589f,
- -0.2022f, 0.0406f, 0.0402f, -0.0370f,
- -0.0552f, 0.1323f, 0.0499f, -0.0270f,
- 0.0450f, 0.2002f, -0.0219f, 0.0645f,
- -0.0065f, 0.2172f, 0.1731f, 0.1270f,
- 0.0205f, -0.0432f, -0.1742f, -0.0674f,
- -0.0365f, -0.3219f, 0.1785f, -0.0473f,
- -0.0792f, -0.0136f, 0.0290f, 0.0446f,
- 0.1158f, -0.1206f, -0.1005f, 0.0128f,
- 0.0381f, -0.3563f, -0.0904f, -0.0175f,
- 0.1253f, 0.1103f, 0.2376f, 0.0693f,
- 0.2207f, -0.0725f, 0.0756f, 0.0296f,
- 0.3080f, 0.0724f, 0.2164f, 0.1716f,
- 0.2403f, -0.2941f, 0.2234f, 0.0037f,
- -0.0980f, 0.1115f, -0.0772f, 0.0333f,
- 0.1119f, -0.4345f, 0.0818f, -0.1924f,
- 0.1152f, -0.1945f, 0.0584f, -0.0809f,
- -0.0954f, -0.5530f, 0.1204f, -0.0747f,
- 0.1146f, -0.4752f, 0.0950f, 0.0684f,
- 0.0368f, 0.1132f, -0.1772f, 0.0279f,
- -0.1005f, 0.0244f, -0.2212f, -0.0313f,
- 0.1534f, 0.2169f, 0.3173f, 0.2538f,
- 0.3552f, 0.3364f, 0.3457f, 0.3297f,
- -0.0003f, 0.0593f, -0.0401f, -0.0028f,
- 0.1544f, 0.1517f, 0.1017f, 0.1697f,
- 0.0969f, -0.2516f, 0.0871f, 0.1202f,
- 0.0119f, -0.0682f, -0.0240f, -0.0075f,
- -0.1389f, -0.0520f, -0.0920f, -0.1396f,
- 0.0672f, 0.1392f, 0.0935f, 0.0373f,
- 0.1082f, 0.0185f, 0.1273f, 0.1021f,
- -0.3336f, -0.3825f, -0.6008f, -0.7142f,
- -0.2587f, 0.0157f, -0.1429f, -0.0564f,
- 0.0328f, 0.1196f, -0.0725f, -0.0929f,
- -0.3548f, -0.2175f, -0.2930f, -0.2825f,
- -0.0066f, 0.0587f, -0.4138f, 0.0117f,
- 0.1133f, 0.0211f, -0.0499f, -0.0194f,
- 0.1823f, 0.1128f, 0.0573f, 0.0140f,
- 0.2655f, -0.1803f, 0.2675f, 0.2565f,
- 0.2253f, 0.1513f, -0.1007f, 0.1000f,
- -0.0639f, 0.0086f, 0.0303f, -0.0766f,
- -0.1939f, 0.2057f, -0.2423f, 0.0769f,
- 0.0686f, -0.1137f, 0.2511f, 0.0480f,
- 0.0571f, -0.0847f, 0.0629f, 0.0448f,
- -0.4005f, 0.0596f, -0.0270f, 0.0070f,
- 0.0922f, 0.0418f, -0.0140f, 0.0958f,
- -0.0218f, 0.0900f, 0.0477f, 0.1115f,
- 0.1225f, 0.3240f, 0.0291f, 0.2393f,
- -0.0158f, -0.0206f, -0.1019f, 0.0642f,
- -0.1011f, -0.1364f, -0.1560f, -0.0251f,
- -0.4360f, 0.0958f, -0.4289f, -0.1051f,
- -0.1723f, -0.0732f, -0.2905f, -0.1783f,
- -0.1166f, 0.0848f, -0.0978f, -0.0897f,
- -0.0229f, -0.2016f, -0.0050f, -0.0033f,
- -0.1734f, -0.1320f, 0.0110f, -0.0649f,
- -0.0370f, -0.1189f, 0.0929f, -0.0594f,
- -0.0657f, 0.0080f, 0.1716f, 0.0350f,
- 0.0503f, -0.0355f, -0.0068f, -0.1159f,
- -0.1695f, 0.1897f, 0.0702f, 0.0873f,
-};
-
const Word16 YG_dicHR_4_16kHz_fx[] =
{
//Q12
@@ -19608,29 +17829,12 @@ const Word16 YG_dicHR_4_16kHz_fx[] =
-694, 777, 287, 357,
};
-const float YG_meanL2G_16kHz[] =
-{
- 0.1036f, 0.1590f,
-};
-
const Word16 YG_meanL2G_16kHz_fx[] =
{
//Q12
424, 651,
};
-const float YG_dicL2G_16kHz[] =
-{
- -0.0624f, 0.0298f,
- 0.0723f, 0.0768f,
- -0.0553f, -0.0814f,
- 0.1633f, 0.1633f,
- 0.0249f, -0.0130f,
- -0.1415f, -0.1581f,
- -0.2937f, -0.3039f,
- 0.2962f, 0.3062f,
-};
-
const Word16 YG_dicL2G_16kHz_fx[] =//Q12
{
-255, 122,
@@ -19649,23 +17853,10 @@ const Word16 Odx_fft64[64] =
32,27,22,17,12,7,2,61,56,51,46,41,36,31,26,21,16,11,6,1,60,55,50,45,40,35,30,25,20,15,10,5
}; // Q0
-const float w_fft64[32] =
-{
- 1.0000000f,0.00000000f,0.70710677f,0.70710677f,0.92387950f,0.38268346f,0.38268346f,0.92387950f,
- 0.98078525f,0.19509032f,0.55557024f,0.83146960f,0.83146960f,0.55557024f,0.19509032f,0.98078525f,
- 0.99518472f,0.098017141f,0.63439327f,0.77301043f,0.88192123f,0.47139674f,0.29028469f,0.95694035f,
- 0.95694035f,0.29028469f,0.47139674f,0.88192123f,0.77301043f,0.63439327f,0.098017141f,0.99518472f
-};
-
const Word16 Ip_fft64[6] = { 32,1,0,64,32,96 }; // Q0
const Word16 Odx_fft32_15[32] = { 0,17,2,19,4,21,6,23,8,25,10,27,12,29,14,31,16,1,18,3,20,5,22,7,24,9,26,11,28,13,30,15 }; // Q0
-const float w_fft32[16] =
-{
- 1.0000000f,0.00000000f,0.70710677f,0.70710677f,0.92387950f,0.38268346f,0.38268346f,0.92387950f,
- 0.98078525f,0.19509032f,0.55557024f,0.83146960f,0.83146960f,0.55557024f,0.19509032f,0.98078525f
-};
const Word32 w_fft32_16fx[16] =//Q30
{
1073741824, 0, 759250113, 759250113, 992008059, 410903236, 410903236, 992008059,
@@ -19677,12 +17868,8 @@ const Word16 Odx_fft32_5[32] = { 0,27,22,17,12,7,2,29,24,19,14,9,4,31,26,21,16,1
const Word16 Odx_fft16[16] = {0,11,6,1,12,7,2,13,8,3,14,9,4,15,10,5}; // Q0
-const float w_fft16[8] = { 1.0000000f,0.00000000f,0.70710677f,0.70710677f,0.92387950f,0.38268346f,0.38268346f,0.92387950f };
-
const Word16 Ip_fft16[6] = {8,1,0,16,8,24}; // Q0
-const float w_fft8[8] = {1.0000000f,0.00000000f,0.70710677f,0.70710677f };
-
const Word16 Ip_fft8[6] = {4,1,0,8,4,12}; // Q0
const Word16 Idx_dortft80[80] =
@@ -19753,17 +17940,6 @@ const Word16 Idx_dortft480[480] =
const Word16 Ip_fft128[10] = { 64, 1, 0, 128, 64, 192, 32, 160, 96, 224 }; // Q0
-const float w_fft128[64] =
-{
- 1.0000000f, 0.00000000f, 0.70710677f, 0.70710677f, 0.92387950f, 0.38268346f, 0.38268346f, 0.92387950f,
- 0.98078525f, 0.19509032f, 0.55557024f, 0.83146960f, 0.83146960f, 0.55557024f, 0.19509032f, 0.98078525f,
- 0.99518472f, 0.09801714f, 0.63439327f, 0.77301043f, 0.88192123f, 0.47139674f, 0.29028469f, 0.95694035f,
- 0.95694035f, 0.29028469f, 0.47139674f, 0.88192123f, 0.77301043f, 0.63439327f, 0.09801714f, 0.99518472f,
- 0.99879545f, 0.04906767f, 0.67155895f, 0.74095112f, 0.90398929f, 0.42755509f, 0.33688985f, 0.94154406f,
- 0.97003125f, 0.24298017f, 0.51410274f, 0.85772861f, 0.80320753f, 0.59569930f, 0.14673047f, 0.98917650f,
- 0.98917650f, 0.14673047f, 0.59569930f, 0.80320753f, 0.85772861f, 0.51410274f, 0.24298017f, 0.97003125f,
- 0.94154406f, 0.33688985f, 0.42755509f, 0.90398929f, 0.74095112f, 0.67155895f, 0.04906767f, 0.99879545f
-};
const Word32 w_fft128_16fx[64] =
{
1073741824, 0, 759250112, 759250112, 992008064, 410903232, 410903232, 992008064,
@@ -19778,63 +17954,8 @@ const Word32 w_fft128_16fx[64] =
const Word16 Ip_fft256[10] = {128, 1, 0, 256, 128, 384, 64, 320,192, 448}; // Q0
-const float w_fft256[128] =
-{
- 1.00000000f, 0.00000000f, 0.70710678f, 0.70710678f, 0.92387953f, 0.38268343f, 0.38268343f, 0.92387953f,
- 0.98078528f, 0.19509032f, 0.55557023f, 0.83146961f, 0.83146961f, 0.55557023f, 0.19509032f, 0.98078528f,
- 0.99518473f, 0.09801714f, 0.63439328f, 0.77301045f, 0.88192126f, 0.47139674f, 0.29028468f, 0.95694034f,
- 0.95694034f, 0.29028468f, 0.47139674f, 0.88192126f, 0.77301045f, 0.63439328f, 0.09801714f, 0.99518473f,
- 0.99879546f, 0.04906767f, 0.67155895f, 0.74095113f, 0.90398929f, 0.42755509f, 0.33688985f, 0.94154407f,
- 0.97003125f, 0.24298018f, 0.51410274f, 0.85772861f, 0.80320753f, 0.59569930f, 0.14673047f, 0.98917651f,
- 0.98917651f, 0.14673047f, 0.59569930f, 0.80320753f, 0.85772861f, 0.51410274f, 0.24298018f, 0.97003125f,
- 0.94154407f, 0.33688985f, 0.42755509f, 0.90398929f, 0.74095113f, 0.67155895f, 0.04906767f, 0.99879546f,
- 0.99969882f, 0.02454123f, 0.68954054f, 0.72424708f, 0.91420976f, 0.40524131f, 0.35989504f, 0.93299280f,
- 0.97570213f, 0.21910124f, 0.53499762f, 0.84485357f, 0.81758481f, 0.57580819f, 0.17096189f, 0.98527764f,
- 0.99247953f, 0.12241068f, 0.61523159f, 0.78834643f, 0.87008699f, 0.49289819f, 0.26671276f, 0.96377607f,
- 0.94952818f, 0.31368174f, 0.44961133f, 0.89322430f, 0.75720885f, 0.65317284f, 0.07356456f, 0.99729046f,
- 0.99729046f, 0.07356456f, 0.65317284f, 0.75720885f, 0.89322430f, 0.44961133f, 0.31368174f, 0.94952818f,
- 0.96377607f, 0.26671276f, 0.49289819f, 0.87008699f, 0.78834643f, 0.61523159f, 0.12241068f, 0.99247953f,
- 0.98527764f, 0.17096189f, 0.57580819f, 0.81758481f, 0.84485357f, 0.53499762f, 0.21910124f, 0.97570213f,
- 0.93299280f, 0.35989504f, 0.40524131f, 0.91420976f, 0.72424708f, 0.68954054f, 0.02454123f, 0.99969882f
-};
-
const Word16 Ip_fft512[18] = {256, 1, 0, 512, 256, 768, 128, 640,384, 896, 64, 576, 320, 832, 192, 704,448, 960}; // Q0
-const float w_fft512[256] =
-{
- 1.00000000f, 0.00000000f, 0.70710678f, 0.70710678f, 0.92387953f, 0.38268343f, 0.38268343f, 0.92387953f,
- 0.98078528f, 0.19509032f, 0.55557023f, 0.83146961f, 0.83146961f, 0.55557023f, 0.19509032f, 0.98078528f,
- 0.99518473f, 0.09801714f, 0.63439328f, 0.77301045f, 0.88192126f, 0.47139674f, 0.29028468f, 0.95694034f,
- 0.95694034f, 0.29028468f, 0.47139674f, 0.88192126f, 0.77301045f, 0.63439328f, 0.09801714f, 0.99518473f,
- 0.99879546f, 0.04906767f, 0.67155895f, 0.74095113f, 0.90398929f, 0.42755509f, 0.33688985f, 0.94154407f,
- 0.97003125f, 0.24298018f, 0.51410274f, 0.85772861f, 0.80320753f, 0.59569930f, 0.14673047f, 0.98917651f,
- 0.98917651f, 0.14673047f, 0.59569930f, 0.80320753f, 0.85772861f, 0.51410274f, 0.24298018f, 0.97003125f,
- 0.94154407f, 0.33688985f, 0.42755509f, 0.90398929f, 0.74095113f, 0.67155895f, 0.04906767f, 0.99879546f,
- 0.99969882f, 0.02454123f, 0.68954054f, 0.72424708f, 0.91420976f, 0.40524131f, 0.35989504f, 0.93299280f,
- 0.97570213f, 0.21910124f, 0.53499762f, 0.84485357f, 0.81758481f, 0.57580819f, 0.17096189f, 0.98527764f,
- 0.99247953f, 0.12241068f, 0.61523159f, 0.78834643f, 0.87008699f, 0.49289819f, 0.26671276f, 0.96377607f,
- 0.94952818f, 0.31368174f, 0.44961133f, 0.89322430f, 0.75720885f, 0.65317284f, 0.07356456f, 0.99729046f,
- 0.99729046f, 0.07356456f, 0.65317284f, 0.75720885f, 0.89322430f, 0.44961133f, 0.31368174f, 0.94952818f,
- 0.96377607f, 0.26671276f, 0.49289819f, 0.87008699f, 0.78834643f, 0.61523159f, 0.12241068f, 0.99247953f,
- 0.98527764f, 0.17096189f, 0.57580819f, 0.81758481f, 0.84485357f, 0.53499762f, 0.21910124f, 0.97570213f,
- 0.93299280f, 0.35989504f, 0.40524131f, 0.91420976f, 0.72424708f, 0.68954054f, 0.02454123f, 0.99969882f,
- 0.99992470f, 0.01227154f, 0.69837625f, 0.71573083f, 0.91911385f, 0.39399204f, 0.37131719f, 0.92850608f,
- 0.97831737f, 0.20711138f, 0.54532499f, 0.83822471f, 0.82458930f, 0.56573181f, 0.18303989f, 0.98310549f,
- 0.99390697f, 0.11022221f, 0.62485949f, 0.78073723f, 0.87607009f, 0.48218377f, 0.27851969f, 0.96043052f,
- 0.95330604f, 0.30200595f, 0.46053871f, 0.88763962f, 0.76516727f, 0.64383154f, 0.08579731f, 0.99631261f,
- 0.99811811f, 0.06132074f, 0.66241578f, 0.74913639f, 0.89867447f, 0.43861624f, 0.32531029f, 0.94560733f,
- 0.96697647f, 0.25486566f, 0.50353838f, 0.86397286f, 0.79583690f, 0.60551104f, 0.13458071f, 0.99090264f,
- 0.98730142f, 0.15885814f, 0.58579786f, 0.81045720f, 0.85135519f, 0.52458968f, 0.23105811f, 0.97293995f,
- 0.93733901f, 0.34841868f, 0.41642956f, 0.90916798f, 0.73265427f, 0.68060100f, 0.03680722f, 0.99932238f,
- 0.99932238f, 0.03680722f, 0.68060100f, 0.73265427f, 0.90916798f, 0.41642956f, 0.34841868f, 0.93733901f,
- 0.97293995f, 0.23105811f, 0.52458968f, 0.85135519f, 0.81045720f, 0.58579786f, 0.15885814f, 0.98730142f,
- 0.99090264f, 0.13458071f, 0.60551104f, 0.79583690f, 0.86397286f, 0.50353838f, 0.25486566f, 0.96697647f,
- 0.94560733f, 0.32531029f, 0.43861624f, 0.89867447f, 0.74913639f, 0.66241578f, 0.06132074f, 0.99811811f,
- 0.99631261f, 0.08579731f, 0.64383154f, 0.76516727f, 0.88763962f, 0.46053871f, 0.30200595f, 0.95330604f,
- 0.96043052f, 0.27851969f, 0.48218377f, 0.87607009f, 0.78073723f, 0.62485949f, 0.11022221f, 0.99390697f,
- 0.98310549f, 0.18303989f, 0.56573181f, 0.82458930f, 0.83822471f, 0.54532499f, 0.20711138f, 0.97831737f,
- 0.92850608f, 0.37131719f, 0.39399204f, 0.91911385f, 0.71573083f, 0.69837625f, 0.01227154f, 0.99992470f
-};
const Word16 w_fft512_fx_evs[256] =//Q14
{
16384, 0, 11585, 11585, 15137, 6270, 6270, 15137,
@@ -19879,23 +18000,9 @@ const Word16 Idx_dortft40[40] =
const Word16 Odx_fft8_5[8] = {0, 3, 6, 1, 4, 7, 2, 5}; // Q0
const Word16 Idx_dortft20[20] = {0, 5, 10, 15, 16, 1, 6, 11, 12, 17, 2, 7, 8, 13, 18, 3, 4, 9, 14, 19}; // Q0
const Word16 Odx_fft4_5[4] = {0, 3, 2, 1}; // Q0
-const float w_fft4[2] = {1.0000000f, 0.00000000f};
const Word16 Ip_fft4[6] = {2,1,0,4,2,6}; // Q0
const Word16 ip_edct2_64[6] = {16, 64, 0, 32, 16, 48}; // Q0
-const float w_edct2_64[80] =
-{
- 1.00000000f, 0.00000000f, 0.70710678f, 0.70710678f, 0.92387953f, 0.38268343f, 0.38268343f, 0.92387953f,
- 0.98078528f, 0.19509032f, 0.55557023f, 0.83146961f, 0.83146961f, 0.55557023f, 0.19509032f, 0.98078528f,
- 0.70710678f, 0.49984940f, 0.49939772f, 0.49864522f, 0.49759236f, 0.49623976f, 0.49458825f, 0.49263882f,
- 0.49039264f, 0.48785106f, 0.48501562f, 0.48188803f, 0.47847016f, 0.47476409f, 0.47077203f, 0.46649639f,
- 0.46193976f, 0.45710487f, 0.45199464f, 0.44661215f, 0.44096063f, 0.43504349f, 0.42886430f, 0.42242678f,
- 0.41573480f, 0.40879240f, 0.40160376f, 0.39417321f, 0.38650522f, 0.37860442f, 0.37047556f, 0.36212354f,
- 0.35355339f, 0.34477027f, 0.33577947f, 0.32658642f, 0.31719664f, 0.30761579f, 0.29784965f, 0.28790409f,
- 0.27778511f, 0.26749880f, 0.25705137f, 0.24644909f, 0.23569836f, 0.22480566f, 0.21377754f, 0.20262065f,
- 0.19134171f, 0.17994751f, 0.16844492f, 0.15684087f, 0.14514233f, 0.13335637f, 0.12149008f, 0.10955062f,
- 0.09754516f, 0.08548094f, 0.07336523f, 0.06120533f, 0.04900857f, 0.03678228f, 0.02453383f, 0.01227061f
-};
const Word16 w_edct2_64_fx[80] = /*Q14 */
{
16384, 0, 11585, 11585, 15137, 6270, 6270, 15137,
@@ -19910,712 +18017,6 @@ const Word16 w_edct2_64_fx[80] = /*Q14 */
1598, 1401, 1202, 1003, 803, 603, 402, 201
};
-const float FFT_RotVector_32[40] = {
- 0.9807852507f, -0.1950903237f, 0.9238796234f, -0.3826834261f, 0.8314696550f, -0.5555702448f, 0.7071067691f, -0.7071067691f,
- 0.5555703044f, -0.8314695954f, 0.3826835155f, -0.9238795042f, 0.1950902939f, -0.9807852507f, 0.9238796234f, -0.3826834261f,
- 0.7071067691f, -0.7071067691f, 0.3826835155f, -0.9238795042f, -0.3826833963f, -0.9238795042f, -0.7071067691f, -0.7071067691f,
- -0.9238795042f, -0.3826834261f, 0.8314696550f, -0.5555702448f, 0.3826835155f, -0.9238795042f, -0.1950902939f, -0.9807852507f,
- -0.7071067691f, -0.7071067691f, -0.9807852507f, -0.1950903237f, -0.9238796234f, 0.3826834261f, -0.5555703044f, 0.8314695954f
-};
-
-const float FFT_RotVector_256[448] = {
- 1.0000000000f, -0.0000000000f, 0.9996988177f, -0.0245412290f, 0.9987954497f, -0.0490676761f, 0.9972904325f, -0.0735645667f,
- 0.9951847196f, -0.0980171412f, 0.9924795628f, -0.1224106774f, 0.9891765118f, -0.1467304677f, 0.9852776527f, -0.1709618866f,
- 0.9807852507f, -0.1950903237f, 0.9757021070f, -0.2191012353f, 0.9700312614f, -0.2429801822f, 0.9637760520f, -0.2667127550f,
- 0.9569403529f, -0.2902846634f, 0.9495281577f, -0.3136817515f, 0.9415440559f, -0.3368898630f, 0.9329928160f, -0.3598950505f,
- 0.9238795042f, -0.3826834261f, 0.9142097831f, -0.4052413106f, 0.9039893150f, -0.4275550842f, 0.8932242990f, -0.4496113360f,
- 0.8819212914f, -0.4713967443f, 0.8700869679f, -0.4928981960f, 0.8577286005f, -0.5141027570f, 0.8448535800f, -0.5349976420f,
- 0.8314695954f, -0.5555702448f, 0.8175848126f, -0.5758081675f, 0.8032075167f, -0.5956993103f, 0.7883464098f, -0.6152315736f,
- 0.7730104327f, -0.6343932748f, 0.7572088242f, -0.6531728506f, 0.7409511209f, -0.6715589762f, 0.7242470980f, -0.6895405650f,
- 1.0000000000f, -0.0000000000f, 0.9987954497f, -0.0490676761f, 0.9951847196f, -0.0980171412f, 0.9891765118f, -0.1467304677f,
- 0.9807852507f, -0.1950903237f, 0.9700312614f, -0.2429801822f, 0.9569403529f, -0.2902846634f, 0.9415440559f, -0.3368898630f,
- 0.9238795042f, -0.3826834261f, 0.9039893150f, -0.4275550842f, 0.8819212914f, -0.4713967443f, 0.8577286005f, -0.5141027570f,
- 0.8314695954f, -0.5555702448f, 0.8032075167f, -0.5956993103f, 0.7730104327f, -0.6343932748f, 0.7409511209f, -0.6715589762f,
- 0.7071067691f, -0.7071067691f, 0.6715589762f, -0.7409511209f, 0.6343932748f, -0.7730104327f, 0.5956993103f, -0.8032075167f,
- 0.5555702448f, -0.8314695954f, 0.5141027570f, -0.8577286005f, 0.4713967443f, -0.8819212914f, 0.4275550842f, -0.9039893150f,
- 0.3826834261f, -0.9238795042f, 0.3368898630f, -0.9415440559f, 0.2902846634f, -0.9569403529f, 0.2429801822f, -0.9700312614f,
- 0.1950903237f, -0.9807852507f, 0.1467304677f, -0.9891765118f, 0.0980171412f, -0.9951847196f, 0.0490676761f, -0.9987954497f,
- 1.0000000000f, -0.0000000000f, 0.9972904325f, -0.0735645667f, 0.9891765118f, -0.1467304677f, 0.9757021070f, -0.2191012353f,
- 0.9569403529f, -0.2902846634f, 0.9329928160f, -0.3598950505f, 0.9039893150f, -0.4275550842f, 0.8700869679f, -0.4928981960f,
- 0.8314695954f, -0.5555702448f, 0.7883464098f, -0.6152315736f, 0.7409511209f, -0.6715589762f, 0.6895405650f, -0.7242470980f,
- 0.6343932748f, -0.7730104327f, 0.5758081675f, -0.8175848126f, 0.5141027570f, -0.8577286005f, 0.4496113360f, -0.8932242990f,
- 0.3826834261f, -0.9238795042f, 0.3136817515f, -0.9495281577f, 0.2429801822f, -0.9700312614f, 0.1709618866f, -0.9852776527f,
- 0.0980171412f, -0.9951847196f, 0.0245412290f, -0.9996988177f, -0.0490676761f, -0.9987954497f, -0.1224106774f, -0.9924795628f,
- -0.1950903237f, -0.9807852507f, -0.2667127550f, -0.9637760520f, -0.3368898630f, -0.9415440559f, -0.4052413106f, -0.9142097831f,
- -0.4713967443f, -0.8819212914f, -0.5349976420f, -0.8448535800f, -0.5956993103f, -0.8032075167f, -0.6531728506f, -0.7572088242f,
- 1.0000000000f, -0.0000000000f, 0.9951847196f, -0.0980171412f, 0.9807852507f, -0.1950903237f, 0.9569403529f, -0.2902846634f,
- 0.9238795042f, -0.3826834261f, 0.8819212914f, -0.4713967443f, 0.8314695954f, -0.5555702448f, 0.7730104327f, -0.6343932748f,
- 0.7071067691f, -0.7071067691f, 0.6343932748f, -0.7730104327f, 0.5555702448f, -0.8314695954f, 0.4713967443f, -0.8819212914f,
- 0.3826834261f, -0.9238795042f, 0.2902846634f, -0.9569403529f, 0.1950903237f, -0.9807852507f, 0.0980171412f, -0.9951847196f,
- -0.0000000000f, -1.0000000000f, -0.0980171412f, -0.9951847196f, -0.1950903237f, -0.9807852507f, -0.2902846634f, -0.9569403529f,
- -0.3826834261f, -0.9238795042f, -0.4713967443f, -0.8819212914f, -0.5555702448f, -0.8314695954f, -0.6343932748f, -0.7730104327f,
- -0.7071067691f, -0.7071067691f, -0.7730104327f, -0.6343932748f, -0.8314695954f, -0.5555702448f, -0.8819212914f, -0.4713967443f,
- -0.9238795042f, -0.3826834261f, -0.9569403529f, -0.2902846634f, -0.9807852507f, -0.1950903237f, -0.9951847196f, -0.0980171412f,
- 1.0000000000f, -0.0000000000f, 0.9924795628f, -0.1224106774f, 0.9700312614f, -0.2429801822f, 0.9329928160f, -0.3598950505f,
- 0.8819212914f, -0.4713967443f, 0.8175848126f, -0.5758081675f, 0.7409511209f, -0.6715589762f, 0.6531728506f, -0.7572088242f,
- 0.5555702448f, -0.8314695954f, 0.4496113360f, -0.8932242990f, 0.3368898630f, -0.9415440559f, 0.2191012353f, -0.9757021070f,
- 0.0980171412f, -0.9951847196f, -0.0245412290f, -0.9996988177f, -0.1467304677f, -0.9891765118f, -0.2667127550f, -0.9637760520f,
- -0.3826834261f, -0.9238795042f, -0.4928981960f, -0.8700869679f, -0.5956993103f, -0.8032075167f, -0.6895405650f, -0.7242470980f,
- -0.7730104327f, -0.6343932748f, -0.8448535800f, -0.5349976420f, -0.9039893150f, -0.4275550842f, -0.9495281577f, -0.3136817515f,
- -0.9807852507f, -0.1950903237f, -0.9972904325f, -0.0735645667f, -0.9987954497f, 0.0490676761f, -0.9852776527f, 0.1709618866f,
- -0.9569403529f, 0.2902846634f, -0.9142097831f, 0.4052413106f, -0.8577286005f, 0.5141027570f, -0.7883464098f, 0.6152315736f,
- 1.0000000000f, -0.0000000000f, 0.9891765118f, -0.1467304677f, 0.9569403529f, -0.2902846634f, 0.9039893150f, -0.4275550842f,
- 0.8314695954f, -0.5555702448f, 0.7409511209f, -0.6715589762f, 0.6343932748f, -0.7730104327f, 0.5141027570f, -0.8577286005f,
- 0.3826834261f, -0.9238795042f, 0.2429801822f, -0.9700312614f, 0.0980171412f, -0.9951847196f, -0.0490676761f, -0.9987954497f,
- -0.1950903237f, -0.9807852507f, -0.3368898630f, -0.9415440559f, -0.4713967443f, -0.8819212914f, -0.5956993103f, -0.8032075167f,
- -0.7071067691f, -0.7071067691f, -0.8032075167f, -0.5956993103f, -0.8819212914f, -0.4713967443f, -0.9415440559f, -0.3368898630f,
- -0.9807852507f, -0.1950903237f, -0.9987954497f, -0.0490676761f, -0.9951847196f, 0.0980171412f, -0.9700312614f, 0.2429801822f,
- -0.9238795042f, 0.3826834261f, -0.8577286005f, 0.5141027570f, -0.7730104327f, 0.6343932748f, -0.6715589762f, 0.7409511209f,
- -0.5555702448f, 0.8314695954f, -0.4275550842f, 0.9039893150f, -0.2902846634f, 0.9569403529f, -0.1467304677f, 0.9891765118f,
- 1.0000000000f, -0.0000000000f, 0.9852776527f, -0.1709618866f, 0.9415440559f, -0.3368898630f, 0.8700869679f, -0.4928981960f,
- 0.7730104327f, -0.6343932748f, 0.6531728506f, -0.7572088242f, 0.5141027570f, -0.8577286005f, 0.3598950505f, -0.9329928160f,
- 0.1950903237f, -0.9807852507f, 0.0245412290f, -0.9996988177f, -0.1467304677f, -0.9891765118f, -0.3136817515f, -0.9495281577f,
- -0.4713967443f, -0.8819212914f, -0.6152315736f, -0.7883464098f, -0.7409511209f, -0.6715589762f, -0.8448535800f, -0.5349976420f,
- -0.9238795042f, -0.3826834261f, -0.9757021070f, -0.2191012353f, -0.9987954497f, -0.0490676761f, -0.9924795628f, 0.1224106774f,
- -0.9569403529f, 0.2902846634f, -0.8932242990f, 0.4496113360f, -0.8032075167f, 0.5956993103f, -0.6895405650f, 0.7242470980f,
- -0.5555702448f, 0.8314695954f, -0.4052413106f, 0.9142097831f, -0.2429801822f, 0.9700312614f, -0.0735645667f, 0.9972904325f,
- 0.0980171412f, 0.9951847196f, 0.2667127550f, 0.9637760520f, 0.4275550842f, 0.9039893150f, 0.5758081675f, 0.8175848126f
-};
-
-const float FFT_RotVector_400[760] = {
- 1.0000000000f, -0.0000000000f, 0.9995065331f, -0.0314107575f, 0.9980267286f, -0.0627905205f, 0.9955619574f, -0.0941083133f,
- 0.9921147227f, -0.1253332347f, 0.9876883626f, -0.1564344615f, 0.9822872281f, -0.1873813123f, 0.9759167433f, -0.2181432396f,
- 0.9685831666f, -0.2486898899f, 0.9602937102f, -0.2789911032f, 0.9510565400f, -0.3090170026f, 0.9408807755f, -0.3387379348f,
- 0.9297764897f, -0.3681245446f, 0.9177546501f, -0.3971478939f, 0.9048270583f, -0.4257792830f, 0.8910065293f, -0.4539904892f,
- 0.8763066530f, -0.4817536771f, 0.8607420325f, -0.5090414286f, 0.8443279266f, -0.5358268023f, 0.8270805478f, -0.5620833635f,
- 1.0000000000f, -0.0000000000f, 0.9980267286f, -0.0627905205f, 0.9921147227f, -0.1253332347f, 0.9822872281f, -0.1873813123f,
- 0.9685831666f, -0.2486898899f, 0.9510565400f, -0.3090170026f, 0.9297764897f, -0.3681245446f, 0.9048270583f, -0.4257792830f,
- 0.8763066530f, -0.4817536771f, 0.8443279266f, -0.5358268023f, 0.8090170026f, -0.5877852440f, 0.7705132365f, -0.6374239922f,
- 0.7289686203f, -0.6845471263f, 0.6845471263f, -0.7289686203f, 0.6374239922f, -0.7705132365f, 0.5877852440f, -0.8090170026f,
- 0.5358268023f, -0.8443279266f, 0.4817536771f, -0.8763066530f, 0.4257792830f, -0.9048270583f, 0.3681245446f, -0.9297764897f,
- 1.0000000000f, -0.0000000000f, 0.9955619574f, -0.0941083133f, 0.9822872281f, -0.1873813123f, 0.9602937102f, -0.2789911032f,
- 0.9297764897f, -0.3681245446f, 0.8910065293f, -0.4539904892f, 0.8443279266f, -0.5358268023f, 0.7901549935f, -0.6129070520f,
- 0.7289686203f, -0.6845471263f, 0.6613118649f, -0.7501110435f, 0.5877852440f, -0.8090170026f, 0.5090414286f, -0.8607420325f,
- 0.4257792830f, -0.9048270583f, 0.3387379348f, -0.9408807755f, 0.2486898899f, -0.9685831666f, 0.1564344615f, -0.9876883626f,
- 0.0627905205f, -0.9980267286f, -0.0314107575f, -0.9995065331f, -0.1253332347f, -0.9921147227f, -0.2181432396f, -0.9759167433f,
- 1.0000000000f, -0.0000000000f, 0.9921147227f, -0.1253332347f, 0.9685831666f, -0.2486898899f, 0.9297764897f, -0.3681245446f,
- 0.8763066530f, -0.4817536771f, 0.8090170026f, -0.5877852440f, 0.7289686203f, -0.6845471263f, 0.6374239922f, -0.7705132365f,
- 0.5358268023f, -0.8443279266f, 0.4257792830f, -0.9048270583f, 0.3090170026f, -0.9510565400f, 0.1873813123f, -0.9822872281f,
- 0.0627905205f, -0.9980267286f, -0.0627905205f, -0.9980267286f, -0.1873813123f, -0.9822872281f, -0.3090170026f, -0.9510565400f,
- -0.4257792830f, -0.9048270583f, -0.5358268023f, -0.8443279266f, -0.6374239922f, -0.7705132365f, -0.7289686203f, -0.6845471263f,
- 1.0000000000f, -0.0000000000f, 0.9876883626f, -0.1564344615f, 0.9510565400f, -0.3090170026f, 0.8910065293f, -0.4539904892f,
- 0.8090170026f, -0.5877852440f, 0.7071067691f, -0.7071067691f, 0.5877852440f, -0.8090170026f, 0.4539904892f, -0.8910065293f,
- 0.3090170026f, -0.9510565400f, 0.1564344615f, -0.9876883626f, -0.0000000000f, -1.0000000000f, -0.1564344615f, -0.9876883626f,
- -0.3090170026f, -0.9510565400f, -0.4539904892f, -0.8910065293f, -0.5877852440f, -0.8090170026f, -0.7071067691f, -0.7071067691f,
- -0.8090170026f, -0.5877852440f, -0.8910065293f, -0.4539904892f, -0.9510565400f, -0.3090170026f, -0.9876883626f, -0.1564344615f,
- 1.0000000000f, -0.0000000000f, 0.9822872281f, -0.1873813123f, 0.9297764897f, -0.3681245446f, 0.8443279266f, -0.5358268023f,
- 0.7289686203f, -0.6845471263f, 0.5877852440f, -0.8090170026f, 0.4257792830f, -0.9048270583f, 0.2486898899f, -0.9685831666f,
- 0.0627905205f, -0.9980267286f, -0.1253332347f, -0.9921147227f, -0.3090170026f, -0.9510565400f, -0.4817536771f, -0.8763066530f,
- -0.6374239922f, -0.7705132365f, -0.7705132365f, -0.6374239922f, -0.8763066530f, -0.4817536771f, -0.9510565400f, -0.3090170026f,
- -0.9921147227f, -0.1253332347f, -0.9980267286f, 0.0627905205f, -0.9685831666f, 0.2486898899f, -0.9048270583f, 0.4257792830f,
- 1.0000000000f, -0.0000000000f, 0.9759167433f, -0.2181432396f, 0.9048270583f, -0.4257792830f, 0.7901549935f, -0.6129070520f,
- 0.6374239922f, -0.7705132365f, 0.4539904892f, -0.8910065293f, 0.2486898899f, -0.9685831666f, 0.0314107575f, -0.9995065331f,
- -0.1873813123f, -0.9822872281f, -0.3971478939f, -0.9177546501f, -0.5877852440f, -0.8090170026f, -0.7501110435f, -0.6613118649f,
- -0.8763066530f, -0.4817536771f, -0.9602937102f, -0.2789911032f, -0.9980267286f, -0.0627905205f, -0.9876883626f, 0.1564344615f,
- -0.9297764897f, 0.3681245446f, -0.8270805478f, 0.5620833635f, -0.6845471263f, 0.7289686203f, -0.5090414286f, 0.8607420325f,
- 1.0000000000f, -0.0000000000f, 0.9685831666f, -0.2486898899f, 0.8763066530f, -0.4817536771f, 0.7289686203f, -0.6845471263f,
- 0.5358268023f, -0.8443279266f, 0.3090170026f, -0.9510565400f, 0.0627905205f, -0.9980267286f, -0.1873813123f, -0.9822872281f,
- -0.4257792830f, -0.9048270583f, -0.6374239922f, -0.7705132365f, -0.8090170026f, -0.5877852440f, -0.9297764897f, -0.3681245446f,
- -0.9921147227f, -0.1253332347f, -0.9921147227f, 0.1253332347f, -0.9297764897f, 0.3681245446f, -0.8090170026f, 0.5877852440f,
- -0.6374239922f, 0.7705132365f, -0.4257792830f, 0.9048270583f, -0.1873813123f, 0.9822872281f, 0.0627905205f, 0.9980267286f,
- 1.0000000000f, -0.0000000000f, 0.9602937102f, -0.2789911032f, 0.8443279266f, -0.5358268023f, 0.6613118649f, -0.7501110435f,
- 0.4257792830f, -0.9048270583f, 0.1564344615f, -0.9876883626f, -0.1253332347f, -0.9921147227f, -0.3971478939f, -0.9177546501f,
- -0.6374239922f, -0.7705132365f, -0.8270805478f, -0.5620833635f, -0.9510565400f, -0.3090170026f, -0.9995065331f, -0.0314107575f,
- -0.9685831666f, 0.2486898899f, -0.8607420325f, 0.5090414286f, -0.6845471263f, 0.7289686203f, -0.4539904892f, 0.8910065293f,
- -0.1873813123f, 0.9822872281f, 0.0941083133f, 0.9955619574f, 0.3681245446f, 0.9297764897f, 0.6129070520f, 0.7901549935f,
- 1.0000000000f, -0.0000000000f, 0.9998766184f, -0.0157073177f, 0.9995065331f, -0.0314107575f, 0.9988898635f, -0.0471064523f,
- 0.9980267286f, -0.0627905205f, 0.9969173074f, -0.0784590989f, 0.9955619574f, -0.0941083133f, 0.9939609766f, -0.1097343117f,
- 0.9921147227f, -0.1253332347f, 0.9900236726f, -0.1409012377f, 0.9876883626f, -0.1564344615f, 0.9851093292f, -0.1719291061f,
- 0.9822872281f, -0.1873813123f, 0.9792228341f, -0.2027872950f, 0.9759167433f, -0.2181432396f, 0.9723699093f, -0.2334453613f,
- 0.9685831666f, -0.2486898899f, 0.9645574093f, -0.2638730407f, 0.9602937102f, -0.2789911032f, 0.9557930231f, -0.2940403223f,
- 1.0000000000f, -0.0000000000f, 0.9988898635f, -0.0471064523f, 0.9955619574f, -0.0941083133f, 0.9900236726f, -0.1409012377f,
- 0.9822872281f, -0.1873813123f, 0.9723699093f, -0.2334453613f, 0.9602937102f, -0.2789911032f, 0.9460853338f, -0.3239174187f,
- 0.9297764897f, -0.3681245446f, 0.9114032984f, -0.4115143716f, 0.8910065293f, -0.4539904892f, 0.8686315417f, -0.4954586625f,
- 0.8443279266f, -0.5358268023f, 0.8181497455f, -0.5750052333f, 0.7901549935f, -0.6129070520f, 0.7604059577f, -0.6494480371f,
- 0.7289686203f, -0.6845471263f, 0.6959127784f, -0.7181262970f, 0.6613118649f, -0.7501110435f, 0.6252426505f, -0.7804304361f,
- 1.0000000000f, -0.0000000000f, 0.9969173074f, -0.0784590989f, 0.9876883626f, -0.1564344615f, 0.9723699093f, -0.2334453613f,
- 0.9510565400f, -0.3090170026f, 0.9238795042f, -0.3826834261f, 0.8910065293f, -0.4539904892f, 0.8526401520f, -0.5224985480f,
- 0.8090170026f, -0.5877852440f, 0.7604059577f, -0.6494480371f, 0.7071067691f, -0.7071067691f, 0.6494480371f, -0.7604059577f,
- 0.5877852440f, -0.8090170026f, 0.5224985480f, -0.8526401520f, 0.4539904892f, -0.8910065293f, 0.3826834261f, -0.9238795042f,
- 0.3090170026f, -0.9510565400f, 0.2334453613f, -0.9723699093f, 0.1564344615f, -0.9876883626f, 0.0784590989f, -0.9969173074f,
- 1.0000000000f, -0.0000000000f, 0.9939609766f, -0.1097343117f, 0.9759167433f, -0.2181432396f, 0.9460853338f, -0.3239174187f,
- 0.9048270583f, -0.4257792830f, 0.8526401520f, -0.5224985480f, 0.7901549935f, -0.6129070520f, 0.7181262970f, -0.6959127784f,
- 0.6374239922f, -0.7705132365f, 0.5490227938f, -0.8358073831f, 0.4539904892f, -0.8910065293f, 0.3534748554f, -0.9354440570f,
- 0.2486898899f, -0.9685831666f, 0.1409012377f, -0.9900236726f, 0.0314107575f, -0.9995065331f, -0.0784590989f, -0.9969173074f,
- -0.1873813123f, -0.9822872281f, -0.2940403223f, -0.9557930231f, -0.3971478939f, -0.9177546501f, -0.4954586625f, -0.8686315417f,
- 1.0000000000f, -0.0000000000f, 0.9900236726f, -0.1409012377f, 0.9602937102f, -0.2789911032f, 0.9114032984f, -0.4115143716f,
- 0.8443279266f, -0.5358268023f, 0.7604059577f, -0.6494480371f, 0.6613118649f, -0.7501110435f, 0.5490227938f, -0.8358073831f,
- 0.4257792830f, -0.9048270583f, 0.2940403223f, -0.9557930231f, 0.1564344615f, -0.9876883626f, 0.0157073177f, -0.9998766184f,
- -0.1253332347f, -0.9921147227f, -0.2638730407f, -0.9645574093f, -0.3971478939f, -0.9177546501f, -0.5224985480f, -0.8526401520f,
- -0.6374239922f, -0.7705132365f, -0.7396311164f, -0.6730124950f, -0.8270805478f, -0.5620833635f, -0.8980275989f, -0.4399391711f,
- 1.0000000000f, -0.0000000000f, 0.9851093292f, -0.1719291061f, 0.9408807755f, -0.3387379348f, 0.8686315417f, -0.4954586625f,
- 0.7705132365f, -0.6374239922f, 0.6494480371f, -0.7604059577f, 0.5090414286f, -0.8607420325f, 0.3534748554f, -0.9354440570f,
- 0.1873813123f, -0.9822872281f, 0.0157073177f, -0.9998766184f, -0.1564344615f, -0.9876883626f, -0.3239174187f, -0.9460853338f,
- -0.4817536771f, -0.8763066530f, -0.6252426505f, -0.7804304361f, -0.7501110435f, -0.6613118649f, -0.8526401520f, -0.5224985480f,
- -0.9297764897f, -0.3681245446f, -0.9792228341f, -0.2027872950f, -0.9995065331f, -0.0314107575f, -0.9900236726f, 0.1409012377f,
- 1.0000000000f, -0.0000000000f, 0.9792228341f, -0.2027872950f, 0.9177546501f, -0.3971478939f, 0.8181497455f, -0.5750052333f,
- 0.6845471263f, -0.7289686203f, 0.5224985480f, -0.8526401520f, 0.3387379348f, -0.9408807755f, 0.1409012377f, -0.9900236726f,
- -0.0627905205f, -0.9980267286f, -0.2638730407f, -0.9645574093f, -0.4539904892f, -0.8910065293f, -0.6252426505f, -0.7804304361f,
- -0.7705132365f, -0.6374239922f, -0.8837656379f, -0.4679298103f, -0.9602937102f, -0.2789911032f, -0.9969173074f, -0.0784590989f,
- -0.9921147227f, 0.1253332347f, -0.9460853338f, 0.3239174187f, -0.8607420325f, 0.5090414286f, -0.7396311164f, 0.6730124950f,
- 1.0000000000f, -0.0000000000f, 0.9723699093f, -0.2334453613f, 0.8910065293f, -0.4539904892f, 0.7604059577f, -0.6494480371f,
- 0.5877852440f, -0.8090170026f, 0.3826834261f, -0.9238795042f, 0.1564344615f, -0.9876883626f, -0.0784590989f, -0.9969173074f,
- -0.3090170026f, -0.9510565400f, -0.5224985480f, -0.8526401520f, -0.7071067691f, -0.7071067691f, -0.8526401520f, -0.5224985480f,
- -0.9510565400f, -0.3090170026f, -0.9969173074f, -0.0784590989f, -0.9876883626f, 0.1564344615f, -0.9238795042f, 0.3826834261f,
- -0.8090170026f, 0.5877852440f, -0.6494480371f, 0.7604059577f, -0.4539904892f, 0.8910065293f, -0.2334453613f, 0.9723699093f,
- 1.0000000000f, -0.0000000000f, 0.9645574093f, -0.2638730407f, 0.8607420325f, -0.5090414286f, 0.6959127784f, -0.7181262970f,
- 0.4817536771f, -0.8763066530f, 0.2334453613f, -0.9723699093f, -0.0314107575f, -0.9995065331f, -0.2940403223f, -0.9557930231f,
- -0.5358268023f, -0.8443279266f, -0.7396311164f, -0.6730124950f, -0.8910065293f, -0.4539904892f, -0.9792228341f, -0.2027872950f,
- -0.9980267286f, 0.0627905205f, -0.9460853338f, 0.3239174187f, -0.8270805478f, 0.5620833635f, -0.6494480371f, 0.7604059577f,
- -0.4257792830f, 0.9048270583f, -0.1719291061f, 0.9851093292f, 0.0941083133f, 0.9955619574f, 0.3534748554f, 0.9354440570f,
- 1.0000000000f, -0.0000000000f, 0.9557930231f, -0.2940403223f, 0.8270805478f, -0.5620833635f, 0.6252426505f, -0.7804304361f,
- 0.3681245446f, -0.9297764897f, 0.0784590989f, -0.9969173074f, -0.2181432396f, -0.9759167433f, -0.4954586625f, -0.8686315417f,
- -0.7289686203f, -0.6845471263f, -0.8980275989f, -0.4399391711f, -0.9876883626f, -0.1564344615f, -0.9900236726f, 0.1409012377f,
- -0.9048270583f, 0.4257792830f, -0.7396311164f, 0.6730124950f, -0.5090414286f, 0.8607420325f, -0.2334453613f, 0.9723699093f,
- 0.0627905205f, 0.9980267286f, 0.3534748554f, 0.9354440570f, 0.6129070520f, 0.7901549935f, 0.8181497455f, 0.5750052333f
-};
-
-const float FFT_RotVector_600[1140] = {
- 1.0000000000f, -0.0000000000f, 0.9997806549f, -0.0209424198f,
- 0.9991228580f, -0.0418756530f, 0.9980267286f, -0.0627905205f, 0.9964928627f, -0.0836778432f, 0.9945219159f, -0.1045284644f,
- 0.9921147227f, -0.1253332347f, 0.9892723560f, -0.1460830271f, 0.9859960079f, -0.1667687446f, 0.9822872281f, -0.1873813123f,
- 0.9781476259f, -0.2079116851f, 0.9735789299f, -0.2283508629f, 0.9685831666f, -0.2486898899f, 0.9631625414f, -0.2689198256f,
- 0.9573194981f, -0.2890318036f, 0.9510565400f, -0.3090170026f, 0.9443763494f, -0.3288666606f, 0.9372819662f, -0.3485720456f,
- 0.9297764897f, -0.3681245446f, 0.9218631387f, -0.3875155747f, 0.9135454297f, -0.4067366421f, 0.9048270583f, -0.4257792830f,
- 0.8957117796f, -0.4446351826f, 0.8862035871f, -0.4632960260f, 0.8763066530f, -0.4817536771f, 0.8660253882f, -0.5000000000f,
- 0.8553642631f, -0.5180270076f, 0.8443279266f, -0.5358268023f, 0.8329212666f, -0.5533915758f, 0.8211492300f, -0.5707135797f,
- 1.0000000000f, -0.0000000000f, 0.9991228580f, -0.0418756530f, 0.9964928627f, -0.0836778432f, 0.9921147227f, -0.1253332347f,
- 0.9859960079f, -0.1667687446f, 0.9781476259f, -0.2079116851f, 0.9685831666f, -0.2486898899f, 0.9573194981f, -0.2890318036f,
- 0.9443763494f, -0.3288666606f, 0.9297764897f, -0.3681245446f, 0.9135454297f, -0.4067366421f, 0.8957117796f, -0.4446351826f,
- 0.8763066530f, -0.4817536771f, 0.8553642631f, -0.5180270076f, 0.8329212666f, -0.5533915758f, 0.8090170026f, -0.5877852440f,
- 0.7836934328f, -0.6211477518f, 0.7569950819f, -0.6534206271f, 0.7289686203f, -0.6845471263f, 0.6996633410f, -0.7144726515f,
- 0.6691306233f, -0.7431448102f, 0.6374239922f, -0.7705132365f, 0.6045991182f, -0.7965298891f, 0.5707135797f, -0.8211492300f,
- 0.5358268023f, -0.8443279266f, 0.5000000000f, -0.8660253882f, 0.4632960260f, -0.8862035871f, 0.4257792830f, -0.9048270583f,
- 0.3875155747f, -0.9218631387f, 0.3485720456f, -0.9372819662f, 1.0000000000f, -0.0000000000f, 0.9980267286f, -0.0627905205f,
- 0.9921147227f, -0.1253332347f, 0.9822872281f, -0.1873813123f, 0.9685831666f, -0.2486898899f, 0.9510565400f, -0.3090170026f,
- 0.9297764897f, -0.3681245446f, 0.9048270583f, -0.4257792830f, 0.8763066530f, -0.4817536771f, 0.8443279266f, -0.5358268023f,
- 0.8090170026f, -0.5877852440f, 0.7705132365f, -0.6374239922f, 0.7289686203f, -0.6845471263f, 0.6845471263f, -0.7289686203f,
- 0.6374239922f, -0.7705132365f, 0.5877852440f, -0.8090170026f, 0.5358268023f, -0.8443279266f, 0.4817536771f, -0.8763066530f,
- 0.4257792830f, -0.9048270583f, 0.3681245446f, -0.9297764897f, 0.3090170026f, -0.9510565400f, 0.2486898899f, -0.9685831666f,
- 0.1873813123f, -0.9822872281f, 0.1253332347f, -0.9921147227f, 0.0627905205f, -0.9980267286f, -0.0000000000f, -1.0000000000f,
- -0.0627905205f, -0.9980267286f, -0.1253332347f, -0.9921147227f, -0.1873813123f, -0.9822872281f, -0.2486898899f, -0.9685831666f,
- 1.0000000000f, -0.0000000000f, 0.9964928627f, -0.0836778432f, 0.9859960079f, -0.1667687446f, 0.9685831666f, -0.2486898899f,
- 0.9443763494f, -0.3288666606f, 0.9135454297f, -0.4067366421f, 0.8763066530f, -0.4817536771f, 0.8329212666f, -0.5533915758f,
- 0.7836934328f, -0.6211477518f, 0.7289686203f, -0.6845471263f, 0.6691306233f, -0.7431448102f, 0.6045991182f, -0.7965298891f,
- 0.5358268023f, -0.8443279266f, 0.4632960260f, -0.8862035871f, 0.3875155747f, -0.9218631387f, 0.3090170026f, -0.9510565400f,
- 0.2283508629f, -0.9735789299f, 0.1460830271f, -0.9892723560f, 0.0627905205f, -0.9980267286f, -0.0209424198f, -0.9997806549f,
- -0.1045284644f, -0.9945219159f, -0.1873813123f, -0.9822872281f, -0.2689198256f, -0.9631625414f, -0.3485720456f, -0.9372819662f,
- -0.4257792830f, -0.9048270583f, -0.5000000000f, -0.8660253882f, -0.5707135797f, -0.8211492300f, -0.6374239922f, -0.7705132365f,
- -0.6996633410f, -0.7144726515f, -0.7569950819f, -0.6534206271f, 1.0000000000f, -0.0000000000f, 0.9945219159f, -0.1045284644f,
- 0.9781476259f, -0.2079116851f, 0.9510565400f, -0.3090170026f, 0.9135454297f, -0.4067366421f, 0.8660253882f, -0.5000000000f,
- 0.8090170026f, -0.5877852440f, 0.7431448102f, -0.6691306233f, 0.6691306233f, -0.7431448102f, 0.5877852440f, -0.8090170026f,
- 0.5000000000f, -0.8660253882f, 0.4067366421f, -0.9135454297f, 0.3090170026f, -0.9510565400f, 0.2079116851f, -0.9781476259f,
- 0.1045284644f, -0.9945219159f, -0.0000000000f, -1.0000000000f, -0.1045284644f, -0.9945219159f, -0.2079116851f, -0.9781476259f,
- -0.3090170026f, -0.9510565400f, -0.4067366421f, -0.9135454297f, -0.5000000000f, -0.8660253882f, -0.5877852440f, -0.8090170026f,
- -0.6691306233f, -0.7431448102f, -0.7431448102f, -0.6691306233f, -0.8090170026f, -0.5877852440f, -0.8660253882f, -0.5000000000f,
- -0.9135454297f, -0.4067366421f, -0.9510565400f, -0.3090170026f, -0.9781476259f, -0.2079116851f, -0.9945219159f, -0.1045284644f,
- 1.0000000000f, -0.0000000000f, 0.9921147227f, -0.1253332347f, 0.9685831666f, -0.2486898899f, 0.9297764897f, -0.3681245446f,
- 0.8763066530f, -0.4817536771f, 0.8090170026f, -0.5877852440f, 0.7289686203f, -0.6845471263f, 0.6374239922f, -0.7705132365f,
- 0.5358268023f, -0.8443279266f, 0.4257792830f, -0.9048270583f, 0.3090170026f, -0.9510565400f, 0.1873813123f, -0.9822872281f,
- 0.0627905205f, -0.9980267286f, -0.0627905205f, -0.9980267286f, -0.1873813123f, -0.9822872281f, -0.3090170026f, -0.9510565400f,
- -0.4257792830f, -0.9048270583f, -0.5358268023f, -0.8443279266f, -0.6374239922f, -0.7705132365f, -0.7289686203f, -0.6845471263f,
- -0.8090170026f, -0.5877852440f, -0.8763066530f, -0.4817536771f, -0.9297764897f, -0.3681245446f, -0.9685831666f, -0.2486898899f,
- -0.9921147227f, -0.1253332347f, -1.0000000000f, 0.0000000000f, -0.9921147227f, 0.1253332347f, -0.9685831666f, 0.2486898899f,
- -0.9297764897f, 0.3681245446f, -0.8763066530f, 0.4817536771f, 1.0000000000f, -0.0000000000f, 0.9892723560f, -0.1460830271f,
- 0.9573194981f, -0.2890318036f, 0.9048270583f, -0.4257792830f, 0.8329212666f, -0.5533915758f, 0.7431448102f, -0.6691306233f,
- 0.6374239922f, -0.7705132365f, 0.5180270076f, -0.8553642631f, 0.3875155747f, -0.9218631387f, 0.2486898899f, -0.9685831666f,
- 0.1045284644f, -0.9945219159f, -0.0418756530f, -0.9991228580f, -0.1873813123f, -0.9822872281f, -0.3288666606f, -0.9443763494f,
- -0.4632960260f, -0.8862035871f, -0.5877852440f, -0.8090170026f, -0.6996633410f, -0.7144726515f, -0.7965298891f, -0.6045991182f,
- -0.8763066530f, -0.4817536771f, -0.9372819662f, -0.3485720456f, -0.9781476259f, -0.2079116851f, -0.9980267286f, -0.0627905205f,
- -0.9964928627f, 0.0836778432f, -0.9735789299f, 0.2283508629f, -0.9297764897f, 0.3681245446f, -0.8660253882f, 0.5000000000f,
- -0.7836934328f, 0.6211477518f, -0.6845471263f, 0.7289686203f, -0.5707135797f, 0.8211492300f, -0.4446351826f, 0.8957117796f,
- 1.0000000000f, -0.0000000000f, 0.9859960079f, -0.1667687446f, 0.9443763494f, -0.3288666606f, 0.8763066530f, -0.4817536771f,
- 0.7836934328f, -0.6211477518f, 0.6691306233f, -0.7431448102f, 0.5358268023f, -0.8443279266f, 0.3875155747f, -0.9218631387f,
- 0.2283508629f, -0.9735789299f, 0.0627905205f, -0.9980267286f, -0.1045284644f, -0.9945219159f, -0.2689198256f, -0.9631625414f,
- -0.4257792830f, -0.9048270583f, -0.5707135797f, -0.8211492300f, -0.6996633410f, -0.7144726515f, -0.8090170026f, -0.5877852440f,
- -0.8957117796f, -0.4446351826f, -0.9573194981f, -0.2890318036f, -0.9921147227f, -0.1253332347f, -0.9991228580f, 0.0418756530f,
- -0.9781476259f, 0.2079116851f, -0.9297764897f, 0.3681245446f, -0.8553642631f, 0.5180270076f, -0.7569950819f, 0.6534206271f,
- -0.6374239922f, 0.7705132365f, -0.5000000000f, 0.8660253882f, -0.3485720456f, 0.9372819662f, -0.1873813123f, 0.9822872281f,
- -0.0209424198f, 0.9997806549f, 0.1460830271f, 0.9892723560f, 1.0000000000f, -0.0000000000f, 0.9822872281f, -0.1873813123f,
- 0.9297764897f, -0.3681245446f, 0.8443279266f, -0.5358268023f, 0.7289686203f, -0.6845471263f, 0.5877852440f, -0.8090170026f,
- 0.4257792830f, -0.9048270583f, 0.2486898899f, -0.9685831666f, 0.0627905205f, -0.9980267286f, -0.1253332347f, -0.9921147227f,
- -0.3090170026f, -0.9510565400f, -0.4817536771f, -0.8763066530f, -0.6374239922f, -0.7705132365f, -0.7705132365f, -0.6374239922f,
- -0.8763066530f, -0.4817536771f, -0.9510565400f, -0.3090170026f, -0.9921147227f, -0.1253332347f, -0.9980267286f, 0.0627905205f,
- -0.9685831666f, 0.2486898899f, -0.9048270583f, 0.4257792830f, -0.8090170026f, 0.5877852440f, -0.6845471263f, 0.7289686203f,
- -0.5358268023f, 0.8443279266f, -0.3681245446f, 0.9297764897f, -0.1873813123f, 0.9822872281f, 0.0000000000f, 1.0000000000f,
- 0.1873813123f, 0.9822872281f, 0.3681245446f, 0.9297764897f, 0.5358268023f, 0.8443279266f, 0.6845471263f, 0.7289686203f,
- 1.0000000000f, -0.0000000000f, 0.9999451637f, -0.0104717845f, 0.9997806549f, -0.0209424198f, 0.9995065331f, -0.0314107575f,
- 0.9991228580f, -0.0418756530f, 0.9986295104f, -0.0523359552f, 0.9980267286f, -0.0627905205f, 0.9973144531f, -0.0732381940f,
- 0.9964928627f, -0.0836778432f, 0.9955619574f, -0.0941083133f, 0.9945219159f, -0.1045284644f, 0.9933727384f, -0.1149371490f,
- 0.9921147227f, -0.1253332347f, 0.9907478690f, -0.1357155740f, 0.9892723560f, -0.1460830271f, 0.9876883626f, -0.1564344615f,
- 0.9859960079f, -0.1667687446f, 0.9841955900f, -0.1770847440f, 0.9822872281f, -0.1873813123f, 0.9802711606f, -0.1976573467f,
- 0.9781476259f, -0.2079116851f, 0.9759167433f, -0.2181432396f, 0.9735789299f, -0.2283508629f, 0.9711343050f, -0.2385334522f,
- 0.9685831666f, -0.2486898899f, 0.9659258127f, -0.2588190436f, 0.9631625414f, -0.2689198256f, 0.9602937102f, -0.2789911032f,
- 0.9573194981f, -0.2890318036f, 0.9542403221f, -0.2990407944f, 1.0000000000f, -0.0000000000f, 0.9995065331f, -0.0314107575f,
- 0.9980267286f, -0.0627905205f, 0.9955619574f, -0.0941083133f, 0.9921147227f, -0.1253332347f, 0.9876883626f, -0.1564344615f,
- 0.9822872281f, -0.1873813123f, 0.9759167433f, -0.2181432396f, 0.9685831666f, -0.2486898899f, 0.9602937102f, -0.2789911032f,
- 0.9510565400f, -0.3090170026f, 0.9408807755f, -0.3387379348f, 0.9297764897f, -0.3681245446f, 0.9177546501f, -0.3971478939f,
- 0.9048270583f, -0.4257792830f, 0.8910065293f, -0.4539904892f, 0.8763066530f, -0.4817536771f, 0.8607420325f, -0.5090414286f,
- 0.8443279266f, -0.5358268023f, 0.8270805478f, -0.5620833635f, 0.8090170026f, -0.5877852440f, 0.7901549935f, -0.6129070520f,
- 0.7705132365f, -0.6374239922f, 0.7501110435f, -0.6613118649f, 0.7289686203f, -0.6845471263f, 0.7071067691f, -0.7071067691f,
- 0.6845471263f, -0.7289686203f, 0.6613118649f, -0.7501110435f, 0.6374239922f, -0.7705132365f, 0.6129070520f, -0.7901549935f,
- 1.0000000000f, -0.0000000000f, 0.9986295104f, -0.0523359552f, 0.9945219159f, -0.1045284644f, 0.9876883626f, -0.1564344615f,
- 0.9781476259f, -0.2079116851f, 0.9659258127f, -0.2588190436f, 0.9510565400f, -0.3090170026f, 0.9335803986f, -0.3583679497f,
- 0.9135454297f, -0.4067366421f, 0.8910065293f, -0.4539904892f, 0.8660253882f, -0.5000000000f, 0.8386705518f, -0.5446390510f,
- 0.8090170026f, -0.5877852440f, 0.7771459818f, -0.6293203831f, 0.7431448102f, -0.6691306233f, 0.7071067691f, -0.7071067691f,
- 0.6691306233f, -0.7431448102f, 0.6293203831f, -0.7771459818f, 0.5877852440f, -0.8090170026f, 0.5446390510f, -0.8386705518f,
- 0.5000000000f, -0.8660253882f, 0.4539904892f, -0.8910065293f, 0.4067366421f, -0.9135454297f, 0.3583679497f, -0.9335803986f,
- 0.3090170026f, -0.9510565400f, 0.2588190436f, -0.9659258127f, 0.2079116851f, -0.9781476259f, 0.1564344615f, -0.9876883626f,
- 0.1045284644f, -0.9945219159f, 0.0523359552f, -0.9986295104f, 1.0000000000f, -0.0000000000f, 0.9973144531f, -0.0732381940f,
- 0.9892723560f, -0.1460830271f, 0.9759167433f, -0.2181432396f, 0.9573194981f, -0.2890318036f, 0.9335803986f, -0.3583679497f,
- 0.9048270583f, -0.4257792830f, 0.8712137938f, -0.4909037650f, 0.8329212666f, -0.5533915758f, 0.7901549935f, -0.6129070520f,
- 0.7431448102f, -0.6691306233f, 0.6921432018f, -0.7217602134f, 0.6374239922f, -0.7705132365f, 0.5792811513f, -0.8151277900f,
- 0.5180270076f, -0.8553642631f, 0.4539904892f, -0.8910065293f, 0.3875155747f, -0.9218631387f, 0.3189592957f, -0.9477683902f,
- 0.2486898899f, -0.9685831666f, 0.1770847440f, -0.9841955900f, 0.1045284644f, -0.9945219159f, 0.0314107575f, -0.9995065331f,
- -0.0418756530f, -0.9991228580f, -0.1149371490f, -0.9933727384f, -0.1873813123f, -0.9822872281f, -0.2588190436f, -0.9659258127f,
- -0.3288666606f, -0.9443763494f, -0.3971478939f, -0.9177546501f, -0.4632960260f, -0.8862035871f, -0.5269557834f, -0.8498926759f,
- 1.0000000000f, -0.0000000000f, 0.9955619574f, -0.0941083133f, 0.9822872281f, -0.1873813123f, 0.9602937102f, -0.2789911032f,
- 0.9297764897f, -0.3681245446f, 0.8910065293f, -0.4539904892f, 0.8443279266f, -0.5358268023f, 0.7901549935f, -0.6129070520f,
- 0.7289686203f, -0.6845471263f, 0.6613118649f, -0.7501110435f, 0.5877852440f, -0.8090170026f, 0.5090414286f, -0.8607420325f,
- 0.4257792830f, -0.9048270583f, 0.3387379348f, -0.9408807755f, 0.2486898899f, -0.9685831666f, 0.1564344615f, -0.9876883626f,
- 0.0627905205f, -0.9980267286f, -0.0314107575f, -0.9995065331f, -0.1253332347f, -0.9921147227f, -0.2181432396f, -0.9759167433f,
- -0.3090170026f, -0.9510565400f, -0.3971478939f, -0.9177546501f, -0.4817536771f, -0.8763066530f, -0.5620833635f, -0.8270805478f,
- -0.6374239922f, -0.7705132365f, -0.7071067691f, -0.7071067691f, -0.7705132365f, -0.6374239922f, -0.8270805478f, -0.5620833635f,
- -0.8763066530f, -0.4817536771f, -0.9177546501f, -0.3971478939f, 1.0000000000f, -0.0000000000f, 0.9933727384f, -0.1149371490f,
- 0.9735789299f, -0.2283508629f, 0.9408807755f, -0.3387379348f, 0.8957117796f, -0.4446351826f, 0.8386705518f, -0.5446390510f,
- 0.7705132365f, -0.6374239922f, 0.6921432018f, -0.7217602134f, 0.6045991182f, -0.7965298891f, 0.5090414286f, -0.8607420325f,
- 0.4067366421f, -0.9135454297f, 0.2990407944f, -0.9542403221f, 0.1873813123f, -0.9822872281f, 0.0732381940f, -0.9973144531f,
- -0.0418756530f, -0.9991228580f, -0.1564344615f, -0.9876883626f, -0.2689198256f, -0.9631625414f, -0.3778407872f, -0.9258705974f,
- -0.4817536771f, -0.8763066530f, -0.5792811513f, -0.8151277900f, -0.6691306233f, -0.7431448102f, -0.7501110435f, -0.6613118649f,
- -0.8211492300f, -0.5707135797f, -0.8813034296f, -0.4725507796f, -0.9297764897f, -0.3681245446f, -0.9659258127f, -0.2588190436f,
- -0.9892723560f, -0.1460830271f, -0.9995065331f, -0.0314107575f, -0.9964928627f, 0.0836778432f, -0.9802711606f, 0.1976573467f,
- 1.0000000000f, -0.0000000000f, 0.9907478690f, -0.1357155740f, 0.9631625414f, -0.2689198256f, 0.9177546501f, -0.3971478939f,
- 0.8553642631f, -0.5180270076f, 0.7771459818f, -0.6293203831f, 0.6845471263f, -0.7289686203f, 0.5792811513f, -0.8151277900f,
- 0.4632960260f, -0.8862035871f, 0.3387379348f, -0.9408807755f, 0.2079116851f, -0.9781476259f, 0.0732381940f, -0.9973144531f,
- -0.0627905205f, -0.9980267286f, -0.1976573467f, -0.9802711606f, -0.3288666606f, -0.9443763494f, -0.4539904892f, -0.8910065293f,
- -0.5707135797f, -0.8211492300f, -0.6768759489f, -0.7360970974f, -0.7705132365f, -0.6374239922f, -0.8498926759f, -0.5269557834f,
- -0.9135454297f, -0.4067366421f, -0.9602937102f, -0.2789911032f, -0.9892723560f, -0.1460830271f, -0.9999451637f, -0.0104717845f,
- -0.9921147227f, 0.1253332347f, -0.9659258127f, 0.2588190436f, -0.9218631387f, 0.3875155747f, -0.8607420325f, 0.5090414286f,
- -0.7836934328f, 0.6211477518f, -0.6921432018f, 0.7217602134f, 1.0000000000f, -0.0000000000f, 0.9876883626f, -0.1564344615f,
- 0.9510565400f, -0.3090170026f, 0.8910065293f, -0.4539904892f, 0.8090170026f, -0.5877852440f, 0.7071067691f, -0.7071067691f,
- 0.5877852440f, -0.8090170026f, 0.4539904892f, -0.8910065293f, 0.3090170026f, -0.9510565400f, 0.1564344615f, -0.9876883626f,
- -0.0000000000f, -1.0000000000f, -0.1564344615f, -0.9876883626f, -0.3090170026f, -0.9510565400f, -0.4539904892f, -0.8910065293f,
- -0.5877852440f, -0.8090170026f, -0.7071067691f, -0.7071067691f, -0.8090170026f, -0.5877852440f, -0.8910065293f, -0.4539904892f,
- -0.9510565400f, -0.3090170026f, -0.9876883626f, -0.1564344615f, -1.0000000000f, 0.0000000000f, -0.9876883626f, 0.1564344615f,
- -0.9510565400f, 0.3090170026f, -0.8910065293f, 0.4539904892f, -0.8090170026f, 0.5877852440f, -0.7071067691f, 0.7071067691f,
- -0.5877852440f, 0.8090170026f, -0.4539904892f, 0.8910065293f, -0.3090170026f, 0.9510565400f, -0.1564344615f, 0.9876883626f,
- 1.0000000000f, -0.0000000000f, 0.9841955900f, -0.1770847440f, 0.9372819662f, -0.3485720456f, 0.8607420325f, -0.5090414286f,
- 0.7569950819f, -0.6534206271f, 0.6293203831f, -0.7771459818f, 0.4817536771f, -0.8763066530f, 0.3189592957f, -0.9477683902f,
- 0.1460830271f, -0.9892723560f, -0.0314107575f, -0.9995065331f, -0.2079116851f, -0.9781476259f, -0.3778407872f, -0.9258705974f,
- -0.5358268023f, -0.8443279266f, -0.6768759489f, -0.7360970974f, -0.7965298891f, -0.6045991182f, -0.8910065293f, -0.4539904892f,
- -0.9573194981f, -0.2890318036f, -0.9933727384f, -0.1149371490f, -0.9980267286f, 0.0627905205f, -0.9711343050f, 0.2385334522f,
- -0.9135454297f, 0.4067366421f, -0.8270805478f, 0.5620833635f, -0.7144726515f, 0.6996633410f, -0.5792811513f, 0.8151277900f,
- -0.4257792830f, 0.9048270583f, -0.2588190436f, 0.9659258127f, -0.0836778432f, 0.9964928627f, 0.0941083133f, 0.9955619574f,
- 0.2689198256f, 0.9631625414f, 0.4352310896f, 0.9003187418f, 1.0000000000f, -0.0000000000f, 0.9802711606f, -0.1976573467f,
- 0.9218631387f, -0.3875155747f, 0.8270805478f, -0.5620833635f, 0.6996633410f, -0.7144726515f, 0.5446390510f, -0.8386705518f,
- 0.3681245446f, -0.9297764897f, 0.1770847440f, -0.9841955900f, -0.0209424198f, -0.9997806549f, -0.2181432396f, -0.9759167433f,
- -0.4067366421f, -0.9135454297f, -0.5792811513f, -0.8151277900f, -0.7289686203f, -0.6845471263f, -0.8498926759f, -0.5269557834f,
- -0.9372819662f, -0.3485720456f, -0.9876883626f, -0.1564344615f, -0.9991228580f, 0.0418756530f, -0.9711343050f, 0.2385334522f,
- -0.9048270583f, 0.4257792830f, -0.8028174639f, 0.5962249041f, -0.6691306233f, 0.7431448102f, -0.5090414286f, 0.8607420325f,
- -0.3288666606f, 0.9443763494f, -0.1357155740f, 0.9907478690f, 0.0627905205f, 0.9980267286f, 0.2588190436f, 0.9659258127f,
- 0.4446351826f, 0.8957117796f, 0.6129070520f, 0.7901549935f, 0.7569950819f, 0.6534206271f, 0.8712137938f, 0.4909037650f
-};
-
-const float FFT_RotVector_640[1240] = {
- 1.0000000000f, -0.0000000000f, 0.9998072386f, -0.0196336918f, 0.9992290139f, -0.0392598175f, 0.9982656240f, -0.0588708036f,
- 0.9969173074f, -0.0784590989f, 0.9951847196f, -0.0980171412f, 0.9930684566f, -0.1175373942f, 0.9905693531f, -0.1370123476f,
- 0.9876883626f, -0.1564344615f, 0.9844265580f, -0.1757962853f, 0.9807852507f, -0.1950903237f, 0.9767658710f, -0.2143091559f,
- 0.9723699093f, -0.2334453613f, 0.9675990939f, -0.2524915636f, 0.9624552131f, -0.2714404464f, 0.9569403529f, -0.2902846634f,
- 0.9510565400f, -0.3090170026f, 0.9448060393f, -0.3276301920f, 0.9381913543f, -0.3461170495f, 0.9312149286f, -0.3644705117f,
- 1.0000000000f, -0.0000000000f, 0.9992290139f, -0.0392598175f, 0.9969173074f, -0.0784590989f, 0.9930684566f, -0.1175373942f,
- 0.9876883626f, -0.1564344615f, 0.9807852507f, -0.1950903237f, 0.9723699093f, -0.2334453613f, 0.9624552131f, -0.2714404464f,
- 0.9510565400f, -0.3090170026f, 0.9381913543f, -0.3461170495f, 0.9238795042f, -0.3826834261f, 0.9081431627f, -0.4186597466f,
- 0.8910065293f, -0.4539904892f, 0.8724960089f, -0.4886212349f, 0.8526401520f, -0.5224985480f, 0.8314695954f, -0.5555702448f,
- 0.8090170026f, -0.5877852440f, 0.7853169441f, -0.6190939546f, 0.7604059577f, -0.6494480371f, 0.7343224883f, -0.6788007617f,
- 1.0000000000f, -0.0000000000f, 0.9982656240f, -0.0588708036f, 0.9930684566f, -0.1175373942f, 0.9844265580f, -0.1757962853f,
- 0.9723699093f, -0.2334453613f, 0.9569403529f, -0.2902846634f, 0.9381913543f, -0.3461170495f, 0.9161879420f, -0.4007488191f,
- 0.8910065293f, -0.4539904892f, 0.8627343774f, -0.5056573749f, 0.8314695954f, -0.5555702448f, 0.7973206639f, -0.6035559177f,
- 0.7604059577f, -0.6494480371f, 0.7208535671f, -0.6930873394f, 0.6788007617f, -0.7343224883f, 0.6343932748f, -0.7730104327f,
- 0.5877852440f, -0.8090170026f, 0.5391383171f, -0.8422172070f, 0.4886212349f, -0.8724960089f, 0.4364092350f, -0.8997482657f,
- 1.0000000000f, -0.0000000000f, 0.9969173074f, -0.0784590989f, 0.9876883626f, -0.1564344615f, 0.9723699093f, -0.2334453613f,
- 0.9510565400f, -0.3090170026f, 0.9238795042f, -0.3826834261f, 0.8910065293f, -0.4539904892f, 0.8526401520f, -0.5224985480f,
- 0.8090170026f, -0.5877852440f, 0.7604059577f, -0.6494480371f, 0.7071067691f, -0.7071067691f, 0.6494480371f, -0.7604059577f,
- 0.5877852440f, -0.8090170026f, 0.5224985480f, -0.8526401520f, 0.4539904892f, -0.8910065293f, 0.3826834261f, -0.9238795042f,
- 0.3090170026f, -0.9510565400f, 0.2334453613f, -0.9723699093f, 0.1564344615f, -0.9876883626f, 0.0784590989f, -0.9969173074f,
- 1.0000000000f, -0.0000000000f, 0.9951847196f, -0.0980171412f, 0.9807852507f, -0.1950903237f, 0.9569403529f, -0.2902846634f,
- 0.9238795042f, -0.3826834261f, 0.8819212914f, -0.4713967443f, 0.8314695954f, -0.5555702448f, 0.7730104327f, -0.6343932748f,
- 0.7071067691f, -0.7071067691f, 0.6343932748f, -0.7730104327f, 0.5555702448f, -0.8314695954f, 0.4713967443f, -0.8819212914f,
- 0.3826834261f, -0.9238795042f, 0.2902846634f, -0.9569403529f, 0.1950903237f, -0.9807852507f, 0.0980171412f, -0.9951847196f,
- -0.0000000000f, -1.0000000000f, -0.0980171412f, -0.9951847196f, -0.1950903237f, -0.9807852507f, -0.2902846634f, -0.9569403529f,
- 1.0000000000f, -0.0000000000f, 0.9930684566f, -0.1175373942f, 0.9723699093f, -0.2334453613f, 0.9381913543f, -0.3461170495f,
- 0.8910065293f, -0.4539904892f, 0.8314695954f, -0.5555702448f, 0.7604059577f, -0.6494480371f, 0.6788007617f, -0.7343224883f,
- 0.5877852440f, -0.8090170026f, 0.4886212349f, -0.8724960089f, 0.3826834261f, -0.9238795042f, 0.2714404464f, -0.9624552131f,
- 0.1564344615f, -0.9876883626f, 0.0392598175f, -0.9992290139f, -0.0784590989f, -0.9969173074f, -0.1950903237f, -0.9807852507f,
- -0.3090170026f, -0.9510565400f, -0.4186597466f, -0.9081431627f, -0.5224985480f, -0.8526401520f, -0.6190939546f, -0.7853169441f,
- 1.0000000000f, -0.0000000000f, 0.9905693531f, -0.1370123476f, 0.9624552131f, -0.2714404464f, 0.9161879420f, -0.4007488191f,
- 0.8526401520f, -0.5224985480f, 0.7730104327f, -0.6343932748f, 0.6788007617f, -0.7343224883f, 0.5717879534f, -0.8204014301f,
- 0.4539904892f, -0.8910065293f, 0.3276301920f, -0.9448060393f, 0.1950903237f, -0.9807852507f, 0.0588708036f, -0.9982656240f,
- -0.0784590989f, -0.9969173074f, -0.2143091559f, -0.9767658710f, -0.3461170495f, -0.9381913543f, -0.4713967443f, -0.8819212914f,
- -0.5877852440f, -0.8090170026f, -0.6930873394f, -0.7208535671f, -0.7853169441f, -0.6190939546f, -0.8627343774f, -0.5056573749f,
- 1.0000000000f, -0.0000000000f, 0.9876883626f, -0.1564344615f, 0.9510565400f, -0.3090170026f, 0.8910065293f, -0.4539904892f,
- 0.8090170026f, -0.5877852440f, 0.7071067691f, -0.7071067691f, 0.5877852440f, -0.8090170026f, 0.4539904892f, -0.8910065293f,
- 0.3090170026f, -0.9510565400f, 0.1564344615f, -0.9876883626f, -0.0000000000f, -1.0000000000f, -0.1564344615f, -0.9876883626f,
- -0.3090170026f, -0.9510565400f, -0.4539904892f, -0.8910065293f, -0.5877852440f, -0.8090170026f, -0.7071067691f, -0.7071067691f,
- -0.8090170026f, -0.5877852440f, -0.8910065293f, -0.4539904892f, -0.9510565400f, -0.3090170026f, -0.9876883626f, -0.1564344615f,
- 1.0000000000f, -0.0000000000f, 0.9844265580f, -0.1757962853f, 0.9381913543f, -0.3461170495f, 0.8627343774f, -0.5056573749f,
- 0.7604059577f, -0.6494480371f, 0.6343932748f, -0.7730104327f, 0.4886212349f, -0.8724960089f, 0.3276301920f, -0.9448060393f,
- 0.1564344615f, -0.9876883626f, -0.0196336918f, -0.9998072386f, -0.1950903237f, -0.9807852507f, -0.3644705117f, -0.9312149286f,
- -0.5224985480f, -0.8526401520f, -0.6642524600f, -0.7475083470f, -0.7853169441f, -0.6190939546f, -0.8819212914f, -0.4713967443f,
- -0.9510565400f, -0.3090170026f, -0.9905693531f, -0.1370123476f, -0.9992290139f, 0.0392598175f, -0.9767658710f, 0.2143091559f,
- 1.0000000000f, -0.0000000000f, 0.9807852507f, -0.1950903237f, 0.9238795042f, -0.3826834261f, 0.8314695954f, -0.5555702448f,
- 0.7071067691f, -0.7071067691f, 0.5555702448f, -0.8314695954f, 0.3826834261f, -0.9238795042f, 0.1950903237f, -0.9807852507f,
- -0.0000000000f, -1.0000000000f, -0.1950903237f, -0.9807852507f, -0.3826834261f, -0.9238795042f, -0.5555702448f, -0.8314695954f,
- -0.7071067691f, -0.7071067691f, -0.8314695954f, -0.5555702448f, -0.9238795042f, -0.3826834261f, -0.9807852507f, -0.1950903237f,
- -1.0000000000f, 0.0000000000f, -0.9807852507f, 0.1950903237f, -0.9238795042f, 0.3826834261f, -0.8314695954f, 0.5555702448f,
- 1.0000000000f, -0.0000000000f, 0.9767658710f, -0.2143091559f, 0.9081431627f, -0.4186597466f, 0.7973206639f, -0.6035559177f,
- 0.6494480371f, -0.7604059577f, 0.4713967443f, -0.8819212914f, 0.2714404464f, -0.9624552131f, 0.0588708036f, -0.9982656240f,
- -0.1564344615f, -0.9876883626f, -0.3644705117f, -0.9312149286f, -0.5555702448f, -0.8314695954f, -0.7208535671f, -0.6930873394f,
- -0.8526401520f, -0.5224985480f, -0.9448060393f, -0.3276301920f, -0.9930684566f, -0.1175373942f, -0.9951847196f, 0.0980171412f,
- -0.9510565400f, 0.3090170026f, -0.8627343774f, 0.5056573749f, -0.7343224883f, 0.6788007617f, -0.5717879534f, 0.8204014301f,
- 1.0000000000f, -0.0000000000f, 0.9723699093f, -0.2334453613f, 0.8910065293f, -0.4539904892f, 0.7604059577f, -0.6494480371f,
- 0.5877852440f, -0.8090170026f, 0.3826834261f, -0.9238795042f, 0.1564344615f, -0.9876883626f, -0.0784590989f, -0.9969173074f,
- -0.3090170026f, -0.9510565400f, -0.5224985480f, -0.8526401520f, -0.7071067691f, -0.7071067691f, -0.8526401520f, -0.5224985480f,
- -0.9510565400f, -0.3090170026f, -0.9969173074f, -0.0784590989f, -0.9876883626f, 0.1564344615f, -0.9238795042f, 0.3826834261f,
- -0.8090170026f, 0.5877852440f, -0.6494480371f, 0.7604059577f, -0.4539904892f, 0.8910065293f, -0.2334453613f, 0.9723699093f,
- 1.0000000000f, -0.0000000000f, 0.9675990939f, -0.2524915636f, 0.8724960089f, -0.4886212349f, 0.7208535671f, -0.6930873394f,
- 0.5224985480f, -0.8526401520f, 0.2902846634f, -0.9569403529f, 0.0392598175f, -0.9992290139f, -0.2143091559f, -0.9767658710f,
- -0.4539904892f, -0.8910065293f, -0.6642524600f, -0.7475083470f, -0.8314695954f, -0.5555702448f, -0.9448060393f, -0.3276301920f,
- -0.9969173074f, -0.0784590989f, -0.9844265580f, 0.1757962853f, -0.9081431627f, 0.4186597466f, -0.7730104327f, 0.6343932748f,
- -0.5877852440f, 0.8090170026f, -0.3644705117f, 0.9312149286f, -0.1175373942f, 0.9930684566f, 0.1370123476f, 0.9905693531f,
- 1.0000000000f, -0.0000000000f, 0.9624552131f, -0.2714404464f, 0.8526401520f, -0.5224985480f, 0.6788007617f, -0.7343224883f,
- 0.4539904892f, -0.8910065293f, 0.1950903237f, -0.9807852507f, -0.0784590989f, -0.9969173074f, -0.3461170495f, -0.9381913543f,
- -0.5877852440f, -0.8090170026f, -0.7853169441f, -0.6190939546f, -0.9238795042f, -0.3826834261f, -0.9930684566f, -0.1175373942f,
- -0.9876883626f, 0.1564344615f, -0.9081431627f, 0.4186597466f, -0.7604059577f, 0.6494480371f, -0.5555702448f, 0.8314695954f,
- -0.3090170026f, 0.9510565400f, -0.0392598175f, 0.9992290139f, 0.2334453613f, 0.9723699093f, 0.4886212349f, 0.8724960089f,
- 1.0000000000f, -0.0000000000f, 0.9569403529f, -0.2902846634f, 0.8314695954f, -0.5555702448f, 0.6343932748f, -0.7730104327f,
- 0.3826834261f, -0.9238795042f, 0.0980171412f, -0.9951847196f, -0.1950903237f, -0.9807852507f, -0.4713967443f, -0.8819212914f,
- -0.7071067691f, -0.7071067691f, -0.8819212914f, -0.4713967443f, -0.9807852507f, -0.1950903237f, -0.9951847196f, 0.0980171412f,
- -0.9238795042f, 0.3826834261f, -0.7730104327f, 0.6343932748f, -0.5555702448f, 0.8314695954f, -0.2902846634f, 0.9569403529f,
- 0.0000000000f, 1.0000000000f, 0.2902846634f, 0.9569403529f, 0.5555702448f, 0.8314695954f, 0.7730104327f, 0.6343932748f,
- 1.0000000000f, -0.0000000000f, 0.9999517798f, -0.0098173190f, 0.9998072386f, -0.0196336918f, 0.9995663166f, -0.0294481739f,
- 0.9992290139f, -0.0392598175f, 0.9987954497f, -0.0490676761f, 0.9982656240f, -0.0588708036f, 0.9976395369f, -0.0686682612f,
- 0.9969173074f, -0.0784590989f, 0.9960990548f, -0.0882423669f, 0.9951847196f, -0.0980171412f, 0.9941744804f, -0.1077824607f,
- 0.9930684566f, -0.1175373942f, 0.9918667078f, -0.1272810102f, 0.9905693531f, -0.1370123476f, 0.9891765118f, -0.1467304677f,
- 0.9876883626f, -0.1564344615f, 0.9861049652f, -0.1661233753f, 0.9844265580f, -0.1757962853f, 0.9826532602f, -0.1854522377f,
- 1.0000000000f, -0.0000000000f, 0.9995663166f, -0.0294481739f, 0.9982656240f, -0.0588708036f, 0.9960990548f, -0.0882423669f,
- 0.9930684566f, -0.1175373942f, 0.9891765118f, -0.1467304677f, 0.9844265580f, -0.1757962853f, 0.9788227677f, -0.2047096044f,
- 0.9723699093f, -0.2334453613f, 0.9650736451f, -0.2619786263f, 0.9569403529f, -0.2902846634f, 0.9479769468f, -0.3183389306f,
- 0.9381913543f, -0.3461170495f, 0.9275919199f, -0.3735949695f, 0.9161879420f, -0.4007488191f, 0.9039893150f, -0.4275550842f,
- 0.8910065293f, -0.4539904892f, 0.8772509098f, -0.4800321162f, 0.8627343774f, -0.5056573749f, 0.8474695683f, -0.5308440328f,
- 1.0000000000f, -0.0000000000f, 0.9987954497f, -0.0490676761f, 0.9951847196f, -0.0980171412f, 0.9891765118f, -0.1467304677f,
- 0.9807852507f, -0.1950903237f, 0.9700312614f, -0.2429801822f, 0.9569403529f, -0.2902846634f, 0.9415440559f, -0.3368898630f,
- 0.9238795042f, -0.3826834261f, 0.9039893150f, -0.4275550842f, 0.8819212914f, -0.4713967443f, 0.8577286005f, -0.5141027570f,
- 0.8314695954f, -0.5555702448f, 0.8032075167f, -0.5956993103f, 0.7730104327f, -0.6343932748f, 0.7409511209f, -0.6715589762f,
- 0.7071067691f, -0.7071067691f, 0.6715589762f, -0.7409511209f, 0.6343932748f, -0.7730104327f, 0.5956993103f, -0.8032075167f,
- 1.0000000000f, -0.0000000000f, 0.9976395369f, -0.0686682612f, 0.9905693531f, -0.1370123476f, 0.9788227677f, -0.2047096044f,
- 0.9624552131f, -0.2714404464f, 0.9415440559f, -0.3368898630f, 0.9161879420f, -0.4007488191f, 0.8865066171f, -0.4627159238f,
- 0.8526401520f, -0.5224985480f, 0.8147484660f, -0.5798145533f, 0.7730104327f, -0.6343932748f, 0.7276231050f, -0.6859771013f,
- 0.6788007617f, -0.7343224883f, 0.6267738342f, -0.7792012691f, 0.5717879534f, -0.8204014301f, 0.5141027570f, -0.8577286005f,
- 0.4539904892f, -0.8910065293f, 0.3917350173f, -0.9200780988f, 0.3276301920f, -0.9448060393f, 0.2619786263f, -0.9650736451f,
- 1.0000000000f, -0.0000000000f, 0.9960990548f, -0.0882423669f, 0.9844265580f, -0.1757962853f, 0.9650736451f, -0.2619786263f,
- 0.9381913543f, -0.3461170495f, 0.9039893150f, -0.4275550842f, 0.8627343774f, -0.5056573749f, 0.8147484660f, -0.5798145533f,
- 0.7604059577f, -0.6494480371f, 0.7001308203f, -0.7140145898f, 0.6343932748f, -0.7730104327f, 0.5637062788f, -0.8259753585f,
- 0.4886212349f, -0.8724960089f, 0.4097240269f, -0.9122095108f, 0.3276301920f, -0.9448060393f, 0.2429801822f, -0.9700312614f,
- 0.1564344615f, -0.9876883626f, 0.0686682612f, -0.9976395369f, -0.0196336918f, -0.9998072386f, -0.1077824607f, -0.9941744804f,
- 1.0000000000f, -0.0000000000f, 0.9941744804f, -0.1077824607f, 0.9767658710f, -0.2143091559f, 0.9479769468f, -0.3183389306f,
- 0.9081431627f, -0.4186597466f, 0.8577286005f, -0.5141027570f, 0.7973206639f, -0.6035559177f, 0.7276231050f, -0.6859771013f,
- 0.6494480371f, -0.7604059577f, 0.5637062788f, -0.8259753585f, 0.4713967443f, -0.8819212914f, 0.3735949695f, -0.9275919199f,
- 0.2714404464f, -0.9624552131f, 0.1661233753f, -0.9861049652f, 0.0588708036f, -0.9982656240f, -0.0490676761f, -0.9987954497f,
- -0.1564344615f, -0.9876883626f, -0.2619786263f, -0.9650736451f, -0.3644705117f, -0.9312149286f, -0.4627159238f, -0.8865066171f,
- 1.0000000000f, -0.0000000000f, 0.9918667078f, -0.1272810102f, 0.9675990939f, -0.2524915636f, 0.9275919199f, -0.3735949695f,
- 0.8724960089f, -0.4886212349f, 0.8032075167f, -0.5956993103f, 0.7208535671f, -0.6930873394f, 0.6267738342f, -0.7792012691f,
- 0.5224985480f, -0.8526401520f, 0.4097240269f, -0.9122095108f, 0.2902846634f, -0.9569403529f, 0.1661233753f, -0.9861049652f,
- 0.0392598175f, -0.9992290139f, -0.0882423669f, -0.9960990548f, -0.2143091559f, -0.9767658710f, -0.3368898630f, -0.9415440559f,
- -0.4539904892f, -0.8910065293f, -0.5637062788f, -0.8259753585f, -0.6642524600f, -0.7475083470f, -0.7539935112f, -0.6568819284f,
- 1.0000000000f, -0.0000000000f, 0.9891765118f, -0.1467304677f, 0.9569403529f, -0.2902846634f, 0.9039893150f, -0.4275550842f,
- 0.8314695954f, -0.5555702448f, 0.7409511209f, -0.6715589762f, 0.6343932748f, -0.7730104327f, 0.5141027570f, -0.8577286005f,
- 0.3826834261f, -0.9238795042f, 0.2429801822f, -0.9700312614f, 0.0980171412f, -0.9951847196f, -0.0490676761f, -0.9987954497f,
- -0.1950903237f, -0.9807852507f, -0.3368898630f, -0.9415440559f, -0.4713967443f, -0.8819212914f, -0.5956993103f, -0.8032075167f,
- -0.7071067691f, -0.7071067691f, -0.8032075167f, -0.5956993103f, -0.8819212914f, -0.4713967443f, -0.9415440559f, -0.3368898630f,
- 1.0000000000f, -0.0000000000f, 0.9861049652f, -0.1661233753f, 0.9448060393f, -0.3276301920f, 0.8772509098f, -0.4800321162f,
- 0.7853169441f, -0.6190939546f, 0.6715589762f, -0.7409511209f, 0.5391383171f, -0.8422172070f, 0.3917350173f, -0.9200780988f,
- 0.2334453613f, -0.9723699093f, 0.0686682612f, -0.9976395369f, -0.0980171412f, -0.9951847196f, -0.2619786263f, -0.9650736451f,
- -0.4186597466f, -0.9081431627f, -0.5637062788f, -0.8259753585f, -0.6930873394f, -0.7208535671f, -0.8032075167f, -0.5956993103f,
- -0.8910065293f, -0.4539904892f, -0.9540444016f, -0.2996652722f, -0.9905693531f, -0.1370123476f, -0.9995663166f, 0.0294481739f,
- 1.0000000000f, -0.0000000000f, 0.9826532602f, -0.1854522377f, 0.9312149286f, -0.3644705117f, 0.8474695683f, -0.5308440328f,
- 0.7343224883f, -0.6788007617f, 0.5956993103f, -0.8032075167f, 0.4364092350f, -0.8997482657f, 0.2619786263f, -0.9650736451f,
- 0.0784590989f, -0.9969173074f, -0.1077824607f, -0.9941744804f, -0.2902846634f, -0.9569403529f, -0.4627159238f, -0.8865066171f,
- -0.6190939546f, -0.7853169441f, -0.7539935112f, -0.6568819284f, -0.8627343774f, -0.5056573749f, -0.9415440559f, -0.3368898630f,
- -0.9876883626f, -0.1564344615f, -0.9995663166f, 0.0294481739f, -0.9767658710f, 0.2143091559f, -0.9200780988f, 0.3917350173f,
- 1.0000000000f, -0.0000000000f, 0.9788227677f, -0.2047096044f, 0.9161879420f, -0.4007488191f, 0.8147484660f, -0.5798145533f,
- 0.6788007617f, -0.7343224883f, 0.5141027570f, -0.8577286005f, 0.3276301920f, -0.9448060393f, 0.1272810102f, -0.9918667078f,
- -0.0784590989f, -0.9969173074f, -0.2808761001f, -0.9597440362f, -0.4713967443f, -0.8819212914f, -0.6419516206f, -0.7667451501f,
- -0.7853169441f, -0.6190939546f, -0.8954205513f, -0.4452213347f, -0.9675990939f, -0.2524915636f, -0.9987954497f, -0.0490676761f,
- -0.9876883626f, 0.1564344615f, -0.9347481728f, 0.3553108871f, -0.8422172070f, 0.5391383171f, -0.7140145898f, 0.7001308203f,
- 1.0000000000f, -0.0000000000f, 0.9746148586f, -0.2238880545f, 0.8997482657f, -0.4364092350f, 0.7792012691f, -0.6267738342f,
- 0.6190939546f, -0.7853169441f, 0.4275550842f, -0.9039893150f, 0.2143091559f, -0.9767658710f, -0.0098173190f, -0.9999517798f,
- -0.2334453613f, -0.9723699093f, -0.4452213347f, -0.8954205513f, -0.6343932748f, -0.7730104327f, -0.7913569212f, -0.6113544106f,
- -0.9081431627f, -0.4186597466f, -0.9788227677f, -0.2047096044f, -0.9998072386f, 0.0196336918f, -0.9700312614f, 0.2429801822f,
- -0.8910065293f, 0.4539904892f, -0.7667451501f, 0.6419516206f, -0.6035559177f, 0.7973206639f, -0.4097240269f, 0.9122095108f,
- 1.0000000000f, -0.0000000000f, 0.9700312614f, -0.2429801822f, 0.8819212914f, -0.4713967443f, 0.7409511209f, -0.6715589762f,
- 0.5555702448f, -0.8314695954f, 0.3368898630f, -0.9415440559f, 0.0980171412f, -0.9951847196f, -0.1467304677f, -0.9891765118f,
- -0.3826834261f, -0.9238795042f, -0.5956993103f, -0.8032075167f, -0.7730104327f, -0.6343932748f, -0.9039893150f, -0.4275550842f,
- -0.9807852507f, -0.1950903237f, -0.9987954497f, 0.0490676761f, -0.9569403529f, 0.2902846634f, -0.8577286005f, 0.5141027570f,
- -0.7071067691f, 0.7071067691f, -0.5141027570f, 0.8577286005f, -0.2902846634f, 0.9569403529f, -0.0490676761f, 0.9987954497f,
- 1.0000000000f, -0.0000000000f, 0.9650736451f, -0.2619786263f, 0.8627343774f, -0.5056573749f, 0.7001308203f, -0.7140145898f,
- 0.4886212349f, -0.8724960089f, 0.2429801822f, -0.9700312614f, -0.0196336918f, -0.9998072386f, -0.2808761001f, -0.9597440362f,
- -0.5224985480f, -0.8526401520f, -0.7276231050f, -0.6859771013f, -0.8819212914f, -0.4713967443f, -0.9746148586f, -0.2238880545f,
- -0.9992290139f, 0.0392598175f, -0.9540444016f, 0.2996652722f, -0.8422172070f, 0.5391383171f, -0.6715589762f, 0.7409511209f,
- -0.4539904892f, 0.8910065293f, -0.2047096044f, 0.9788227677f, 0.0588708036f, 0.9982656240f, 0.3183389306f, 0.9479769468f,
- 1.0000000000f, -0.0000000000f, 0.9597440362f, -0.2808761001f, 0.8422172070f, -0.5391383171f, 0.6568819284f, -0.7539935112f,
- 0.4186597466f, -0.9081431627f, 0.1467304677f, -0.9891765118f, -0.1370123476f, -0.9905693531f, -0.4097240269f, -0.9122095108f,
- -0.6494480371f, -0.7604059577f, -0.8368837237f, -0.5473806858f, -0.9569403529f, -0.2902846634f, -0.9999517798f, -0.0098173190f,
- -0.9624552131f, 0.2714404464f, -0.8474695683f, 0.5308440328f, -0.6642524600f, 0.7475083470f, -0.4275550842f, 0.9039893150f,
- -0.1564344615f, 0.9876883626f, 0.1272810102f, 0.9918667078f, 0.4007488191f, 0.9161879420f, 0.6419516206f, 0.7667451501f,
- 1.0000000000f, -0.0000000000f, 0.9540444016f, -0.2996652722f, 0.8204014301f, -0.5717879534f, 0.6113544106f, -0.7913569212f,
- 0.3461170495f, -0.9381913543f, 0.0490676761f, -0.9987954497f, -0.2524915636f, -0.9675990939f, -0.5308440328f, -0.8474695683f,
- -0.7604059577f, -0.6494480371f, -0.9200780988f, -0.3917350173f, -0.9951847196f, -0.0980171412f, -0.9788227677f, 0.2047096044f,
- -0.8724960089f, 0.4886212349f, -0.6859771013f, 0.7276231050f, -0.4364092350f, 0.8997482657f, -0.1467304677f, 0.9891765118f,
- 0.1564344615f, 0.9876883626f, 0.4452213347f, 0.8954205513f, 0.6930873394f, 0.7208535671f, 0.8772509098f, 0.4800321162f
-};
-
-const float FFT_RotVector_960[1860] = {
- 1.0000000000f, -0.0000000000f, 0.9999143481f, -0.0130895954f,
- 0.9996573329f, -0.0261769481f, 0.9992290139f, -0.0392598175f, 0.9986295104f, -0.0523359552f, 0.9978589416f, -0.0654031262f,
- 0.9969173074f, -0.0784590989f, 0.9958049059f, -0.0915016159f, 0.9945219159f, -0.1045284644f, 0.9930684566f, -0.1175373942f,
- 0.9914448857f, -0.1305261850f, 0.9896513820f, -0.1434926242f, 0.9876883626f, -0.1564344615f, 0.9855560660f, -0.1693495065f,
- 0.9832549095f, -0.1822355241f, 0.9807852507f, -0.1950903237f, 0.9781476259f, -0.2079116851f, 0.9753423333f, -0.2206974328f,
- 0.9723699093f, -0.2334453613f, 0.9692308903f, -0.2461532950f, 0.9659258127f, -0.2588190436f, 0.9624552131f, -0.2714404464f,
- 0.9588197470f, -0.2840153575f, 0.9550199509f, -0.2965415716f, 0.9510565400f, -0.3090170026f, 0.9469301105f, -0.3214394748f,
- 0.9426414967f, -0.3338068724f, 0.9381913543f, -0.3461170495f, 0.9335803986f, -0.3583679497f, 0.9288095236f, -0.3705574274f,
- 1.0000000000f, -0.0000000000f, 0.9996573329f, -0.0261769481f, 0.9986295104f, -0.0523359552f, 0.9969173074f, -0.0784590989f,
- 0.9945219159f, -0.1045284644f, 0.9914448857f, -0.1305261850f, 0.9876883626f, -0.1564344615f, 0.9832549095f, -0.1822355241f,
- 0.9781476259f, -0.2079116851f, 0.9723699093f, -0.2334453613f, 0.9659258127f, -0.2588190436f, 0.9588197470f, -0.2840153575f,
- 0.9510565400f, -0.3090170026f, 0.9426414967f, -0.3338068724f, 0.9335803986f, -0.3583679497f, 0.9238795042f, -0.3826834261f,
- 0.9135454297f, -0.4067366421f, 0.9025852680f, -0.4305110872f, 0.8910065293f, -0.4539904892f, 0.8788171411f, -0.4771587551f,
- 0.8660253882f, -0.5000000000f, 0.8526401520f, -0.5224985480f, 0.8386705518f, -0.5446390510f, 0.8241261840f, -0.5664062500f,
- 0.8090170026f, -0.5877852440f, 0.7933533192f, -0.6087614298f, 0.7771459818f, -0.6293203831f, 0.7604059577f, -0.6494480371f,
- 0.7431448102f, -0.6691306233f, 0.7253744006f, -0.6883545518f, 1.0000000000f, -0.0000000000f, 0.9992290139f, -0.0392598175f,
- 0.9969173074f, -0.0784590989f, 0.9930684566f, -0.1175373942f, 0.9876883626f, -0.1564344615f, 0.9807852507f, -0.1950903237f,
- 0.9723699093f, -0.2334453613f, 0.9624552131f, -0.2714404464f, 0.9510565400f, -0.3090170026f, 0.9381913543f, -0.3461170495f,
- 0.9238795042f, -0.3826834261f, 0.9081431627f, -0.4186597466f, 0.8910065293f, -0.4539904892f, 0.8724960089f, -0.4886212349f,
- 0.8526401520f, -0.5224985480f, 0.8314695954f, -0.5555702448f, 0.8090170026f, -0.5877852440f, 0.7853169441f, -0.6190939546f,
- 0.7604059577f, -0.6494480371f, 0.7343224883f, -0.6788007617f, 0.7071067691f, -0.7071067691f, 0.6788007617f, -0.7343224883f,
- 0.6494480371f, -0.7604059577f, 0.6190939546f, -0.7853169441f, 0.5877852440f, -0.8090170026f, 0.5555702448f, -0.8314695954f,
- 0.5224985480f, -0.8526401520f, 0.4886212349f, -0.8724960089f, 0.4539904892f, -0.8910065293f, 0.4186597466f, -0.9081431627f,
- 1.0000000000f, -0.0000000000f, 0.9986295104f, -0.0523359552f, 0.9945219159f, -0.1045284644f, 0.9876883626f, -0.1564344615f,
- 0.9781476259f, -0.2079116851f, 0.9659258127f, -0.2588190436f, 0.9510565400f, -0.3090170026f, 0.9335803986f, -0.3583679497f,
- 0.9135454297f, -0.4067366421f, 0.8910065293f, -0.4539904892f, 0.8660253882f, -0.5000000000f, 0.8386705518f, -0.5446390510f,
- 0.8090170026f, -0.5877852440f, 0.7771459818f, -0.6293203831f, 0.7431448102f, -0.6691306233f, 0.7071067691f, -0.7071067691f,
- 0.6691306233f, -0.7431448102f, 0.6293203831f, -0.7771459818f, 0.5877852440f, -0.8090170026f, 0.5446390510f, -0.8386705518f,
- 0.5000000000f, -0.8660253882f, 0.4539904892f, -0.8910065293f, 0.4067366421f, -0.9135454297f, 0.3583679497f, -0.9335803986f,
- 0.3090170026f, -0.9510565400f, 0.2588190436f, -0.9659258127f, 0.2079116851f, -0.9781476259f, 0.1564344615f, -0.9876883626f,
- 0.1045284644f, -0.9945219159f, 0.0523359552f, -0.9986295104f, 1.0000000000f, -0.0000000000f, 0.9978589416f, -0.0654031262f,
- 0.9914448857f, -0.1305261850f, 0.9807852507f, -0.1950903237f, 0.9659258127f, -0.2588190436f, 0.9469301105f, -0.3214394748f,
- 0.9238795042f, -0.3826834261f, 0.8968727589f, -0.4422886968f, 0.8660253882f, -0.5000000000f, 0.8314695954f, -0.5555702448f,
- 0.7933533192f, -0.6087614298f, 0.7518398166f, -0.6593458056f, 0.7071067691f, -0.7071067691f, 0.6593458056f, -0.7518398166f,
- 0.6087614298f, -0.7933533192f, 0.5555702448f, -0.8314695954f, 0.5000000000f, -0.8660253882f, 0.4422886968f, -0.8968727589f,
- 0.3826834261f, -0.9238795042f, 0.3214394748f, -0.9469301105f, 0.2588190436f, -0.9659258127f, 0.1950903237f, -0.9807852507f,
- 0.1305261850f, -0.9914448857f, 0.0654031262f, -0.9978589416f, -0.0000000000f, -1.0000000000f, -0.0654031262f, -0.9978589416f,
- -0.1305261850f, -0.9914448857f, -0.1950903237f, -0.9807852507f, -0.2588190436f, -0.9659258127f, -0.3214394748f, -0.9469301105f,
- 1.0000000000f, -0.0000000000f, 0.9969173074f, -0.0784590989f, 0.9876883626f, -0.1564344615f, 0.9723699093f, -0.2334453613f,
- 0.9510565400f, -0.3090170026f, 0.9238795042f, -0.3826834261f, 0.8910065293f, -0.4539904892f, 0.8526401520f, -0.5224985480f,
- 0.8090170026f, -0.5877852440f, 0.7604059577f, -0.6494480371f, 0.7071067691f, -0.7071067691f, 0.6494480371f, -0.7604059577f,
- 0.5877852440f, -0.8090170026f, 0.5224985480f, -0.8526401520f, 0.4539904892f, -0.8910065293f, 0.3826834261f, -0.9238795042f,
- 0.3090170026f, -0.9510565400f, 0.2334453613f, -0.9723699093f, 0.1564344615f, -0.9876883626f, 0.0784590989f, -0.9969173074f,
- -0.0000000000f, -1.0000000000f, -0.0784590989f, -0.9969173074f, -0.1564344615f, -0.9876883626f, -0.2334453613f, -0.9723699093f,
- -0.3090170026f, -0.9510565400f, -0.3826834261f, -0.9238795042f, -0.4539904892f, -0.8910065293f, -0.5224985480f, -0.8526401520f,
- -0.5877852440f, -0.8090170026f, -0.6494480371f, -0.7604059577f, 1.0000000000f, -0.0000000000f, 0.9958049059f, -0.0915016159f,
- 0.9832549095f, -0.1822355241f, 0.9624552131f, -0.2714404464f, 0.9335803986f, -0.3583679497f, 0.8968727589f, -0.4422886968f,
- 0.8526401520f, -0.5224985480f, 0.8012537956f, -0.5983245969f, 0.7431448102f, -0.6691306233f, 0.6788007617f, -0.7343224883f,
- 0.6087614298f, -0.7933533192f, 0.5336145163f, -0.8457278013f, 0.4539904892f, -0.8910065293f, 0.3705574274f, -0.9288095236f,
- 0.2840153575f, -0.9588197470f, 0.1950903237f, -0.9807852507f, 0.1045284644f, -0.9945219159f, 0.0130895954f, -0.9999143481f,
- -0.0784590989f, -0.9969173074f, -0.1693495065f, -0.9855560660f, -0.2588190436f, -0.9659258127f, -0.3461170495f, -0.9381913543f,
- -0.4305110872f, -0.9025852680f, -0.5112931132f, -0.8594064116f, -0.5877852440f, -0.8090170026f, -0.6593458056f, -0.7518398166f,
- -0.7253744006f, -0.6883545518f, -0.7853169441f, -0.6190939546f, -0.8386705518f, -0.5446390510f, -0.8849876523f, -0.4656145275f,
- 1.0000000000f, -0.0000000000f, 0.9945219159f, -0.1045284644f, 0.9781476259f, -0.2079116851f, 0.9510565400f, -0.3090170026f,
- 0.9135454297f, -0.4067366421f, 0.8660253882f, -0.5000000000f, 0.8090170026f, -0.5877852440f, 0.7431448102f, -0.6691306233f,
- 0.6691306233f, -0.7431448102f, 0.5877852440f, -0.8090170026f, 0.5000000000f, -0.8660253882f, 0.4067366421f, -0.9135454297f,
- 0.3090170026f, -0.9510565400f, 0.2079116851f, -0.9781476259f, 0.1045284644f, -0.9945219159f, -0.0000000000f, -1.0000000000f,
- -0.1045284644f, -0.9945219159f, -0.2079116851f, -0.9781476259f, -0.3090170026f, -0.9510565400f, -0.4067366421f, -0.9135454297f,
- -0.5000000000f, -0.8660253882f, -0.5877852440f, -0.8090170026f, -0.6691306233f, -0.7431448102f, -0.7431448102f, -0.6691306233f,
- -0.8090170026f, -0.5877852440f, -0.8660253882f, -0.5000000000f, -0.9135454297f, -0.4067366421f, -0.9510565400f, -0.3090170026f,
- -0.9781476259f, -0.2079116851f, -0.9945219159f, -0.1045284644f, 1.0000000000f, -0.0000000000f, 0.9930684566f, -0.1175373942f,
- 0.9723699093f, -0.2334453613f, 0.9381913543f, -0.3461170495f, 0.8910065293f, -0.4539904892f, 0.8314695954f, -0.5555702448f,
- 0.7604059577f, -0.6494480371f, 0.6788007617f, -0.7343224883f, 0.5877852440f, -0.8090170026f, 0.4886212349f, -0.8724960089f,
- 0.3826834261f, -0.9238795042f, 0.2714404464f, -0.9624552131f, 0.1564344615f, -0.9876883626f, 0.0392598175f, -0.9992290139f,
- -0.0784590989f, -0.9969173074f, -0.1950903237f, -0.9807852507f, -0.3090170026f, -0.9510565400f, -0.4186597466f, -0.9081431627f,
- -0.5224985480f, -0.8526401520f, -0.6190939546f, -0.7853169441f, -0.7071067691f, -0.7071067691f, -0.7853169441f, -0.6190939546f,
- -0.8526401520f, -0.5224985480f, -0.9081431627f, -0.4186597466f, -0.9510565400f, -0.3090170026f, -0.9807852507f, -0.1950903237f,
- -0.9969173074f, -0.0784590989f, -0.9992290139f, 0.0392598175f, -0.9876883626f, 0.1564344615f, -0.9624552131f, 0.2714404464f,
- 1.0000000000f, -0.0000000000f, 0.9914448857f, -0.1305261850f, 0.9659258127f, -0.2588190436f, 0.9238795042f, -0.3826834261f,
- 0.8660253882f, -0.5000000000f, 0.7933533192f, -0.6087614298f, 0.7071067691f, -0.7071067691f, 0.6087614298f, -0.7933533192f,
- 0.5000000000f, -0.8660253882f, 0.3826834261f, -0.9238795042f, 0.2588190436f, -0.9659258127f, 0.1305261850f, -0.9914448857f,
- -0.0000000000f, -1.0000000000f, -0.1305261850f, -0.9914448857f, -0.2588190436f, -0.9659258127f, -0.3826834261f, -0.9238795042f,
- -0.5000000000f, -0.8660253882f, -0.6087614298f, -0.7933533192f, -0.7071067691f, -0.7071067691f, -0.7933533192f, -0.6087614298f,
- -0.8660253882f, -0.5000000000f, -0.9238795042f, -0.3826834261f, -0.9659258127f, -0.2588190436f, -0.9914448857f, -0.1305261850f,
- -1.0000000000f, 0.0000000000f, -0.9914448857f, 0.1305261850f, -0.9659258127f, 0.2588190436f, -0.9238795042f, 0.3826834261f,
- -0.8660253882f, 0.5000000000f, -0.7933533192f, 0.6087614298f, 1.0000000000f, -0.0000000000f, 0.9896513820f, -0.1434926242f,
- 0.9588197470f, -0.2840153575f, 0.9081431627f, -0.4186597466f, 0.8386705518f, -0.5446390510f, 0.7518398166f, -0.6593458056f,
- 0.6494480371f, -0.7604059577f, 0.5336145163f, -0.8457278013f, 0.4067366421f, -0.9135454297f, 0.2714404464f, -0.9624552131f,
- 0.1305261850f, -0.9914448857f, -0.0130895954f, -0.9999143481f, -0.1564344615f, -0.9876883626f, -0.2965415716f, -0.9550199509f,
- -0.4305110872f, -0.9025852680f, -0.5555702448f, -0.8314695954f, -0.6691306233f, -0.7431448102f, -0.7688418031f, -0.6394389868f,
- -0.8526401520f, -0.5224985480f, -0.9187912345f, -0.3947438598f, -0.9659258127f, -0.2588190436f, -0.9930684566f, -0.1175373942f,
- -0.9996573329f, 0.0261769481f, -0.9855560660f, 0.1693495065f, -0.9510565400f, 0.3090170026f, -0.8968727589f, 0.4422886968f,
- -0.8241261840f, 0.5664062500f, -0.7343224883f, 0.6788007617f, -0.6293203831f, 0.7771459818f, -0.5112931132f, 0.8594064116f,
- 1.0000000000f, -0.0000000000f, 0.9876883626f, -0.1564344615f, 0.9510565400f, -0.3090170026f, 0.8910065293f, -0.4539904892f,
- 0.8090170026f, -0.5877852440f, 0.7071067691f, -0.7071067691f, 0.5877852440f, -0.8090170026f, 0.4539904892f, -0.8910065293f,
- 0.3090170026f, -0.9510565400f, 0.1564344615f, -0.9876883626f, -0.0000000000f, -1.0000000000f, -0.1564344615f, -0.9876883626f,
- -0.3090170026f, -0.9510565400f, -0.4539904892f, -0.8910065293f, -0.5877852440f, -0.8090170026f, -0.7071067691f, -0.7071067691f,
- -0.8090170026f, -0.5877852440f, -0.8910065293f, -0.4539904892f, -0.9510565400f, -0.3090170026f, -0.9876883626f, -0.1564344615f,
- -1.0000000000f, 0.0000000000f, -0.9876883626f, 0.1564344615f, -0.9510565400f, 0.3090170026f, -0.8910065293f, 0.4539904892f,
- -0.8090170026f, 0.5877852440f, -0.7071067691f, 0.7071067691f, -0.5877852440f, 0.8090170026f, -0.4539904892f, 0.8910065293f,
- -0.3090170026f, 0.9510565400f, -0.1564344615f, 0.9876883626f, 1.0000000000f, -0.0000000000f, 0.9855560660f, -0.1693495065f,
- 0.9426414967f, -0.3338068724f, 0.8724960089f, -0.4886212349f, 0.7771459818f, -0.6293203831f, 0.6593458056f, -0.7518398166f,
- 0.5224985480f, -0.8526401520f, 0.3705574274f, -0.9288095236f, 0.2079116851f, -0.9781476259f, 0.0392598175f, -0.9992290139f,
- -0.1305261850f, -0.9914448857f, -0.2965415716f, -0.9550199509f, -0.4539904892f, -0.8910065293f, -0.5983245969f, -0.8012537956f,
- -0.7253744006f, -0.6883545518f, -0.8314695954f, -0.5555702448f, -0.9135454297f, -0.4067366421f, -0.9692308903f, -0.2461532950f,
- -0.9969173074f, -0.0784590989f, -0.9958049059f, 0.0915016159f, -0.9659258127f, 0.2588190436f, -0.9081431627f, 0.4186597466f,
- -0.8241261840f, 0.5664062500f, -0.7163019180f, 0.6977904439f, -0.5877852440f, 0.8090170026f, -0.4422886968f, 0.8968727589f,
- -0.2840153575f, 0.9588197470f, -0.1175373942f, 0.9930684566f, 0.0523359552f, 0.9986295104f, 0.2206974328f, 0.9753423333f,
- 1.0000000000f, -0.0000000000f, 0.9832549095f, -0.1822355241f, 0.9335803986f, -0.3583679497f, 0.8526401520f, -0.5224985480f,
- 0.7431448102f, -0.6691306233f, 0.6087614298f, -0.7933533192f, 0.4539904892f, -0.8910065293f, 0.2840153575f, -0.9588197470f,
- 0.1045284644f, -0.9945219159f, -0.0784590989f, -0.9969173074f, -0.2588190436f, -0.9659258127f, -0.4305110872f, -0.9025852680f,
- -0.5877852440f, -0.8090170026f, -0.7253744006f, -0.6883545518f, -0.8386705518f, -0.5446390510f, -0.9238795042f, -0.3826834261f,
- -0.9781476259f, -0.2079116851f, -0.9996573329f, -0.0261769481f, -0.9876883626f, 0.1564344615f, -0.9426414967f, 0.3338068724f,
- -0.8660253882f, 0.5000000000f, -0.7604059577f, 0.6494480371f, -0.6293203831f, 0.7771459818f, -0.4771587551f, 0.8788171411f,
- -0.3090170026f, 0.9510565400f, -0.1305261850f, 0.9914448857f, 0.0523359552f, 0.9986295104f, 0.2334453613f, 0.9723699093f,
- 0.4067366421f, 0.9135454297f, 0.5664062500f, 0.8241261840f, 1.0000000000f, -0.0000000000f, 0.9807852507f, -0.1950903237f,
- 0.9238795042f, -0.3826834261f, 0.8314695954f, -0.5555702448f, 0.7071067691f, -0.7071067691f, 0.5555702448f, -0.8314695954f,
- 0.3826834261f, -0.9238795042f, 0.1950903237f, -0.9807852507f, -0.0000000000f, -1.0000000000f, -0.1950903237f, -0.9807852507f,
- -0.3826834261f, -0.9238795042f, -0.5555702448f, -0.8314695954f, -0.7071067691f, -0.7071067691f, -0.8314695954f, -0.5555702448f,
- -0.9238795042f, -0.3826834261f, -0.9807852507f, -0.1950903237f, -1.0000000000f, 0.0000000000f, -0.9807852507f, 0.1950903237f,
- -0.9238795042f, 0.3826834261f, -0.8314695954f, 0.5555702448f, -0.7071067691f, 0.7071067691f, -0.5555702448f, 0.8314695954f,
- -0.3826834261f, 0.9238795042f, -0.1950903237f, 0.9807852507f, 0.0000000000f, 1.0000000000f, 0.1950903237f, 0.9807852507f,
- 0.3826834261f, 0.9238795042f, 0.5555702448f, 0.8314695954f, 0.7071067691f, 0.7071067691f, 0.8314695954f, 0.5555702448f,
- 1.0000000000f, -0.0000000000f, 0.9999786019f, -0.0065449378f, 0.9999143481f, -0.0130895954f, 0.9998072386f, -0.0196336918f,
- 0.9996573329f, -0.0261769481f, 0.9994645715f, -0.0327190831f, 0.9992290139f, -0.0392598175f, 0.9989506602f, -0.0457988679f,
- 0.9986295104f, -0.0523359552f, 0.9982656240f, -0.0588708036f, 0.9978589416f, -0.0654031262f, 0.9974094629f, -0.0719326511f,
- 0.9969173074f, -0.0784590989f, 0.9963824749f, -0.0849821791f, 0.9958049059f, -0.0915016159f, 0.9951847196f, -0.0980171412f,
- 0.9945219159f, -0.1045284644f, 0.9938164353f, -0.1110353097f, 0.9930684566f, -0.1175373942f, 0.9922779202f, -0.1240344495f,
- 0.9914448857f, -0.1305261850f, 0.9905693531f, -0.1370123476f, 0.9896513820f, -0.1434926242f, 0.9886910319f, -0.1499667615f,
- 0.9876883626f, -0.1564344615f, 0.9866433144f, -0.1628954709f, 0.9855560660f, -0.1693495065f, 0.9844265580f, -0.1757962853f,
- 0.9832549095f, -0.1822355241f, 0.9820411205f, -0.1886669695f, 1.0000000000f, -0.0000000000f, 0.9998072386f, -0.0196336918f,
- 0.9992290139f, -0.0392598175f, 0.9982656240f, -0.0588708036f, 0.9969173074f, -0.0784590989f, 0.9951847196f, -0.0980171412f,
- 0.9930684566f, -0.1175373942f, 0.9905693531f, -0.1370123476f, 0.9876883626f, -0.1564344615f, 0.9844265580f, -0.1757962853f,
- 0.9807852507f, -0.1950903237f, 0.9767658710f, -0.2143091559f, 0.9723699093f, -0.2334453613f, 0.9675990939f, -0.2524915636f,
- 0.9624552131f, -0.2714404464f, 0.9569403529f, -0.2902846634f, 0.9510565400f, -0.3090170026f, 0.9448060393f, -0.3276301920f,
- 0.9381913543f, -0.3461170495f, 0.9312149286f, -0.3644705117f, 0.9238795042f, -0.3826834261f, 0.9161879420f, -0.4007488191f,
- 0.9081431627f, -0.4186597466f, 0.8997482657f, -0.4364092350f, 0.8910065293f, -0.4539904892f, 0.8819212914f, -0.4713967443f,
- 0.8724960089f, -0.4886212349f, 0.8627343774f, -0.5056573749f, 0.8526401520f, -0.5224985480f, 0.8422172070f, -0.5391383171f,
- 1.0000000000f, -0.0000000000f, 0.9994645715f, -0.0327190831f, 0.9978589416f, -0.0654031262f, 0.9951847196f, -0.0980171412f,
- 0.9914448857f, -0.1305261850f, 0.9866433144f, -0.1628954709f, 0.9807852507f, -0.1950903237f, 0.9738769531f, -0.2270762622f,
- 0.9659258127f, -0.2588190436f, 0.9569403529f, -0.2902846634f, 0.9469301105f, -0.3214394748f, 0.9359059334f, -0.3522500396f,
- 0.9238795042f, -0.3826834261f, 0.9108638167f, -0.4127070308f, 0.8968727589f, -0.4422886968f, 0.8819212914f, -0.4713967443f,
- 0.8660253882f, -0.5000000000f, 0.8492021561f, -0.5280678272f, 0.8314695954f, -0.5555702448f, 0.8128466606f, -0.5824776888f,
- 0.7933533192f, -0.6087614298f, 0.7730104327f, -0.6343932748f, 0.7518398166f, -0.6593458056f, 0.7298640609f, -0.6835923195f,
- 0.7071067691f, -0.7071067691f, 0.6835923195f, -0.7298640609f, 0.6593458056f, -0.7518398166f, 0.6343932748f, -0.7730104327f,
- 0.6087614298f, -0.7933533192f, 0.5824776888f, -0.8128466606f, 1.0000000000f, -0.0000000000f, 0.9989506602f, -0.0457988679f,
- 0.9958049059f, -0.0915016159f, 0.9905693531f, -0.1370123476f, 0.9832549095f, -0.1822355241f, 0.9738769531f, -0.2270762622f,
- 0.9624552131f, -0.2714404464f, 0.9490136504f, -0.3152349889f, 0.9335803986f, -0.3583679497f, 0.9161879420f, -0.4007488191f,
- 0.8968727589f, -0.4422886968f, 0.8756753206f, -0.4829003513f, 0.8526401520f, -0.5224985480f, 0.8278156519f, -0.5610002279f,
- 0.8012537956f, -0.5983245969f, 0.7730104327f, -0.6343932748f, 0.7431448102f, -0.6691306233f, 0.7117196321f, -0.7024636865f,
- 0.6788007617f, -0.7343224883f, 0.6444573402f, -0.7646402717f, 0.6087614298f, -0.7933533192f, 0.5717879534f, -0.8204014301f,
- 0.5336145163f, -0.8457278013f, 0.4943211973f, -0.8692793250f, 0.4539904892f, -0.8910065293f, 0.4127070308f, -0.9108638167f,
- 0.3705574274f, -0.9288095236f, 0.3276301920f, -0.9448060393f, 0.2840153575f, -0.9588197470f, 0.2398044616f, -0.9708212018f,
- 1.0000000000f, -0.0000000000f, 0.9982656240f, -0.0588708036f, 0.9930684566f, -0.1175373942f, 0.9844265580f, -0.1757962853f,
- 0.9723699093f, -0.2334453613f, 0.9569403529f, -0.2902846634f, 0.9381913543f, -0.3461170495f, 0.9161879420f, -0.4007488191f,
- 0.8910065293f, -0.4539904892f, 0.8627343774f, -0.5056573749f, 0.8314695954f, -0.5555702448f, 0.7973206639f, -0.6035559177f,
- 0.7604059577f, -0.6494480371f, 0.7208535671f, -0.6930873394f, 0.6788007617f, -0.7343224883f, 0.6343932748f, -0.7730104327f,
- 0.5877852440f, -0.8090170026f, 0.5391383171f, -0.8422172070f, 0.4886212349f, -0.8724960089f, 0.4364092350f, -0.8997482657f,
- 0.3826834261f, -0.9238795042f, 0.3276301920f, -0.9448060393f, 0.2714404464f, -0.9624552131f, 0.2143091559f, -0.9767658710f,
- 0.1564344615f, -0.9876883626f, 0.0980171412f, -0.9951847196f, 0.0392598175f, -0.9992290139f, -0.0196336918f, -0.9998072386f,
- -0.0784590989f, -0.9969173074f, -0.1370123476f, -0.9905693531f, 1.0000000000f, -0.0000000000f, 0.9974094629f, -0.0719326511f,
- 0.9896513820f, -0.1434926242f, 0.9767658710f, -0.2143091559f, 0.9588197470f, -0.2840153575f, 0.9359059334f, -0.3522500396f,
- 0.9081431627f, -0.4186597466f, 0.8756753206f, -0.4829003513f, 0.8386705518f, -0.5446390510f, 0.7973206639f, -0.6035559177f,
- 0.7518398166f, -0.6593458056f, 0.7024636865f, -0.7117196321f, 0.6494480371f, -0.7604059577f, 0.5930676460f, -0.8051526546f,
- 0.5336145163f, -0.8457278013f, 0.4713967443f, -0.8819212914f, 0.4067366421f, -0.9135454297f, 0.3399692476f, -0.9404365420f,
- 0.2714404464f, -0.9624552131f, 0.2015053183f, -0.9794874191f, 0.1305261850f, -0.9914448857f, 0.0588708036f, -0.9982656240f,
- -0.0130895954f, -0.9999143481f, -0.0849821791f, -0.9963824749f, -0.1564344615f, -0.9876883626f, -0.2270762622f, -0.9738769531f,
- -0.2965415716f, -0.9550199509f, -0.3644705117f, -0.9312149286f, -0.4305110872f, -0.9025852680f, -0.4943211973f, -0.8692793250f,
- 1.0000000000f, -0.0000000000f, 0.9963824749f, -0.0849821791f, 0.9855560660f, -0.1693495065f, 0.9675990939f, -0.2524915636f,
- 0.9426414967f, -0.3338068724f, 0.9108638167f, -0.4127070308f, 0.8724960089f, -0.4886212349f, 0.8278156519f, -0.5610002279f,
- 0.7771459818f, -0.6293203831f, 0.7208535671f, -0.6930873394f, 0.6593458056f, -0.7518398166f, 0.5930676460f, -0.8051526546f,
- 0.5224985480f, -0.8526401520f, 0.4481492043f, -0.8939588070f, 0.3705574274f, -0.9288095236f, 0.2902846634f, -0.9569403529f,
- 0.2079116851f, -0.9781476259f, 0.1240344495f, -0.9922779202f, 0.0392598175f, -0.9992290139f, -0.0457988679f, -0.9989506602f,
- -0.1305261850f, -0.9914448857f, -0.2143091559f, -0.9767658710f, -0.2965415716f, -0.9550199509f, -0.3766284883f, -0.9263643622f,
- -0.4539904892f, -0.8910065293f, -0.5280678272f, -0.8492021561f, -0.5983245969f, -0.8012537956f, -0.6642524600f, -0.7475083470f,
- -0.7253744006f, -0.6883545518f, -0.7812481523f, -0.6242205501f, 1.0000000000f, -0.0000000000f, 0.9951847196f, -0.0980171412f,
- 0.9807852507f, -0.1950903237f, 0.9569403529f, -0.2902846634f, 0.9238795042f, -0.3826834261f, 0.8819212914f, -0.4713967443f,
- 0.8314695954f, -0.5555702448f, 0.7730104327f, -0.6343932748f, 0.7071067691f, -0.7071067691f, 0.6343932748f, -0.7730104327f,
- 0.5555702448f, -0.8314695954f, 0.4713967443f, -0.8819212914f, 0.3826834261f, -0.9238795042f, 0.2902846634f, -0.9569403529f,
- 0.1950903237f, -0.9807852507f, 0.0980171412f, -0.9951847196f, -0.0000000000f, -1.0000000000f, -0.0980171412f, -0.9951847196f,
- -0.1950903237f, -0.9807852507f, -0.2902846634f, -0.9569403529f, -0.3826834261f, -0.9238795042f, -0.4713967443f, -0.8819212914f,
- -0.5555702448f, -0.8314695954f, -0.6343932748f, -0.7730104327f, -0.7071067691f, -0.7071067691f, -0.7730104327f, -0.6343932748f,
- -0.8314695954f, -0.5555702448f, -0.8819212914f, -0.4713967443f, -0.9238795042f, -0.3826834261f, -0.9569403529f, -0.2902846634f,
- 1.0000000000f, -0.0000000000f, 0.9938164353f, -0.1110353097f, 0.9753423333f, -0.2206974328f, 0.9448060393f, -0.3276301920f,
- 0.9025852680f, -0.4305110872f, 0.8492021561f, -0.5280678272f, 0.7853169441f, -0.6190939546f, 0.7117196321f, -0.7024636865f,
- 0.6293203831f, -0.7771459818f, 0.5391383171f, -0.8422172070f, 0.4422886968f, -0.8968727589f, 0.3399692476f, -0.9404365420f,
- 0.2334453613f, -0.9723699093f, 0.1240344495f, -0.9922779202f, 0.0130895954f, -0.9999143481f, -0.0980171412f, -0.9951847196f,
- -0.2079116851f, -0.9781476259f, -0.3152349889f, -0.9490136504f, -0.4186597466f, -0.9081431627f, -0.5169069171f, -0.8560416102f,
- -0.6087614298f, -0.7933533192f, -0.6930873394f, -0.7208535671f, -0.7688418031f, -0.6394389868f, -0.8350879550f, -0.5501164198f,
- -0.8910065293f, -0.4539904892f, -0.9359059334f, -0.3522500396f, -0.9692308903f, -0.2461532950f, -0.9905693531f, -0.1370123476f,
- -0.9996573329f, -0.0261769481f, -0.9963824749f, 0.0849821791f, 1.0000000000f, -0.0000000000f, 0.9922779202f, -0.1240344495f,
- 0.9692308903f, -0.2461532950f, 0.9312149286f, -0.3644705117f, 0.8788171411f, -0.4771587551f, 0.8128466606f, -0.5824776888f,
- 0.7343224883f, -0.6788007617f, 0.6444573402f, -0.7646402717f, 0.5446390510f, -0.8386705518f, 0.4364092350f, -0.8997482657f,
- 0.3214394748f, -0.9469301105f, 0.2015053183f, -0.9794874191f, 0.0784590989f, -0.9969173074f, -0.0457988679f, -0.9989506602f,
- -0.1693495065f, -0.9855560660f, -0.2902846634f, -0.9569403529f, -0.4067366421f, -0.9135454297f, -0.5169069171f, -0.8560416102f,
- -0.6190939546f, -0.7853169441f, -0.7117196321f, -0.7024636865f, -0.7933533192f, -0.6087614298f, -0.8627343774f, -0.5056573749f,
- -0.9187912345f, -0.3947438598f, -0.9606580734f, -0.2777338326f, -0.9876883626f, -0.1564344615f, -0.9994645715f, -0.0327190831f,
- -0.9958049059f, 0.0915016159f, -0.9767658710f, 0.2143091559f, -0.9426414967f, 0.3338068724f, -0.8939588070f, 0.4481492043f,
- 1.0000000000f, -0.0000000000f, 0.9905693531f, -0.1370123476f, 0.9624552131f, -0.2714404464f, 0.9161879420f, -0.4007488191f,
- 0.8526401520f, -0.5224985480f, 0.7730104327f, -0.6343932748f, 0.6788007617f, -0.7343224883f, 0.5717879534f, -0.8204014301f,
- 0.4539904892f, -0.8910065293f, 0.3276301920f, -0.9448060393f, 0.1950903237f, -0.9807852507f, 0.0588708036f, -0.9982656240f,
- -0.0784590989f, -0.9969173074f, -0.2143091559f, -0.9767658710f, -0.3461170495f, -0.9381913543f, -0.4713967443f, -0.8819212914f,
- -0.5877852440f, -0.8090170026f, -0.6930873394f, -0.7208535671f, -0.7853169441f, -0.6190939546f, -0.8627343774f, -0.5056573749f,
- -0.9238795042f, -0.3826834261f, -0.9675990939f, -0.2524915636f, -0.9930684566f, -0.1175373942f, -0.9998072386f, 0.0196336918f,
- -0.9876883626f, 0.1564344615f, -0.9569403529f, 0.2902846634f, -0.9081431627f, 0.4186597466f, -0.8422172070f, 0.5391383171f,
- -0.7604059577f, 0.6494480371f, -0.6642524600f, 0.7475083470f, 1.0000000000f, -0.0000000000f, 0.9886910319f, -0.1499667615f,
- 0.9550199509f, -0.2965415716f, 0.8997482657f, -0.4364092350f, 0.8241261840f, -0.5664062500f, 0.7298640609f, -0.6835923195f,
- 0.6190939546f, -0.7853169441f, 0.4943211973f, -0.8692793250f, 0.3583679497f, -0.9335803986f, 0.2143091559f, -0.9767658710f,
- 0.0654031262f, -0.9978589416f, -0.0849821791f, -0.9963824749f, -0.2334453613f, -0.9723699093f, -0.3766284883f, -0.9263643622f,
- -0.5112931132f, -0.8594064116f, -0.6343932748f, -0.7730104327f, -0.7431448102f, -0.6691306233f, -0.8350879550f, -0.5501164198f,
- -0.9081431627f, -0.4186597466f, -0.9606580734f, -0.2777338326f, -0.9914448857f, -0.1305261850f, -0.9998072386f, 0.0196336918f,
- -0.9855560660f, 0.1693495065f, -0.9490136504f, 0.3152349889f, -0.8910065293f, 0.4539904892f, -0.8128466606f, 0.5824776888f,
- -0.7163019180f, 0.6977904439f, -0.6035559177f, 0.7973206639f, -0.4771587551f, 0.8788171411f, -0.3399692476f, 0.9404365420f,
- 1.0000000000f, -0.0000000000f, 0.9866433144f, -0.1628954709f, 0.9469301105f, -0.3214394748f, 0.8819212914f, -0.4713967443f,
- 0.7933533192f, -0.6087614298f, 0.6835923195f, -0.7298640609f, 0.5555702448f, -0.8314695954f, 0.4127070308f, -0.9108638167f,
- 0.2588190436f, -0.9659258127f, 0.0980171412f, -0.9951847196f, -0.0654031262f, -0.9978589416f, -0.2270762622f, -0.9738769531f,
- -0.3826834261f, -0.9238795042f, -0.5280678272f, -0.8492021561f, -0.6593458056f, -0.7518398166f, -0.7730104327f, -0.6343932748f,
- -0.8660253882f, -0.5000000000f, -0.9359059334f, -0.3522500396f, -0.9807852507f, -0.1950903237f, -0.9994645715f, -0.0327190831f,
- -0.9914448857f, 0.1305261850f, -0.9569403529f, 0.2902846634f, -0.8968727589f, 0.4422886968f, -0.8128466606f, 0.5824776888f,
- -0.7071067691f, 0.7071067691f, -0.5824776888f, 0.8128466606f, -0.4422886968f, 0.8968727589f, -0.2902846634f, 0.9569403529f,
- -0.1305261850f, 0.9914448857f, 0.0327190831f, 0.9994645715f, 1.0000000000f, -0.0000000000f, 0.9844265580f, -0.1757962853f,
- 0.9381913543f, -0.3461170495f, 0.8627343774f, -0.5056573749f, 0.7604059577f, -0.6494480371f, 0.6343932748f, -0.7730104327f,
- 0.4886212349f, -0.8724960089f, 0.3276301920f, -0.9448060393f, 0.1564344615f, -0.9876883626f, -0.0196336918f, -0.9998072386f,
- -0.1950903237f, -0.9807852507f, -0.3644705117f, -0.9312149286f, -0.5224985480f, -0.8526401520f, -0.6642524600f, -0.7475083470f,
- -0.7853169441f, -0.6190939546f, -0.8819212914f, -0.4713967443f, -0.9510565400f, -0.3090170026f, -0.9905693531f, -0.1370123476f,
- -0.9992290139f, 0.0392598175f, -0.9767658710f, 0.2143091559f, -0.9238795042f, 0.3826834261f, -0.8422172070f, 0.5391383171f,
- -0.7343224883f, 0.6788007617f, -0.6035559177f, 0.7973206639f, -0.4539904892f, 0.8910065293f, -0.2902846634f, 0.9569403529f,
- -0.1175373942f, 0.9930684566f, 0.0588708036f, 0.9982656240f, 0.2334453613f, 0.9723699093f, 0.4007488191f, 0.9161879420f,
- 1.0000000000f, -0.0000000000f, 0.9820411205f, -0.1886669695f, 0.9288095236f, -0.3705574274f, 0.8422172070f, -0.5391383171f,
- 0.7253744006f, -0.6883545518f, 0.5824776888f, -0.8128466606f, 0.4186597466f, -0.9081431627f, 0.2398044616f, -0.9708212018f,
- 0.0523359552f, -0.9986295104f, -0.1370123476f, -0.9905693531f, -0.3214394748f, -0.9469301105f, -0.4943211973f, -0.8692793250f,
- -0.6494480371f, -0.7604059577f, -0.7812481523f, -0.6242205501f, -0.8849876523f, -0.4656145275f, -0.9569403529f, -0.2902846634f,
- -0.9945219159f, -0.1045284644f, -0.9963824749f, 0.0849821791f, -0.9624552131f, 0.2714404464f, -0.8939588070f, 0.4481492043f,
- -0.7933533192f, 0.6087614298f, -0.6642524600f, 0.7475083470f, -0.5112931132f, 0.8594064116f, -0.3399692476f, 0.9404365420f,
- -0.1564344615f, 0.9876883626f, 0.0327190831f, 0.9994645715f, 0.2206974328f, 0.9753423333f, 0.4007488191f, 0.9161879420f,
- 0.5664062500f, 0.8241261840f, 0.7117196321f, 0.7024636865f, 1.0000000000f, -0.0000000000f, 0.9794874191f, -0.2015053183f,
- 0.9187912345f, -0.3947438598f, 0.8204014301f, -0.5717879534f, 0.6883545518f, -0.7253744006f, 0.5280678272f, -0.8492021561f,
- 0.3461170495f, -0.9381913543f, 0.1499667615f, -0.9886910319f, -0.0523359552f, -0.9986295104f, -0.2524915636f, -0.9675990939f,
- -0.4422886968f, -0.8968727589f, -0.6139408350f, -0.7893520594f, -0.7604059577f, -0.6494480371f, -0.8756753206f, -0.4829003513f,
- -0.9550199509f, -0.2965415716f, -0.9951847196f, -0.0980171412f, -0.9945219159f, 0.1045284644f, -0.9530586600f, 0.3027857840f,
- -0.8724960089f, 0.4886212349f, -0.7561390996f, 0.6544109583f, -0.6087614298f, 0.7933533192f, -0.4364092350f, 0.8997482657f,
- -0.2461532950f, 0.9692308903f, -0.0457988679f, 0.9989506602f, 0.1564344615f, 0.9876883626f, 0.3522500396f, 0.9359059334f,
- 0.5336145163f, 0.8457278013f, 0.6930873394f, 0.7208535671f, 0.8241261840f, 0.5664062500f, 0.9213551283f, 0.3887219727f
-};
-
-
/* HVQ */
const Word16 hvq_thr_adj_fx[5] = { 23170, 16384, 8192, 16384, 23170 }; /* Q15 */
@@ -21902,58 +19303,6 @@ const Word16 cu4_fx[6][3] = /*Q13*/
const Word16 h_high_fx[5] = { -410, -3572, 25602, -3572, -410 };//Q15
-const float sincos_t_rad3[T_SIN_PI_2+1] =
-{
- 0.000000000000000f, 0.004090604026235f, 0.008181139603937f, 0.012271538285720f, 0.016361731626487f, 0.020451651184577f, 0.024541228522912f, 0.028630395210139f,
- 0.032719082821776f, 0.036807222941359f, 0.040894747161583f, 0.044981587085452f, 0.049067674327418f, 0.053152940514528f, 0.057237317287569f, 0.061320736302209f,
- 0.065403129230143f, 0.069484427760237f, 0.073564563599667f, 0.077643468475068f, 0.081721074133668f, 0.085797312344440f, 0.089872114899235f, 0.093945413613929f,
- 0.098017140329561f, 0.102087226913474f, 0.106155605260457f, 0.110222207293883f, 0.114286964966846f, 0.118349810263305f, 0.122410675199216f, 0.126469491823675f,
- 0.130526192220052f, 0.134580708507126f, 0.138632972840227f, 0.142682917412363f, 0.146730474455362f, 0.150775576241001f, 0.154818155082141f, 0.158858143333861f,
- 0.162895473394589f, 0.166930077707230f, 0.170961888760301f, 0.174990839089060f, 0.179016861276633f, 0.183039887955141f, 0.187059851806832f, 0.191076685565203f,
- 0.195090322016128f, 0.199100693998982f, 0.203107734407763f, 0.207111376192219f, 0.211111552358965f, 0.215108195972610f, 0.219101240156870f, 0.223090618095693f,
- 0.227076263034373f, 0.231058108280671f, 0.235036087205927f, 0.239010133246176f, 0.242980179903264f, 0.246946160745958f, 0.250908009411060f, 0.254865659604515f,
- 0.258819045102521f, 0.262768099752639f, 0.266712757474898f, 0.270652952262902f, 0.274588618184932f, 0.278519689385053f, 0.282446100084213f, 0.286367784581343f,
- 0.290284677254462f, 0.294196712561769f, 0.298103825042740f, 0.302005949319228f, 0.305903020096553f, 0.309794972164597f, 0.313681740398891f, 0.317563259761712f,
- 0.321439465303162f, 0.325310292162263f, 0.329175675568039f, 0.333035550840599f, 0.336889853392220f, 0.340738518728429f, 0.344581482449080f, 0.348418680249435f,
- 0.352250047921233f, 0.356075521353776f, 0.359895036534988f, 0.363708529552498f, 0.367515936594704f, 0.371317193951837f, 0.375112238017038f, 0.378901005287410f,
- 0.382683432365090f, 0.386459455958303f, 0.390229012882428f, 0.393992040061048f, 0.397748474527011f, 0.401498253423481f, 0.405241314004990f, 0.408977593638489f,
- 0.412707029804395f, 0.416429560097637f, 0.420145122228702f, 0.423853654024676f, 0.427555093430282f, 0.431249378508924f, 0.434936447443717f, 0.438616238538528f,
- 0.442288690219001f, 0.445953741033595f, 0.449611329654607f, 0.453261394879198f, 0.456903875630421f, 0.460538710958240f, 0.464165840040552f, 0.467785202184201f,
- 0.471396736825998f, 0.475000383533732f, 0.478596082007181f, 0.482183772079123f, 0.485763393716340f, 0.489334887020625f, 0.492898192229784f, 0.496453249718633f,
- 0.500000000000000f, 0.503538383725718f, 0.507068341687617f, 0.510589814818519f, 0.514102744193222f, 0.517607071029487f, 0.521102736689023f, 0.524589682678469f,
- 0.528067850650368f, 0.531537182404149f, 0.534997619887097f, 0.538449105195327f, 0.541891580574752f, 0.545324988422046f, 0.548749271285616f, 0.552164371866554f,
- 0.555570233019602f, 0.558966797754107f, 0.562354009234973f, 0.565731810783613f, 0.569100145878898f, 0.572458958158102f, 0.575808191417845f, 0.579147789615035f,
- 0.582477696867802f, 0.585797857456439f, 0.589108215824328f, 0.592408716578875f, 0.595699304492433f, 0.598979924503229f, 0.602250521716282f, 0.605511041404326f,
- 0.608761429008721f, 0.612001630140370f, 0.615231590580627f, 0.618451256282204f, 0.621660573370077f, 0.624859488142386f, 0.628047947071334f, 0.631225896804083f,
- 0.634393284163645f, 0.637550056149777f, 0.640696159939861f, 0.643831542889791f, 0.646956152534857f, 0.650069936590618f, 0.653172842953777f, 0.656264819703058f,
- 0.659345815100069f, 0.662415777590172f, 0.665474655803342f, 0.668522398555031f, 0.671558954847018f, 0.674584273868271f, 0.677598304995789f, 0.680600997795453f,
- 0.683592302022871f, 0.686572167624217f, 0.689540544737067f, 0.692497383691237f, 0.695442635009612f, 0.698376249408973f, 0.701298177800824f, 0.704208371292213f,
- 0.707106781186547f, 0.709993358984412f, 0.712868056384380f, 0.715730825283819f, 0.718581617779698f, 0.721420386169390f, 0.724247082951467f, 0.727061660826497f,
- 0.729864072697836f, 0.732654271672413f, 0.735432211061519f, 0.738197844381584f, 0.740951125354959f, 0.743692007910687f, 0.746420446185274f, 0.749136394523459f,
- 0.751839807478977f, 0.754530639815318f, 0.757208846506485f, 0.759874382737746f, 0.762527203906388f, 0.765167265622459f, 0.767794523709512f, 0.770408934205345f,
- 0.773010453362737f, 0.775599037650177f, 0.778174643752598f, 0.780737228572094f, 0.783286749228650f, 0.785823163060853f, 0.788346427626606f, 0.790856500703845f,
- 0.793353340291235f, 0.795836904608884f, 0.798307152099031f, 0.800764041426753f, 0.803207531480645f, 0.805637581373517f, 0.808054150443073f, 0.810457198252595f,
- 0.812846684591615f, 0.815222569476594f, 0.817584813151584f, 0.819933376088899f, 0.822268218989775f, 0.824589302785025f, 0.826896588635696f, 0.829190037933717f,
- 0.831469612302545f, 0.833735273597809f, 0.835986983907947f, 0.838224705554838f, 0.840448401094438f, 0.842658033317402f, 0.844853565249707f, 0.847034960153274f,
- 0.849202181526579f, 0.851355193105265f, 0.853493958862750f, 0.855618443010829f, 0.857728610000272f, 0.859824424521420f, 0.861905851504774f, 0.863972856121587f,
- 0.866025403784439f, 0.868063460147822f, 0.870086991108711f, 0.872095962807139f, 0.874090341626759f, 0.876070094195407f, 0.878035187385663f, 0.879985588315404f,
- 0.881921264348355f, 0.883842183094633f, 0.885748312411290f, 0.887639620402854f, 0.889516075421856f, 0.891377646069366f, 0.893224301195515f, 0.895056009900018f,
- 0.896872741532688f, 0.898674465693954f, 0.900461152235364f, 0.902232771260093f, 0.903989293123443f, 0.905730688433339f, 0.907456928050819f, 0.909167983090522f,
- 0.910863824921176f, 0.912544425166069f, 0.914209755703531f, 0.915859788667400f, 0.917494496447491f, 0.919113851690058f, 0.920717827298248f, 0.922306396432559f,
- 0.923879532511287f, 0.925437209210971f, 0.926979400466833f, 0.928506080473216f, 0.930017223684012f, 0.931512804813095f, 0.932992798834739f, 0.934457180984039f,
- 0.935905926757326f, 0.937339011912575f, 0.938756412469813f, 0.940158104711519f, 0.941544065183021f, 0.942914270692887f, 0.944268698313317f, 0.945607325380521f,
- 0.946930129495106f, 0.948237088522441f, 0.949528180593037f, 0.950803384102905f, 0.952062677713924f, 0.953306040354194f, 0.954533451218389f, 0.955744889768105f,
- 0.956940335732209f, 0.958119769107168f, 0.959283170157394f, 0.960430519415566f, 0.961561797682962f, 0.962676986029777f, 0.963776065795440f, 0.964859018588927f,
- 0.965925826289068f, 0.966976471044852f, 0.968010935275723f, 0.969029201671875f, 0.970031253194544f, 0.971017073076290f, 0.971986644821279f, 0.972939952205560f,
- 0.973876979277334f, 0.974797710357222f, 0.975702130038528f, 0.976590223187499f, 0.977461974943572f, 0.978317370719628f, 0.979156396202234f, 0.979979037351883f,
- 0.980785280403230f, 0.981575111865320f, 0.982348518521816f, 0.983105487431216f, 0.983846005927077f, 0.984570061618220f, 0.985277642388941f, 0.985968736399212f,
- 0.986643332084879f, 0.987301418157858f, 0.987942983606322f, 0.988568017694885f, 0.989176509964781f, 0.989768450234042f, 0.990343828597665f, 0.990902635427780f,
- 0.991444861373810f, 0.991970497362629f, 0.992479534598710f, 0.992971964564277f, 0.993447779019444f, 0.993906970002356f, 0.994349529829318f, 0.994775451094928f,
- 0.995184726672197f, 0.995577349712672f, 0.995953313646548f, 0.996312612182778f, 0.996655239309180f, 0.996981189292537f, 0.997290456678690f, 0.997583036292635f,
- 0.997858923238603f, 0.998118112900149f, 0.998360600940223f, 0.998586383301244f, 0.998795456205172f, 0.998987816153567f, 0.999163459927649f, 0.999322384588350f,
- 0.999464587476366f, 0.999590066212200f, 0.999698818696204f, 0.999790843108610f, 0.999866137909562f, 0.999924701839145f, 0.999966533917401f, 0.999991633444351f,
- 1.000000000000000f
-};
const Word16 sincos_t_rad3_fx[T_SIN_PI_2 + 1] =
{//Q15
0, 134, 268, 402, 536, 670, 804, 938,
@@ -23495,7 +20844,7 @@ const Coding codesTnsCoeff3WB[] =
{ 7+INDEX_SHIFT, 2818, 12 } /* 101100000010 */
};
-const int16_t nTnsCoeffCodes = sizeof(codesTnsCoeff0TCX20)/sizeof(codesTnsCoeff0TCX20[0]);
+const Word16 nTnsCoeffCodes = sizeof(codesTnsCoeff0TCX20)/sizeof(codesTnsCoeff0TCX20[0]);
const Coding * const codesTnsCoeffSWBTCX20[] = { codesTnsCoeff0TCX20, codesTnsCoeff1TCX20, codesTnsCoeff2TCX20, codesTnsCoeff3TCX20, codesTnsCoeff4TCX20, codesTnsCoeff5, codesTnsCoeff6, codesTnsCoeff7 };
const Coding * const codesTnsCoeffSWBTCX10[] = { codesTnsCoeff0TCX10, codesTnsCoeff1TCX10, codesTnsCoeff2TCX10, codesTnsCoeff3TCX10, codesTnsCoeff4TCX10, codesTnsCoeff5, codesTnsCoeff6, codesTnsCoeff7 };
diff --git a/lib_com/rom_com.h b/lib_com/rom_com.h
index 822c996b84592db21ca8fa95c906cf7c8c3b9445..431c6b7047870558f861250a47cbd42b32b68e73 100644
--- a/lib_com/rom_com.h
+++ b/lib_com/rom_com.h
@@ -49,13 +49,13 @@
#define INTERP_EXP 0
typedef struct
{
- int32_t fin; /* input frequency */
+ Word32 fin; /* input frequency */
Word32 fin_fx; /* input frequency Q0 */
- int32_t fout; /* output frequency */
+ Word32 fout; /* output frequency */
Word32 fout_fx; /* output frequency Q0 */
- int16_t fac_num; /* numerator of resampling factor */
+ Word16 fac_num; /* numerator of resampling factor */
Word16 fac_num_fx; /* numerator of resampling factor Q0 */
Word16 fac_den_fx; /* denominator of resampling factor Q0 */
@@ -63,7 +63,7 @@ typedef struct
const Word16 *filter_fx; /* resampling filter coefficients Q14 */
- int16_t filt_len; /* number of filter coeff. */
+ Word16 filt_len; /* number of filter coeff. */
Word16 filt_len_fx; /* number of filter coeff. Q0 */
uint16_t flags; /* flags from config. table */
@@ -177,9 +177,7 @@ extern const Word16 h_high_fx[5]; // Q15
extern const Word16 sincos_t_fx[161]; // Q15
extern const Word16 sincos_t_ext_fx[]; // Q15
extern const Word32 crit_bands_fx[];
-extern const float crit_bands[]; /* Table of critical bands */
-extern const float sincos_t_ext[];
-extern const float sincos_t_rad3[];
+extern const float sincos_t_ext[]; // fft_rel dep
extern const Word16 sincos_t_rad3_fx[]; // Q15
extern const Word16 fft256_read_indexes[]; /* FFT Q0*/
extern const Word16 inter4_2_fx_Q15[]; // Q15 /* 1/4 resolution interpolation filter */
@@ -195,12 +193,6 @@ extern const Word32 crit_bands_fx[]; /* Table of criti
extern const Word16 wind_sss_fx[LEN_WIN_SSS]; // Q15 /*window for modify_sf ana*/
extern const Word16 filter5_39s320_120_fx[]; // Q15
-extern const float lag_window_8k_flt[17];
-extern const float lag_window_12k8_flt[][17];
-extern const float lag_window_16k_flt[][17];
-extern const float lag_window_25k6_flt[][17];
-extern const float lag_window_32k_flt[][17];
-extern const float lag_window_48k_flt[17];
extern const Word16 lag_window_8k[2][16]; // Q15
extern const Word16 lag_window_12k8[NUM_LAGW_STRENGTHS][2][16]; // Q15
extern const Word16 lag_window_16k[NUM_LAGW_STRENGTHS][2][16]; // Q15
@@ -273,9 +265,9 @@ extern const Word16 gp_gamma_3sfr_6b_fx[]; // Q14/Q9
extern const Word16 gp_gamma_4sfr_6b_fx[]; // Q14/Q9
-extern const int16_t E_ROM_qua_gain5b_const[];
-extern const int16_t E_ROM_qua_gain6b_const[];
-extern const int16_t E_ROM_qua_gain7b_const[];
+extern const Word16 E_ROM_qua_gain5b_const[];
+extern const Word16 E_ROM_qua_gain6b_const[];
+extern const Word16 E_ROM_qua_gain7b_const[];
extern const Word16 tbl_gain_code_tc_fx[N_GAIN_CODE_TC]; // Q13
extern const Word16 tbl_gain_code_tc_quant_mean[N_GAIN_CODE_TC - 1]; // Q13
@@ -425,8 +417,7 @@ extern const Word16 *const Predictors_fx[]; // Q15
extern const Word16 CBsizes[]; // Q0
extern const Word16 CBbits[]; // Q0
-extern const Word16 CBbits_p[]; // Q0
-extern const float vals[NO_LEADERS][MAX_NO_VALS];
+extern const Word16 CBbits_p[]; // Q0
extern const Word16 vals_fx[NO_LEADERS][MAX_NO_VALS]; // Q1
extern const Word16 no_vals[NO_LEADERS]; // Q0
@@ -438,10 +429,6 @@ extern const Word16 no_vals_ind[NO_LEADERS][MAX_NO_VALS]; // Q0
extern const Word16 C_VQ[LATTICE_DIM + 1][LATTICE_DIM + 1]; // Q0
// extern const Word16 C_VQ_fx[LATTICE_DIM + 1][LATTICE_DIM + 1];
-extern const float sigma_MSLVQ[][16];
-extern const float sigma_p[][16];
-extern const float scales[][MAX_NO_SCALES * 2];
-extern const float scales_p[][MAX_NO_SCALES * 2];
extern const Word16 BitsVQ[]; // Q0
extern const Word16 BitsVQ_p[]; // Q0
extern const UWord8 no_lead_idx[][2]; // Q0
@@ -936,13 +923,9 @@ extern const Word16 fg_inv_tbl_fx[13]; // Q0
/* functions and tables for pvq_indexing */
extern const UWord32 exactdivodd[ODD_DIV_SIZE]; // Q0
-extern const float gain_att[];
-extern const float stab_trans[];
-extern const float env_stab_tp[2][2];
-extern const float att_step[];
extern const Word16 gain_att_fx[40]; // Q15
extern const Word16 att_step_fx[4]; // Q13
-extern const int16_t gain_cb_size[];
+extern const Word16 gain_cb_size[];
extern const Word16 stab_trans_fx[]; // Q15
extern const Word16 env_stab_tp_fx[2][2]; // Q15
/*----------------------------------------------------------------------------------*
@@ -1051,130 +1034,77 @@ extern const Word16 gsc_sfm_start[]; // Q0
extern const Word16 gsc_sfm_end[]; // Q0
extern const Word16 gsc_sfm_size[]; // Q0
-extern const float sm_table[];
-extern const Word16 sm_table_fx[]; // Q15
-extern const float mfreq_loc[];
+extern const Word16 sm_table_fx[]; // Q15
extern const Word16 mfreq_bindiv_loc[]; // Q0
-extern const float mean_gp[];
extern const Word16 mean_gp_fx[]; /*Q14*/
-extern const float dic_gp[];
-extern const Word16 dic_gp_fx[]; /*Q14*/
-extern const float Gain_mean[];
-extern const float Gain_meanHR[];
-extern const float Gain_mean_dic[];
-extern const float Gain_mean_dicHR[];
-
-extern const float YG_mean16[];
-extern const Word16 YG_mean16_fx[]; /*Q12 */
-extern const float YG_dicMR_1[];
-extern const float YG_dicMR_2[];
-extern const float YG_dicMR_3[];
-extern const float YG_dicMR_4[];
+extern const Word16 dic_gp_fx[]; /*Q14*/
+
+extern const Word16 YG_mean16_fx[]; /*Q12 */
extern const Word16 YG_dicMR_1_fx[]; /*Q12 */
extern const Word16 YG_dicMR_2_fx[]; /*Q12 */
extern const Word16 YG_dicMR_3_fx[]; /*Q12 */
extern const Word16 YG_dicMR_4_fx[]; /*Q12 */
-extern const float mean_m[];
-extern const Word16 mean_m_fx[]; /*Q12 */
-extern const float mean_gain_dic[];
+extern const Word16 mean_m_fx[]; /*Q12 */
extern const Word16 mean_gain_dic_fx[]; /*Q12 */
-extern const float YGain_mean_LR[];
-extern const Word16 YGain_mean_LR_fx[]; /* Q12 */
-extern const float YGain_dic1_LR[];
-extern const float YGain_dic2_LR[];
-extern const float YGain_dic3_LR[];
-extern const Word16 YGain_dic1_LR_fx[]; /* Q12 */
-extern const Word16 YGain_dic2_LR_fx[]; /*Q12 */
-extern const Word16 YGain_dic3_LR_fx[]; /*Q12 */
-extern const float Gain_dic2_NBHR[];
-extern const float Gain_dic3_NBHR[];
-extern const Word16 Gain_dic3_NBHR_fx[]; /*Q12 */
-extern const Word16 Gain_dic2_NBHR_fx[]; /*Q12 */
-extern const float YG_mean16HR[];
-extern const Word16 YG_mean16HR_fx[]; /* Q12 */
-extern const float YG_dicHR_1[];
-extern const Word16 YG_dicHR_1_fx[]; /* Q12 */
-extern const float YG_dicHR_2[];
-extern const Word16 YG_dicHR_2_fx[]; /* Q12 */
-extern const float YG_dicHR_3[];
-extern const Word16 YG_dicHR_3_fx[]; /* Q12 */
-extern const float YG_mean16HR_16kHz[];
+extern const Word16 YGain_mean_LR_fx[]; /* Q12 */
+extern const Word16 YGain_dic1_LR_fx[]; /* Q12 */
+extern const Word16 YGain_dic2_LR_fx[]; /*Q12 */
+extern const Word16 YGain_dic3_LR_fx[]; /*Q12 */
+extern const Word16 Gain_dic3_NBHR_fx[]; /*Q12 */
+extern const Word16 Gain_dic2_NBHR_fx[]; /*Q12 */
+extern const Word16 YG_mean16HR_fx[]; /* Q12 */
+extern const Word16 YG_dicHR_1_fx[]; /* Q12 */
+extern const Word16 YG_dicHR_2_fx[]; /* Q12 */
+extern const Word16 YG_dicHR_3_fx[]; /* Q12 */
extern const Word16 YG_mean16HR_16kHz_fx[]; /* Q12 */
-extern const float YG_dicHR_4_16kHz[];
-extern const Word16 YG_dicHR_4_16kHz_fx[]; /* Q12 */
-extern const float YG_meanL2G_16kHz[];
-extern const Word16 YG_meanL2G_16kHz_fx[]; /* Q12 */
-extern const float YG_dicL2G_16kHz[];
+extern const Word16 YG_dicHR_4_16kHz_fx[]; /* Q12 */
+extern const Word16 YG_meanL2G_16kHz_fx[]; /* Q12 */
extern const Word16 YG_dicL2G_16kHz_fx[]; /* Q12 */
extern const Word16 GSC_freq_bits[]; // Q0
extern const Word32 GSC_freq_bits_fx[]; /*Q18*/
extern const Word32 GSC_freq_bits_fx_Q18[]; /*Q18*/
extern const Word16 GSC_freq_DL0_bits[]; /* Q0 */
extern const Word16 Compl_GSC_freq_bits[]; /* Q0 */
-extern const float Gain_meanNB[];
-extern const Word16 Gain_meanNB_fx[]; /*Q12*/
-extern const float Gain_mean_dicNB[];
-extern const Word16 Gain_mean_dicNB_fx[]; /*Q12 */
-extern const float Mean_dic_NB[];
-extern const Word16 Mean_dic_NB_fx[]; /*Q12 */
-extern const float Gain_dic1_NB[];
-extern const float Gain_dic2_NB[];
-extern const float Gain_dic3_NB[];
-extern const Word16 Gain_dic1_NB_fx[]; /*Q12 */
-extern const Word16 Gain_dic2_NB_fx[]; /*Q12 */
-extern const Word16 Gain_dic3_NB_fx[]; /*Q12 */
+extern const Word16 Gain_meanNB_fx[]; /*Q12*/
+extern const Word16 Gain_mean_dicNB_fx[]; /*Q12 */
+extern const Word16 Mean_dic_NB_fx[]; /*Q12 */
+extern const Word16 Gain_dic1_NB_fx[]; /*Q12 */
+extern const Word16 Gain_dic2_NB_fx[]; /*Q12 */
+extern const Word16 Gain_dic3_NB_fx[]; /*Q12 */
/*------------------------------------------------------------------------------*
* FFT transform
*------------------------------------------------------------------------------*/
-extern const Word16 Odx_fft64[64]; // Q0
-extern const float w_fft64[32];
-extern const Word16 Ip_fft64[6]; // Q0
-extern const Word16 Odx_fft32_15[32]; // Q0
-extern const float w_fft32[16];
-extern const Word32 w_fft32_16fx[16]; // Q30
-extern const Word16 Ip_fft32[6]; // Q0
-extern const Word16 Odx_fft32_5[32]; // Q0
-extern const Word16 Odx_fft16[16]; // Q0
-extern const float w_fft16[8];
-extern const Word16 Ip_fft16[6]; // Q0
-extern const float w_fft8[8];
-extern const Word16 Ip_fft8[6]; // Q0
-extern const Word16 Idx_dortft80[80]; // Q0
-extern const Word16 Idx_dortft120[120]; // Q0
-extern const Word16 Idx_dortft160[160]; // Q0
-extern const Word16 Idx_dortft320[320]; // Q0
-extern const Word16 Idx_dortft480[480]; // Q0
-extern const Word16 Ip_fft128[10]; // Q0
-extern const float w_fft128[64];
-extern const Word32 w_fft128_16fx[64]; // Q30
-extern const Word16 Ip_fft256[10]; // Q0
-extern const float w_fft256[128];
-extern const Word16 Ip_fft512[18]; // Q0
-extern const float w_fft512[256];
+extern const Word16 Odx_fft64[64]; // Q0
+extern const Word16 Ip_fft64[6]; // Q0
+extern const Word16 Odx_fft32_15[32]; // Q0
+extern const Word32 w_fft32_16fx[16]; // Q30
+extern const Word16 Ip_fft32[6]; // Q0
+extern const Word16 Odx_fft32_5[32]; // Q0
+extern const Word16 Odx_fft16[16]; // Q0
+extern const Word16 Ip_fft16[6]; // Q0
+extern const Word16 Ip_fft8[6]; // Q0
+extern const Word16 Idx_dortft80[80]; // Q0
+extern const Word16 Idx_dortft120[120]; // Q0
+extern const Word16 Idx_dortft160[160]; // Q0
+extern const Word16 Idx_dortft320[320]; // Q0
+extern const Word16 Idx_dortft480[480]; // Q0
+extern const Word16 Ip_fft128[10]; // Q0
+extern const Word32 w_fft128_16fx[64]; // Q30
+extern const Word16 Ip_fft256[10]; // Q0
+extern const Word16 Ip_fft512[18]; // Q0
extern const Word16 w_fft512_fx_evs[256]; // Q14
-// extern const Word16 w_fft512_fx[256];
-extern const Word16 Idx_dortft40[40]; // Q0
-extern const Word16 Odx_fft8_5[8]; // Q0
-extern const Word16 ip_edct2_64[6]; // Q0
-extern const float w_edct2_64[80];
-extern const Word16 w_edct2_64_fx[80]; /*Q14 */
-extern const Word16 Idx_dortft20[20]; // Q0
-extern const Word16 Odx_fft4_5[4]; // Q0
-extern const float w_fft4[2];
-extern const Word16 Ip_fft4[6]; // Q0
-
-extern const float FFT_RotVector_32[40];
-extern const float FFT_RotVector_256[448];
-extern const float FFT_RotVector_400[760];
-extern const float FFT_RotVector_600[1140];
-extern const float FFT_RotVector_640[1240];
-extern const float FFT_RotVector_960[1860];
-
+extern const Word16 Idx_dortft40[40]; // Q0
+extern const Word16 Odx_fft8_5[8]; // Q0
+extern const Word16 ip_edct2_64[6]; // Q0
+extern const Word16 w_edct2_64_fx[80]; /*Q14 */
+extern const Word16 Idx_dortft20[20]; // Q0
+extern const Word16 Odx_fft4_5[4]; // Q0
+extern const Word16 Ip_fft4[6]; // Q0
/*----------------------------------------------------------------------------------*
* FEC for HQ core
@@ -1432,7 +1362,7 @@ extern const Word16 nTnsCoeffCodes; // Q0
extern const Coding *const codesTnsCoeffSWBTCX20[];
extern const Coding *const codesTnsCoeffSWBTCX10[];
extern const Coding *const codesTnsCoeffWBTCX20[];
-extern const int16_t nTnsCoeffTables;
+extern const Word16 nTnsCoeffTables;
extern const Coding codesTnsOrderTCX20[];
extern const Coding codesTnsOrderTCX10[];
diff --git a/lib_dec/ivas_stereo_dft_dec_fx.c b/lib_dec/ivas_stereo_dft_dec_fx.c
index 11185330c8df8d75f8253ac6a6a74f98cf725ee3..3ee0f8e8c7a041648d0ade0266b758032e78a0d1 100644
--- a/lib_dec/ivas_stereo_dft_dec_fx.c
+++ b/lib_dec/ivas_stereo_dft_dec_fx.c
@@ -448,9 +448,9 @@ static void stereo_dft_dequantize_res_gains_fx(
FOR( i = 0; i < N; i++ )
{
/* Ensure the indices are within range -- may go out of range due to frame loss */
- ind1[i] = check_bounds_s( ind1[i], 0, 30 ); /* Q0 */
+ ind1[i] = check_bounds_s_fx( ind1[i], 0, 30 ); /* Q0 */
move16();
- ind2[i] = check_bounds_s( ind2[i], 0, 7 ); /* Q0 */
+ ind2[i] = check_bounds_s_fx( ind2[i], 0, 7 ); /* Q0 */
move16();
IF( LE_16( ind1[i], 15 ) )
{
diff --git a/lib_enc/analy_sp_fx.c b/lib_enc/analy_sp_fx.c
index bcf1ae7ac5490b6abb07f7ee95cc9263bc402f9a..183b0c3e3f0f76bd802333ecfaf319c30ff49560 100644
--- a/lib_enc/analy_sp_fx.c
+++ b/lib_enc/analy_sp_fx.c
@@ -653,8 +653,8 @@ void ivas_analy_sp_fx_front(
move16();
IF( LEtot != 0 )
{
- /* Q of LEtot is Q_new + Q_SCALE - 1, LEtot / 2 can be considered as LEtot in Q_new + Q_SCALE - 2*/
- temp32_log = BASOP_Util_Log10( LEtot, sub( Q31, add( Q_new, QSCALE - Q2 ) ) ); // Q25
+ /* Q of LEtot is Q_new + Q_SCALE - 1, LEtot / 2 can be considered as LEtot in Q_new + Q_SCALE - 1*/
+ temp32_log = BASOP_Util_Log10( LEtot, sub( Q31, add( Q_new, QSCALE - Q1 ) ) ); // Q25
temp32_log = Mpy_32_32( temp32_log, 1342177280 /* 10.f in Q27 */ ); // (Q25, Q27) -> Q21
*Etot = extract_l( L_shr( temp32_log, Q21 - Q8 ) ); // Q8
move16();
@@ -665,6 +665,7 @@ void ivas_analy_sp_fx_front(
Word16 Qout = add( Q_new, QSCALE - 2 );
find_enr_dft_fx( hCPE, input_Fs, hCPE->hStereoDft->DFT_fx[0], pt_bands, lf_E, &LEtot, min_band, max_band, Bin_E, band_energies, sub( Q31, hCPE->hStereoDft->DFT_fx_e[0] ), &Qout );
scale_sig32( lf_E, VOIC_BINS, sub( add( Q_new, QSCALE - 2 ), Qout ) );
+ scale_sig32( Bin_E, ( L_FFT / 2 ), sub( add( Q_new, QSCALE - 2 ), Qout ) );
MVR2R_WORD32( lf_E, lf_E + VOIC_BINS, VOIC_BINS );
MVR2R_WORD32( Bin_E, Bin_E + ( L_FFT / 2 ), L_FFT / 2 );
MVR2R_WORD32( band_energies, band_energies + NB_BANDS, NB_BANDS );
@@ -808,7 +809,7 @@ static void ivas_find_enr(
move16();
Ltmp1 = L_deposit_l( 0 );
- FOR( ; freq <= crit_bands[i]; freq += BIN_FREQ_FX )
+ FOR( ; freq <= crit_bands_fx[i]; freq += BIN_FREQ_FX )
{
/*ptE = *ptR * *ptR + *ptI * *ptI */ /* energy */
Word64 te = ( W_add( W_mult0_32_32( *ptR, *ptR ), W_mult0_32_32( *ptI, *ptI ) ) ); // 2 * Qfft
@@ -896,7 +897,7 @@ static void ivas_find_enr(
move16();
Ltmp1 = L_deposit_l( 0 );
- FOR( ; freq <= crit_bands[i]; freq += BIN_FREQ_FX )
+ FOR( ; freq <= crit_bands_fx[i]; freq += BIN_FREQ_FX )
{
/* *ptE = *ptR * *ptR + *ptI * *ptI */
Word64 te = ( W_add( W_mult0_32_32( *ptR, *ptR ), W_mult0_32_32( *ptI, *ptI ) ) );
@@ -1033,7 +1034,7 @@ static void ivas_find_enr1(
move32();
cnt = 0;
move16();
- WHILE( freq <= crit_bands[i] )
+ WHILE( LE_32( freq, crit_bands_fx[i] ) )
{
// *ptE = *ptR * *ptR + *ptI * *ptI; /* energy */
Word64 te = ( W_add( W_mult0_32_32( *ptR, *ptR ), W_mult0_32_32( *ptI, *ptI ) ) ); // 2 * Qfft
@@ -1083,7 +1084,7 @@ static void ivas_find_enr1(
move32();
cnt = 0;
move16();
- WHILE( freq <= crit_bands[i] )
+ WHILE( LE_32( freq, crit_bands_fx[i] ) )
{
// *Bin_E = *ptR * *ptR + *ptI * *ptI;
Word64 te = ( W_add( W_mult0_32_32( *ptR, *ptR ), W_mult0_32_32( *ptI, *ptI ) ) ); // 2 * Qfft
@@ -1201,7 +1202,7 @@ static void find_enr(
move16();
Ltmp1 = L_deposit_l( 0 );
- FOR( ; freq <= crit_bands[i]; freq += BIN_FREQ_FX )
+ FOR( ; LE_32( freq, crit_bands_fx[i] ); freq += BIN_FREQ_FX )
{
/*ptE = *ptR * *ptR + *ptI * *ptI */ /* energy */
Ltmp = L_mult( *ptI, *ptI );
@@ -1286,7 +1287,7 @@ static void find_enr(
move16();
Ltmp1 = L_deposit_l( 0 );
- FOR( ; freq <= crit_bands[i]; freq += BIN_FREQ_FX )
+ FOR( ; LE_32( freq, crit_bands_fx[i] ); freq += BIN_FREQ_FX )
{
/* *ptE = *ptR * *ptR + *ptI * *ptI */
Ltmp = L_mult( *ptI, *ptI );
diff --git a/lib_enc/ivas_core_enc.c b/lib_enc/ivas_core_enc.c
index 0b2a3923106999dcdd1d7e42110319c2024ef2dc..e9b45a8c9029809bc9aceaa5146feaceffe0a334 100644
--- a/lib_enc/ivas_core_enc.c
+++ b/lib_enc/ivas_core_enc.c
@@ -60,7 +60,7 @@ ivas_error ivas_core_enc(
const Word16 n_CoreChannels, /* i : number of core channels to be coded */
Word16 old_inp_12k8_fx[][L_INP_12k8], /* i : buffer of old input signal */
Word16 old_inp_16k_fx[][L_INP], /* i : buffer of old input signal */
- Word32 ener_fx[], /* i : residual energy from Levinson-Durbin Q6 */
+ Word32 ener_fx[], /* i : residual energy from Levinson-Durbin epsP_fx_q */
Word16 A_fx[][NB_SUBFR16k * ( M + 1 )], /* i : A(z) unquantized for the 4 subframes */
Word16 Aw_fx[][NB_SUBFR16k * ( M + 1 )], /* i : weighted A(z) unquantized for subframes */
Word32 epsP_fx[][M + 1], /* i : LP prediction errors epsP_fx_q */
diff --git a/lib_enc/ivas_core_pre_proc.c b/lib_enc/ivas_core_pre_proc.c
index ff79c509eb748d81bb73dedd6576f55a47c68f90..e57e55c21f69afa45359fd349232be3cde493214 100644
--- a/lib_enc/ivas_core_pre_proc.c
+++ b/lib_enc/ivas_core_pre_proc.c
@@ -59,7 +59,7 @@ ivas_error pre_proc_ivas(
Word16 old_inp_12k8_fx[], /* i/o: buffer of old input signal */
Word16 old_inp_16k_fx[], /* i/o: buffer of old input signal @ 16kHz */
Word16 **inp_fx, /* o : ptr. to inp. signal in the current frame*/
- Word32 *ener_fx, /* o : residual energy from Levinson-Durbin Q6 */
+ Word32 *ener_fx, /* o : residual energy from Levinson-Durbin epsP_fx_q */
Word16 A_fx[NB_SUBFR16k * ( M + 1 )], /* i/o: A(z) unquantized for the 4 subframes */
Word16 Aw_fx[NB_SUBFR16k * ( M + 1 )], /* i/o: weighted A(z) unquantized for subframes */
Word32 epsP_fx[M + 1], /* i : LP prediction errors epsP_fx_q */
@@ -1200,7 +1200,14 @@ ivas_error ivas_compute_core_buffers_fx(
Copy( st->lsp_old1_fx, st->lspold_enc_fx, M );
}
- analy_lp_ivas_fx( inp_16k_fx, L_FRAME16k, L_look, ener_fx, A_fx, epsP_h, epsP_l, lsp_new_fx, lsp_mid_fx, st->lspold_enc_fx, st->pitch, st->voicing_fx, INT_FS_16k, 0, Q_new ? *Q_new : 0, Q_r );
+ IF( Q_new )
+ {
+ analy_lp_ivas_fx( inp_16k_fx, L_FRAME16k, L_look, ener_fx, A_fx, epsP_h, epsP_l, lsp_new_fx, lsp_mid_fx, st->lspold_enc_fx, st->pitch, st->voicing_fx, INT_FS_16k, 0, sub( *Q_new, 1 ), Q_r );
+ }
+ ELSE
+ {
+ analy_lp_ivas_fx( inp_16k_fx, L_FRAME16k, L_look, ener_fx, A_fx, epsP_h, epsP_l, lsp_new_fx, lsp_mid_fx, st->lspold_enc_fx, st->pitch, st->voicing_fx, INT_FS_16k, 0, -1, Q_r );
+ }
/*--------------------------------------------------------------*
* Compute Weighted Input
diff --git a/lib_enc/ivas_corecoder_enc_reconfig.c b/lib_enc/ivas_corecoder_enc_reconfig.c
index 46e708dfe20b028b3dc1c684eb9570472713c374..ea5676d5f909e31d496b472b0ad51108cc8848bf 100644
--- a/lib_enc/ivas_corecoder_enc_reconfig.c
+++ b/lib_enc/ivas_corecoder_enc_reconfig.c
@@ -67,7 +67,7 @@ ivas_error ivas_corecoder_enc_reconfig_fx(
BSTR_ENC_HANDLE hBstr;
Word16 i, nb_bits;
Indice temp_ind_list[MAX_NUM_IND_TEMP_LIST];
- Word16 nb_bits_tot, input_frame;
+ Word16 nb_bits_tot, input_frame, q_input_buff[MCT_MAX_BLOCKS];
Word16 nchan_transport_real, nchan_transport_old_real;
ENCODER_CONFIG_HANDLE hEncoderConfig;
ivas_error error;
@@ -80,6 +80,7 @@ ivas_error ivas_corecoder_enc_reconfig_fx(
error = IVAS_ERR_OK;
move32();
+ set16_fx( q_input_buff, Q31, MCT_MAX_BLOCKS );
input_frame = idiv1616U( extract_l( L_shr( hEncoderConfig->input_Fs, 1 ) ), FRAMES_PER_SEC / 2 );
len_inp_memory = input_frame;
move16();
@@ -302,6 +303,8 @@ ivas_error ivas_corecoder_enc_reconfig_fx(
{
set32_fx( input_buff_fx[0], 0, len_inp_memory );
Copy32( st_ivas->hSCE[0]->hCoreCoder[0]->input_buff32_fx, input_buff_fx[0], len_inp_memory );
+ q_input_buff[0] = st_ivas->hSCE[0]->hCoreCoder[0]->q_inp32;
+ move16();
}
FOR( n = 0; n < CPE_CHANNELS; n++ )
@@ -310,6 +313,8 @@ ivas_error ivas_corecoder_enc_reconfig_fx(
IF( nCPE_old > 0 )
{
Copy32( st_ivas->hCPE[0]->hCoreCoder[n]->input_buff32_fx, input_buff_fx[n + 1], len_inp_memory );
+ q_input_buff[n + 1] = st_ivas->hCPE[0]->hCoreCoder[n]->q_inp32;
+ move16();
}
}
@@ -330,6 +335,8 @@ ivas_error ivas_corecoder_enc_reconfig_fx(
IF( GT_16( n_CoreCoder_existing, sce_id ) )
{
Copy32( st_ivas->hSCE[sce_id]->hCoreCoder[0]->input_buff32_fx, input_buff_fx[sce_id], len_inp_memory );
+ q_input_buff[sce_id] = st_ivas->hSCE[sce_id]->hCoreCoder[0]->q_inp32;
+ move16();
}
destroy_sce_enc( st_ivas->hSCE[sce_id], ( EQ_16( st_ivas->hEncoderConfig->element_mode_init, EVS_MONO ) && !st_ivas->hEncoderConfig->stereo_dmx_evs ) );
st_ivas->hSCE[sce_id] = NULL;
@@ -343,6 +350,8 @@ ivas_error ivas_corecoder_enc_reconfig_fx(
IF( n_CoreCoder_existing > cpe_id * CPE_CHANNELS + n )
{
Copy32( st_ivas->hCPE[cpe_id]->hCoreCoder[n]->input_buff32_fx, input_buff_fx[( cpe_id - st_ivas->nCPE ) * CPE_CHANNELS + n], len_inp_memory );
+ q_input_buff[( cpe_id - st_ivas->nCPE ) * CPE_CHANNELS + n] = st_ivas->hCPE[cpe_id]->hCoreCoder[n]->q_inp32;
+ move16();
}
}
destroy_cpe_enc( st_ivas->hCPE[cpe_id] );
@@ -390,6 +399,8 @@ ivas_error ivas_corecoder_enc_reconfig_fx(
IF( GT_16( n_CoreCoder_existing, sce_id ) && NE_16( hEncoderConfig->ivas_format, MASA_ISM_FORMAT ) )
{
Copy32( input_buff_fx[sce_id], st_ivas->hSCE[sce_id]->hCoreCoder[0]->input_buff32_fx, len_inp_memory );
+ st_ivas->hSCE[sce_id]->hCoreCoder[0]->q_inp32 = q_input_buff[sce_id];
+ move16();
}
test();
/* only reset indices if it is not the first index list, this already contains the IVAS format bits */
@@ -465,6 +476,8 @@ ivas_error ivas_corecoder_enc_reconfig_fx(
IF( GT_16( n_CoreCoder_existing, add( i_mult( cpe_id, CPE_CHANNELS ), n ) ) )
{
Copy32( input_buff_fx[n], st_ivas->hCPE[cpe_id]->hCoreCoder[n]->input_buff32_fx, len_inp_memory );
+ st_ivas->hCPE[cpe_id]->hCoreCoder[n]->q_inp32 = q_input_buff[n];
+ move16();
}
}
@@ -548,6 +561,8 @@ ivas_error ivas_corecoder_enc_reconfig_fx(
IF( st_ivas->nSCE )
{
Copy32( input_buff_fx[0], st_ivas->hSCE[0]->hCoreCoder[0]->input_buff32_fx, len_inp_memory );
+ st_ivas->hSCE[0]->hCoreCoder[0]->q_inp32 = q_input_buff[0];
+ move16();
}
IF( st_ivas->nCPE )
@@ -555,6 +570,8 @@ ivas_error ivas_corecoder_enc_reconfig_fx(
FOR( n = 0; n < CPE_CHANNELS; n++ )
{
Copy32( input_buff_fx[n + 1], st_ivas->hCPE[0]->hCoreCoder[n]->input_buff32_fx, len_inp_memory );
+ st_ivas->hCPE[0]->hCoreCoder[n]->q_inp32 = q_input_buff[n + 1];
+ move16();
}
}
}
diff --git a/lib_enc/ivas_init_enc.c b/lib_enc/ivas_init_enc.c
index 83c6655f0af5d05ac822902bf30c0a85cd131046..06e4f7a3aecbf5db926bf33897ad2733f28adfa7 100644
--- a/lib_enc/ivas_init_enc.c
+++ b/lib_enc/ivas_init_enc.c
@@ -280,7 +280,7 @@ Word16 getNumChanAnalysis_fx(
void copy_encoder_config(
Encoder_Struct *st_ivas, /* i : IVAS encoder structure */
Encoder_State *st, /* o : encoder state structure */
- const int16_t flag_all /* i : flag 1==update all, 0=partial update*/
+ const Word16 flag_all /* i : flag 1==update all, 0=partial update*/
)
{
if ( flag_all )
@@ -453,12 +453,12 @@ ivas_error ivas_init_encoder(
Encoder_Struct *st_ivas /* i/o: IVAS encoder structure */
)
{
- int16_t i, n;
- int16_t nchan_inp_buff;
- int16_t sce_id, cpe_id;
+ Word16 i, n;
+ Word16 nchan_inp_buff;
+ Word16 sce_id, cpe_id;
IVAS_FORMAT ivas_format;
- int32_t input_Fs, ivas_total_brate;
- int32_t element_brate_tmp[MAX_NUM_OBJECTS];
+ Word32 input_Fs, ivas_total_brate;
+ Word32 element_brate_tmp[MAX_NUM_OBJECTS];
ENCODER_CONFIG_HANDLE hEncoderConfig;
ivas_error error;
@@ -640,11 +640,7 @@ ivas_error ivas_init_encoder(
}
else if ( ivas_format == SBA_FORMAT || ivas_format == MASA_FORMAT )
{
-#ifndef IVAS_FLOAT_FIXED
- if ( ( error = ivas_qmetadata_open( &( st_ivas->hQMetaData ) ) ) != IVAS_ERR_OK )
-#else
IF( ( error = ivas_qmetadata_open_fx( &( st_ivas->hQMetaData ) ) ) != IVAS_ERR_OK )
-#endif
{
return error;
}
@@ -712,8 +708,8 @@ ivas_error ivas_init_encoder(
}
else if ( ivas_format == MASA_ISM_FORMAT )
{
- int32_t ism_total_brate;
- int16_t k;
+ Word32 ism_total_brate;
+ Word16 k;
st_ivas->ism_mode = ivas_omasa_ism_mode_select_fx( ivas_total_brate, hEncoderConfig->nchan_ism );
move32();
@@ -740,11 +736,7 @@ ivas_error ivas_init_encoder(
}
}
-#ifndef IVAS_FLOAT_FIXED
- if ( ( error = ivas_qmetadata_open( &( st_ivas->hQMetaData ) ) ) != IVAS_ERR_OK )
-#else
IF( ( error = ivas_qmetadata_open_fx( &( st_ivas->hQMetaData ) ) ) != IVAS_ERR_OK )
-#endif
{
return error;
}
@@ -790,11 +782,7 @@ ivas_error ivas_init_encoder(
}
/* allocate and initialize SBA handles */
-#ifndef IVAS_FLOAT_FIXED
- if ( ( error = ivas_qmetadata_open( &( st_ivas->hQMetaData ) ) ) != IVAS_ERR_OK )
-#else
IF( ( error = ivas_qmetadata_open_fx( &( st_ivas->hQMetaData ) ) ) != IVAS_ERR_OK )
-#endif
{
return error;
}
@@ -949,15 +937,11 @@ ivas_error ivas_init_encoder(
}
else if ( st_ivas->mc_mode == MC_MODE_MCMASA )
{
- int32_t brate_sce, brate_cpe;
+ Word32 brate_sce, brate_cpe;
ivas_mcmasa_setNumTransportChannels_fx( &( st_ivas->nchan_transport ), &( hEncoderConfig->element_mode_init ), ivas_total_brate );
-#ifndef IVAS_FLOAT_FIXED
- if ( ( error = ivas_qmetadata_open( &( st_ivas->hQMetaData ) ) ) != IVAS_ERR_OK )
-#else
IF( ( error = ivas_qmetadata_open_fx( &( st_ivas->hQMetaData ) ) ) != IVAS_ERR_OK )
-#endif
{
return error;
}
@@ -1953,7 +1937,7 @@ void ivas_destroy_enc(
Encoder_Struct *st_ivas /* i/o: IVAS encoder structure */
)
{
- int16_t i, n, nchan_inp;
+ Word16 i, n, nchan_inp;
nchan_inp = st_ivas->hEncoderConfig->nchan_inp;
/* SCE handles */
diff --git a/lib_enc/ivas_ism_dtx_enc.c b/lib_enc/ivas_ism_dtx_enc.c
index 244734b996a5e8fe4a6ea7a4cbd23729b9b80501..791404a11104208056aa91fb8bc18c7e6e609904 100644
--- a/lib_enc/ivas_ism_dtx_enc.c
+++ b/lib_enc/ivas_ism_dtx_enc.c
@@ -509,7 +509,7 @@ void ivas_ism_coh_estim_dtx_enc_fx(
coh_e = 0;
}
/* ensure value of coherence is between [0,1] */
- hISMDTX->coh_fx[sce_id] = check_bounds_s( hISMDTX->coh_fx[sce_id], 0, shl_sat( 1, 15 - coh_e ) );
+ hISMDTX->coh_fx[sce_id] = check_bounds_s_fx( hISMDTX->coh_fx[sce_id], 0, shl_sat( 1, 15 - coh_e ) );
hISMDTX->coh_fx[sce_id] = shl_sat( hISMDTX->coh_fx[sce_id], coh_e );
move16();
move16();
diff --git a/lib_enc/ivas_qspherical_enc.c b/lib_enc/ivas_qspherical_enc.c
index f0596bab37af46d6d6b18a61349d7678047f8417..4bf3650e60d7be1cd50da97914d95849eef64d1d 100644
--- a/lib_enc/ivas_qspherical_enc.c
+++ b/lib_enc/ivas_qspherical_enc.c
@@ -749,7 +749,7 @@ static Word32 quantize_theta_phi_fx( // Q22
/* Note: (id_th % 2 == 1) must be equal to id_th % 2 */
IF( NE_32( mc_format, MC_LS_SETUP_INVALID ) )
{
- id_ph = quantize_phi_chan_compand_fx( phi, phi_hat, no_phi_loc[id_th], (Word16) GT_32( theta_cb[id_th], MC_MASA_THR_ELEVATION ), mc_format );
+ id_ph = quantize_phi_chan_compand_fx( phi, phi_hat, no_phi_loc[id_th], (Word16) GT_32( L_shr( theta_cb[id_th], Q22 ), MC_MASA_THR_ELEVATION ), mc_format );
*id_phi_remap = id_ph;
move16();
}
diff --git a/lib_enc/ivas_sce_enc.c b/lib_enc/ivas_sce_enc.c
index ca56a64077189170ecef21dcb7ec06e953ba7214..881d480cbfc7057e79f32c050b4bb9176bd4ef40 100644
--- a/lib_enc/ivas_sce_enc.c
+++ b/lib_enc/ivas_sce_enc.c
@@ -243,10 +243,6 @@ ivas_error ivas_sce_enc_fx(
/*----------------------------------------------------------------*
* Front Pre-processing
*----------------------------------------------------------------*/
- FOR( Word16 i = 0; i < hSCE->hCoreCoder[0]->nb_subfr; i++ )
- {
- Scale_sig( &A_fx[0][i * ( M + 1 )], M + 1, sub( norm_s( A_fx[0][i * ( M + 1 )] ), 2 ) ); // scaling to Q12
- }
set16_fx( old_wsp_fx[0], 0, L_WSP );
q_old_wsp = Q15;
move16();
diff --git a/lib_enc/ivas_stereo_dft_td_itd.c b/lib_enc/ivas_stereo_dft_td_itd.c
index fbcb2ce00df673121a4608c695bae22e229d5203..35f2467151a02a6e921a27388ed7b42b5758abd7 100644
--- a/lib_enc/ivas_stereo_dft_td_itd.c
+++ b/lib_enc/ivas_stereo_dft_td_itd.c
@@ -232,11 +232,11 @@ static void stereo_td_channel_extrapolate_fx(
IF( LE_16( g_e, 0 ) )
g = g;
ELSE
- g = check_bounds_s( g, negate( shl( 1, 15 - g_e ) ), shl( ONE_HALF, ( 1 - g_e ) ) );
+ g = check_bounds_s_fx( g, negate( shl( 1, 15 - g_e ) ), shl( ONE_HALF, ( 1 - g_e ) ) );
IF( LE_16( nsr_e, 0 ) )
nsr = nsr;
ELSE
- nsr = check_bounds_s( nsr, 0, shl( 1, 15 - ( nsr_e ) ) );
+ nsr = check_bounds_s_fx( nsr, 0, shl( 1, 15 - ( nsr_e ) ) );
g = shl( g, g_e - 1 ); // q14
nsr = shl( nsr, nsr_e ); // Q15
g_lpc_e = 0;
diff --git a/lib_enc/swb_tbe_enc_fx.c b/lib_enc/swb_tbe_enc_fx.c
index 23c4ccda8732aac1e65afee7c5012c3e2ac4c860..3e8e7aac5c2a32f6e53bab6620196270c1bfdf7f 100644
--- a/lib_enc/swb_tbe_enc_fx.c
+++ b/lib_enc/swb_tbe_enc_fx.c
@@ -2468,8 +2468,12 @@ void swb_tbe_enc_fx(
&exp );
FOR( i = 0; i < L_SHB_LAHEAD; i++ )
{
- L_tmp = Mult_32_16( Lscale, shaped_shb_excitation_fx[i] ); /* Q(16-exp+Q_bwe_exc) */
- shaped_shb_excitation_fx[i] = round_fx( L_shl( L_tmp, exp ) ); /* Q_bwe_exc */
+ L_tmp = Mult_32_16( Lscale, shaped_shb_excitation_fx[i] ); /* Q(16-exp+Q_bwe_exc) */
+#ifdef BASOP_NOGLOB
+ shaped_shb_excitation_fx[i] = round_fx_sat( L_shl_sat( L_tmp, exp ) ); /* Q_bwe_exc */
+#else
+ shaped_shb_excitation_fx[i] = round_fx( L_shl( L_tmp, exp ) ); /* Q_bwe_exc */
+#endif
}
IF( exp < 0 )
{