BUILD.gn (5221B)
1 # 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 9 import("../webrtc.gni") 10 11 rtc_library("corruption_score_calculator") { 12 sources = [ "include/corruption_score_calculator.h" ] 13 deps = [ 14 "../api/video:video_frame", 15 "../api/video:video_rtp_headers", 16 "../api/video/corruption_detection:frame_instrumentation_data", 17 ] 18 } 19 20 rtc_library("common_video") { 21 visibility = [ "*" ] 22 23 sources = [ 24 "bitrate_adjuster.cc", 25 "frame_rate_estimator.cc", 26 "frame_rate_estimator.h", 27 "framerate_controller.cc", 28 "framerate_controller.h", 29 "h264/h264_bitstream_parser.cc", 30 "h264/h264_bitstream_parser.h", 31 "h264/h264_common.cc", 32 "h264/h264_common.h", 33 "h264/pps_parser.cc", 34 "h264/pps_parser.h", 35 "h264/sps_parser.cc", 36 "h264/sps_parser.h", 37 "h264/sps_vui_rewriter.cc", 38 "h264/sps_vui_rewriter.h", 39 "include/bitrate_adjuster.h", 40 "include/quality_limitation_reason.h", 41 "include/video_frame_buffer.h", 42 "include/video_frame_buffer_pool.h", 43 "libyuv/include/webrtc_libyuv.h", 44 "libyuv/webrtc_libyuv.cc", 45 "video_frame_buffer.cc", 46 "video_frame_buffer_pool.cc", 47 ] 48 49 if (rtc_use_h265) { 50 sources += [ 51 "h265/h265_bitstream_parser.cc", 52 "h265/h265_bitstream_parser.h", 53 "h265/h265_common.cc", 54 "h265/h265_common.h", 55 "h265/h265_inline.cc", 56 "h265/h265_inline.h", 57 "h265/h265_pps_parser.cc", 58 "h265/h265_pps_parser.h", 59 "h265/h265_sps_parser.cc", 60 "h265/h265_sps_parser.h", 61 "h265/h265_vps_parser.cc", 62 "h265/h265_vps_parser.h", 63 ] 64 } 65 66 deps = [ 67 "../api:array_view", 68 "../api:make_ref_counted", 69 "../api:scoped_refptr", 70 "../api:sequence_checker", 71 "../api/task_queue", 72 "../api/units:time_delta", 73 "../api/units:timestamp", 74 "../api/video:encoded_image", 75 "../api/video:video_bitrate_allocation", 76 "../api/video:video_bitrate_allocator", 77 "../api/video:video_frame", 78 "../api/video:video_frame_i010", 79 "../api/video:video_rtp_headers", 80 "../api/video_codecs:bitstream_parser_api", 81 "../api/video_codecs:video_codecs_api", 82 "../rtc_base:bit_buffer", 83 "../rtc_base:bitstream_reader", 84 "../rtc_base:buffer", 85 "../rtc_base:checks", 86 "../rtc_base:event_tracer", 87 "../rtc_base:logging", 88 "../rtc_base:macromagic", 89 "../rtc_base:race_checker", 90 "../rtc_base:rate_statistics", 91 "../rtc_base:refcount", 92 "../rtc_base:safe_minmax", 93 "../rtc_base:timeutils", 94 "../rtc_base/synchronization:mutex", 95 "../rtc_base/system:rtc_export", 96 "../system_wrappers:metrics", 97 "//third_party/abseil-cpp/absl/numeric:bits", 98 "//third_party/libyuv", 99 ] 100 if (rtc_use_h265) { 101 deps += [ 102 "../rtc_base:compile_assert_c", 103 "../rtc_base/containers:flat_map", 104 ] 105 } 106 } 107 108 rtc_source_set("frame_counts") { 109 visibility = [ "*" ] 110 111 sources = [ "frame_counts.h" ] 112 } 113 114 if (rtc_include_tests && !build_with_chromium) { 115 common_video_resources = [ "../resources/foreman_cif.yuv" ] 116 117 if (is_ios) { 118 bundle_data("common_video_unittests_bundle_data") { 119 testonly = true 120 sources = common_video_resources 121 outputs = [ "{{bundle_resources_dir}}/{{source_file_part}}" ] 122 } 123 } 124 125 rtc_test("common_video_unittests") { 126 testonly = true 127 128 sources = [ 129 "bitrate_adjuster_unittest.cc", 130 "frame_rate_estimator_unittest.cc", 131 "framerate_controller_unittest.cc", 132 "h264/h264_bitstream_parser_unittest.cc", 133 "h264/pps_parser_unittest.cc", 134 "h264/sps_parser_unittest.cc", 135 "h264/sps_vui_rewriter_unittest.cc", 136 "libyuv/libyuv_unittest.cc", 137 "video_frame_buffer_pool_unittest.cc", 138 "video_frame_unittest.cc", 139 ] 140 141 if (rtc_use_h265) { 142 sources += [ 143 "h265/h265_bitstream_parser_unittest.cc", 144 "h265/h265_pps_parser_unittest.cc", 145 "h265/h265_sps_parser_unittest.cc", 146 "h265/h265_vps_parser_unittest.cc", 147 ] 148 } 149 150 deps = [ 151 ":common_video", 152 "../api:array_view", 153 "../api:scoped_refptr", 154 "../api/units:time_delta", 155 "../api/units:timestamp", 156 "../api/video:video_frame", 157 "../api/video:video_frame_i010", 158 "../api/video:video_rtp_headers", 159 "../api/video_codecs:video_codecs_api", 160 "../rtc_base:bit_buffer", 161 "../rtc_base:buffer", 162 "../rtc_base:checks", 163 "../rtc_base:logging", 164 "../rtc_base:macromagic", 165 "../rtc_base:rtc_base_tests_utils", 166 "../rtc_base:timeutils", 167 "../system_wrappers", 168 "../test:fileutils", 169 "../test:frame_utils", 170 "../test:test_main", 171 "../test:test_support", 172 "../test:video_test_common", 173 "//testing/gtest", 174 "//third_party/libyuv", 175 ] 176 177 data = common_video_resources 178 if (is_android) { 179 shard_timeout = 900 180 } 181 182 if (is_ios) { 183 deps += [ ":common_video_unittests_bundle_data" ] 184 } 185 } 186 }