1 /* 2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. 3 * 4 * Use of this source code is governed by a BSD-style license 5 * that can be found in the LICENSE file in the root of the source 6 * tree. An additional intellectual property rights grant can be found 7 * in the file PATENTS. All contributing project authors may 8 * be found in the AUTHORS file in the root of the source tree. 9 */ 10 11 /* 12 * lpc_masking_model.h 13 * 14 * LPC functions 15 * 16 */ 17 18 #ifndef WEBRTC_MODULES_AUDIO_CODING_CODECS_ISAC_FIX_SOURCE_LPC_MASKING_MODEL_H_ 19 #define WEBRTC_MODULES_AUDIO_CODING_CODECS_ISAC_FIX_SOURCE_LPC_MASKING_MODEL_H_ 20 21 #ifdef __cplusplus 22 extern "C" { 23 #endif 24 25 #include "structs.h" 26 27 void WebRtcIsacfix_GetVars(const int16_t *input, 28 const int16_t *pitchGains_Q12, 29 uint32_t *oldEnergy, 30 int16_t *varscale); 31 32 void WebRtcIsacfix_GetLpcCoef(int16_t *inLoQ0, 33 int16_t *inHiQ0, 34 MaskFiltstr_enc *maskdata, 35 int16_t snrQ10, 36 const int16_t *pitchGains_Q12, 37 int32_t *gain_lo_hiQ17, 38 int16_t *lo_coeffQ15, 39 int16_t *hi_coeffQ15); 40 41 typedef int32_t (*CalculateResidualEnergy)(int lpc_order, 42 int32_t q_val_corr, 43 int q_val_polynomial, 44 int16_t* a_polynomial, 45 int32_t* corr_coeffs, 46 int* q_val_residual_energy); 47 extern CalculateResidualEnergy WebRtcIsacfix_CalculateResidualEnergy; 48 49 int32_t WebRtcIsacfix_CalculateResidualEnergyC(int lpc_order, 50 int32_t q_val_corr, 51 int q_val_polynomial, 52 int16_t* a_polynomial, 53 int32_t* corr_coeffs, 54 int* q_val_residual_energy); 55 56 #if defined(MIPS_DSP_R2_LE) 57 int32_t WebRtcIsacfix_CalculateResidualEnergyMIPS(int lpc_order, 58 int32_t q_val_corr, 59 int q_val_polynomial, 60 int16_t* a_polynomial, 61 int32_t* corr_coeffs, 62 int* q_val_residual_energy); 63 #endif 64 65 #ifdef __cplusplus 66 } /* extern "C" */ 67 #endif 68 69 #endif /* WEBRTC_MODULES_AUDIO_CODING_CODECS_ISAC_FIX_SOURCE_LPC_MASKING_MODEL_H_ */ 70