blob: 32ac627ed244239ff8221028e0afca736261e5c4 [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
9import("../../build/webrtc.gni")
10
11source_set("video_coding") {
12 sources = [
Henrik Kjellander2557b862015-11-18 22:00:21 +010013 "codec_database.cc",
14 "codec_database.h",
15 "codec_timer.cc",
16 "codec_timer.h",
17 "content_metrics_processing.cc",
18 "content_metrics_processing.h",
19 "decoding_state.cc",
20 "decoding_state.h",
21 "encoded_frame.cc",
22 "encoded_frame.h",
23 "fec_tables_xor.h",
24 "frame_buffer.cc",
25 "frame_buffer.h",
26 "generic_decoder.cc",
27 "generic_decoder.h",
28 "generic_encoder.cc",
29 "generic_encoder.h",
30 "include/video_coding.h",
31 "include/video_coding_defines.h",
32 "inter_frame_delay.cc",
33 "inter_frame_delay.h",
34 "internal_defines.h",
35 "jitter_buffer.cc",
36 "jitter_buffer.h",
37 "jitter_buffer_common.h",
38 "jitter_estimator.cc",
39 "jitter_estimator.h",
40 "media_opt_util.cc",
41 "media_opt_util.h",
42 "media_optimization.cc",
43 "media_optimization.h",
44 "nack_fec_tables.h",
45 "packet.cc",
46 "packet.h",
47 "qm_select.cc",
48 "qm_select.h",
49 "qm_select_data.h",
50 "receiver.cc",
51 "receiver.h",
52 "rtt_filter.cc",
53 "rtt_filter.h",
54 "session_info.cc",
55 "session_info.h",
56 "timestamp_map.cc",
57 "timestamp_map.h",
58 "timing.cc",
59 "timing.h",
60 "video_coding_impl.cc",
61 "video_coding_impl.h",
62 "video_receiver.cc",
63 "video_sender.cc",
kjellander@webrtc.org1227ab82014-06-23 19:21:07 +000064 ]
65
kjellander@webrtc.orgf21ea912014-09-28 17:37:22 +000066 configs += [ "../..:common_config" ]
67 public_configs = [ "../..:common_inherited_config" ]
68
kjellander@webrtc.org8649fed2015-01-08 21:22:01 +000069 if (is_win) {
70 cflags = [
71 # TODO(jschuh): Bug 1348: fix this warning.
72 "/wd4267", # size_t to int truncation.
73 ]
74 }
75
kjellander@webrtc.org42ee5b52014-08-25 14:15:35 +000076 if (is_clang) {
77 # Suppress warnings from Chrome's Clang plugins.
78 # See http://code.google.com/p/webrtc/issues/detail?id=163 for details.
79 configs -= [ "//build/config/clang:find_bad_constructs" ]
80 }
81
kjellander@webrtc.org1227ab82014-06-23 19:21:07 +000082 deps = [
83 ":video_coding_utility",
Zeke Chin71f6f442015-06-29 14:34:58 -070084 ":webrtc_h264",
kjellander@webrtc.org1227ab82014-06-23 19:21:07 +000085 ":webrtc_i420",
86 ":webrtc_vp8",
marpan@webrtc.org5b883172014-11-01 06:10:48 +000087 ":webrtc_vp9",
kwiberg@webrtc.orgac2d27d2015-02-26 13:59:22 +000088 "../..:webrtc_common",
kjellander@webrtc.org1227ab82014-06-23 19:21:07 +000089 "../../common_video",
90 "../../system_wrappers",
91 ]
92}
93
94source_set("video_coding_utility") {
stefan@webrtc.org73823ca2014-07-07 11:46:43 +000095 sources = [
stefan@webrtc.org73823ca2014-07-07 11:46:43 +000096 "utility/frame_dropper.cc",
kjellander@webrtc.orgb7ce9642015-11-18 23:04:10 +010097 "utility/frame_dropper.h",
98 "utility/moving_average.h",
asapersson86b01602015-10-20 23:55:26 -070099 "utility/qp_parser.cc",
kjellander@webrtc.orgb7ce9642015-11-18 23:04:10 +0100100 "utility/qp_parser.h",
kjellander@webrtc.orgb8caf6a2014-09-30 18:05:02 +0000101 "utility/quality_scaler.cc",
kjellander@webrtc.orgb7ce9642015-11-18 23:04:10 +0100102 "utility/quality_scaler.h",
jackychen98d8cf52015-05-21 11:12:02 -0700103 "utility/vp8_header_parser.cc",
kjellander@webrtc.orgb7ce9642015-11-18 23:04:10 +0100104 "utility/vp8_header_parser.h",
stefan@webrtc.org73823ca2014-07-07 11:46:43 +0000105 ]
106
kjellander@webrtc.orgf21ea912014-09-28 17:37:22 +0000107 configs += [ "../..:common_config" ]
108 public_configs = [ "../..:common_inherited_config" ]
109
kjellander@webrtc.org42ee5b52014-08-25 14:15:35 +0000110 if (is_clang) {
111 # Suppress warnings from Chrome's Clang plugins.
112 # See http://code.google.com/p/webrtc/issues/detail?id=163 for details.
113 configs -= [ "//build/config/clang:find_bad_constructs" ]
114 }
115
Henrik Kjellander57e5fd22015-05-25 12:55:39 +0200116 deps = [
117 "../../system_wrappers",
118 ]
kjellander@webrtc.org1227ab82014-06-23 19:21:07 +0000119}
120
Zeke Chin71f6f442015-06-29 14:34:58 -0700121source_set("webrtc_h264") {
122 sources = [
123 "codecs/h264/h264.cc",
124 "codecs/h264/include/h264.h",
125 ]
126
127 configs += [ "../..:common_config" ]
128 public_configs = [ "../..:common_inherited_config" ]
129
130 if (is_clang) {
131 # Suppress warnings from Chrome's Clang plugins.
132 # See http://code.google.com/p/webrtc/issues/detail?id=163 for details.
133 configs -= [ "//build/config/clang:find_bad_constructs" ]
134 }
135
136 deps = [
137 "../../system_wrappers",
138 ]
hbosa9a1d2a2016-01-11 10:19:02 -0800139
140 if (use_third_party_h264) {
141 # Dependency added so that variables use_openh264 and ffmpeg_branding are
142 # recognized build arguments (avoid "Build argument has no effect" error).
143 # The variables and dependencies will be used for real as soon as
144 # https://codereview.webrtc.org/1306813009/ lands. In the meantime, the
145 # build arguments are to be used by waterfall/trybots.
146 deps += [
147 "//third_party/ffmpeg:ffmpeg",
148 "//third_party/openh264:encoder",
149 ]
150 }
Zeke Chin71f6f442015-06-29 14:34:58 -0700151}
152
153# TODO(tkchin): Source set for webrtc_h264_video_toolbox. Currently not
154# possible to add, see https://crbug.com/297668.
155
kjellander@webrtc.org1227ab82014-06-23 19:21:07 +0000156source_set("webrtc_i420") {
stefan@webrtc.org73823ca2014-07-07 11:46:43 +0000157 sources = [
Henrik Kjellandera74c08d2015-10-22 12:23:11 +0200158 "codecs/i420/i420.cc",
159 "codecs/i420/include/i420.h",
stefan@webrtc.org73823ca2014-07-07 11:46:43 +0000160 ]
161
kjellander@webrtc.orgf21ea912014-09-28 17:37:22 +0000162 configs += [ "../..:common_config" ]
163 public_configs = [ "../..:common_inherited_config" ]
164
kjellander@webrtc.org42ee5b52014-08-25 14:15:35 +0000165 if (is_clang) {
166 # Suppress warnings from Chrome's Clang plugins.
167 # See http://code.google.com/p/webrtc/issues/detail?id=163 for details.
168 configs -= [ "//build/config/clang:find_bad_constructs" ]
169 }
170
Henrik Kjellander57e5fd22015-05-25 12:55:39 +0200171 deps = [
172 "../../system_wrappers",
173 ]
kjellander@webrtc.org1227ab82014-06-23 19:21:07 +0000174}
175
176source_set("webrtc_vp8") {
stefan@webrtc.org73823ca2014-07-07 11:46:43 +0000177 sources = [
kjellander@webrtc.orgb8caf6a2014-09-30 18:05:02 +0000178 "codecs/vp8/default_temporal_layers.cc",
179 "codecs/vp8/default_temporal_layers.h",
pbos@webrtc.org9115cde2014-12-09 10:36:40 +0000180 "codecs/vp8/include/vp8.h",
181 "codecs/vp8/include/vp8_common_types.h",
kjellander@webrtc.orgb8caf6a2014-09-30 18:05:02 +0000182 "codecs/vp8/realtime_temporal_layers.cc",
183 "codecs/vp8/reference_picture_selection.cc",
184 "codecs/vp8/reference_picture_selection.h",
pbos@webrtc.org9115cde2014-12-09 10:36:40 +0000185 "codecs/vp8/screenshare_layers.cc",
186 "codecs/vp8/screenshare_layers.h",
187 "codecs/vp8/simulcast_encoder_adapter.cc",
188 "codecs/vp8/simulcast_encoder_adapter.h",
stefan@webrtc.org73823ca2014-07-07 11:46:43 +0000189 "codecs/vp8/temporal_layers.h",
190 "codecs/vp8/vp8_factory.cc",
pbos@webrtc.org9115cde2014-12-09 10:36:40 +0000191 "codecs/vp8/vp8_factory.h",
kjellander@webrtc.orgb8caf6a2014-09-30 18:05:02 +0000192 "codecs/vp8/vp8_impl.cc",
193 "codecs/vp8/vp8_impl.h",
stefan@webrtc.org73823ca2014-07-07 11:46:43 +0000194 ]
kjellander@webrtc.org42ee5b52014-08-25 14:15:35 +0000195
kjellander@webrtc.orgf21ea912014-09-28 17:37:22 +0000196 configs += [ "../..:common_config" ]
197 public_configs = [ "../..:common_inherited_config" ]
198
kjellander@webrtc.org42ee5b52014-08-25 14:15:35 +0000199 if (is_clang) {
200 # Suppress warnings from Chrome's Clang plugins.
201 # See http://code.google.com/p/webrtc/issues/detail?id=163 for details.
202 configs -= [ "//build/config/clang:find_bad_constructs" ]
203 }
204
kjellander@webrtc.org8649fed2015-01-08 21:22:01 +0000205 if (is_win) {
206 cflags = [
207 # TODO(jschuh): Bug 1348: fix this warning.
208 "/wd4267", # size_t to int truncation.
209 ]
210 }
211
stefan@webrtc.org73823ca2014-07-07 11:46:43 +0000212 deps = [
213 ":video_coding_utility",
kwiberg@webrtc.orgac2d27d2015-02-26 13:59:22 +0000214 "../..:webrtc_common",
stefan@webrtc.org73823ca2014-07-07 11:46:43 +0000215 "../../common_video",
216 "../../system_wrappers",
217 ]
kjellander@webrtc.orgb8caf6a2014-09-30 18:05:02 +0000218 if (rtc_build_libvpx) {
Henrik Kjellander57e5fd22015-05-25 12:55:39 +0200219 deps += [ rtc_libvpx_dir ]
kjellander@webrtc.orgb8caf6a2014-09-30 18:05:02 +0000220 }
kjellander@webrtc.org1227ab82014-06-23 19:21:07 +0000221}
marpan@webrtc.org5b883172014-11-01 06:10:48 +0000222
223source_set("webrtc_vp9") {
Peter Boströmbd05f0b2015-11-17 15:27:32 +0100224 sources = [
225 "codecs/vp9/include/vp9.h",
226 "codecs/vp9/screenshare_layers.cc",
227 "codecs/vp9/screenshare_layers.h",
228 "codecs/vp9/vp9_frame_buffer_pool.cc",
229 "codecs/vp9/vp9_frame_buffer_pool.h",
230 "codecs/vp9/vp9_impl.cc",
231 "codecs/vp9/vp9_impl.h",
232 ]
marpan@webrtc.org5b883172014-11-01 06:10:48 +0000233
234 configs += [ "../..:common_config" ]
235 public_configs = [ "../..:common_inherited_config" ]
236
237 if (is_clang) {
238 # Suppress warnings from Chrome's Clang plugins.
239 # See http://code.google.com/p/webrtc/issues/detail?id=163 for details.
240 configs -= [ "//build/config/clang:find_bad_constructs" ]
241 }
242
marpan@webrtc.org5b883172014-11-01 06:10:48 +0000243 deps = [
244 ":video_coding_utility",
245 "../../common_video",
246 "../../system_wrappers",
247 ]
248 if (rtc_build_libvpx) {
Henrik Kjellander57e5fd22015-05-25 12:55:39 +0200249 deps += [ rtc_libvpx_dir ]
marpan@webrtc.org5b883172014-11-01 06:10:48 +0000250 }
251}