blob: 5faf28048e0fb11646c6d2ba24955e89020a87c7 [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")
kjellander@webrtc.org1227ab82014-06-23 19:21:07 +000010
kjellanderb62dbbe2016-09-23 00:38:52 -070011rtc_static_library("video") {
kjellander@webrtc.org788f0582014-08-28 13:51:08 +000012 sources = [
Peter Boström7623ce42015-12-09 12:13:30 +010013 "call_stats.cc",
14 "call_stats.h",
mflodman15d83572016-10-06 08:35:11 -070015 "encoder_rtcp_feedback.cc",
16 "encoder_rtcp_feedback.h",
Peter Boström7623ce42015-12-09 12:13:30 +010017 "overuse_frame_detector.cc",
18 "overuse_frame_detector.h",
19 "payload_router.cc",
20 "payload_router.h",
palmkvist349092b2016-12-13 02:45:57 -080021 "quality_threshold.cc",
22 "quality_threshold.h",
kjellander@webrtc.org788f0582014-08-28 13:51:08 +000023 "receive_statistics_proxy.cc",
24 "receive_statistics_proxy.h",
Peter Boström7623ce42015-12-09 12:13:30 +010025 "report_block_stats.cc",
26 "report_block_stats.h",
mflodman4cd27902016-08-05 06:28:45 -070027 "rtp_streams_synchronizer.cc",
28 "rtp_streams_synchronizer.h",
nisseb1f2ff92017-06-09 04:01:55 -070029 "rtp_video_stream_receiver.cc",
30 "rtp_video_stream_receiver.h",
asapersson35151f32016-05-02 23:44:01 -070031 "send_delay_stats.cc",
32 "send_delay_stats.h",
kjellander@webrtc.org788f0582014-08-28 13:51:08 +000033 "send_statistics_proxy.cc",
34 "send_statistics_proxy.h",
asapersson0e9d6d92016-05-23 06:07:55 -070035 "stats_counter.cc",
36 "stats_counter.h",
Peter Boström7623ce42015-12-09 12:13:30 +010037 "stream_synchronization.cc",
38 "stream_synchronization.h",
charujainbf6a45b2016-11-03 04:21:42 -070039 "transport_adapter.cc",
40 "transport_adapter.h",
kjellander@webrtc.org788f0582014-08-28 13:51:08 +000041 "video_receive_stream.cc",
42 "video_receive_stream.h",
43 "video_send_stream.cc",
44 "video_send_stream.h",
mflodmancfc8e3b2016-05-03 21:22:04 -070045 "video_stream_decoder.cc",
46 "video_stream_decoder.h",
Peter Boström7623ce42015-12-09 12:13:30 +010047 "vie_encoder.cc",
48 "vie_encoder.h",
kjellander@webrtc.org788f0582014-08-28 13:51:08 +000049 ]
50
kjellandere40a7ee2016-10-16 23:56:12 -070051 if (!build_with_chromium && is_clang) {
52 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
ehmaldonado38a21322016-09-02 04:10:34 -070053 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
kjellander@webrtc.org788f0582014-08-28 13:51:08 +000054 }
55
kwiberg@webrtc.orgac2d27d2015-02-26 13:59:22 +000056 deps = [
mbonadei81c79f52017-04-25 23:42:15 -070057 "..:video_stream_api",
kwiberg@webrtc.orgac2d27d2015-02-26 13:59:22 +000058 "..:webrtc_common",
aleloia8eb7562016-11-28 07:02:13 -080059 "../api:transport_api",
ilnikd60d06a2017-04-05 03:02:20 -070060 "../api/video_codecs:video_codecs_api",
kjellander@webrtc.org7ffeab52016-02-26 22:46:09 +010061 "../base:rtc_base_approved",
tereliusbc5d9212017-01-13 09:14:33 -080062 "../base:rtc_numerics",
perkj26091b12016-09-01 01:17:40 -070063 "../base:rtc_task_queue",
perkj39a41d92017-06-12 05:53:35 -070064 "../base:sequenced_task_checker",
65 "../base:weak_ptr",
mbonadei9087d492017-04-25 00:35:35 -070066 "../call:call_interfaces",
nissed76b7b22017-06-01 04:02:35 -070067 "../call:rtp_interfaces",
Peter Boström2ee24392015-06-22 07:57:16 +020068 "../common_video",
skvladcc91d282016-10-03 18:31:22 -070069 "../logging:rtc_event_log_api",
philipel022b54e2016-12-20 04:15:59 -080070 "../media:rtc_media_base",
mbonadei1140f972017-04-26 03:38:35 -070071 "../modules:module_api",
Peter Boström2ee24392015-06-22 07:57:16 +020072 "../modules/bitrate_controller",
kjellander@webrtc.org7ffeab52016-02-26 22:46:09 +010073 "../modules/congestion_controller",
sprangebbf8a82015-09-21 15:11:14 -070074 "../modules/pacing",
kjellander@webrtc.org7ffeab52016-02-26 22:46:09 +010075 "../modules/remote_bitrate_estimator",
Peter Boström2ee24392015-06-22 07:57:16 +020076 "../modules/rtp_rtcp",
77 "../modules/utility",
Peter Boström2ee24392015-06-22 07:57:16 +020078 "../modules/video_coding",
mbonadei9087d492017-04-25 00:35:35 -070079 "../modules/video_coding:video_coding_utility",
80 "../modules/video_coding:webrtc_vp8",
Peter Boström2ee24392015-06-22 07:57:16 +020081 "../modules/video_processing",
kjellander8237abf2015-12-08 07:12:06 -080082 "../system_wrappers",
Peter Boström7623ce42015-12-09 12:13:30 +010083 "../voice_engine",
kwiberg@webrtc.orgac2d27d2015-02-26 13:59:22 +000084 ]
kjellander@webrtc.org1227ab82014-06-23 19:21:07 +000085}
Peter Boström02083222016-06-14 12:52:54 +020086
87if (rtc_include_tests) {
kjellandera3cac052016-10-24 01:52:39 -070088 rtc_source_set("video_quality_test") {
89 testonly = true
kjellandere0629c02017-04-25 04:04:50 -070090 visibility = [ ":*" ] # Only targets in this file can depend on this.
kjellandera3cac052016-10-24 01:52:39 -070091 sources = [
92 "video_quality_test.cc",
93 "video_quality_test.h",
94 ]
95 deps = [
ilnikdf92c5c2017-02-23 02:08:44 -080096 "../base:rtc_base_tests_utils",
brandtr696c9c62016-12-19 05:47:28 -080097 "../base:rtc_task_queue",
mbonadei9087d492017-04-25 00:35:35 -070098 "../call:call_interfaces",
99 "../common_video",
100 "../logging:rtc_event_log_api",
sprang67561a62017-06-15 06:34:42 -0700101 "../media:rtc_media",
magjedceecea42016-11-28 07:20:21 -0800102 "../media:rtc_media_base",
mbonadei9087d492017-04-25 00:35:35 -0700103 "../modules/audio_mixer:audio_mixer_impl",
104 "../modules/rtp_rtcp",
105 "../modules/video_coding:webrtc_h264",
106 "../modules/video_coding:webrtc_vp8",
107 "../modules/video_coding:webrtc_vp9",
kjellandera3cac052016-10-24 01:52:39 -0700108 "../system_wrappers",
mbonadei9087d492017-04-25 00:35:35 -0700109 "../test:test_common",
110 "../test:test_support",
111 "../voice_engine",
kjellandera3cac052016-10-24 01:52:39 -0700112 "//testing/gtest",
ehmaldonado021eef32017-01-05 07:09:50 -0800113 "//webrtc/test:test_renderer",
perkjc5726c12017-03-01 03:37:08 -0800114 "//webrtc/test:video_test_common",
kjellandera3cac052016-10-24 01:52:39 -0700115 ]
kjellandera3cac052016-10-24 01:52:39 -0700116 if (!build_with_chromium && is_clang) {
117 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
118 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
119 }
120 }
121
ehmaldonado021eef32017-01-05 07:09:50 -0800122 rtc_source_set("video_full_stack_tests") {
123 testonly = true
kjellandere0629c02017-04-25 04:04:50 -0700124
125 # Skip restricting visibility on mobile platforms since the tests on those
126 # gets additional generated targets which would require many lines here to
127 # cover (which would be confusing to read and hard to maintain).
128 if (!is_android && !is_ios) {
129 visibility = [ "//webrtc:webrtc_perf_tests" ]
130 }
ehmaldonado021eef32017-01-05 07:09:50 -0800131 sources = [
132 "full_stack_tests.cc",
133 ]
134 deps = [
135 ":video_quality_test",
sprang89c4a7e2017-06-30 13:27:40 -0700136 "../modules/pacing:pacing",
mbonadei9087d492017-04-25 00:35:35 -0700137 "../test:field_trial",
138 "../test:test_support",
ehmaldonado021eef32017-01-05 07:09:50 -0800139 "//testing/gtest",
140 "//webrtc/test:test_common",
141 ]
142 if (!build_with_chromium && is_clang) {
143 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
144 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
145 }
146 if (rtc_use_h264) {
147 defines = [ "WEBRTC_USE_H264" ]
148 }
149 }
150
kjellandera3cac052016-10-24 01:52:39 -0700151 rtc_executable("video_loopback") {
152 testonly = true
153 sources = [
154 "video_loopback.cc",
155 ]
156 deps = [
157 ":video_quality_test",
sprang1168fd42017-06-21 09:00:17 -0700158 "../base:rtc_base_approved",
kjellandera3cac052016-10-24 01:52:39 -0700159 "../system_wrappers:metrics_default",
160 "../test:field_trial",
161 "../test:run_test",
162 "../test:test_common",
163 "../test:test_renderer",
mbonadei9087d492017-04-25 00:35:35 -0700164 "../test:test_support",
kjellandera3cac052016-10-24 01:52:39 -0700165 "//testing/gmock",
166 "//testing/gtest",
167 "//third_party/gflags",
168 ]
169 if (!build_with_chromium && is_clang) {
170 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
171 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
172 }
173 }
174
175 rtc_executable("screenshare_loopback") {
176 testonly = true
177 sources = [
178 "screenshare_loopback.cc",
179 ]
180
181 deps = [
182 ":video_quality_test",
mbonadei9087d492017-04-25 00:35:35 -0700183 "../base:rtc_base_approved",
kjellandera3cac052016-10-24 01:52:39 -0700184 "../system_wrappers:metrics_default",
185 "../test:field_trial",
186 "../test:run_test",
187 "../test:test_common",
188 "../test:test_renderer",
mbonadei9087d492017-04-25 00:35:35 -0700189 "../test:test_support",
kjellandera3cac052016-10-24 01:52:39 -0700190 ]
191 if (!build_with_chromium && is_clang) {
192 # Suppress warnings from Chrome's Clang plugins.
193 # See http://code.google.com/p/webrtc/issues/detail?id=163 for details.
194 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
195 }
196 }
197
stefan64427e52016-12-20 07:26:58 -0800198 rtc_executable("video_replay") {
199 testonly = true
200 sources = [
201 "replay.cc",
202 ]
203 deps = [
mbonadei9087d492017-04-25 00:35:35 -0700204 "..:webrtc_common",
ilnikd60d06a2017-04-05 03:02:20 -0700205 "../api/video_codecs:video_codecs_api",
mbonadei9087d492017-04-25 00:35:35 -0700206 "../base:rtc_base_approved",
207 "../call:call_interfaces",
208 "../common_video",
209 "../logging:rtc_event_log_api",
210 "../modules/rtp_rtcp",
211 "../system_wrappers",
stefan64427e52016-12-20 07:26:58 -0800212 "../system_wrappers:metrics_default",
213 "../test:field_trial",
mbonadei9087d492017-04-25 00:35:35 -0700214 "../test:rtp_test_utils",
stefan64427e52016-12-20 07:26:58 -0800215 "../test:run_test",
216 "../test:test_common",
217 "../test:test_renderer",
mbonadei9087d492017-04-25 00:35:35 -0700218 "../test:test_support",
219 "../test:video_test_common",
stefan64427e52016-12-20 07:26:58 -0800220 "//third_party/gflags",
221 ]
stefan64427e52016-12-20 07:26:58 -0800222 if (!build_with_chromium && is_clang) {
223 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
224 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
225 }
226 }
227
Peter Boström02083222016-06-14 12:52:54 +0200228 # TODO(pbos): Rename test suite.
ehmaldonado38a21322016-09-02 04:10:34 -0700229 rtc_source_set("video_tests") {
Peter Boström02083222016-06-14 12:52:54 +0200230 testonly = true
kjellandere0629c02017-04-25 04:04:50 -0700231
232 # Skip restricting visibility on mobile platforms since the tests on those
233 # gets additional generated targets which would require many lines here to
234 # cover (which would be confusing to read and hard to maintain).
235 if (!is_android && !is_ios) {
236 visibility = [ "//webrtc:video_engine_tests" ]
237 }
hta9aa96882016-12-06 05:36:03 -0800238 defines = []
Peter Boström02083222016-06-14 12:52:54 +0200239 sources = [
240 "call_stats_unittest.cc",
mflodman15d83572016-10-06 08:35:11 -0700241 "encoder_rtcp_feedback_unittest.cc",
Peter Boström02083222016-06-14 12:52:54 +0200242 "end_to_end_tests.cc",
243 "overuse_frame_detector_unittest.cc",
244 "payload_router_unittest.cc",
Sebastian Janssone92f93f2017-06-22 14:44:04 +0200245 "picture_id_tests.cc",
palmkvist349092b2016-12-13 02:45:57 -0800246 "quality_threshold_unittest.cc",
sakale5ba44e2016-10-26 07:09:24 -0700247 "receive_statistics_proxy_unittest.cc",
Peter Boström02083222016-06-14 12:52:54 +0200248 "report_block_stats_unittest.cc",
nisseb1f2ff92017-06-09 04:01:55 -0700249 "rtp_video_stream_receiver_unittest.cc",
Peter Boström02083222016-06-14 12:52:54 +0200250 "send_delay_stats_unittest.cc",
251 "send_statistics_proxy_unittest.cc",
252 "stats_counter_unittest.cc",
253 "stream_synchronization_unittest.cc",
johanf2183ff2017-02-28 01:33:09 -0800254 "video_receive_stream_unittest.cc",
Peter Boström02083222016-06-14 12:52:54 +0200255 "video_send_stream_tests.cc",
perkj26091b12016-09-01 01:17:40 -0700256 "vie_encoder_unittest.cc",
Peter Boström02083222016-06-14 12:52:54 +0200257 ]
258 deps = [
259 ":video",
mbonadei81c79f52017-04-25 23:42:15 -0700260 "..:video_stream_api",
mbonadei9087d492017-04-25 00:35:35 -0700261 "../api:video_frame_api",
262 "../api/video_codecs:video_codecs_api",
263 "../base:rtc_base_approved",
264 "../base:rtc_base_tests_utils",
265 "../call:call_interfaces",
nisse0f15f922017-06-21 01:05:22 -0700266 "../call:rtp_receiver",
mbonadei9087d492017-04-25 00:35:35 -0700267 "../common_video",
268 "../logging:rtc_event_log_api",
brandtr5e171752017-05-23 03:32:16 -0700269 "../media:rtc_media",
magjedceecea42016-11-28 07:20:21 -0800270 "../media:rtc_media_base",
mbonadei9087d492017-04-25 00:35:35 -0700271 "../media:rtc_media_tests_utils",
mbonadei1140f972017-04-26 03:38:35 -0700272 "../modules:module_api",
mbonadei9087d492017-04-25 00:35:35 -0700273 "../modules/pacing",
274 "../modules/rtp_rtcp",
kjellandere0629c02017-04-25 04:04:50 -0700275 "../modules/rtp_rtcp:mock_rtp_rtcp",
mbonadei9087d492017-04-25 00:35:35 -0700276 "../modules/utility",
277 "../modules/video_coding",
278 "../modules/video_coding:video_coding_utility",
279 "../modules/video_coding:webrtc_h264",
280 "../modules/video_coding:webrtc_vp8",
281 "../modules/video_coding:webrtc_vp9",
282 "../system_wrappers",
283 "../system_wrappers:field_trial_default",
284 "../system_wrappers:metrics_api",
285 "../system_wrappers:metrics_default",
286 "../test:direct_transport",
287 "../test:field_trial",
288 "../test:rtp_test_utils",
289 "../test:test_common",
290 "../test:test_support",
291 "../test:video_test_common",
Peter Boström02083222016-06-14 12:52:54 +0200292 "//testing/gmock",
293 "//testing/gtest",
294 ]
kjellandere40a7ee2016-10-16 23:56:12 -0700295 if (!build_with_chromium && is_clang) {
296 # Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
ehmaldonado38a21322016-09-02 04:10:34 -0700297 suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
Peter Boström02083222016-06-14 12:52:54 +0200298 }
brandtr445fb8f2016-11-14 04:11:23 -0800299 if (rtc_use_h264) {
hta9aa96882016-12-06 05:36:03 -0800300 defines += [ "WEBRTC_USE_H264" ]
brandtr445fb8f2016-11-14 04:11:23 -0800301 }
Peter Boström02083222016-06-14 12:52:54 +0200302 }
303}