blob: 941f13ce86ab3e717bb3874641f3986709a17b40 [file] [log] [blame]
kjellander@webrtc.org1227ab82014-06-23 19:21:07 +00001# Copyright (c) 2014 The WebRTC project authors. All Rights Reserved.
2#
3# Use of this source code is governed by a BSD-style license
4# that can be found in the LICENSE file in the root of the source
5# tree. An additional intellectual property rights grant can be found
6# in the file PATENTS. All contributing project authors may
7# be found in the AUTHORS file in the root of the source tree.
8
mbonadei9aa3f0a2017-01-24 06:58:22 -08009import("../../webrtc.gni")
kjellanderfb114242016-06-13 00:19:48 -070010import("audio_coding.gni")
11import("//build/config/arm.gni")
kjellanderfb114242016-06-13 00:19:48 -070012import("//third_party/protobuf/proto_library.gni")
kjellander@webrtc.org1227ab82014-06-23 19:21:07 +000013
kwiberg0edb05b2016-01-19 05:54:28 -080014audio_codec_deps = [
15 ":cng",
16 ":g711",
17 ":pcm16b",
18]
kwiberg0edb05b2016-01-19 05:54:28 -080019if (rtc_include_ilbc) {
kwiberg0edb05b2016-01-19 05:54:28 -080020 audio_codec_deps += [ ":ilbc" ]
21}
22if (rtc_include_opus) {
kwiberg0edb05b2016-01-19 05:54:28 -080023 audio_codec_deps += [ ":webrtc_opus" ]
24}
25if (!build_with_mozilla) {
26 if (current_cpu == "arm") {
kwiberg0edb05b2016-01-19 05:54:28 -080027 audio_codec_deps += [ ":isac_fix" ]
28 } else {
kwiberg0edb05b2016-01-19 05:54:28 -080029 audio_codec_deps += [ ":isac" ]
30 }
kwiberg0edb05b2016-01-19 05:54:28 -080031 audio_codec_deps += [ ":g722" ]
32}
33if (!build_with_mozilla && !build_with_chromium) {
kwiberg0edb05b2016-01-19 05:54:28 -080034 audio_codec_deps += [ ":red" ]
35}
kjellanderfb114242016-06-13 00:19:48 -070036audio_coding_deps = audio_codec_deps + [
37 "../..:webrtc_common",
38 "../../common_audio",
39 "../../system_wrappers",
40 ]
kwiberg0edb05b2016-01-19 05:54:28 -080041
kwibergda2bf4e2016-10-24 13:47:09 -070042rtc_static_library("audio_format_conversion") {
43 sources = [
44 "codecs/audio_format_conversion.cc",
45 "codecs/audio_format_conversion.h",
46 ]
47 deps = [
kwiberga6b82982016-10-24 16:31:17 -070048 "../..:webrtc_common",
kwiberg529662a2017-09-04 05:43:17 -070049 "../../api:array_view",
kwiberg84f6a3f2017-09-05 08:43:13 -070050 "../../api:optional",
kwiberg087bd342017-02-10 08:15:44 -080051 "../../api/audio_codecs:audio_codecs_api",
ehmaldonadof6a861a2017-07-19 10:40:47 -070052 "../../rtc_base:rtc_base_approved",
kwibergda2bf4e2016-10-24 13:47:09 -070053 ]
54}
55
kjellanderb62dbbe2016-09-23 00:38:52 -070056rtc_static_library("rent_a_codec") {
kwibergfce4a942015-10-27 11:40:24 -070057 sources = [
kjellander3e6db232015-11-26 04:44:54 -080058 "acm2/acm_codec_database.cc",
59 "acm2/acm_codec_database.h",
60 "acm2/rent_a_codec.cc",
61 "acm2/rent_a_codec.h",
kwibergfce4a942015-10-27 11:40:24 -070062 ]
kjellander676e08f2016-12-07 08:23:27 -080063 deps = [
kwiberg529662a2017-09-04 05:43:17 -070064 "../../api:array_view",
kwiberg84f6a3f2017-09-05 08:43:13 -070065 "../../api:optional",
kwiberg087bd342017-02-10 08:15:44 -080066 "../../api/audio_codecs:audio_codecs_api",
kjellander676e08f2016-12-07 08:23:27 -080067 "../..:webrtc_common",
ehmaldonadof6a861a2017-07-19 10:40:47 -070068 "../../rtc_base:protobuf_utils",
69 "../../rtc_base:rtc_base_approved",
kwiberg65cb70d2017-03-03 06:16:28 -080070 "../../system_wrappers",
71 ":audio_coding_module_typedefs",
kwiberg65cb70d2017-03-03 06:16:28 -080072 ":isac_common",
73 ":isac_fix_c",
74 ":neteq_decoder_enum",
kjellander676e08f2016-12-07 08:23:27 -080075 ] + audio_codec_deps
mbonadei7c2c8432017-04-07 00:59:12 -070076
kwiberg0edb05b2016-01-19 05:54:28 -080077 defines = audio_codec_defines
kwibergfce4a942015-10-27 11:40:24 -070078}
79
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +000080config("audio_coding_config") {
81 include_dirs = [
kjellander3e6db232015-11-26 04:44:54 -080082 "include",
Henrik Kjellanderff761fb2015-11-04 08:31:52 +010083 "../include",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +000084 ]
85}
86
kwiberg65cb70d2017-03-03 06:16:28 -080087rtc_source_set("audio_coding_module_typedefs") {
88 sources = [
89 "include/audio_coding_module_typedefs.h",
90 ]
91 deps = [
mbonadei1140f972017-04-26 03:38:35 -070092 "..:module_api",
kwiberg65cb70d2017-03-03 06:16:28 -080093 "../..:webrtc_common",
94 ]
95}
96
kjellanderb62dbbe2016-09-23 00:38:52 -070097rtc_static_library("audio_coding") {
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +000098 sources = [
kjellander3e6db232015-11-26 04:44:54 -080099 "acm2/acm_receiver.cc",
100 "acm2/acm_receiver.h",
101 "acm2/acm_resampler.cc",
102 "acm2/acm_resampler.h",
103 "acm2/audio_coding_module.cc",
kjellander3e6db232015-11-26 04:44:54 -0800104 "acm2/call_statistics.cc",
105 "acm2/call_statistics.h",
106 "acm2/codec_manager.cc",
107 "acm2/codec_manager.h",
kjellander3e6db232015-11-26 04:44:54 -0800108 "include/audio_coding_module.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000109 ]
110
111 defines = []
112
ehmaldonadoe9cc6862016-09-05 06:10:18 -0700113 public_configs = [ ":audio_coding_config" ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000114
kjellanderfb114242016-06-13 00:19:48 -0700115 if (rtc_include_opus) {
116 public_deps = [
117 ":webrtc_opus",
118 ]
119 }
120
kjellander@webrtc.org8649fed2015-01-08 21:22:01 +0000121 if (is_win) {
122 cflags = [
123 # TODO(kjellander): Bug 261: fix this warning.
124 "/wd4373", # virtual function override.
125 ]
126 }
127
kjellanderfb114242016-06-13 00:19:48 -0700128 deps = audio_coding_deps + [
mbonadei1140f972017-04-26 03:38:35 -0700129 "..:module_api",
kwiberg529662a2017-09-04 05:43:17 -0700130 "../../api:array_view",
kwiberg087bd342017-02-10 08:15:44 -0800131 "../../api/audio_codecs:audio_codecs_api",
132 "../../api/audio_codecs:builtin_audio_decoder_factory",
kwiberg65cb70d2017-03-03 06:16:28 -0800133 ":audio_coding_module_typedefs",
kwiberg0edb05b2016-01-19 05:54:28 -0800134 ":neteq",
135 ":rent_a_codec",
ehmaldonadof6a861a2017-07-19 10:40:47 -0700136 "../../rtc_base:rtc_base_approved",
kwiberg84f6a3f2017-09-05 08:43:13 -0700137 "../../api:optional",
skvladcc91d282016-10-03 18:31:22 -0700138 "../../logging:rtc_event_log_api",
kwiberg0edb05b2016-01-19 05:54:28 -0800139 ]
kjellanderfb114242016-06-13 00:19:48 -0700140 defines = audio_coding_defines
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000141}
142
kwiberg087bd342017-02-10 08:15:44 -0800143rtc_static_library("legacy_encoded_audio_frame") {
kwiberg@webrtc.orge04a93b2014-12-09 10:12:53 +0000144 sources = [
ossu7f40ba42016-09-21 05:50:37 -0700145 "codecs/legacy_encoded_audio_frame.cc",
146 "codecs/legacy_encoded_audio_frame.h",
kwiberg@webrtc.orge04a93b2014-12-09 10:12:53 +0000147 ]
Henrik Kjellander57e5fd22015-05-25 12:55:39 +0200148 deps = [
kwiberg529662a2017-09-04 05:43:17 -0700149 "../../api:array_view",
kwiberg087bd342017-02-10 08:15:44 -0800150 "../../api/audio_codecs:audio_codecs_api",
ehmaldonadof6a861a2017-07-19 10:40:47 -0700151 "../../rtc_base:rtc_base_approved",
Henrik Kjellander57e5fd22015-05-25 12:55:39 +0200152 ]
kwiberg@webrtc.orge04a93b2014-12-09 10:12:53 +0000153}
154
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000155config("cng_config") {
Mirko Bonadei25724042017-09-18 13:09:16 +0200156 include_dirs = [ "codecs/cng/include" ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000157}
158
kjellanderb62dbbe2016-09-23 00:38:52 -0700159rtc_static_library("cng") {
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000160 sources = [
henrik.lundin@webrtc.orgff1a3e32014-12-10 07:29:08 +0000161 "codecs/cng/audio_encoder_cng.cc",
kjellander@webrtc.org3c652b62015-11-18 23:07:57 +0100162 "codecs/cng/audio_encoder_cng.h",
ossu97ba30e2016-04-25 07:55:58 -0700163 "codecs/cng/webrtc_cng.cc",
kjellander@webrtc.org3c652b62015-11-18 23:07:57 +0100164 "codecs/cng/webrtc_cng.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000165 ]
166
ehmaldonadoe9cc6862016-09-05 06:10:18 -0700167 public_configs = [ ":cng_config" ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000168
henrik.lundin@webrtc.orgc1c92912014-12-16 13:41:36 +0000169 deps = [
kjellander676e08f2016-12-07 08:23:27 -0800170 "../..:webrtc_common",
kwiberg529662a2017-09-04 05:43:17 -0700171 "../../api:array_view",
ossueb1fde42017-05-02 06:46:30 -0700172 "../../api/audio_codecs:audio_codecs_api",
Henrik Lundind048aa02015-12-03 17:47:21 +0100173 "../../common_audio",
ehmaldonadof6a861a2017-07-19 10:40:47 -0700174 "../../rtc_base:rtc_base_approved",
henrik.lundin@webrtc.orgc1c92912014-12-16 13:41:36 +0000175 ]
176}
177
178config("red_config") {
Henrik Kjellander57e5fd22015-05-25 12:55:39 +0200179 include_dirs = [ "codecs/red" ]
henrik.lundin@webrtc.orgc1c92912014-12-16 13:41:36 +0000180}
181
kjellanderb62dbbe2016-09-23 00:38:52 -0700182rtc_static_library("red") {
henrik.lundin@webrtc.orgc1c92912014-12-16 13:41:36 +0000183 sources = [
184 "codecs/red/audio_encoder_copy_red.cc",
185 "codecs/red/audio_encoder_copy_red.h",
186 ]
187
ehmaldonadoe9cc6862016-09-05 06:10:18 -0700188 public_configs = [ ":red_config" ]
henrik.lundin@webrtc.orgc1c92912014-12-16 13:41:36 +0000189
190 deps = [
ossueb1fde42017-05-02 06:46:30 -0700191 "../../api/audio_codecs:audio_codecs_api",
Henrik Lundind048aa02015-12-03 17:47:21 +0100192 "../../common_audio",
ehmaldonadof6a861a2017-07-19 10:40:47 -0700193 "../../rtc_base:rtc_base_approved",
henrik.lundin@webrtc.orgc1c92912014-12-16 13:41:36 +0000194 ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000195}
196
197config("g711_config") {
Mirko Bonadei25724042017-09-18 13:09:16 +0200198 include_dirs = [ "codecs/g711/include" ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000199}
200
kjellanderb62dbbe2016-09-23 00:38:52 -0700201rtc_static_library("g711") {
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000202 sources = [
kwiberg6faf5be2015-09-22 06:16:51 -0700203 "codecs/g711/audio_decoder_pcm.cc",
kjellander@webrtc.org3c652b62015-11-18 23:07:57 +0100204 "codecs/g711/audio_decoder_pcm.h",
henrik.lundin@webrtc.orgdef1e972014-10-21 12:48:29 +0000205 "codecs/g711/audio_encoder_pcm.cc",
kjellander@webrtc.org3c652b62015-11-18 23:07:57 +0100206 "codecs/g711/audio_encoder_pcm.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000207 ]
208
ehmaldonadoe9cc6862016-09-05 06:10:18 -0700209 public_configs = [ ":g711_config" ]
henrik.lundin@webrtc.orgc1c92912014-12-16 13:41:36 +0000210
Henrik Kjellander57e5fd22015-05-25 12:55:39 +0200211 deps = [
kwiberg087bd342017-02-10 08:15:44 -0800212 ":legacy_encoded_audio_frame",
kjellander676e08f2016-12-07 08:23:27 -0800213 "../..:webrtc_common",
kwiberg087bd342017-02-10 08:15:44 -0800214 "../../api/audio_codecs:audio_codecs_api",
ehmaldonadof6a861a2017-07-19 10:40:47 -0700215 "../../rtc_base:rtc_base_approved",
Henrik Kjellander57e5fd22015-05-25 12:55:39 +0200216 ]
kjellander7439f972016-12-05 22:47:46 -0800217 public_deps = [
218 ":g711_c",
219 ]
220}
221
222rtc_source_set("g711_c") {
223 visibility = [ ":*" ] # Only targets in this file can depend on this.
224 sources = [
225 "codecs/g711/g711.c",
226 "codecs/g711/g711.h",
227 "codecs/g711/g711_interface.c",
228 "codecs/g711/g711_interface.h",
229 ]
kjellander676e08f2016-12-07 08:23:27 -0800230 deps = [
231 "../..:webrtc_common",
232 ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000233}
234
235config("g722_config") {
Mirko Bonadei25724042017-09-18 13:09:16 +0200236 include_dirs = [ "codecs/g722/include" ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000237}
238
kjellanderb62dbbe2016-09-23 00:38:52 -0700239rtc_static_library("g722") {
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000240 sources = [
kwibergada4c132015-09-17 03:12:35 -0700241 "codecs/g722/audio_decoder_g722.cc",
kjellander@webrtc.org3c652b62015-11-18 23:07:57 +0100242 "codecs/g722/audio_decoder_g722.h",
kwiberg@webrtc.org0cd55582014-12-02 11:45:51 +0000243 "codecs/g722/audio_encoder_g722.cc",
kjellander@webrtc.org3c652b62015-11-18 23:07:57 +0100244 "codecs/g722/audio_encoder_g722.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000245 ]
246
ehmaldonadoe9cc6862016-09-05 06:10:18 -0700247 public_configs = [ ":g722_config" ]
henrik.lundin@webrtc.orgc1c92912014-12-16 13:41:36 +0000248
Henrik Kjellander57e5fd22015-05-25 12:55:39 +0200249 deps = [
kwiberg087bd342017-02-10 08:15:44 -0800250 ":legacy_encoded_audio_frame",
kjellander676e08f2016-12-07 08:23:27 -0800251 "../..:webrtc_common",
kwiberg087bd342017-02-10 08:15:44 -0800252 "../../api/audio_codecs:audio_codecs_api",
kwibergb8727ae2017-06-17 17:41:59 -0700253 "../../api/audio_codecs/g722:audio_encoder_g722_config",
ehmaldonadof6a861a2017-07-19 10:40:47 -0700254 "../../rtc_base:rtc_base_approved",
Henrik Kjellander57e5fd22015-05-25 12:55:39 +0200255 ]
kjellander7439f972016-12-05 22:47:46 -0800256 public_deps = [
257 ":g722_c",
258 ]
259}
260
261rtc_source_set("g722_c") {
262 visibility = [ ":*" ] # Only targets in this file can depend on this.
263 sources = [
264 "codecs/g722/g722_decode.c",
265 "codecs/g722/g722_enc_dec.h",
266 "codecs/g722/g722_encode.c",
267 "codecs/g722/g722_interface.c",
268 "codecs/g722/g722_interface.h",
269 ]
kjellander676e08f2016-12-07 08:23:27 -0800270 deps = [
271 "../..:webrtc_common",
272 ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000273}
274
275config("ilbc_config") {
Mirko Bonadei25724042017-09-18 13:09:16 +0200276 include_dirs = [ "codecs/ilbc/include" ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000277}
278
kjellanderb62dbbe2016-09-23 00:38:52 -0700279rtc_static_library("ilbc") {
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000280 sources = [
kwibergfff9f172015-09-16 21:26:32 -0700281 "codecs/ilbc/audio_decoder_ilbc.cc",
kjellander@webrtc.org3c652b62015-11-18 23:07:57 +0100282 "codecs/ilbc/audio_decoder_ilbc.h",
Henrik Kjellander57e5fd22015-05-25 12:55:39 +0200283 "codecs/ilbc/audio_encoder_ilbc.cc",
kjellander@webrtc.org3c652b62015-11-18 23:07:57 +0100284 "codecs/ilbc/audio_encoder_ilbc.h",
kjellander7439f972016-12-05 22:47:46 -0800285 ]
286
287 public_configs = [ ":ilbc_config" ]
288
289 deps = [
kwiberg087bd342017-02-10 08:15:44 -0800290 ":legacy_encoded_audio_frame",
kjellander676e08f2016-12-07 08:23:27 -0800291 "../..:webrtc_common",
kwiberg087bd342017-02-10 08:15:44 -0800292 "../../api/audio_codecs:audio_codecs_api",
solenbergdb3c9b02017-06-28 02:05:04 -0700293 "../../api/audio_codecs/ilbc:audio_encoder_ilbc_config",
kjellander7439f972016-12-05 22:47:46 -0800294 "../../common_audio",
ehmaldonadof6a861a2017-07-19 10:40:47 -0700295 "../../rtc_base:rtc_base_approved",
kjellander7439f972016-12-05 22:47:46 -0800296 ]
297 public_deps = [
298 ":ilbc_c",
299 ]
300}
301
302rtc_source_set("ilbc_c") {
303 visibility = [ ":*" ] # Only targets in this file can depend on this.
304 sources = [
305 "codecs/ilbc/abs_quant.c",
306 "codecs/ilbc/abs_quant.h",
307 "codecs/ilbc/abs_quant_loop.c",
308 "codecs/ilbc/abs_quant_loop.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000309 "codecs/ilbc/augmented_cb_corr.c",
310 "codecs/ilbc/augmented_cb_corr.h",
311 "codecs/ilbc/bw_expand.c",
312 "codecs/ilbc/bw_expand.h",
313 "codecs/ilbc/cb_construct.c",
314 "codecs/ilbc/cb_construct.h",
Henrik Kjellander57e5fd22015-05-25 12:55:39 +0200315 "codecs/ilbc/cb_mem_energy.c",
316 "codecs/ilbc/cb_mem_energy.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000317 "codecs/ilbc/cb_mem_energy_augmentation.c",
318 "codecs/ilbc/cb_mem_energy_augmentation.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000319 "codecs/ilbc/cb_mem_energy_calc.c",
320 "codecs/ilbc/cb_mem_energy_calc.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000321 "codecs/ilbc/cb_search.c",
Henrik Kjellander57e5fd22015-05-25 12:55:39 +0200322 "codecs/ilbc/cb_search.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000323 "codecs/ilbc/cb_search_core.c",
324 "codecs/ilbc/cb_search_core.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000325 "codecs/ilbc/cb_update_best_index.c",
326 "codecs/ilbc/cb_update_best_index.h",
327 "codecs/ilbc/chebyshev.c",
328 "codecs/ilbc/chebyshev.h",
329 "codecs/ilbc/comp_corr.c",
330 "codecs/ilbc/comp_corr.h",
331 "codecs/ilbc/constants.c",
332 "codecs/ilbc/constants.h",
333 "codecs/ilbc/create_augmented_vec.c",
334 "codecs/ilbc/create_augmented_vec.h",
335 "codecs/ilbc/decode.c",
336 "codecs/ilbc/decode.h",
337 "codecs/ilbc/decode_residual.c",
338 "codecs/ilbc/decode_residual.h",
339 "codecs/ilbc/decoder_interpolate_lsf.c",
340 "codecs/ilbc/decoder_interpolate_lsf.h",
341 "codecs/ilbc/defines.h",
342 "codecs/ilbc/do_plc.c",
343 "codecs/ilbc/do_plc.h",
344 "codecs/ilbc/encode.c",
345 "codecs/ilbc/encode.h",
346 "codecs/ilbc/energy_inverse.c",
347 "codecs/ilbc/energy_inverse.h",
Henrik Kjellander57e5fd22015-05-25 12:55:39 +0200348 "codecs/ilbc/enh_upsample.c",
349 "codecs/ilbc/enh_upsample.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000350 "codecs/ilbc/enhancer.c",
351 "codecs/ilbc/enhancer.h",
352 "codecs/ilbc/enhancer_interface.c",
353 "codecs/ilbc/enhancer_interface.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000354 "codecs/ilbc/filtered_cb_vecs.c",
355 "codecs/ilbc/filtered_cb_vecs.h",
356 "codecs/ilbc/frame_classify.c",
357 "codecs/ilbc/frame_classify.h",
358 "codecs/ilbc/gain_dequant.c",
359 "codecs/ilbc/gain_dequant.h",
360 "codecs/ilbc/gain_quant.c",
361 "codecs/ilbc/gain_quant.h",
362 "codecs/ilbc/get_cd_vec.c",
363 "codecs/ilbc/get_cd_vec.h",
364 "codecs/ilbc/get_lsp_poly.c",
365 "codecs/ilbc/get_lsp_poly.h",
366 "codecs/ilbc/get_sync_seq.c",
367 "codecs/ilbc/get_sync_seq.h",
368 "codecs/ilbc/hp_input.c",
369 "codecs/ilbc/hp_input.h",
370 "codecs/ilbc/hp_output.c",
371 "codecs/ilbc/hp_output.h",
372 "codecs/ilbc/ilbc.c",
kjellander@webrtc.org3c652b62015-11-18 23:07:57 +0100373 "codecs/ilbc/ilbc.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000374 "codecs/ilbc/index_conv_dec.c",
375 "codecs/ilbc/index_conv_dec.h",
376 "codecs/ilbc/index_conv_enc.c",
377 "codecs/ilbc/index_conv_enc.h",
378 "codecs/ilbc/init_decode.c",
379 "codecs/ilbc/init_decode.h",
380 "codecs/ilbc/init_encode.c",
381 "codecs/ilbc/init_encode.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000382 "codecs/ilbc/interpolate.c",
383 "codecs/ilbc/interpolate.h",
384 "codecs/ilbc/interpolate_samples.c",
385 "codecs/ilbc/interpolate_samples.h",
386 "codecs/ilbc/lpc_encode.c",
387 "codecs/ilbc/lpc_encode.h",
388 "codecs/ilbc/lsf_check.c",
389 "codecs/ilbc/lsf_check.h",
390 "codecs/ilbc/lsf_interpolate_to_poly_dec.c",
391 "codecs/ilbc/lsf_interpolate_to_poly_dec.h",
392 "codecs/ilbc/lsf_interpolate_to_poly_enc.c",
393 "codecs/ilbc/lsf_interpolate_to_poly_enc.h",
394 "codecs/ilbc/lsf_to_lsp.c",
395 "codecs/ilbc/lsf_to_lsp.h",
396 "codecs/ilbc/lsf_to_poly.c",
397 "codecs/ilbc/lsf_to_poly.h",
398 "codecs/ilbc/lsp_to_lsf.c",
399 "codecs/ilbc/lsp_to_lsf.h",
400 "codecs/ilbc/my_corr.c",
401 "codecs/ilbc/my_corr.h",
402 "codecs/ilbc/nearest_neighbor.c",
403 "codecs/ilbc/nearest_neighbor.h",
404 "codecs/ilbc/pack_bits.c",
405 "codecs/ilbc/pack_bits.h",
406 "codecs/ilbc/poly_to_lsf.c",
407 "codecs/ilbc/poly_to_lsf.h",
408 "codecs/ilbc/poly_to_lsp.c",
409 "codecs/ilbc/poly_to_lsp.h",
410 "codecs/ilbc/refiner.c",
411 "codecs/ilbc/refiner.h",
412 "codecs/ilbc/simple_interpolate_lsf.c",
413 "codecs/ilbc/simple_interpolate_lsf.h",
414 "codecs/ilbc/simple_lpc_analysis.c",
415 "codecs/ilbc/simple_lpc_analysis.h",
416 "codecs/ilbc/simple_lsf_dequant.c",
417 "codecs/ilbc/simple_lsf_dequant.h",
418 "codecs/ilbc/simple_lsf_quant.c",
419 "codecs/ilbc/simple_lsf_quant.h",
420 "codecs/ilbc/smooth.c",
421 "codecs/ilbc/smooth.h",
422 "codecs/ilbc/smooth_out_data.c",
423 "codecs/ilbc/smooth_out_data.h",
424 "codecs/ilbc/sort_sq.c",
425 "codecs/ilbc/sort_sq.h",
426 "codecs/ilbc/split_vq.c",
427 "codecs/ilbc/split_vq.h",
428 "codecs/ilbc/state_construct.c",
429 "codecs/ilbc/state_construct.h",
430 "codecs/ilbc/state_search.c",
431 "codecs/ilbc/state_search.h",
432 "codecs/ilbc/swap_bytes.c",
433 "codecs/ilbc/swap_bytes.h",
434 "codecs/ilbc/unpack_bits.c",
435 "codecs/ilbc/unpack_bits.h",
436 "codecs/ilbc/vq3.c",
437 "codecs/ilbc/vq3.h",
438 "codecs/ilbc/vq4.c",
439 "codecs/ilbc/vq4.h",
440 "codecs/ilbc/window32_w32.c",
441 "codecs/ilbc/window32_w32.h",
442 "codecs/ilbc/xcorr_coef.c",
443 "codecs/ilbc/xcorr_coef.h",
444 ]
445
ehmaldonadoe9cc6862016-09-05 06:10:18 -0700446 public_configs = [ ":ilbc_config" ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000447
henrik.lundin@webrtc.orgc1c92912014-12-16 13:41:36 +0000448 deps = [
kjellander676e08f2016-12-07 08:23:27 -0800449 "../..:webrtc_common",
kwiberg087bd342017-02-10 08:15:44 -0800450 "../../api/audio_codecs:audio_codecs_api",
Henrik Lundind048aa02015-12-03 17:47:21 +0100451 "../../common_audio",
ehmaldonadof6a861a2017-07-19 10:40:47 -0700452 "../../rtc_base:rtc_base_approved",
henrik.lundin@webrtc.orgc1c92912014-12-16 13:41:36 +0000453 ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000454}
455
kjellanderb62dbbe2016-09-23 00:38:52 -0700456rtc_static_library("isac_common") {
kwiberg608c3cf2015-08-24 02:03:23 -0700457 sources = [
458 "codecs/isac/audio_encoder_isac_t.h",
459 "codecs/isac/audio_encoder_isac_t_impl.h",
460 "codecs/isac/locked_bandwidth_info.cc",
461 "codecs/isac/locked_bandwidth_info.h",
462 ]
kjellander676e08f2016-12-07 08:23:27 -0800463 deps = [
kwiberga6ca5182017-01-30 05:28:54 -0800464 "../..:webrtc_common",
ossua1a040a2017-04-06 10:03:21 -0700465 "../../api/audio_codecs:audio_codecs_api",
ehmaldonadof6a861a2017-07-19 10:40:47 -0700466 "../../rtc_base:rtc_base_approved",
kjellander676e08f2016-12-07 08:23:27 -0800467 ]
kwiberg608c3cf2015-08-24 02:03:23 -0700468}
469
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000470config("isac_config") {
Mirko Bonadei25724042017-09-18 13:09:16 +0200471 include_dirs = [ "codecs/isac/main/include" ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000472}
473
kjellanderb62dbbe2016-09-23 00:38:52 -0700474rtc_static_library("isac") {
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000475 sources = [
kwiberga6ca5182017-01-30 05:28:54 -0800476 "codecs/isac/main/include/audio_decoder_isac.h",
477 "codecs/isac/main/include/audio_encoder_isac.h",
kjellander7439f972016-12-05 22:47:46 -0800478 "codecs/isac/main/source/audio_decoder_isac.cc",
479 "codecs/isac/main/source/audio_encoder_isac.cc",
480 ]
481
482 deps = [
kjellander7439f972016-12-05 22:47:46 -0800483 ":isac_common",
kwiberg087bd342017-02-10 08:15:44 -0800484 "../../api/audio_codecs:audio_codecs_api",
kjellander7439f972016-12-05 22:47:46 -0800485 ]
486 public_deps = [
487 ":isac_c",
488 ]
489}
490
491rtc_static_library("isac_c") {
492 visibility = [ ":*" ] # Only targets in this file can depend on this.
493 sources = [
Henrik Kjellander74640892015-10-29 11:31:02 +0100494 "codecs/isac/main/include/isac.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000495 "codecs/isac/main/source/arith_routines.c",
496 "codecs/isac/main/source/arith_routines.h",
497 "codecs/isac/main/source/arith_routines_hist.c",
498 "codecs/isac/main/source/arith_routines_logist.c",
499 "codecs/isac/main/source/bandwidth_estimator.c",
500 "codecs/isac/main/source/bandwidth_estimator.h",
501 "codecs/isac/main/source/codec.h",
502 "codecs/isac/main/source/crc.c",
503 "codecs/isac/main/source/crc.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000504 "codecs/isac/main/source/decode.c",
Henrik Kjellander57e5fd22015-05-25 12:55:39 +0200505 "codecs/isac/main/source/decode_bwe.c",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000506 "codecs/isac/main/source/encode.c",
507 "codecs/isac/main/source/encode_lpc_swb.c",
508 "codecs/isac/main/source/encode_lpc_swb.h",
509 "codecs/isac/main/source/entropy_coding.c",
510 "codecs/isac/main/source/entropy_coding.h",
511 "codecs/isac/main/source/fft.c",
512 "codecs/isac/main/source/fft.h",
Henrik Kjellander57e5fd22015-05-25 12:55:39 +0200513 "codecs/isac/main/source/filter_functions.c",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000514 "codecs/isac/main/source/filterbank_tables.c",
515 "codecs/isac/main/source/filterbank_tables.h",
Henrik Kjellander57e5fd22015-05-25 12:55:39 +0200516 "codecs/isac/main/source/filterbanks.c",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000517 "codecs/isac/main/source/intialize.c",
518 "codecs/isac/main/source/isac.c",
Karl Wiberg74043682015-09-22 19:31:40 +0200519 "codecs/isac/main/source/isac_float_type.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000520 "codecs/isac/main/source/lattice.c",
521 "codecs/isac/main/source/lpc_analysis.c",
522 "codecs/isac/main/source/lpc_analysis.h",
523 "codecs/isac/main/source/lpc_gain_swb_tables.c",
524 "codecs/isac/main/source/lpc_gain_swb_tables.h",
525 "codecs/isac/main/source/lpc_shape_swb12_tables.c",
526 "codecs/isac/main/source/lpc_shape_swb12_tables.h",
527 "codecs/isac/main/source/lpc_shape_swb16_tables.c",
528 "codecs/isac/main/source/lpc_shape_swb16_tables.h",
529 "codecs/isac/main/source/lpc_tables.c",
530 "codecs/isac/main/source/lpc_tables.h",
531 "codecs/isac/main/source/os_specific_inline.h",
532 "codecs/isac/main/source/pitch_estimator.c",
533 "codecs/isac/main/source/pitch_estimator.h",
534 "codecs/isac/main/source/pitch_filter.c",
535 "codecs/isac/main/source/pitch_gain_tables.c",
536 "codecs/isac/main/source/pitch_gain_tables.h",
537 "codecs/isac/main/source/pitch_lag_tables.c",
538 "codecs/isac/main/source/pitch_lag_tables.h",
539 "codecs/isac/main/source/settings.h",
540 "codecs/isac/main/source/spectrum_ar_model_tables.c",
541 "codecs/isac/main/source/spectrum_ar_model_tables.h",
542 "codecs/isac/main/source/structs.h",
543 "codecs/isac/main/source/transform.c",
544 ]
545
546 if (is_linux) {
547 libs = [ "m" ]
548 }
549
ehmaldonadoe9cc6862016-09-05 06:10:18 -0700550 public_configs = [ ":isac_config" ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000551
kwiberg@webrtc.orgb3ad8cf2014-12-11 10:08:19 +0000552 deps = [
kjellander676e08f2016-12-07 08:23:27 -0800553 ":isac_common",
aleloicfee2152016-08-29 04:09:19 -0700554 "../..:webrtc_common",
kwiberg@webrtc.orgb3ad8cf2014-12-11 10:08:19 +0000555 "../../common_audio",
ehmaldonadof6a861a2017-07-19 10:40:47 -0700556 "../../rtc_base:compile_assert_c",
557 "../../rtc_base:rtc_base_approved",
kwiberg@webrtc.orgb3ad8cf2014-12-11 10:08:19 +0000558 ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000559}
560
561config("isac_fix_config") {
Mirko Bonadei25724042017-09-18 13:09:16 +0200562 include_dirs = [ "codecs/isac/fix/include" ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000563}
564
kjellanderb62dbbe2016-09-23 00:38:52 -0700565rtc_static_library("isac_fix") {
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000566 sources = [
kjellander7439f972016-12-05 22:47:46 -0800567 "codecs/isac/fix/source/audio_decoder_isacfix.cc",
568 "codecs/isac/fix/source/audio_encoder_isacfix.cc",
569 ]
570
571 public_configs = [ ":isac_fix_config" ]
572
573 deps = [
kjellander7439f972016-12-05 22:47:46 -0800574 ":isac_common",
kwiberg087bd342017-02-10 08:15:44 -0800575 "../../api/audio_codecs:audio_codecs_api",
kjellander7439f972016-12-05 22:47:46 -0800576 "../../common_audio",
577 "../../system_wrappers",
578 ]
579 public_deps = [
580 ":isac_fix_c",
581 ]
582
583 if (rtc_build_with_neon) {
584 deps += [ ":isac_neon" ]
585 }
586}
587
kwiberga6ca5182017-01-30 05:28:54 -0800588rtc_source_set("isac_fix_common") {
589 visibility = [ ":*" ] # Only targets in this file can depend on this.
590 sources = [
591 "codecs/isac/fix/source/codec.h",
592 "codecs/isac/fix/source/fft.c",
593 "codecs/isac/fix/source/fft.h",
594 "codecs/isac/fix/source/settings.h",
595 ]
596 public_configs = [ ":isac_fix_config" ]
597}
kjellander676e08f2016-12-07 08:23:27 -0800598
mbonadei5c0d7032017-07-06 03:48:55 -0700599rtc_source_set("isac_fix_c_arm_asm") {
600 sources = []
601 if (current_cpu == "arm" && arm_version >= 7) {
602 sources += [
603 "codecs/isac/fix/source/lattice_armv7.S",
604 "codecs/isac/fix/source/pitch_filter_armv6.S",
605 ]
606 }
607}
608
kwiberga6ca5182017-01-30 05:28:54 -0800609rtc_source_set("isac_fix_c") {
kjellander7439f972016-12-05 22:47:46 -0800610 visibility = [ ":*" ] # Only targets in this file can depend on this.
611 sources = [
Henrik Kjellander74640892015-10-29 11:31:02 +0100612 "codecs/isac/fix/include/audio_decoder_isacfix.h",
613 "codecs/isac/fix/include/audio_encoder_isacfix.h",
614 "codecs/isac/fix/include/isacfix.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000615 "codecs/isac/fix/source/arith_routines.c",
616 "codecs/isac/fix/source/arith_routines_hist.c",
617 "codecs/isac/fix/source/arith_routines_logist.c",
618 "codecs/isac/fix/source/arith_routins.h",
619 "codecs/isac/fix/source/bandwidth_estimator.c",
620 "codecs/isac/fix/source/bandwidth_estimator.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000621 "codecs/isac/fix/source/decode.c",
Henrik Kjellander57e5fd22015-05-25 12:55:39 +0200622 "codecs/isac/fix/source/decode_bwe.c",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000623 "codecs/isac/fix/source/decode_plc.c",
624 "codecs/isac/fix/source/encode.c",
625 "codecs/isac/fix/source/entropy_coding.c",
626 "codecs/isac/fix/source/entropy_coding.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000627 "codecs/isac/fix/source/filterbank_tables.c",
628 "codecs/isac/fix/source/filterbank_tables.h",
Henrik Kjellander57e5fd22015-05-25 12:55:39 +0200629 "codecs/isac/fix/source/filterbanks.c",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000630 "codecs/isac/fix/source/filters.c",
631 "codecs/isac/fix/source/initialize.c",
Karl Wiberg74043682015-09-22 19:31:40 +0200632 "codecs/isac/fix/source/isac_fix_type.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000633 "codecs/isac/fix/source/isacfix.c",
634 "codecs/isac/fix/source/lattice.c",
Andrew MacDonaldac4234c2015-06-24 18:25:54 -0700635 "codecs/isac/fix/source/lattice_c.c",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000636 "codecs/isac/fix/source/lpc_masking_model.c",
637 "codecs/isac/fix/source/lpc_masking_model.h",
638 "codecs/isac/fix/source/lpc_tables.c",
639 "codecs/isac/fix/source/lpc_tables.h",
640 "codecs/isac/fix/source/pitch_estimator.c",
641 "codecs/isac/fix/source/pitch_estimator.h",
Ljubomir Papuga8f85dbc2015-04-21 16:52:45 -0700642 "codecs/isac/fix/source/pitch_estimator_c.c",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000643 "codecs/isac/fix/source/pitch_filter.c",
Ljubomir Papuga8f85dbc2015-04-21 16:52:45 -0700644 "codecs/isac/fix/source/pitch_filter_c.c",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000645 "codecs/isac/fix/source/pitch_gain_tables.c",
646 "codecs/isac/fix/source/pitch_gain_tables.h",
647 "codecs/isac/fix/source/pitch_lag_tables.c",
648 "codecs/isac/fix/source/pitch_lag_tables.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000649 "codecs/isac/fix/source/spectrum_ar_model_tables.c",
650 "codecs/isac/fix/source/spectrum_ar_model_tables.h",
651 "codecs/isac/fix/source/structs.h",
652 "codecs/isac/fix/source/transform.c",
653 "codecs/isac/fix/source/transform_tables.c",
654 ]
655
ehmaldonadoe9cc6862016-09-05 06:10:18 -0700656 public_configs = [ ":isac_fix_config" ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000657
kjellander676e08f2016-12-07 08:23:27 -0800658 deps = [
kjellander676e08f2016-12-07 08:23:27 -0800659 ":isac_common",
660 "../..:webrtc_common",
kwiberg087bd342017-02-10 08:15:44 -0800661 "../../api/audio_codecs:audio_codecs_api",
kjellander676e08f2016-12-07 08:23:27 -0800662 "../../common_audio",
ehmaldonadof6a861a2017-07-19 10:40:47 -0700663 "../../rtc_base:compile_assert_c",
664 "../../rtc_base:rtc_base_approved",
kjellander676e08f2016-12-07 08:23:27 -0800665 "../../system_wrappers",
666 ]
667
kwiberga6ca5182017-01-30 05:28:54 -0800668 public_deps = [
669 ":isac_fix_common",
670 ]
671
mbonadeie5dc3ce2017-01-25 05:34:46 -0800672 if (rtc_build_with_neon) {
673 deps += [ ":isac_neon" ]
674 }
675
Andrew MacDonaldac4234c2015-06-24 18:25:54 -0700676 if (current_cpu == "arm" && arm_version >= 7) {
Andrew MacDonaldac4234c2015-06-24 18:25:54 -0700677 sources -= [
678 "codecs/isac/fix/source/lattice_c.c",
679 "codecs/isac/fix/source/pitch_filter_c.c",
680 ]
mbonadei5c0d7032017-07-06 03:48:55 -0700681 deps += [ ":isac_fix_c_arm_asm" ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000682 }
683
kjellander@webrtc.org72273912015-02-23 19:08:31 +0000684 if (current_cpu == "mipsel") {
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000685 sources += [
686 "codecs/isac/fix/source/entropy_coding_mips.c",
687 "codecs/isac/fix/source/filters_mips.c",
688 "codecs/isac/fix/source/lattice_mips.c",
689 "codecs/isac/fix/source/pitch_estimator_mips.c",
690 "codecs/isac/fix/source/transform_mips.c",
691 ]
Andrew MacDonaldac4234c2015-06-24 18:25:54 -0700692 sources -= [
693 "codecs/isac/fix/source/lattice_c.c",
694 "codecs/isac/fix/source/pitch_estimator_c.c",
695 ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000696 if (mips_dsp_rev > 0) {
Henrik Kjellander57e5fd22015-05-25 12:55:39 +0200697 sources += [ "codecs/isac/fix/source/filterbanks_mips.c" ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000698 }
699 if (mips_dsp_rev > 1) {
700 sources += [
701 "codecs/isac/fix/source/lpc_masking_model_mips.c",
702 "codecs/isac/fix/source/pitch_filter_mips.c",
703 ]
Henrik Kjellander57e5fd22015-05-25 12:55:39 +0200704 sources -= [ "codecs/isac/fix/source/pitch_filter_c.c" ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000705 }
706 }
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000707}
708
Andrew MacDonaldac4234c2015-06-24 18:25:54 -0700709if (rtc_build_with_neon) {
kjellanderb62dbbe2016-09-23 00:38:52 -0700710 rtc_static_library("isac_neon") {
Zhongwei Yaof242e662015-05-06 16:39:17 +0800711 sources = [
712 "codecs/isac/fix/source/entropy_coding_neon.c",
Zhongwei Yaob3cc77f2015-07-28 11:17:40 +0800713 "codecs/isac/fix/source/filterbanks_neon.c",
Zhongwei Yaof242e662015-05-06 16:39:17 +0800714 "codecs/isac/fix/source/filters_neon.c",
715 "codecs/isac/fix/source/lattice_neon.c",
716 "codecs/isac/fix/source/transform_neon.c",
717 ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000718
Andrew MacDonaldac4234c2015-06-24 18:25:54 -0700719 if (current_cpu != "arm64") {
720 # Enable compilation for the NEON instruction set. This is needed
721 # since //build/config/arm.gni only enables NEON for iOS, not Android.
722 # This provides the same functionality as webrtc/build/arm_neon.gypi.
ehmaldonado38a21322016-09-02 04:10:34 -0700723 suppressed_configs += [ "//build/config/compiler:compiler_arm_fpu" ]
Andrew MacDonaldac4234c2015-06-24 18:25:54 -0700724 cflags = [ "-mfpu=neon" ]
725 }
726
727 # Disable LTO on NEON targets due to compiler bug.
728 # TODO(fdegans): Enable this. See crbug.com/408997.
kjellander@webrtc.org6d08ca62014-09-07 17:36:10 +0000729 if (rtc_use_lto) {
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000730 cflags -= [
731 "-flto",
732 "-ffat-lto-objects",
733 ]
734 }
735
Henrik Kjellander57e5fd22015-05-25 12:55:39 +0200736 deps = [
kwiberga6ca5182017-01-30 05:28:54 -0800737 ":isac_fix_common",
Henrik Kjellander57e5fd22015-05-25 12:55:39 +0200738 "../../common_audio",
ehmaldonadof6a861a2017-07-19 10:40:47 -0700739 "../../rtc_base:rtc_base_approved",
Henrik Kjellander57e5fd22015-05-25 12:55:39 +0200740 ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000741 }
742}
743
744config("pcm16b_config") {
Mirko Bonadei25724042017-09-18 13:09:16 +0200745 include_dirs = [ "codecs/pcm16b/include" ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000746}
747
kjellanderb62dbbe2016-09-23 00:38:52 -0700748rtc_static_library("pcm16b") {
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000749 sources = [
Karl Wibergc0ac6ca2015-09-17 07:47:34 +0200750 "codecs/pcm16b/audio_decoder_pcm16b.cc",
kjellander@webrtc.org3c652b62015-11-18 23:07:57 +0100751 "codecs/pcm16b/audio_decoder_pcm16b.h",
Henrik Kjellander57e5fd22015-05-25 12:55:39 +0200752 "codecs/pcm16b/audio_encoder_pcm16b.cc",
kjellander@webrtc.org3c652b62015-11-18 23:07:57 +0100753 "codecs/pcm16b/audio_encoder_pcm16b.h",
kwiberg7ea6e592017-08-16 06:12:57 -0700754 "codecs/pcm16b/pcm16b_common.cc",
755 "codecs/pcm16b/pcm16b_common.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000756 ]
757
henrik.lundin@webrtc.org817e50d2014-12-11 10:47:19 +0000758 deps = [
759 ":g711",
kwiberg087bd342017-02-10 08:15:44 -0800760 ":legacy_encoded_audio_frame",
kjellander676e08f2016-12-07 08:23:27 -0800761 "../..:webrtc_common",
kwiberg087bd342017-02-10 08:15:44 -0800762 "../../api/audio_codecs:audio_codecs_api",
ehmaldonadof6a861a2017-07-19 10:40:47 -0700763 "../../rtc_base:rtc_base_approved",
henrik.lundin@webrtc.org817e50d2014-12-11 10:47:19 +0000764 ]
kjellander7439f972016-12-05 22:47:46 -0800765 public_deps = [
766 ":pcm16b_c",
767 ]
768 public_configs = [ ":pcm16b_config" ]
769}
770
771rtc_source_set("pcm16b_c") {
772 visibility = [ ":*" ] # Only targets in this file can depend on this.
773 sources = [
774 "codecs/pcm16b/pcm16b.c",
775 "codecs/pcm16b/pcm16b.h",
776 ]
henrik.lundin@webrtc.org817e50d2014-12-11 10:47:19 +0000777
ehmaldonadoe9cc6862016-09-05 06:10:18 -0700778 public_configs = [ ":pcm16b_config" ]
kjellander676e08f2016-12-07 08:23:27 -0800779 deps = [
780 "../..:webrtc_common",
781 ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000782}
783
kjellanderb62dbbe2016-09-23 00:38:52 -0700784rtc_static_library("webrtc_opus") {
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000785 sources = [
Karl Wiberg0b058792015-09-15 17:28:18 +0200786 "codecs/opus/audio_decoder_opus.cc",
kjellander@webrtc.org3c652b62015-11-18 23:07:57 +0100787 "codecs/opus/audio_decoder_opus.h",
kwiberg@webrtc.org663fdd02014-10-29 07:28:36 +0000788 "codecs/opus/audio_encoder_opus.cc",
kjellander@webrtc.org3c652b62015-11-18 23:07:57 +0100789 "codecs/opus/audio_encoder_opus.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000790 ]
henrik.lundin@webrtc.orgc1c92912014-12-16 13:41:36 +0000791
Henrik Kjellander57e5fd22015-05-25 12:55:39 +0200792 deps = [
minyue41b9c802016-10-06 07:13:54 -0700793 ":audio_network_adaptor",
kjellander676e08f2016-12-07 08:23:27 -0800794 "../..:webrtc_common",
kwiberg84f6a3f2017-09-05 08:43:13 -0700795 "../../api:optional",
kwiberg087bd342017-02-10 08:15:44 -0800796 "../../api/audio_codecs:audio_codecs_api",
kwiberg96da0112017-06-30 04:23:22 -0700797 "../../api/audio_codecs/opus:audio_encoder_opus_config",
michaelt566d8202017-01-12 10:17:38 -0800798 "../../common_audio",
ehmaldonadof6a861a2017-07-19 10:40:47 -0700799 "../../rtc_base:rtc_base_approved",
800 "../../rtc_base:rtc_numerics",
kjellander676e08f2016-12-07 08:23:27 -0800801 "../../system_wrappers",
Henrik Kjellander57e5fd22015-05-25 12:55:39 +0200802 ]
kjellander7439f972016-12-05 22:47:46 -0800803 public_deps = [
804 ":webrtc_opus_c",
kwiberge5eb7242017-08-25 03:10:50 -0700805 "../../rtc_base:protobuf_utils",
kjellander7439f972016-12-05 22:47:46 -0800806 ]
henrik.lundin@webrtc.orgc1c92912014-12-16 13:41:36 +0000807
michaelta55f0212017-02-02 07:47:19 -0800808 defines = audio_codec_defines
henrik.lundin875862c2016-11-22 02:07:54 -0800809
minyue@webrtc.org7c112f32015-03-17 14:04:56 +0000810 if (rtc_build_opus) {
kjellander7439f972016-12-05 22:47:46 -0800811 public_deps += [ rtc_opus_dir ]
812 } else if (build_with_mozilla) {
813 include_dirs = [ getenv("DIST") + "/include/opus" ]
814 }
815}
816
817rtc_source_set("webrtc_opus_c") {
818 visibility = [ ":*" ] # Only targets in this file can depend on this.
819 sources = [
820 "codecs/opus/opus_inst.h",
821 "codecs/opus/opus_interface.c",
822 "codecs/opus/opus_interface.h",
823 ]
824
minyue2e03c662017-02-01 17:31:11 -0800825 defines = audio_coding_defines
826
kjellander7439f972016-12-05 22:47:46 -0800827 if (rtc_build_opus) {
tfarina702f3972015-09-25 05:57:37 -0700828 public_deps = [
829 rtc_opus_dir,
830 ]
minyue@webrtc.org7c112f32015-03-17 14:04:56 +0000831 } else if (build_with_mozilla) {
832 include_dirs = [ getenv("DIST") + "/include/opus" ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000833 }
kjellander7439f972016-12-05 22:47:46 -0800834
835 deps = [
kjellander676e08f2016-12-07 08:23:27 -0800836 "../..:webrtc_common",
ehmaldonadof6a861a2017-07-19 10:40:47 -0700837 "../../rtc_base:rtc_base_approved",
kjellander7439f972016-12-05 22:47:46 -0800838 ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000839}
840
minyue25f6a392016-09-22 22:23:20 -0700841if (rtc_enable_protobuf) {
842 proto_library("ana_debug_dump_proto") {
843 sources = [
844 "audio_network_adaptor/debug_dump.proto",
845 ]
jbudorick58f17252017-07-26 14:49:20 -0700846 deps = [
847 ":ana_config_proto",
848 ]
Mirko Bonadei92ea95e2017-09-15 06:47:31 +0200849 proto_out_dir = "modules/audio_coding/audio_network_adaptor"
minyue25f6a392016-09-22 22:23:20 -0700850 }
minyuea1d9ad02016-10-02 14:53:37 -0700851 proto_library("ana_config_proto") {
852 sources = [
853 "audio_network_adaptor/config.proto",
854 ]
Mirko Bonadei92ea95e2017-09-15 06:47:31 +0200855 proto_out_dir = "modules/audio_coding/audio_network_adaptor"
minyuea1d9ad02016-10-02 14:53:37 -0700856 }
minyue25f6a392016-09-22 22:23:20 -0700857}
858
eladalon1e7dd312017-09-12 04:38:25 -0700859rtc_static_library("audio_network_adaptor_config") {
860 sources = [
861 "audio_network_adaptor/audio_network_adaptor_config.cc",
862 "audio_network_adaptor/include/audio_network_adaptor_config.h",
863 ]
864 deps = [
865 "../../api:optional",
866 ]
867}
868
minyue0d382ef2016-10-07 07:59:28 -0700869rtc_static_library("audio_network_adaptor") {
minyue7610f852016-09-07 13:51:51 -0700870 sources = [
minyuecaa9cb22016-09-13 13:34:15 -0700871 "audio_network_adaptor/audio_network_adaptor_impl.cc",
872 "audio_network_adaptor/audio_network_adaptor_impl.h",
minyue4aec1d42016-09-21 23:01:26 -0700873 "audio_network_adaptor/bitrate_controller.cc",
874 "audio_network_adaptor/bitrate_controller.h",
minyue2e164c62016-09-14 06:47:36 -0700875 "audio_network_adaptor/channel_controller.cc",
876 "audio_network_adaptor/channel_controller.h",
minyuecaa9cb22016-09-13 13:34:15 -0700877 "audio_network_adaptor/controller.cc",
878 "audio_network_adaptor/controller.h",
879 "audio_network_adaptor/controller_manager.cc",
880 "audio_network_adaptor/controller_manager.h",
minyue25f6a392016-09-22 22:23:20 -0700881 "audio_network_adaptor/debug_dump_writer.cc",
882 "audio_network_adaptor/debug_dump_writer.h",
minyue186cd062016-09-16 05:54:39 -0700883 "audio_network_adaptor/dtx_controller.cc",
884 "audio_network_adaptor/dtx_controller.h",
minyue4b7c9522017-01-24 04:54:59 -0800885 "audio_network_adaptor/event_log_writer.cc",
886 "audio_network_adaptor/event_log_writer.h",
elad.alon6d7900d2017-03-24 04:12:56 -0700887 "audio_network_adaptor/fec_controller_plr_based.cc",
888 "audio_network_adaptor/fec_controller_plr_based.h",
889 "audio_network_adaptor/fec_controller_rplr_based.cc",
890 "audio_network_adaptor/fec_controller_rplr_based.h",
minyuee35d3292016-09-21 16:00:31 -0700891 "audio_network_adaptor/frame_length_controller.cc",
892 "audio_network_adaptor/frame_length_controller.h",
minyue7610f852016-09-07 13:51:51 -0700893 "audio_network_adaptor/include/audio_network_adaptor.h",
elad.alon326263a2017-03-29 03:16:58 -0700894 "audio_network_adaptor/util/threshold_curve.h",
minyue7610f852016-09-07 13:51:51 -0700895 ]
minyue25f6a392016-09-22 22:23:20 -0700896
eladalon1e7dd312017-09-12 04:38:25 -0700897 public_deps = [
898 ":audio_network_adaptor_config",
899 ]
900
minyue41b9c802016-10-06 07:13:54 -0700901 deps = [
902 "../..:webrtc_common",
kwiberg84f6a3f2017-09-05 08:43:13 -0700903 "../../api:optional",
ivoce1198e02017-09-08 08:13:19 -0700904 "../../api/audio_codecs:audio_codecs_api",
kjellander676e08f2016-12-07 08:23:27 -0800905 "../../common_audio",
minyue4b7c9522017-01-24 04:54:59 -0800906 "../../logging:rtc_event_log_api",
ehmaldonadof6a861a2017-07-19 10:40:47 -0700907 "../../rtc_base:protobuf_utils",
908 "../../rtc_base:rtc_base_approved",
minyue41b9c802016-10-06 07:13:54 -0700909 "../../system_wrappers",
910 ]
911
minyue25f6a392016-09-22 22:23:20 -0700912 if (rtc_enable_protobuf) {
minyue41b9c802016-10-06 07:13:54 -0700913 deps += [
minyuea1d9ad02016-10-02 14:53:37 -0700914 ":ana_config_proto",
minyue25f6a392016-09-22 22:23:20 -0700915 ":ana_debug_dump_proto",
916 ]
minyue25f6a392016-09-22 22:23:20 -0700917 }
minyue4b7c9522017-01-24 04:54:59 -0800918
919 if (!build_with_chromium && is_clang) {
920 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
921 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
922 }
minyue7610f852016-09-07 13:51:51 -0700923}
924
kwiberg65cb70d2017-03-03 06:16:28 -0800925rtc_source_set("neteq_decoder_enum") {
926 sources = [
927 "neteq/neteq_decoder_enum.cc",
928 "neteq/neteq_decoder_enum.h",
929 ]
930 deps = [
kwiberg84f6a3f2017-09-05 08:43:13 -0700931 "../../api:optional",
kwiberg65cb70d2017-03-03 06:16:28 -0800932 "../../api/audio_codecs:audio_codecs_api",
ehmaldonadof6a861a2017-07-19 10:40:47 -0700933 "../../rtc_base:rtc_base_approved",
kwiberg65cb70d2017-03-03 06:16:28 -0800934 ]
935}
kjellander676e08f2016-12-07 08:23:27 -0800936
kwiberg65cb70d2017-03-03 06:16:28 -0800937rtc_static_library("neteq") {
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000938 sources = [
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000939 "neteq/accelerate.cc",
940 "neteq/accelerate.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000941 "neteq/audio_multi_vector.cc",
942 "neteq/audio_multi_vector.h",
943 "neteq/audio_vector.cc",
944 "neteq/audio_vector.h",
945 "neteq/background_noise.cc",
946 "neteq/background_noise.h",
947 "neteq/buffer_level_filter.cc",
948 "neteq/buffer_level_filter.h",
949 "neteq/comfort_noise.cc",
950 "neteq/comfort_noise.h",
minyue53ff70f2016-05-02 01:50:30 -0700951 "neteq/cross_correlation.cc",
952 "neteq/cross_correlation.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000953 "neteq/decision_logic.cc",
954 "neteq/decision_logic.h",
955 "neteq/decision_logic_fax.cc",
956 "neteq/decision_logic_fax.h",
957 "neteq/decision_logic_normal.cc",
958 "neteq/decision_logic_normal.h",
959 "neteq/decoder_database.cc",
960 "neteq/decoder_database.h",
961 "neteq/defines.h",
962 "neteq/delay_manager.cc",
963 "neteq/delay_manager.h",
964 "neteq/delay_peak_detector.cc",
965 "neteq/delay_peak_detector.h",
966 "neteq/dsp_helper.cc",
967 "neteq/dsp_helper.h",
968 "neteq/dtmf_buffer.cc",
969 "neteq/dtmf_buffer.h",
970 "neteq/dtmf_tone_generator.cc",
971 "neteq/dtmf_tone_generator.h",
972 "neteq/expand.cc",
973 "neteq/expand.h",
Henrik Kjellander74640892015-10-29 11:31:02 +0100974 "neteq/include/neteq.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000975 "neteq/merge.cc",
976 "neteq/merge.h",
henrik.lundin91951862016-06-08 06:43:41 -0700977 "neteq/nack_tracker.cc",
978 "neteq/nack_tracker.h",
Henrik Kjellander57e5fd22015-05-25 12:55:39 +0200979 "neteq/neteq.cc",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000980 "neteq/neteq_impl.cc",
981 "neteq/neteq_impl.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000982 "neteq/normal.cc",
983 "neteq/normal.h",
henrik.lundin84f8cd62016-04-26 07:45:16 -0700984 "neteq/packet.cc",
985 "neteq/packet.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000986 "neteq/packet_buffer.cc",
987 "neteq/packet_buffer.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000988 "neteq/post_decode_vad.cc",
989 "neteq/post_decode_vad.h",
990 "neteq/preemptive_expand.cc",
991 "neteq/preemptive_expand.h",
992 "neteq/random_vector.cc",
993 "neteq/random_vector.h",
ossua70695a2016-09-22 02:06:28 -0700994 "neteq/red_payload_splitter.cc",
995 "neteq/red_payload_splitter.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000996 "neteq/rtcp.cc",
997 "neteq/rtcp.h",
Henrik Kjellander57e5fd22015-05-25 12:55:39 +0200998 "neteq/statistics_calculator.cc",
999 "neteq/statistics_calculator.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +00001000 "neteq/sync_buffer.cc",
1001 "neteq/sync_buffer.h",
henrik.lundin8053f792016-04-22 13:21:43 -07001002 "neteq/tick_timer.cc",
1003 "neteq/tick_timer.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +00001004 "neteq/time_stretch.cc",
1005 "neteq/time_stretch.h",
Henrik Kjellander57e5fd22015-05-25 12:55:39 +02001006 "neteq/timestamp_scaler.cc",
1007 "neteq/timestamp_scaler.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +00001008 ]
1009
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +00001010 deps = [
kwiberg65cb70d2017-03-03 06:16:28 -08001011 ":audio_coding_module_typedefs",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +00001012 ":cng",
kwiberg65cb70d2017-03-03 06:16:28 -08001013 ":neteq_decoder_enum",
mbonadei1140f972017-04-26 03:38:35 -07001014 "..:module_api",
kwiberg@webrtc.orgac2d27d2015-02-26 13:59:22 +00001015 "../..:webrtc_common",
kwiberg84f6a3f2017-09-05 08:43:13 -07001016 "../../api:optional",
kwiberg087bd342017-02-10 08:15:44 -08001017 "../../api/audio_codecs:audio_codecs_api",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +00001018 "../../common_audio",
ehmaldonadof6a861a2017-07-19 10:40:47 -07001019 "../../rtc_base:gtest_prod",
1020 "../../rtc_base:rtc_base_approved",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +00001021 "../../system_wrappers",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +00001022 ]
kjellander@webrtc.org1227ab82014-06-23 19:21:07 +00001023}
kjellanderfb114242016-06-13 00:19:48 -07001024
henrik.lundin58466f62016-10-05 02:27:42 -07001025# Although providing only test support, this target must be outside of the
1026# rtc_include_tests conditional. The reason is that it supports fuzzer tests
1027# that ultimately are built and run as a part of the Chromium ecosystem, which
1028# does not set the rtc_include_tests flag.
henrik.lundinb637a942017-04-28 00:59:45 -07001029rtc_source_set("neteq_tools_minimal") {
henrik.lundin58466f62016-10-05 02:27:42 -07001030 sources = [
henrik.lundinb637a942017-04-28 00:59:45 -07001031 "neteq/tools/audio_sink.cc",
1032 "neteq/tools/audio_sink.h",
henrik.lundin58466f62016-10-05 02:27:42 -07001033 "neteq/tools/encode_neteq_input.cc",
1034 "neteq/tools/encode_neteq_input.h",
henrik.lundin7a38fd22017-04-28 01:35:53 -07001035 "neteq/tools/neteq_input.cc",
henrik.lundinb637a942017-04-28 00:59:45 -07001036 "neteq/tools/neteq_input.h",
henrik.lundin58466f62016-10-05 02:27:42 -07001037 "neteq/tools/neteq_test.cc",
1038 "neteq/tools/neteq_test.h",
henrik.lundinb637a942017-04-28 00:59:45 -07001039 "neteq/tools/packet.cc",
1040 "neteq/tools/packet.h",
1041 "neteq/tools/packet_source.cc",
1042 "neteq/tools/packet_source.h",
henrik.lundin58466f62016-10-05 02:27:42 -07001043 ]
1044
kjellandere40a7ee2016-10-16 23:56:12 -07001045 if (!build_with_chromium && is_clang) {
1046 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
henrik.lundin58466f62016-10-05 02:27:42 -07001047 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
1048 }
kjellander676e08f2016-12-07 08:23:27 -08001049
1050 deps = [
kjellander676e08f2016-12-07 08:23:27 -08001051 ":neteq",
henrik.lundinb637a942017-04-28 00:59:45 -07001052 "..:module_api",
kjellander676e08f2016-12-07 08:23:27 -08001053 "../..:webrtc_common",
kwiberg84f6a3f2017-09-05 08:43:13 -07001054 "../../api:optional",
ossueb1fde42017-05-02 06:46:30 -07001055 "../../api/audio_codecs:audio_codecs_api",
kwiberg087bd342017-02-10 08:15:44 -08001056 "../../api/audio_codecs:builtin_audio_decoder_factory",
ehmaldonadof6a861a2017-07-19 10:40:47 -07001057 "../../rtc_base:rtc_base_approved",
henrik.lundinb637a942017-04-28 00:59:45 -07001058 "../rtp_rtcp",
kjellander676e08f2016-12-07 08:23:27 -08001059 ]
henrik.lundin58466f62016-10-05 02:27:42 -07001060}
1061
mbonadei3edccb92017-06-01 04:47:20 -07001062rtc_source_set("neteq_test_tools") {
1063 testonly = true
1064 sources = [
1065 "neteq/tools/audio_checksum.h",
1066 "neteq/tools/audio_loop.cc",
1067 "neteq/tools/audio_loop.h",
1068 "neteq/tools/constant_pcm_packet_source.cc",
1069 "neteq/tools/constant_pcm_packet_source.h",
1070 "neteq/tools/output_audio_file.h",
1071 "neteq/tools/output_wav_file.h",
1072 "neteq/tools/rtp_file_source.cc",
1073 "neteq/tools/rtp_file_source.h",
1074 "neteq/tools/rtp_generator.cc",
1075 "neteq/tools/rtp_generator.h",
1076 ]
1077
1078 public_configs = [ ":neteq_tools_config" ]
1079
1080 if (!build_with_chromium && is_clang) {
1081 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
1082 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
1083 }
1084
1085 deps = [
1086 ":pcm16b",
1087 "..:module_api",
1088 "../..:webrtc_common",
kwiberg529662a2017-09-04 05:43:17 -07001089 "../../api:array_view",
mbonadei3edccb92017-06-01 04:47:20 -07001090 "../../common_audio",
ehmaldonadof6a861a2017-07-19 10:40:47 -07001091 "../../rtc_base:rtc_base_approved",
1092 "../../rtc_base:rtc_base_tests_utils",
mbonadei3edccb92017-06-01 04:47:20 -07001093 "../../test:rtp_test_utils",
1094 "../rtp_rtcp",
1095 ]
1096
1097 public_deps = [
1098 ":neteq_tools",
1099 ":neteq_tools_minimal",
1100 ]
1101
1102 if (rtc_enable_protobuf) {
1103 sources += [
1104 "neteq/tools/neteq_packet_source_input.cc",
1105 "neteq/tools/neteq_packet_source_input.h",
1106 ]
1107 deps += [ ":rtc_event_log_source" ]
1108 }
1109}
1110
1111config("neteq_tools_config") {
1112 include_dirs = [ "tools" ]
1113}
1114
1115rtc_source_set("neteq_tools") {
1116 sources = [
1117 "neteq/tools/fake_decode_from_file.cc",
1118 "neteq/tools/fake_decode_from_file.h",
henrik.lundin3c938fc2017-06-14 06:09:58 -07001119 "neteq/tools/neteq_delay_analyzer.cc",
1120 "neteq/tools/neteq_delay_analyzer.h",
mbonadei3edccb92017-06-01 04:47:20 -07001121 "neteq/tools/neteq_replacement_input.cc",
1122 "neteq/tools/neteq_replacement_input.h",
mbonadei3edccb92017-06-01 04:47:20 -07001123 ]
1124
1125 public_configs = [ ":neteq_tools_config" ]
1126
1127 if (!build_with_chromium && is_clang) {
1128 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
1129 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
1130 }
1131
1132 deps = [
1133 "../..:webrtc_common",
kwiberg529662a2017-09-04 05:43:17 -07001134 "../../api:array_view",
kwiberg84f6a3f2017-09-05 08:43:13 -07001135 "../../api:optional",
mbonadei3edccb92017-06-01 04:47:20 -07001136 "../../api/audio_codecs:audio_codecs_api",
ehmaldonadof6a861a2017-07-19 10:40:47 -07001137 "../../rtc_base:rtc_base_approved",
mbonadei3edccb92017-06-01 04:47:20 -07001138 "../rtp_rtcp",
1139 ]
1140
1141 public_deps = [
Ivo Creusen385b10b2017-10-13 12:37:27 +02001142 ":neteq_input_audio_tools",
mbonadei3edccb92017-06-01 04:47:20 -07001143 ":neteq_tools_minimal",
1144 ]
1145}
1146
Ivo Creusen385b10b2017-10-13 12:37:27 +02001147rtc_source_set("neteq_input_audio_tools") {
1148 sources = [
1149 "neteq/tools/input_audio_file.cc",
1150 "neteq/tools/input_audio_file.h",
1151 "neteq/tools/resample_input_audio_file.cc",
1152 "neteq/tools/resample_input_audio_file.h",
1153 ]
1154
1155 deps = [
1156 "../..:webrtc_common",
1157 "../../common_audio",
1158 "../../rtc_base:rtc_base_approved",
1159 ]
1160}
1161
mbonadei3edccb92017-06-01 04:47:20 -07001162if (rtc_enable_protobuf) {
1163 rtc_static_library("rtc_event_log_source") {
1164 testonly = true
1165
1166 # TODO(kjellander): Remove (bugs.webrtc.org/6828)
1167 # Needs call.h to be moved to webrtc/api first.
1168 check_includes = false
1169
1170 sources = [
1171 "neteq/tools/rtc_event_log_source.cc",
1172 "neteq/tools/rtc_event_log_source.h",
1173 ]
1174
1175 if (!build_with_chromium && is_clang) {
1176 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
1177 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
1178 }
1179
1180 deps = [
mbonadei3edccb92017-06-01 04:47:20 -07001181 "../../logging:rtc_event_log_parser",
ehmaldonadof6a861a2017-07-19 10:40:47 -07001182 "../../rtc_base:rtc_base_approved",
mbonadei3edccb92017-06-01 04:47:20 -07001183 ]
1184 public_deps = [
1185 "../../logging:rtc_event_log_proto",
1186 ]
1187 }
1188}
1189
kjellanderfb114242016-06-13 00:19:48 -07001190if (rtc_include_tests) {
kjellander6ceab082016-10-28 05:44:03 -07001191 group("audio_coding_tests") {
1192 testonly = true
1193 public_deps = [
1194 ":RTPchange",
1195 ":RTPencode",
1196 ":RTPjitter",
1197 ":RTPtimeshift",
1198 ":acm_receive_test",
1199 ":acm_send_test",
kjellander6ceab082016-10-28 05:44:03 -07001200 ":audio_codec_speed_tests",
1201 ":audio_decoder_unittests",
1202 ":audio_decoder_unittests",
1203 ":delay_test",
1204 ":g711_test",
1205 ":g722_test",
1206 ":ilbc_test",
1207 ":insert_packet_with_timing",
1208 ":isac_api_test",
1209 ":isac_fix_test",
1210 ":isac_switch_samprate_test",
1211 ":isac_test",
1212 ":neteq_ilbc_quality_test",
1213 ":neteq_isac_quality_test",
1214 ":neteq_opus_quality_test",
1215 ":neteq_pcmu_quality_test",
1216 ":neteq_speed_test",
1217 ":rtp_analyze",
1218 ":rtpcat",
1219 ":webrtc_opus_fec_test",
1220 ]
1221 if (rtc_enable_protobuf) {
1222 public_deps += [ ":neteq_rtpplay" ]
1223 }
1224 }
1225
ehmaldonado9cbb0a12017-01-30 03:07:03 -08001226 rtc_source_set("audio_coding_modules_tests") {
1227 testonly = true
kjellandere0629c02017-04-25 04:04:50 -07001228
1229 # Skip restricting visibility on mobile platforms since the tests on those
1230 # gets additional generated targets which would require many lines here to
1231 # cover (which would be confusing to read and hard to maintain).
1232 if (!is_android && !is_ios) {
jianjun.zhuc0247402017-07-11 06:20:45 -07001233 visibility = [ "..:modules_tests" ]
kjellandere0629c02017-04-25 04:04:50 -07001234 }
ehmaldonado9cbb0a12017-01-30 03:07:03 -08001235 sources = [
henrik.lundina8e2c632017-05-11 07:18:06 -07001236 "test/ACMTest.h",
ehmaldonado9cbb0a12017-01-30 03:07:03 -08001237 "test/APITest.cc",
henrik.lundina8e2c632017-05-11 07:18:06 -07001238 "test/APITest.h",
ehmaldonado9cbb0a12017-01-30 03:07:03 -08001239 "test/Channel.cc",
henrik.lundina8e2c632017-05-11 07:18:06 -07001240 "test/Channel.h",
ehmaldonado9cbb0a12017-01-30 03:07:03 -08001241 "test/EncodeDecodeTest.cc",
henrik.lundina8e2c632017-05-11 07:18:06 -07001242 "test/EncodeDecodeTest.h",
ehmaldonado9cbb0a12017-01-30 03:07:03 -08001243 "test/PCMFile.cc",
henrik.lundina8e2c632017-05-11 07:18:06 -07001244 "test/PCMFile.h",
ehmaldonado9cbb0a12017-01-30 03:07:03 -08001245 "test/PacketLossTest.cc",
henrik.lundina8e2c632017-05-11 07:18:06 -07001246 "test/PacketLossTest.h",
ehmaldonado9cbb0a12017-01-30 03:07:03 -08001247 "test/RTPFile.cc",
henrik.lundina8e2c632017-05-11 07:18:06 -07001248 "test/RTPFile.h",
ehmaldonado9cbb0a12017-01-30 03:07:03 -08001249 "test/TestAllCodecs.cc",
henrik.lundina8e2c632017-05-11 07:18:06 -07001250 "test/TestAllCodecs.h",
ehmaldonado9cbb0a12017-01-30 03:07:03 -08001251 "test/TestRedFec.cc",
henrik.lundina8e2c632017-05-11 07:18:06 -07001252 "test/TestRedFec.h",
ehmaldonado9cbb0a12017-01-30 03:07:03 -08001253 "test/TestStereo.cc",
henrik.lundina8e2c632017-05-11 07:18:06 -07001254 "test/TestStereo.h",
ehmaldonado9cbb0a12017-01-30 03:07:03 -08001255 "test/TestVADDTX.cc",
henrik.lundina8e2c632017-05-11 07:18:06 -07001256 "test/TestVADDTX.h",
ehmaldonado9cbb0a12017-01-30 03:07:03 -08001257 "test/Tester.cc",
1258 "test/TwoWayCommunication.cc",
henrik.lundina8e2c632017-05-11 07:18:06 -07001259 "test/TwoWayCommunication.h",
ehmaldonado9cbb0a12017-01-30 03:07:03 -08001260 "test/iSACTest.cc",
henrik.lundina8e2c632017-05-11 07:18:06 -07001261 "test/iSACTest.h",
ehmaldonado9cbb0a12017-01-30 03:07:03 -08001262 "test/opus_test.cc",
henrik.lundina8e2c632017-05-11 07:18:06 -07001263 "test/opus_test.h",
ehmaldonado9cbb0a12017-01-30 03:07:03 -08001264 "test/target_delay_unittest.cc",
1265 "test/utility.cc",
henrik.lundina8e2c632017-05-11 07:18:06 -07001266 "test/utility.h",
ehmaldonado9cbb0a12017-01-30 03:07:03 -08001267 ]
1268 deps = [
1269 ":audio_coding",
kwiberg65cb70d2017-03-03 06:16:28 -08001270 ":audio_coding_module_typedefs",
ehmaldonado9cbb0a12017-01-30 03:07:03 -08001271 ":audio_format_conversion",
ehmaldonado9cbb0a12017-01-30 03:07:03 -08001272 ":pcm16b_c",
mbonadei1140f972017-04-26 03:38:35 -07001273 "..:module_api",
ehmaldonado9cbb0a12017-01-30 03:07:03 -08001274 "../..:webrtc_common",
kwiberg84f6a3f2017-09-05 08:43:13 -07001275 "../../api:optional",
kwiberg087bd342017-02-10 08:15:44 -08001276 "../../api/audio_codecs:builtin_audio_decoder_factory",
ehmaldonadof6a861a2017-07-19 10:40:47 -07001277 "../../rtc_base:rtc_base_approved",
ehmaldonado9cbb0a12017-01-30 03:07:03 -08001278 "../../system_wrappers:system_wrappers",
ehmaldonado9cbb0a12017-01-30 03:07:03 -08001279 "../../test:test_support",
1280 ]
1281 defines = audio_coding_defines
1282 if (is_win) {
1283 cflags = [
1284 # TODO(kjellander): bugs.webrtc.org/261: Fix this warning.
1285 "/wd4373", # virtual function override.
1286 ]
1287 }
1288 if (!build_with_chromium && is_clang) {
1289 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
1290 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
1291 }
1292 }
1293
ehmaldonado021eef32017-01-05 07:09:50 -08001294 rtc_source_set("audio_coding_perf_tests") {
1295 testonly = true
kjellandere0629c02017-04-25 04:04:50 -07001296
1297 # Skip restricting visibility on mobile platforms since the tests on those
1298 # gets additional generated targets which would require many lines here to
1299 # cover (which would be confusing to read and hard to maintain).
1300 if (!is_android && !is_ios) {
jianjun.zhuc0247402017-07-11 06:20:45 -07001301 visibility = [ "../..:webrtc_perf_tests" ]
kjellandere0629c02017-04-25 04:04:50 -07001302 }
ehmaldonado021eef32017-01-05 07:09:50 -08001303 sources = [
1304 "codecs/opus/opus_complexity_unittest.cc",
1305 "neteq/test/neteq_performance_unittest.cc",
1306 ]
1307 deps = [
1308 ":neteq_test_support",
henrik.lundinb637a942017-04-28 00:59:45 -07001309 ":neteq_test_tools",
ehmaldonado021eef32017-01-05 07:09:50 -08001310 "../..:webrtc_common",
Karl Wiberg7275e182017-10-25 09:57:40 +02001311 "../../api/audio_codecs/opus:audio_encoder_opus",
ehmaldonadof6a861a2017-07-19 10:40:47 -07001312 "../../rtc_base:protobuf_utils",
1313 "../../rtc_base:rtc_base_approved",
ehmaldonado021eef32017-01-05 07:09:50 -08001314 "../../system_wrappers:system_wrappers",
1315 "../../test:test_support",
1316 ]
mbonadei7c2c8432017-04-07 00:59:12 -07001317
ehmaldonado021eef32017-01-05 07:09:50 -08001318 if (!build_with_chromium && is_clang) {
1319 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
1320 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
1321 }
1322 }
1323
ehmaldonado38a21322016-09-02 04:10:34 -07001324 rtc_source_set("acm_receive_test") {
kjellanderfb114242016-06-13 00:19:48 -07001325 testonly = true
1326 sources = [
henrik.lundin2504c0a2016-10-06 01:31:32 -07001327 "acm2/acm_receive_test.cc",
1328 "acm2/acm_receive_test.h",
kjellanderfb114242016-06-13 00:19:48 -07001329 ]
1330
kjellanderfb114242016-06-13 00:19:48 -07001331 defines = audio_coding_defines
1332
1333 deps = audio_coding_deps + [
1334 ":audio_coding",
kjellander676e08f2016-12-07 08:23:27 -08001335 ":audio_format_conversion",
kwiberg087bd342017-02-10 08:15:44 -08001336 "../../api/audio_codecs:audio_codecs_api",
1337 "../../api/audio_codecs:builtin_audio_decoder_factory",
henrik.lundinb637a942017-04-28 00:59:45 -07001338 ":neteq_tools",
ehmaldonadof6a861a2017-07-19 10:40:47 -07001339 "../../rtc_base:rtc_base_approved",
kjellander676e08f2016-12-07 08:23:27 -08001340 "../../test:test_support",
kjellanderfb114242016-06-13 00:19:48 -07001341 "//testing/gtest",
1342 ]
1343 }
1344
ehmaldonado38a21322016-09-02 04:10:34 -07001345 rtc_source_set("acm_send_test") {
kjellanderfb114242016-06-13 00:19:48 -07001346 testonly = true
1347 sources = [
henrik.lundin2504c0a2016-10-06 01:31:32 -07001348 "acm2/acm_send_test.cc",
1349 "acm2/acm_send_test.h",
kjellanderfb114242016-06-13 00:19:48 -07001350 ]
1351
kjellanderfb114242016-06-13 00:19:48 -07001352 defines = audio_coding_defines
1353
1354 deps = audio_coding_deps + [
1355 ":audio_coding",
henrik.lundinb637a942017-04-28 00:59:45 -07001356 ":neteq_tools",
ossueb1fde42017-05-02 06:46:30 -07001357 "../../api/audio_codecs:audio_codecs_api",
ehmaldonadof6a861a2017-07-19 10:40:47 -07001358 "../../rtc_base:rtc_base_approved",
kjellander676e08f2016-12-07 08:23:27 -08001359 "../../test:test_support",
kjellanderfb114242016-06-13 00:19:48 -07001360 "//testing/gtest",
1361 ]
1362 }
1363
ehmaldonado38a21322016-09-02 04:10:34 -07001364 rtc_executable("delay_test") {
aleloi333f2062016-07-28 01:21:29 -07001365 testonly = true
1366 sources = [
1367 "test/Channel.cc",
henrik.lundina8e2c632017-05-11 07:18:06 -07001368 "test/Channel.h",
aleloi333f2062016-07-28 01:21:29 -07001369 "test/PCMFile.cc",
henrik.lundina8e2c632017-05-11 07:18:06 -07001370 "test/PCMFile.h",
aleloi333f2062016-07-28 01:21:29 -07001371 "test/delay_test.cc",
1372 "test/utility.cc",
henrik.lundina8e2c632017-05-11 07:18:06 -07001373 "test/utility.h",
aleloi333f2062016-07-28 01:21:29 -07001374 ]
1375
aleloi333f2062016-07-28 01:21:29 -07001376 deps = [
1377 ":audio_coding",
kwiberg65cb70d2017-03-03 06:16:28 -08001378 ":audio_coding_module_typedefs",
kwibergda2bf4e2016-10-24 13:47:09 -07001379 ":audio_format_conversion",
mbonadei1140f972017-04-26 03:38:35 -07001380 "..:module_api",
aleloi333f2062016-07-28 01:21:29 -07001381 "../../:webrtc_common",
kwiberg84f6a3f2017-09-05 08:43:13 -07001382 "../../api:optional",
ehmaldonadof6a861a2017-07-19 10:40:47 -07001383 "../../rtc_base:rtc_base_approved",
aleloi333f2062016-07-28 01:21:29 -07001384 "../../system_wrappers",
1385 "../../system_wrappers:system_wrappers_default",
1386 "../../test:test_support",
1387 "../rtp_rtcp",
1388 "//testing/gtest",
aleloi333f2062016-07-28 01:21:29 -07001389 ]
1390 } # delay_test
1391
ehmaldonado38a21322016-09-02 04:10:34 -07001392 rtc_executable("insert_packet_with_timing") {
aleloi00730c72016-07-28 01:27:10 -07001393 testonly = true
1394 sources = [
1395 "test/Channel.cc",
henrik.lundina8e2c632017-05-11 07:18:06 -07001396 "test/Channel.h",
aleloi00730c72016-07-28 01:27:10 -07001397 "test/PCMFile.cc",
henrik.lundina8e2c632017-05-11 07:18:06 -07001398 "test/PCMFile.h",
aleloi00730c72016-07-28 01:27:10 -07001399 "test/insert_packet_with_timing.cc",
1400 ]
1401
kjellandere40a7ee2016-10-16 23:56:12 -07001402 if (!build_with_chromium && is_clang) {
1403 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
ehmaldonado38a21322016-09-02 04:10:34 -07001404 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
aleloi00730c72016-07-28 01:27:10 -07001405 }
1406
1407 deps = [
1408 ":audio_coding",
kwibergda2bf4e2016-10-24 13:47:09 -07001409 ":audio_format_conversion",
mbonadei1140f972017-04-26 03:38:35 -07001410 "..:module_api",
aleloi00730c72016-07-28 01:27:10 -07001411 "../../:webrtc_common",
kwiberg84f6a3f2017-09-05 08:43:13 -07001412 "../../api:optional",
ehmaldonadof6a861a2017-07-19 10:40:47 -07001413 "../../rtc_base:rtc_base_approved",
aleloi00730c72016-07-28 01:27:10 -07001414 "../../system_wrappers",
1415 "../../system_wrappers:system_wrappers_default",
1416 "../../test:test_support",
1417 "../rtp_rtcp",
1418 "//testing/gtest",
aleloi00730c72016-07-28 01:27:10 -07001419 ]
1420 } # insert_packet_with_timing
1421
ehmaldonado3a7f35b2016-09-14 05:10:01 -07001422 audio_decoder_unittests_resources =
Mirko Bonadei92ea95e2017-09-15 06:47:31 +02001423 [ "../../resources/audio_coding/testfile32kHz.pcm" ]
kjellander32c4a202016-08-30 02:53:49 -07001424
1425 if (is_ios) {
1426 bundle_data("audio_decoder_unittests_bundle_data") {
1427 testonly = true
1428 sources = audio_decoder_unittests_resources
1429 outputs = [
1430 "{{bundle_resources_dir}}/{{source_file_part}}",
1431 ]
1432 }
1433 }
1434
ehmaldonado38a21322016-09-02 04:10:34 -07001435 rtc_test("audio_decoder_unittests") {
charujainddf3e4a2016-08-01 07:49:42 -07001436 testonly = true
1437 sources = [
1438 "neteq/audio_decoder_unittest.cc",
1439 ]
1440
kjellandere40a7ee2016-10-16 23:56:12 -07001441 if (!build_with_chromium && is_clang) {
1442 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
ehmaldonado38a21322016-09-02 04:10:34 -07001443 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
charujainddf3e4a2016-08-01 07:49:42 -07001444 }
1445
1446 deps = []
1447
1448 defines = neteq_defines
1449
1450 deps += audio_coding_deps
1451 deps += [
ehmaldonado87b8e9f2017-02-07 06:26:29 -08001452 ":ilbc",
charujainddf3e4a2016-08-01 07:49:42 -07001453 ":isac",
1454 ":isac_fix",
1455 ":neteq",
henrik.lundinb637a942017-04-28 00:59:45 -07001456 ":neteq_tools",
kwiberg087bd342017-02-10 08:15:44 -08001457 "../../api/audio_codecs:audio_codecs_api",
kwiberg96da0112017-06-30 04:23:22 -07001458 "../../api/audio_codecs/opus:audio_encoder_opus",
kjellander6ceab082016-10-28 05:44:03 -07001459 "../../common_audio",
ehmaldonadof6a861a2017-07-19 10:40:47 -07001460 "../../rtc_base:protobuf_utils",
ehmaldonado26bddb92016-11-30 06:12:01 -08001461 "../../test:test_main",
charujainddf3e4a2016-08-01 07:49:42 -07001462 "//testing/gtest",
1463 ]
1464
ehmaldonado3a7f35b2016-09-14 05:10:01 -07001465 data = audio_decoder_unittests_resources
1466
charujainddf3e4a2016-08-01 07:49:42 -07001467 if (is_android) {
1468 deps += [ "//testing/android/native_test:native_test_native_code" ]
sakal714dd4e2016-08-15 02:29:11 -07001469 shard_timeout = 900
charujainddf3e4a2016-08-01 07:49:42 -07001470 }
kjellander32c4a202016-08-30 02:53:49 -07001471 if (is_ios) {
1472 deps += [ ":audio_decoder_unittests_bundle_data" ]
charujainddf3e4a2016-08-01 07:49:42 -07001473 }
1474 } # audio_decoder_unittests
1475
kjellanderfb114242016-06-13 00:19:48 -07001476 if (rtc_enable_protobuf) {
1477 proto_library("neteq_unittest_proto") {
1478 sources = [
1479 "neteq/neteq_unittest.proto",
1480 ]
Mirko Bonadei92ea95e2017-09-15 06:47:31 +02001481 proto_out_dir = "modules/audio_coding/neteq"
kjellanderfb114242016-06-13 00:19:48 -07001482 }
henrik.lundin03153f12016-06-21 05:38:42 -07001483
ehmaldonado38a21322016-09-02 04:10:34 -07001484 rtc_test("neteq_rtpplay") {
henrik.lundin03153f12016-06-21 05:38:42 -07001485 testonly = true
1486 defines = []
mbonadei1140f972017-04-26 03:38:35 -07001487 deps = [
1488 "..:module_api",
1489 ]
henrik.lundin03153f12016-06-21 05:38:42 -07001490 sources = [
1491 "neteq/tools/neteq_rtpplay.cc",
1492 ]
1493
kjellandere40a7ee2016-10-16 23:56:12 -07001494 if (!build_with_chromium && is_clang) {
1495 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
ehmaldonado38a21322016-09-02 04:10:34 -07001496 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
henrik.lundin03153f12016-06-21 05:38:42 -07001497 }
1498
1499 if (is_win) {
1500 cflags = [
1501 # TODO(kjellander): bugs.webrtc.org/261: Fix this warning.
1502 "/wd4373", # virtual function override.
1503 ]
1504 }
1505
1506 deps += [
1507 ":neteq",
henrik.lundinb637a942017-04-28 00:59:45 -07001508 ":neteq_test_tools",
kjellander676e08f2016-12-07 08:23:27 -08001509 "../..:webrtc_common",
ehmaldonadof6a861a2017-07-19 10:40:47 -07001510 "../../rtc_base:rtc_base_approved",
henrik.lundin03153f12016-06-21 05:38:42 -07001511 "../../system_wrappers:system_wrappers_default",
1512 "../../test:test_support",
henrik.lundin03153f12016-06-21 05:38:42 -07001513 ]
1514 }
kjellanderfb114242016-06-13 00:19:48 -07001515 }
1516
minyue81f1da32017-07-27 05:49:57 -07001517 audio_codec_speed_tests_resources = [
1518 "//resources/audio_coding/music_stereo_48kHz.pcm",
1519 "//resources/audio_coding/speech_mono_16kHz.pcm",
1520 "//resources/audio_coding/speech_mono_32_48kHz.pcm",
1521 ]
1522
1523 if (is_ios) {
1524 bundle_data("audio_codec_speed_tests_data") {
1525 testonly = true
1526 sources = audio_codec_speed_tests_resources
1527 outputs = [
1528 "{{bundle_resources_dir}}/{{source_file_part}}",
1529 ]
1530 }
1531 }
1532
ehmaldonado38a21322016-09-02 04:10:34 -07001533 rtc_test("audio_codec_speed_tests") {
aleloie6b60a42016-07-28 02:34:30 -07001534 testonly = true
1535 defines = []
1536 deps = []
1537 sources = [
1538 "codecs/isac/fix/test/isac_speed_test.cc",
1539 "codecs/opus/opus_speed_test.cc",
1540 "codecs/tools/audio_codec_speed_test.cc",
1541 "codecs/tools/audio_codec_speed_test.h",
1542 ]
1543
kjellandere40a7ee2016-10-16 23:56:12 -07001544 if (!build_with_chromium && is_clang) {
1545 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
ehmaldonado38a21322016-09-02 04:10:34 -07001546 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
aleloie6b60a42016-07-28 02:34:30 -07001547 }
1548
minyue81f1da32017-07-27 05:49:57 -07001549 data = audio_codec_speed_tests_resources
1550
aleloie6b60a42016-07-28 02:34:30 -07001551 if (is_android) {
1552 deps += [ "//testing/android/native_test:native_test_native_code" ]
sakal714dd4e2016-08-15 02:29:11 -07001553 shard_timeout = 900
aleloie6b60a42016-07-28 02:34:30 -07001554 }
1555
minyue81f1da32017-07-27 05:49:57 -07001556 if (is_ios) {
1557 deps += [ ":audio_codec_speed_tests_data" ]
1558 }
1559
aleloie6b60a42016-07-28 02:34:30 -07001560 deps += [
1561 ":isac_fix",
1562 ":webrtc_opus",
kjellander676e08f2016-12-07 08:23:27 -08001563 "../..:webrtc_common",
Stefan Holmer1acbd682017-09-01 15:29:28 +02001564 "../../api:libjingle_peerconnection_api",
ehmaldonadof6a861a2017-07-19 10:40:47 -07001565 "../../rtc_base:rtc_base_approved",
Stefan Holmer1acbd682017-09-01 15:29:28 +02001566 "../../system_wrappers:metrics_default",
aleloie6b60a42016-07-28 02:34:30 -07001567 "../../system_wrappers:system_wrappers_default",
Stefan Holmer1acbd682017-09-01 15:29:28 +02001568 "../../test:field_trial",
ehmaldonado26bddb92016-11-30 06:12:01 -08001569 "../../test:test_main",
kjellander6ceab082016-10-28 05:44:03 -07001570 "../audio_processing",
aleloie6b60a42016-07-28 02:34:30 -07001571 "//testing/gtest",
1572 ]
1573 }
1574
ehmaldonado38a21322016-09-02 04:10:34 -07001575 rtc_source_set("neteq_test_support") {
kjellanderfb114242016-06-13 00:19:48 -07001576 testonly = true
1577 sources = [
1578 "neteq/tools/neteq_external_decoder_test.cc",
1579 "neteq/tools/neteq_external_decoder_test.h",
1580 "neteq/tools/neteq_performance_test.cc",
1581 "neteq/tools/neteq_performance_test.h",
kjellanderfb114242016-06-13 00:19:48 -07001582 ]
1583
kjellandere40a7ee2016-10-16 23:56:12 -07001584 if (!build_with_chromium && is_clang) {
1585 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
ehmaldonado38a21322016-09-02 04:10:34 -07001586 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
kjellanderfb114242016-06-13 00:19:48 -07001587 }
1588
1589 deps = [
1590 ":neteq",
henrik.lundinb637a942017-04-28 00:59:45 -07001591 ":neteq_test_tools",
kjellanderfb114242016-06-13 00:19:48 -07001592 ":pcm16b",
mbonadei1140f972017-04-26 03:38:35 -07001593 "..:module_api",
kjellander676e08f2016-12-07 08:23:27 -08001594 "../..:webrtc_common",
kwiberg087bd342017-02-10 08:15:44 -08001595 "../../api/audio_codecs:audio_codecs_api",
1596 "../../api/audio_codecs:builtin_audio_decoder_factory",
ehmaldonadof6a861a2017-07-19 10:40:47 -07001597 "../../rtc_base:rtc_base_approved",
kjellander676e08f2016-12-07 08:23:27 -08001598 "../../system_wrappers",
1599 "../../test:test_support",
kjellanderfb114242016-06-13 00:19:48 -07001600 "//testing/gtest",
kjellanderfb114242016-06-13 00:19:48 -07001601 ]
1602 }
1603
ehmaldonado38a21322016-09-02 04:10:34 -07001604 rtc_source_set("neteq_quality_test_support") {
ehmaldonado861da3c2016-08-19 07:02:24 -07001605 testonly = true
1606 sources = [
1607 "neteq/tools/neteq_quality_test.cc",
1608 "neteq/tools/neteq_quality_test.h",
1609 ]
1610
kjellandere40a7ee2016-10-16 23:56:12 -07001611 if (!build_with_chromium && is_clang) {
1612 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
ehmaldonado38a21322016-09-02 04:10:34 -07001613 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
ehmaldonado861da3c2016-08-19 07:02:24 -07001614 }
1615
1616 deps = [
1617 ":neteq",
henrik.lundinb637a942017-04-28 00:59:45 -07001618 ":neteq_test_tools",
mbonadei1140f972017-04-26 03:38:35 -07001619 "..:module_api",
kjellander676e08f2016-12-07 08:23:27 -08001620 "../..:webrtc_common",
kwiberg087bd342017-02-10 08:15:44 -08001621 "../../api/audio_codecs:builtin_audio_decoder_factory",
ehmaldonadof6a861a2017-07-19 10:40:47 -07001622 "../../rtc_base:rtc_base_approved",
kjellander676e08f2016-12-07 08:23:27 -08001623 "../../test:test_support",
ehmaldonado6c46eaa2016-08-22 09:48:02 -07001624 "//testing/gtest",
ehmaldonado861da3c2016-08-19 07:02:24 -07001625 ]
1626 }
1627
henrik.lundinb637a942017-04-28 00:59:45 -07001628 rtc_source_set("neteq_test_tools_deprecated") {
aleloi3022a342016-07-26 06:36:03 -07001629 testonly = true
1630 sources = [
1631 "neteq/test/NETEQTEST_DummyRTPpacket.cc",
1632 "neteq/test/NETEQTEST_DummyRTPpacket.h",
1633 "neteq/test/NETEQTEST_RTPpacket.cc",
1634 "neteq/test/NETEQTEST_RTPpacket.h",
1635 ]
1636
1637 deps = [
1638 ":cng",
1639 ":g711",
1640 ":g722",
1641 ":ilbc",
1642 ":isac",
1643 ":pcm16b",
mbonadei1140f972017-04-26 03:38:35 -07001644 "..:module_api",
aleloi3022a342016-07-26 06:36:03 -07001645 "../..:webrtc_common",
1646 "//testing/gtest",
1647 ]
1648
1649 include_dirs = [
1650 "neteq/include",
1651 "neteq/test",
aleloi3022a342016-07-26 06:36:03 -07001652 ]
1653
1654 if (is_win) {
1655 cflags = [
1656 # Disable warnings to enable Win64 build, issue 1323.
1657 "/wd4267", # size_t to int truncation
1658 ]
1659 }
1660 }
aleloi47bded42016-07-26 06:46:19 -07001661
aleloi82667732016-08-02 01:45:50 -07001662 config("RTPencode_config") {
1663 defines = [
1664 "CODEC_ILBC",
1665 "CODEC_PCM16B",
1666 "CODEC_G711",
1667 "CODEC_G722",
1668 "CODEC_ISAC",
1669 "CODEC_PCM16B_WB",
1670 "CODEC_ISAC_SWB",
1671 "CODEC_PCM16B_32KHZ",
1672 "CODEC_PCM16B_48KHZ",
1673 "CODEC_CNGCODEC8",
1674 "CODEC_CNGCODEC16",
1675 "CODEC_CNGCODEC32",
1676 "CODEC_ATEVENT_DECODE",
1677 "CODEC_RED",
1678 "CODEC_OPUS",
1679 ]
1680 }
1681
ehmaldonado38a21322016-09-02 04:10:34 -07001682 rtc_executable("RTPencode") {
aleloi82667732016-08-02 01:45:50 -07001683 testonly = true
1684
1685 deps = [
1686 # TODO(hlundin): Make RTPencode use ACM to encode files.
1687 ":cng",
1688 ":g711",
1689 ":g722",
1690 ":ilbc",
1691 ":isac",
kjellander676e08f2016-12-07 08:23:27 -08001692 ":neteq",
henrik.lundinb637a942017-04-28 00:59:45 -07001693 ":neteq_test_tools_deprecated",
aleloi82667732016-08-02 01:45:50 -07001694 ":pcm16b",
1695 ":webrtc_opus",
kjellander676e08f2016-12-07 08:23:27 -08001696 "../..:webrtc_common",
aleloi82667732016-08-02 01:45:50 -07001697 "../../common_audio",
ehmaldonadof6a861a2017-07-19 10:40:47 -07001698 "../../rtc_base:rtc_base_approved",
Stefan Holmer1acbd682017-09-01 15:29:28 +02001699 "../../system_wrappers:metrics_default",
1700 "../../test:field_trial",
aleloi82667732016-08-02 01:45:50 -07001701 ]
1702
1703 configs += [ ":RTPencode_config" ]
1704
1705 sources = [
henrik.lundina8e2c632017-05-11 07:18:06 -07001706 "neteq/test/PayloadTypes.h",
aleloi82667732016-08-02 01:45:50 -07001707 "neteq/test/RTPencode.cc",
1708 ]
1709
1710 include_dirs = [
1711 "neteq/include",
1712 "neteq/test",
1713 ]
1714
1715 if (is_win) {
1716 cflags = [
1717 # Disable warnings to enable Win64 build, issue 1323.
1718 "/wd4267", # size_t to int truncation
1719 ]
1720 }
1721 }
1722
ehmaldonado38a21322016-09-02 04:10:34 -07001723 rtc_executable("RTPchange") {
aleloi76cbe192016-08-02 02:05:03 -07001724 testonly = true
1725
1726 sources = [
1727 "neteq/test/RTPchange.cc",
1728 ]
1729
1730 deps = [
henrik.lundinb637a942017-04-28 00:59:45 -07001731 ":neteq_test_tools_deprecated",
aleloi76cbe192016-08-02 02:05:03 -07001732 ]
1733 }
1734
ehmaldonado38a21322016-09-02 04:10:34 -07001735 rtc_executable("rtpcat") {
aleloi5556dcb2016-08-02 04:27:25 -07001736 testonly = true
1737
1738 sources = [
1739 "neteq/tools/rtpcat.cc",
1740 ]
1741
1742 deps = [
ehmaldonadof6a861a2017-07-19 10:40:47 -07001743 "../../rtc_base:rtc_base_approved",
aleloi5556dcb2016-08-02 04:27:25 -07001744 "../../system_wrappers:system_wrappers_default",
1745 "../../test:rtp_test_utils",
1746 "//testing/gtest",
1747 ]
1748 }
1749
ehmaldonado38a21322016-09-02 04:10:34 -07001750 rtc_executable("RTPtimeshift") {
aleloi5a746502016-08-02 06:06:33 -07001751 testonly = true
1752
1753 sources = [
1754 "neteq/test/RTPtimeshift.cc",
1755 ]
1756
1757 deps = [
henrik.lundinb637a942017-04-28 00:59:45 -07001758 ":neteq_test_tools_deprecated",
kjellander676e08f2016-12-07 08:23:27 -08001759 "../../test:test_support",
aleloi5a746502016-08-02 06:06:33 -07001760 "//testing/gtest",
1761 ]
1762 }
1763
ehmaldonado38a21322016-09-02 04:10:34 -07001764 rtc_executable("RTPjitter") {
aleloi17dfa742016-08-03 01:17:25 -07001765 testonly = true
1766 deps = [
1767 "../..:webrtc_common",
ehmaldonadof6a861a2017-07-19 10:40:47 -07001768 "../../rtc_base:rtc_base_approved",
kjellander676e08f2016-12-07 08:23:27 -08001769 "../../test:test_support",
aleloi17dfa742016-08-03 01:17:25 -07001770 "//testing/gtest",
1771 ]
1772 sources = [
1773 "neteq/test/RTPjitter.cc",
1774 ]
1775 }
1776
ehmaldonado38a21322016-09-02 04:10:34 -07001777 rtc_executable("rtp_analyze") {
aleloi47bded42016-07-26 06:46:19 -07001778 testonly = true
1779
1780 sources = [
1781 "neteq/tools/rtp_analyze.cc",
1782 ]
1783
1784 deps = [
1785 ":neteq",
henrik.lundinb637a942017-04-28 00:59:45 -07001786 ":neteq_test_tools",
aleloi47bded42016-07-26 06:46:19 -07001787 ":pcm16b",
oprypin6e09d872017-08-31 03:21:39 -07001788 "../../rtc_base:rtc_base_approved",
aleloi47bded42016-07-26 06:46:19 -07001789 "../../system_wrappers:system_wrappers_default",
1790 "//testing/gtest",
aleloi47bded42016-07-26 06:46:19 -07001791 ]
1792
kjellandere40a7ee2016-10-16 23:56:12 -07001793 if (!build_with_chromium && is_clang) {
1794 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
ehmaldonado38a21322016-09-02 04:10:34 -07001795 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
aleloi47bded42016-07-26 06:46:19 -07001796 }
1797 }
aleloi630c6d52016-08-10 02:11:30 -07001798
ehmaldonado38a21322016-09-02 04:10:34 -07001799 rtc_executable("neteq_opus_quality_test") {
aleloi630c6d52016-08-10 02:11:30 -07001800 testonly = true
1801
1802 sources = [
1803 "neteq/test/neteq_opus_quality_test.cc",
1804 ]
1805
1806 deps = [
1807 ":neteq",
ehmaldonado861da3c2016-08-19 07:02:24 -07001808 ":neteq_quality_test_support",
henrik.lundinb637a942017-04-28 00:59:45 -07001809 ":neteq_tools",
aleloi630c6d52016-08-10 02:11:30 -07001810 ":webrtc_opus",
oprypin9b2f20c2017-08-29 05:51:57 -07001811 "../../rtc_base:rtc_base_approved",
ehmaldonado26bddb92016-11-30 06:12:01 -08001812 "../../test:test_main",
aleloi630c6d52016-08-10 02:11:30 -07001813 "//testing/gtest",
aleloi630c6d52016-08-10 02:11:30 -07001814 ]
aleloi630c6d52016-08-10 02:11:30 -07001815 }
aleloi116fd612016-08-10 04:16:36 -07001816
ehmaldonado38a21322016-09-02 04:10:34 -07001817 rtc_executable("neteq_speed_test") {
aleloi116fd612016-08-10 04:16:36 -07001818 testonly = true
1819
1820 sources = [
1821 "neteq/test/neteq_speed_test.cc",
1822 ]
1823
1824 deps = [
1825 ":neteq",
1826 ":neteq_test_support",
kjellander676e08f2016-12-07 08:23:27 -08001827 "../..:webrtc_common",
oprypin6e09d872017-08-31 03:21:39 -07001828 "../../rtc_base:rtc_base_approved",
aleloi116fd612016-08-10 04:16:36 -07001829 "../../system_wrappers:system_wrappers_default",
1830 "../../test:test_support",
aleloi116fd612016-08-10 04:16:36 -07001831 ]
1832 }
aleloi63910122016-08-10 04:41:14 -07001833
ehmaldonado38a21322016-09-02 04:10:34 -07001834 rtc_executable("neteq_ilbc_quality_test") {
aleloi0e0be0a2016-08-10 04:55:20 -07001835 testonly = true
1836
1837 sources = [
1838 "neteq/test/neteq_ilbc_quality_test.cc",
1839 ]
1840
1841 deps = [
1842 ":ilbc",
1843 ":neteq",
ehmaldonado861da3c2016-08-19 07:02:24 -07001844 ":neteq_quality_test_support",
henrik.lundinb637a942017-04-28 00:59:45 -07001845 ":neteq_tools",
kjellander676e08f2016-12-07 08:23:27 -08001846 "../..:webrtc_common",
ehmaldonadof6a861a2017-07-19 10:40:47 -07001847 "../../rtc_base:rtc_base_approved",
aleloi0e0be0a2016-08-10 04:55:20 -07001848 "../../system_wrappers:system_wrappers_default",
ehmaldonado26bddb92016-11-30 06:12:01 -08001849 "../../test:test_main",
aleloi0e0be0a2016-08-10 04:55:20 -07001850 "//testing/gtest",
aleloi0e0be0a2016-08-10 04:55:20 -07001851 ]
1852 }
aleloi6df36dc2016-08-10 05:04:47 -07001853
ehmaldonado38a21322016-09-02 04:10:34 -07001854 rtc_executable("neteq_isac_quality_test") {
aleloi6df36dc2016-08-10 05:04:47 -07001855 testonly = true
1856
1857 sources = [
1858 "neteq/test/neteq_isac_quality_test.cc",
1859 ]
1860
1861 deps = [
1862 ":isac_fix",
1863 ":neteq",
ehmaldonado861da3c2016-08-19 07:02:24 -07001864 ":neteq_quality_test_support",
ehmaldonadof6a861a2017-07-19 10:40:47 -07001865 "../../rtc_base:rtc_base_approved",
ehmaldonado26bddb92016-11-30 06:12:01 -08001866 "../../test:test_main",
aleloi6df36dc2016-08-10 05:04:47 -07001867 "//testing/gtest",
aleloi6df36dc2016-08-10 05:04:47 -07001868 ]
1869 }
aleloic4ac7002016-08-10 05:06:27 -07001870
ehmaldonado38a21322016-09-02 04:10:34 -07001871 rtc_executable("neteq_pcmu_quality_test") {
aleloic4ac7002016-08-10 05:06:27 -07001872 testonly = true
1873
1874 sources = [
1875 "neteq/test/neteq_pcmu_quality_test.cc",
1876 ]
1877
1878 deps = [
1879 ":g711",
1880 ":neteq",
ehmaldonado861da3c2016-08-19 07:02:24 -07001881 ":neteq_quality_test_support",
ehmaldonadof6a861a2017-07-19 10:40:47 -07001882 "../../rtc_base:rtc_base_approved",
ehmaldonado26bddb92016-11-30 06:12:01 -08001883 "../../test:test_main",
aleloic4ac7002016-08-10 05:06:27 -07001884 "//testing/gtest",
aleloic4ac7002016-08-10 05:06:27 -07001885 ]
1886 }
aleloib7186d02016-08-16 01:47:16 -07001887
ehmaldonado38a21322016-09-02 04:10:34 -07001888 rtc_executable("isac_fix_test") {
aleloib7186d02016-08-16 01:47:16 -07001889 testonly = true
1890
1891 sources = [
1892 "codecs/isac/fix/test/kenny.cc",
1893 ]
1894
1895 deps = [
1896 ":isac_fix",
1897 "../../test:test_support",
1898 ]
1899
ehmaldonado25586ce2017-09-07 23:18:35 -07001900 data = [
Mirko Bonadei92ea95e2017-09-15 06:47:31 +02001901 "../../resources/speech_and_misc_wb.pcm",
ehmaldonado25586ce2017-09-07 23:18:35 -07001902 ]
1903
aleloib7186d02016-08-16 01:47:16 -07001904 if (is_win) {
1905 cflags = [
1906 # Disable warnings to enable Win64 build, issue 1323.
1907 "/wd4267", # size_t to int truncation
1908 ]
1909 }
1910 }
aleloi16f55a12016-08-23 08:08:23 -07001911
ehmaldonadod02fe4b2016-08-26 13:31:24 -07001912 config("isac_test_warnings_config") {
1913 if (is_win && is_clang) {
1914 cflags = [
1915 # Disable warnings failing when compiling with Clang on Windows.
1916 # https://bugs.chromium.org/p/webrtc/issues/detail?id=5366
1917 "-Wno-format",
1918 ]
1919 }
1920 }
1921
kjellander7439f972016-12-05 22:47:46 -08001922 rtc_source_set("isac_test_util") {
1923 testonly = true
1924 sources = [
1925 "codecs/isac/main/util/utility.c",
1926 ]
1927 }
1928
ehmaldonado38a21322016-09-02 04:10:34 -07001929 rtc_executable("isac_test") {
ivoce51b41a2016-08-24 02:25:57 -07001930 testonly = true
1931
1932 sources = [
1933 "codecs/isac/main/test/simpleKenny.c",
ivoce51b41a2016-08-24 02:25:57 -07001934 ]
1935
1936 include_dirs = [
1937 "codecs/isac/main/include",
1938 "codecs/isac/main/test",
1939 "codecs/isac/main/util",
1940 ]
1941
1942 deps = [
1943 ":isac",
kjellander7439f972016-12-05 22:47:46 -08001944 ":isac_test_util",
ehmaldonadof6a861a2017-07-19 10:40:47 -07001945 "../../rtc_base:rtc_base_approved",
ivoce51b41a2016-08-24 02:25:57 -07001946 ]
1947
ehmaldonadod02fe4b2016-08-26 13:31:24 -07001948 configs += [ ":isac_test_warnings_config" ]
ivoce51b41a2016-08-24 02:25:57 -07001949 }
1950
ehmaldonado38a21322016-09-02 04:10:34 -07001951 rtc_executable("g711_test") {
aleloi16f55a12016-08-23 08:08:23 -07001952 testonly = true
1953
1954 sources = [
1955 "codecs/g711/test/testG711.cc",
1956 ]
1957
aleloi16f55a12016-08-23 08:08:23 -07001958 deps = [
1959 ":g711",
1960 ]
1961 }
aleloi9a117842016-08-23 08:36:10 -07001962
ehmaldonado38a21322016-09-02 04:10:34 -07001963 rtc_executable("g722_test") {
aleloi9a117842016-08-23 08:36:10 -07001964 testonly = true
1965
1966 sources = [
1967 "codecs/g722/test/testG722.cc",
1968 ]
1969
aleloi9a117842016-08-23 08:36:10 -07001970 deps = [
1971 ":g722",
1972 "../..:webrtc_common",
1973 ]
1974 }
ivoc2c670db2016-08-24 06:11:18 -07001975
ehmaldonado38a21322016-09-02 04:10:34 -07001976 rtc_executable("isac_api_test") {
aleloicfee2152016-08-29 04:09:19 -07001977 testonly = true
1978
1979 sources = [
1980 "codecs/isac/main/test/ReleaseTest-API/ReleaseTest-API.cc",
aleloicfee2152016-08-29 04:09:19 -07001981 ]
1982
aleloicfee2152016-08-29 04:09:19 -07001983 deps = [
1984 ":isac",
kjellander7439f972016-12-05 22:47:46 -08001985 ":isac_test_util",
ehmaldonadof6a861a2017-07-19 10:40:47 -07001986 "../../rtc_base:rtc_base_approved",
aleloicfee2152016-08-29 04:09:19 -07001987 ]
1988
1989 include_dirs = [
1990 "codecs/isac/main/include",
1991 "codecs/isac/main/test",
1992 "codecs/isac/main/util",
1993 ]
1994 }
1995
ehmaldonado38a21322016-09-02 04:10:34 -07001996 rtc_executable("isac_switch_samprate_test") {
aleloicfee2152016-08-29 04:09:19 -07001997 testonly = true
1998
1999 sources = [
2000 "codecs/isac/main/test/SwitchingSampRate/SwitchingSampRate.cc",
aleloicfee2152016-08-29 04:09:19 -07002001 ]
2002
aleloicfee2152016-08-29 04:09:19 -07002003 deps = [
2004 ":isac",
kjellander7439f972016-12-05 22:47:46 -08002005 ":isac_test_util",
aleloicfee2152016-08-29 04:09:19 -07002006 ]
2007
2008 include_dirs = [
2009 "codecs/isac/main/include",
2010 "codecs/isac/main/test",
2011 "codecs/isac/main/util",
2012 "../../common_audio/signal_processing/include",
2013 ]
2014 }
2015
ehmaldonado38a21322016-09-02 04:10:34 -07002016 rtc_executable("ilbc_test") {
aleloicfee2152016-08-29 04:09:19 -07002017 testonly = true
2018
2019 sources = [
2020 "codecs/ilbc/test/iLBC_test.c",
2021 ]
2022
aleloicfee2152016-08-29 04:09:19 -07002023 deps = [
2024 ":ilbc",
aleloicfee2152016-08-29 04:09:19 -07002025 ]
2026 }
2027
ehmaldonado38a21322016-09-02 04:10:34 -07002028 rtc_executable("webrtc_opus_fec_test") {
ivoc2c670db2016-08-24 06:11:18 -07002029 testonly = true
2030
2031 sources = [
2032 "codecs/opus/opus_fec_test.cc",
2033 ]
2034
2035 deps = [
2036 ":webrtc_opus",
ivoc2c670db2016-08-24 06:11:18 -07002037 "../../common_audio",
ehmaldonadof6a861a2017-07-19 10:40:47 -07002038 "../../rtc_base:rtc_base_approved",
ehmaldonado26bddb92016-11-30 06:12:01 -08002039 "../../test:test_main",
ivoc2c670db2016-08-24 06:11:18 -07002040 "//testing/gtest",
2041 ]
2042
kjellandere40a7ee2016-10-16 23:56:12 -07002043 if (!build_with_chromium && is_clang) {
2044 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
ehmaldonado38a21322016-09-02 04:10:34 -07002045 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
ivoc2c670db2016-08-24 06:11:18 -07002046 }
2047 }
ehmaldonado36268652017-01-19 08:27:11 -08002048
2049 rtc_source_set("audio_coding_unittests") {
2050 testonly = true
2051
kjellandere0629c02017-04-25 04:04:50 -07002052 # Skip restricting visibility on mobile platforms since the tests on those
2053 # gets additional generated targets which would require many lines here to
2054 # cover (which would be confusing to read and hard to maintain).
2055 if (!is_android && !is_ios) {
jianjun.zhuc0247402017-07-11 06:20:45 -07002056 visibility = [ "..:modules_unittests" ]
kjellandere0629c02017-04-25 04:04:50 -07002057 }
ehmaldonado36268652017-01-19 08:27:11 -08002058 sources = [
2059 "acm2/acm_receiver_unittest.cc",
2060 "acm2/audio_coding_module_unittest.cc",
2061 "acm2/call_statistics_unittest.cc",
2062 "acm2/codec_manager_unittest.cc",
2063 "acm2/rent_a_codec_unittest.cc",
2064 "audio_network_adaptor/audio_network_adaptor_impl_unittest.cc",
2065 "audio_network_adaptor/bitrate_controller_unittest.cc",
2066 "audio_network_adaptor/channel_controller_unittest.cc",
2067 "audio_network_adaptor/controller_manager_unittest.cc",
2068 "audio_network_adaptor/dtx_controller_unittest.cc",
minyue4b7c9522017-01-24 04:54:59 -08002069 "audio_network_adaptor/event_log_writer_unittest.cc",
elad.alon6d7900d2017-03-24 04:12:56 -07002070 "audio_network_adaptor/fec_controller_plr_based_unittest.cc",
2071 "audio_network_adaptor/fec_controller_rplr_based_unittest.cc",
ehmaldonado36268652017-01-19 08:27:11 -08002072 "audio_network_adaptor/frame_length_controller_unittest.cc",
2073 "audio_network_adaptor/mock/mock_controller.h",
2074 "audio_network_adaptor/mock/mock_controller_manager.h",
elad.alon326263a2017-03-29 03:16:58 -07002075 "audio_network_adaptor/util/threshold_curve_unittest.cc",
kwiberg087bd342017-02-10 08:15:44 -08002076 "codecs/builtin_audio_decoder_factory_unittest.cc",
ossua1a040a2017-04-06 10:03:21 -07002077 "codecs/builtin_audio_encoder_factory_unittest.cc",
ehmaldonado36268652017-01-19 08:27:11 -08002078 "codecs/cng/audio_encoder_cng_unittest.cc",
2079 "codecs/cng/cng_unittest.cc",
2080 "codecs/ilbc/ilbc_unittest.cc",
2081 "codecs/isac/fix/source/filterbanks_unittest.cc",
2082 "codecs/isac/fix/source/filters_unittest.cc",
2083 "codecs/isac/fix/source/lpc_masking_model_unittest.cc",
2084 "codecs/isac/fix/source/transform_unittest.cc",
2085 "codecs/isac/main/source/audio_encoder_isac_unittest.cc",
2086 "codecs/isac/main/source/isac_unittest.cc",
2087 "codecs/isac/unittest.cc",
2088 "codecs/legacy_encoded_audio_frame_unittest.cc",
ehmaldonado36268652017-01-19 08:27:11 -08002089 "codecs/opus/audio_encoder_opus_unittest.cc",
2090 "codecs/opus/opus_unittest.cc",
2091 "codecs/red/audio_encoder_copy_red_unittest.cc",
2092 "neteq/audio_multi_vector_unittest.cc",
2093 "neteq/audio_vector_unittest.cc",
2094 "neteq/background_noise_unittest.cc",
2095 "neteq/buffer_level_filter_unittest.cc",
2096 "neteq/comfort_noise_unittest.cc",
2097 "neteq/decision_logic_unittest.cc",
2098 "neteq/decoder_database_unittest.cc",
2099 "neteq/delay_manager_unittest.cc",
2100 "neteq/delay_peak_detector_unittest.cc",
2101 "neteq/dsp_helper_unittest.cc",
2102 "neteq/dtmf_buffer_unittest.cc",
2103 "neteq/dtmf_tone_generator_unittest.cc",
2104 "neteq/expand_unittest.cc",
2105 "neteq/merge_unittest.cc",
ehmaldonado36268652017-01-19 08:27:11 -08002106 "neteq/mock/mock_buffer_level_filter.h",
2107 "neteq/mock/mock_decoder_database.h",
2108 "neteq/mock/mock_delay_manager.h",
2109 "neteq/mock/mock_delay_peak_detector.h",
2110 "neteq/mock/mock_dtmf_buffer.h",
2111 "neteq/mock/mock_dtmf_tone_generator.h",
2112 "neteq/mock/mock_expand.h",
2113 "neteq/mock/mock_external_decoder_pcm16b.h",
2114 "neteq/mock/mock_packet_buffer.h",
2115 "neteq/mock/mock_red_payload_splitter.h",
minyue-webrtcfae474c2017-07-05 11:17:40 +02002116 "neteq/mock/mock_statistics_calculator.h",
ehmaldonado36268652017-01-19 08:27:11 -08002117 "neteq/nack_tracker_unittest.cc",
2118 "neteq/neteq_external_decoder_unittest.cc",
2119 "neteq/neteq_impl_unittest.cc",
2120 "neteq/neteq_network_stats_unittest.cc",
2121 "neteq/neteq_stereo_unittest.cc",
2122 "neteq/neteq_unittest.cc",
2123 "neteq/normal_unittest.cc",
2124 "neteq/packet_buffer_unittest.cc",
2125 "neteq/post_decode_vad_unittest.cc",
2126 "neteq/random_vector_unittest.cc",
2127 "neteq/red_payload_splitter_unittest.cc",
Henrik Lundinac0a5032017-09-25 12:22:46 +02002128 "neteq/statistics_calculator_unittest.cc",
ehmaldonado36268652017-01-19 08:27:11 -08002129 "neteq/sync_buffer_unittest.cc",
2130 "neteq/tick_timer_unittest.cc",
2131 "neteq/time_stretch_unittest.cc",
2132 "neteq/timestamp_scaler_unittest.cc",
2133 "neteq/tools/input_audio_file_unittest.cc",
2134 "neteq/tools/packet_unittest.cc",
2135 ]
2136
2137 deps = [
2138 ":acm_receive_test",
2139 ":acm_send_test",
2140 ":audio_coding",
kwiberg65cb70d2017-03-03 06:16:28 -08002141 ":audio_coding_module_typedefs",
ehmaldonado36268652017-01-19 08:27:11 -08002142 ":audio_format_conversion",
2143 ":audio_network_adaptor",
ehmaldonado36268652017-01-19 08:27:11 -08002144 ":cng",
2145 ":g711",
2146 ":ilbc",
kwiberga6ca5182017-01-30 05:28:54 -08002147 ":isac",
ehmaldonado36268652017-01-19 08:27:11 -08002148 ":isac_c",
2149 ":isac_fix",
kwiberg087bd342017-02-10 08:15:44 -08002150 ":legacy_encoded_audio_frame",
ehmaldonado36268652017-01-19 08:27:11 -08002151 ":neteq",
2152 ":neteq_test_support",
henrik.lundinb637a942017-04-28 00:59:45 -07002153 ":neteq_test_tools",
ehmaldonado36268652017-01-19 08:27:11 -08002154 ":pcm16b",
2155 ":red",
2156 ":rent_a_codec",
2157 ":webrtc_opus",
mbonadei1140f972017-04-26 03:38:35 -07002158 "..:module_api",
ehmaldonado36268652017-01-19 08:27:11 -08002159 "../..:webrtc_common",
kwiberg087bd342017-02-10 08:15:44 -08002160 "../../api/audio_codecs:audio_codecs_api",
2161 "../../api/audio_codecs:builtin_audio_decoder_factory",
ossueb1fde42017-05-02 06:46:30 -07002162 "../../api/audio_codecs:builtin_audio_encoder_factory",
Karl Wiberg7275e182017-10-25 09:57:40 +02002163 "../../api/audio_codecs/opus:audio_encoder_opus",
ehmaldonado36268652017-01-19 08:27:11 -08002164 "../../common_audio",
charujain9a451162017-09-15 03:51:34 -07002165 "../../common_audio:mock_common_audio",
Elad Alon4a87e1c2017-10-03 16:11:34 +02002166 "../../logging:rtc_event_log_api",
ehmaldonadof6a861a2017-07-19 10:40:47 -07002167 "../../rtc_base:protobuf_utils",
2168 "../../rtc_base:rtc_base",
2169 "../../rtc_base:rtc_base_approved",
2170 "../../rtc_base:rtc_base_tests_utils",
ehmaldonado36268652017-01-19 08:27:11 -08002171 "../../system_wrappers:system_wrappers",
kwiberg37e99fd2017-04-10 05:15:48 -07002172 "../../test:audio_codec_mocks",
ehmaldonado36268652017-01-19 08:27:11 -08002173 "../../test:field_trial",
2174 "../../test:rtp_test_utils",
2175 "../../test:test_common",
2176 "../../test:test_support",
2177 "//testing/gmock",
2178 "//testing/gtest",
ehmaldonado36268652017-01-19 08:27:11 -08002179 ]
2180
2181 defines = audio_coding_defines
2182
2183 if (rtc_enable_protobuf) {
minyue-webrtc7ed35f42017-06-13 11:49:29 +02002184 defines += [ "WEBRTC_NETEQ_UNITTEST_BITEXACT" ]
ehmaldonado36268652017-01-19 08:27:11 -08002185 deps += [
2186 ":ana_config_proto",
2187 ":neteq_unittest_proto",
2188 ]
2189 }
2190
2191 if (!build_with_chromium && is_clang) {
2192 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
2193 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
2194 }
2195 }
kjellanderfb114242016-06-13 00:19:48 -07002196}
kwiberg087bd342017-02-10 08:15:44 -08002197
2198# For backwards compatibility only! Use
2199# webrtc/api/audio_codecs:audio_codecs_api instead.
2200# TODO(kwiberg): Remove this.
2201rtc_source_set("audio_decoder_interface") {
2202 sources = [
2203 "codecs/audio_decoder.h",
2204 ]
2205 deps = [
2206 "../../api/audio_codecs:audio_codecs_api",
2207 ]
2208}
2209
2210# For backwards compatibility only! Use
ossueb1fde42017-05-02 06:46:30 -07002211# webrtc/api/audio_codecs:audio_codecs_api instead.
2212# TODO(ossu): Remove this.
2213rtc_source_set("audio_encoder_interface") {
2214 sources = [
2215 "codecs/audio_encoder.h",
2216 ]
2217 deps = [
2218 "../../api/audio_codecs:audio_codecs_api",
2219 ]
2220}
2221
2222# For backwards compatibility only! Use
kwiberg087bd342017-02-10 08:15:44 -08002223# webrtc/api/audio_codecs:builtin_audio_decoder_factory instead.
2224# TODO(kwiberg): Remove this.
2225rtc_source_set("builtin_audio_decoder_factory") {
2226 sources = [
2227 "codecs/builtin_audio_decoder_factory.h",
2228 ]
2229 deps = [
2230 "../../api/audio_codecs:builtin_audio_decoder_factory",
2231 ]
2232}
ossueb1fde42017-05-02 06:46:30 -07002233
2234# For backwards compatibility only! Use
2235# webrtc/api/audio_codecs:builtin_audio_decoder_factory instead.
2236# TODO(ossu): Remove this.
2237rtc_source_set("builtin_audio_encoder_factory") {
2238 sources = [
2239 "codecs/builtin_audio_encoder_factory.h",
2240 ]
2241 deps = [
2242 "../../api/audio_codecs:builtin_audio_encoder_factory",
2243 ]
2244}