xref: /aosp_15_r20/external/webrtc/modules/audio_coding/codecs/ilbc/constants.h (revision d9f758449e529ab9291ac668be2861e7a55c2422)
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 
13  iLBC Speech Coder ANSI-C Source Code
14 
15  constants.h
16 
17 ******************************************************************/
18 
19 #ifndef MODULES_AUDIO_CODING_CODECS_ILBC_MAIN_SOURCE_CONSTANTS_H_
20 #define MODULES_AUDIO_CODING_CODECS_ILBC_MAIN_SOURCE_CONSTANTS_H_
21 
22 #include <stddef.h>
23 #include <stdint.h>
24 
25 #include "modules/audio_coding/codecs/ilbc/defines.h"
26 
27 /* high pass filters */
28 
29 extern const int16_t WebRtcIlbcfix_kHpInCoefs[];
30 extern const int16_t WebRtcIlbcfix_kHpOutCoefs[];
31 
32 /* Window for start state decision */
33 extern const int16_t WebRtcIlbcfix_kStartSequenceEnrgWin[];
34 
35 /* low pass filter used for downsampling */
36 extern const int16_t WebRtcIlbcfix_kLpFiltCoefs[];
37 
38 /* LPC analysis and quantization */
39 
40 extern const int16_t WebRtcIlbcfix_kLpcWin[];
41 extern const int16_t WebRtcIlbcfix_kLpcAsymWin[];
42 extern const int32_t WebRtcIlbcfix_kLpcLagWin[];
43 extern const int16_t WebRtcIlbcfix_kLpcChirpSyntDenum[];
44 extern const int16_t WebRtcIlbcfix_kLpcChirpWeightDenum[];
45 extern const int16_t WebRtcIlbcfix_kLsfDimCb[];
46 extern const int16_t WebRtcIlbcfix_kLsfSizeCb[];
47 extern const int16_t WebRtcIlbcfix_kLsfCb[];
48 extern const int16_t WebRtcIlbcfix_kLsfWeight20ms[];
49 extern const int16_t WebRtcIlbcfix_kLsfWeight30ms[];
50 extern const int16_t WebRtcIlbcfix_kLsfMean[];
51 extern const int16_t WebRtcIlbcfix_kLspMean[];
52 extern const int16_t WebRtcIlbcfix_kCos[];
53 extern const int16_t WebRtcIlbcfix_kCosDerivative[];
54 extern const int16_t WebRtcIlbcfix_kCosGrid[];
55 extern const int16_t WebRtcIlbcfix_kAcosDerivative[];
56 
57 /* state quantization tables */
58 
59 extern const int16_t WebRtcIlbcfix_kStateSq3[];
60 extern const int32_t WebRtcIlbcfix_kChooseFrgQuant[];
61 extern const int16_t WebRtcIlbcfix_kScale[];
62 extern const int16_t WebRtcIlbcfix_kFrgQuantMod[];
63 
64 /* Ranges for search and filters at different subframes */
65 
66 extern const size_t WebRtcIlbcfix_kSearchRange[5][CB_NSTAGES];
67 extern const size_t WebRtcIlbcfix_kFilterRange[];
68 
69 /* gain quantization tables */
70 
71 extern const int16_t WebRtcIlbcfix_kGainSq3[];
72 extern const int16_t WebRtcIlbcfix_kGainSq4[];
73 extern const int16_t WebRtcIlbcfix_kGainSq5[];
74 extern const int16_t WebRtcIlbcfix_kGainSq5Sq[];
75 extern const int16_t* const WebRtcIlbcfix_kGain[];
76 
77 /* adaptive codebook definitions */
78 
79 extern const int16_t WebRtcIlbcfix_kCbFiltersRev[];
80 extern const int16_t WebRtcIlbcfix_kAlpha[];
81 
82 /* enhancer definitions */
83 
84 extern const int16_t WebRtcIlbcfix_kEnhPolyPhaser[ENH_UPS0]
85                                                  [ENH_FLO_MULT2_PLUS1];
86 extern const int16_t WebRtcIlbcfix_kEnhWt[];
87 extern const size_t WebRtcIlbcfix_kEnhPlocs[];
88 
89 /* PLC tables */
90 
91 extern const int16_t WebRtcIlbcfix_kPlcPerSqr[];
92 extern const int16_t WebRtcIlbcfix_kPlcPitchFact[];
93 extern const int16_t WebRtcIlbcfix_kPlcPfSlope[];
94 
95 #endif
96