blob: 30eddc6bf66486116ff8725849299889587615b3 [file] [log] [blame]
kjellander@webrtc.org1227ab82014-06-23 19:21:071# 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 14:58:229import("../webrtc.gni")
kjellander@webrtc.org1227ab82014-06-23 19:21:0710
Mirko Bonadei86d053c2019-10-17 19:32:0411rtc_library("common_video") {
Per Kjellandera7f2d842018-01-10 15:54:5312 visibility = [ "*" ]
13
kjellander@webrtc.org11bea892014-07-03 17:04:1214 sources = [
emircan55a401e2016-04-26 19:55:0715 "bitrate_adjuster.cc",
Erik Språng7daf5502019-08-14 09:04:4016 "frame_rate_estimator.cc",
17 "frame_rate_estimator.h",
Åsa Persson062acd92021-08-16 07:33:1318 "framerate_controller.cc",
19 "framerate_controller.h",
kthelgasonb9061722016-10-26 09:48:1620 "h264/h264_bitstream_parser.cc",
21 "h264/h264_bitstream_parser.h",
sprang52033d62016-06-02 09:43:3222 "h264/h264_common.cc",
23 "h264/h264_common.h",
24 "h264/pps_parser.cc",
25 "h264/pps_parser.h",
26 "h264/sps_parser.cc",
27 "h264/sps_parser.h",
28 "h264/sps_vui_rewriter.cc",
29 "h264/sps_vui_rewriter.h",
emircan55a401e2016-04-26 19:55:0730 "include/bitrate_adjuster.h",
kjellander6f8ce062015-11-16 21:52:2431 "include/incoming_video_stream.h",
Henrik Boströmce33b6a2019-05-28 15:42:3832 "include/quality_limitation_reason.h",
kjellander6f8ce062015-11-16 21:52:2433 "include/video_frame_buffer.h",
Ilya Nikolaevskiy4c87d832020-09-18 13:18:5434 "include/video_frame_buffer_pool.h",
Peter Boström9a638662015-05-13 11:28:1135 "incoming_video_stream.cc",
kjellander@webrtc.org11bea892014-07-03 17:04:1236 "libyuv/include/webrtc_libyuv.h",
kjellander@webrtc.org11bea892014-07-03 17:04:1237 "libyuv/webrtc_libyuv.cc",
magjed@webrtc.org2386d6d2015-03-05 14:03:0838 "video_frame_buffer.cc",
Ilya Nikolaevskiy4c87d832020-09-18 13:18:5439 "video_frame_buffer_pool.cc",
Peter Boström9a638662015-05-13 11:28:1140 "video_render_frames.cc",
41 "video_render_frames.h",
kjellander@webrtc.org11bea892014-07-03 17:04:1242 ]
43
kwiberg@webrtc.orgac2d27d2015-02-26 13:59:2244 deps = [
Danil Chapovalov9a45e892021-09-13 13:55:0345 "../api:array_view",
Mirko Bonadeid9708072019-01-25 19:26:4846 "../api:scoped_refptr",
Artem Titovd15a5752021-02-10 13:31:2447 "../api:sequence_checker",
Sebastian Jansson74682c12019-03-01 10:50:2048 "../api/task_queue",
Erik Språng7daf5502019-08-14 09:04:4049 "../api/units:time_delta",
50 "../api/units:timestamp",
Niels Möller4dc66c52018-10-05 12:17:5851 "../api/video:encoded_image",
Erik Språngc8caaec2018-05-23 13:20:3152 "../api/video:video_bitrate_allocation",
Jiawei Ou4206a0a2018-07-20 22:49:4353 "../api/video:video_bitrate_allocator",
Niels Möllerc6ce9c52018-05-11 09:15:3054 "../api/video:video_frame",
Chen Xing5d24b162019-06-10 10:59:3855 "../api/video:video_rtp_headers",
Kári Tristan Helgasonb1633592019-03-22 10:19:0856 "../api/video_codecs:bitstream_parser_api",
Johannes Kronc3fcee72021-04-19 07:09:2657 "../api/video_codecs:video_codecs_api",
Artem Titov94b57c02019-03-21 12:35:1058 "../rtc_base",
Danil Chapovalov9a45e892021-09-13 13:55:0359 "../rtc_base:bitstream_reader",
Patrik Höglundbe214a22018-01-04 11:14:3560 "../rtc_base:checks",
ehmaldonadof6a861a2017-07-19 17:40:4761 "../rtc_base:rtc_task_queue",
Karl Wiberg12edf4c2018-03-07 13:18:5662 "../rtc_base:safe_minmax",
Markus Handell06d034f2020-07-07 07:17:5663 "../rtc_base/synchronization:mutex",
Mirko Bonadeic66e0042019-10-18 07:52:2264 "../rtc_base/system:rtc_export",
Stefan Holmer0a5792e2018-10-05 11:47:1265 "../system_wrappers:metrics",
Patrik Höglundbe214a22018-01-04 11:14:3566 "//third_party/libyuv",
kwiberg@webrtc.orgac2d27d2015-02-26 13:59:2267 ]
Danil Chapovalov9a45e892021-09-13 13:55:0368 absl_deps = [
69 "//third_party/abseil-cpp/absl/numeric:bits",
70 "//third_party/abseil-cpp/absl/types:optional",
71 ]
kjellander@webrtc.org1227ab82014-06-23 19:21:0772}
kjellander2a3892a2016-06-08 08:27:5273
Niels Möllera8327d42020-08-25 08:28:5074rtc_source_set("frame_counts") {
75 visibility = [ "*" ]
76
77 sources = [ "frame_counts.h" ]
78}
79
Andrey Logvine7c79fd2021-02-01 09:56:3780if (rtc_include_tests && !build_with_chromium) {
Mirko Bonadei92ea95e2017-09-15 04:47:3181 common_video_resources = [ "../resources/foreman_cif.yuv" ]
kjellander32c4a202016-08-30 09:53:4982
83 if (is_ios) {
84 bundle_data("common_video_unittests_bundle_data") {
85 testonly = true
86 sources = common_video_resources
Mirko Bonadeiccbe95f2020-01-21 11:10:1087 outputs = [ "{{bundle_resources_dir}}/{{source_file_part}}" ]
kjellander32c4a202016-08-30 09:53:4988 }
89 }
90
ehmaldonado38a21322016-09-02 11:10:3491 rtc_test("common_video_unittests") {
kjellander2a3892a2016-06-08 08:27:5292 testonly = true
93
94 sources = [
95 "bitrate_adjuster_unittest.cc",
Erik Språng7daf5502019-08-14 09:04:4096 "frame_rate_estimator_unittest.cc",
Åsa Persson062acd92021-08-16 07:33:1397 "framerate_controller_unittest.cc",
kthelgasonb9061722016-10-26 09:48:1698 "h264/h264_bitstream_parser_unittest.cc",
kjellander2a3892a2016-06-08 08:27:5299 "h264/pps_parser_unittest.cc",
100 "h264/sps_parser_unittest.cc",
101 "h264/sps_vui_rewriter_unittest.cc",
kjellander2a3892a2016-06-08 08:27:52102 "libyuv/libyuv_unittest.cc",
Ilya Nikolaevskiy4c87d832020-09-18 13:18:54103 "video_frame_buffer_pool_unittest.cc",
Emircan Uysaler901e0ff2018-06-26 19:22:38104 "video_frame_unittest.cc",
kjellander2a3892a2016-06-08 08:27:52105 ]
106
kjellander2a3892a2016-06-08 08:27:52107 deps = [
108 ":common_video",
Mirko Bonadeid9708072019-01-25 19:26:48109 "../api:scoped_refptr",
Yves Gerey3e707812018-11-28 15:47:49110 "../api/units:time_delta",
Niels Möllerc6ce9c52018-05-11 09:15:30111 "../api/video:video_frame",
Emircan Uysaler901e0ff2018-06-26 19:22:38112 "../api/video:video_frame_i010",
Chen Xing5d24b162019-06-10 10:59:38113 "../api/video:video_rtp_headers",
Johannes Kronc3fcee72021-04-19 07:09:26114 "../api/video_codecs:video_codecs_api",
Artem Titov94b57c02019-03-21 12:35:10115 "../rtc_base",
Yves Gerey3e707812018-11-28 15:47:49116 "../rtc_base:checks",
ehmaldonadof6a861a2017-07-19 17:40:47117 "../rtc_base:rtc_base_approved",
Niels Möller2cb7b5e2018-04-19 08:02:26118 "../rtc_base:rtc_base_tests_utils",
Erik Språng7daf5502019-08-14 09:04:40119 "../system_wrappers:system_wrappers",
Patrik Höglund7696bef2018-03-15 14:05:39120 "../test:fileutils",
Artem Titov33f9d2b2019-12-05 14:59:00121 "../test:frame_utils",
ehmaldonado26bddb92016-11-30 14:12:01122 "../test:test_main",
Yves Gerey21cddff2018-10-30 20:12:42123 "../test:test_support",
kjellander2a3892a2016-06-08 08:27:52124 "../test:video_test_common",
kjellander2a3892a2016-06-08 08:27:52125 "//testing/gtest",
Mirko Bonadei401d0562017-12-14 10:24:00126 "//third_party/libyuv",
kjellander2a3892a2016-06-08 08:27:52127 ]
128
Andrey Logvin78646002021-01-29 10:50:19129 absl_deps = [ "//third_party/abseil-cpp/absl/types:optional" ]
130
ehmaldonado3a7f35b2016-09-14 12:10:01131 data = common_video_resources
kjellander2a3892a2016-06-08 08:27:52132 if (is_android) {
133 deps += [ "//testing/android/native_test:native_test_support" ]
kjellander28a0ffd2016-08-24 14:48:42134 shard_timeout = 900
135 }
kjellander2a3892a2016-06-08 08:27:52136
kjellander32c4a202016-08-30 09:53:49137 if (is_ios) {
138 deps += [ ":common_video_unittests_bundle_data" ]
kjellander2a3892a2016-06-08 08:27:52139 }
140 }
141}