1 /* 2 * Copyright (c) 2011 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 * pitch_lag_tables.h 13 * 14 * This file contains tables for the pitch filter side-info in the entropy 15 * coder. 16 * 17 */ 18 19 #ifndef MODULES_AUDIO_CODING_CODECS_ISAC_MAIN_SOURCE_PITCH_LAG_TABLES_H_ 20 #define MODULES_AUDIO_CODING_CODECS_ISAC_MAIN_SOURCE_PITCH_LAG_TABLES_H_ 21 22 #include <stdint.h> 23 24 /* header file for coding tables for the pitch filter side-info in the entropy 25 * coder */ 26 /********************* Pitch Filter Lag Coefficient Tables 27 * ************************/ 28 29 /* tables for use with small pitch gain */ 30 31 /* cdfs for quantized pitch lags */ 32 extern const uint16_t WebRtcIsac_kQPitchLagCdf1Lo[127]; 33 extern const uint16_t WebRtcIsac_kQPitchLagCdf2Lo[20]; 34 extern const uint16_t WebRtcIsac_kQPitchLagCdf3Lo[2]; 35 extern const uint16_t WebRtcIsac_kQPitchLagCdf4Lo[10]; 36 37 extern const uint16_t* WebRtcIsac_kQPitchLagCdfPtrLo[4]; 38 39 /* size of first cdf table */ 40 extern const uint16_t WebRtcIsac_kQPitchLagCdfSizeLo[1]; 41 42 /* index limits and ranges */ 43 extern const int16_t WebRtcIsac_kQIndexLowerLimitLagLo[4]; 44 extern const int16_t WebRtcIsac_kQIndexUpperLimitLagLo[4]; 45 46 /* initial index for arithmetic decoder */ 47 extern const uint16_t WebRtcIsac_kQInitIndexLagLo[3]; 48 49 /* mean values of pitch filter lags */ 50 extern const double WebRtcIsac_kQMeanLag2Lo[19]; 51 extern const double WebRtcIsac_kQMeanLag3Lo[1]; 52 extern const double WebRtcIsac_kQMeanLag4Lo[9]; 53 54 extern const double WebRtcIsac_kQPitchLagStepsizeLo; 55 56 /* tables for use with medium pitch gain */ 57 58 /* cdfs for quantized pitch lags */ 59 extern const uint16_t WebRtcIsac_kQPitchLagCdf1Mid[255]; 60 extern const uint16_t WebRtcIsac_kQPitchLagCdf2Mid[36]; 61 extern const uint16_t WebRtcIsac_kQPitchLagCdf3Mid[2]; 62 extern const uint16_t WebRtcIsac_kQPitchLagCdf4Mid[20]; 63 64 extern const uint16_t* WebRtcIsac_kQPitchLagCdfPtrMid[4]; 65 66 /* size of first cdf table */ 67 extern const uint16_t WebRtcIsac_kQPitchLagCdfSizeMid[1]; 68 69 /* index limits and ranges */ 70 extern const int16_t WebRtcIsac_kQIndexLowerLimitLagMid[4]; 71 extern const int16_t WebRtcIsac_kQIndexUpperLimitLagMid[4]; 72 73 /* initial index for arithmetic decoder */ 74 extern const uint16_t WebRtcIsac_kQInitIndexLagMid[3]; 75 76 /* mean values of pitch filter lags */ 77 extern const double WebRtcIsac_kQMeanLag2Mid[35]; 78 extern const double WebRtcIsac_kQMeanLag3Mid[1]; 79 extern const double WebRtcIsac_kQMeanLag4Mid[19]; 80 81 extern const double WebRtcIsac_kQPitchLagStepsizeMid; 82 83 /* tables for use with large pitch gain */ 84 85 /* cdfs for quantized pitch lags */ 86 extern const uint16_t WebRtcIsac_kQPitchLagCdf1Hi[511]; 87 extern const uint16_t WebRtcIsac_kQPitchLagCdf2Hi[68]; 88 extern const uint16_t WebRtcIsac_kQPitchLagCdf3Hi[2]; 89 extern const uint16_t WebRtcIsac_kQPitchLagCdf4Hi[35]; 90 91 extern const uint16_t* WebRtcIsac_kQPitchLagCdfPtrHi[4]; 92 93 /* size of first cdf table */ 94 extern const uint16_t WebRtcIsac_kQPitchLagCdfSizeHi[1]; 95 96 /* index limits and ranges */ 97 extern const int16_t WebRtcIsac_kQindexLowerLimitLagHi[4]; 98 extern const int16_t WebRtcIsac_kQindexUpperLimitLagHi[4]; 99 100 /* initial index for arithmetic decoder */ 101 extern const uint16_t WebRtcIsac_kQInitIndexLagHi[3]; 102 103 /* mean values of pitch filter lags */ 104 extern const double WebRtcIsac_kQMeanLag2Hi[67]; 105 extern const double WebRtcIsac_kQMeanLag3Hi[1]; 106 extern const double WebRtcIsac_kQMeanLag4Hi[34]; 107 108 extern const double WebRtcIsac_kQPitchLagStepsizeHi; 109 110 /* transform matrix */ 111 extern const double WebRtcIsac_kTransform[4][4]; 112 113 /* transpose transform matrix */ 114 extern const double WebRtcIsac_kTransformTranspose[4][4]; 115 116 #endif /* MODULES_AUDIO_CODING_CODECS_ISAC_MAIN_SOURCE_PITCH_LAG_TABLES_H_ */ 117