2019-12-10 14:14:09 +01:00
|
|
|
# Copyright (c) 2019 The WebRTC project authors. All Rights Reserved.
|
|
|
|
|
#
|
|
|
|
|
# Use of this source code is governed by a BSD-style license
|
|
|
|
|
# that can be found in the LICENSE file in the root of the source
|
|
|
|
|
# tree. An additional intellectual property rights grant can be found
|
|
|
|
|
# in the file PATENTS. All contributing project authors may
|
|
|
|
|
# be found in the AUTHORS file in the root of the source tree.
|
|
|
|
|
|
|
|
|
|
import("../../webrtc.gni")
|
|
|
|
|
|
|
|
|
|
rtc_library("resource_adaptation") {
|
|
|
|
|
sources = [
|
2020-06-02 13:02:36 +02:00
|
|
|
"adaptation_constraint.cc",
|
|
|
|
|
"adaptation_constraint.h",
|
2020-07-01 15:48:46 +02:00
|
|
|
"broadcast_resource_listener.cc",
|
|
|
|
|
"broadcast_resource_listener.h",
|
2020-07-03 13:51:48 +02:00
|
|
|
"degradation_preference_provider.cc",
|
|
|
|
|
"degradation_preference_provider.h",
|
2020-03-06 13:32:03 +01:00
|
|
|
"encoder_settings.cc",
|
|
|
|
|
"encoder_settings.h",
|
2020-04-17 18:36:19 +02:00
|
|
|
"resource_adaptation_processor.cc",
|
|
|
|
|
"resource_adaptation_processor.h",
|
2020-03-10 19:08:05 +01:00
|
|
|
"resource_adaptation_processor_interface.cc",
|
|
|
|
|
"resource_adaptation_processor_interface.h",
|
2020-01-13 11:27:18 +01:00
|
|
|
"video_source_restrictions.cc",
|
|
|
|
|
"video_source_restrictions.h",
|
2020-04-17 14:40:39 +02:00
|
|
|
"video_stream_adapter.cc",
|
|
|
|
|
"video_stream_adapter.h",
|
2020-04-17 12:10:59 +02:00
|
|
|
"video_stream_input_state.cc",
|
|
|
|
|
"video_stream_input_state.h",
|
|
|
|
|
"video_stream_input_state_provider.cc",
|
|
|
|
|
"video_stream_input_state_provider.h",
|
2019-12-10 14:14:09 +01:00
|
|
|
]
|
|
|
|
|
deps = [
|
2022-03-29 11:04:48 +02:00
|
|
|
"../../api:field_trials_view",
|
2020-01-16 13:55:29 +01:00
|
|
|
"../../api:rtp_parameters",
|
2020-05-11 16:29:22 +02:00
|
|
|
"../../api:scoped_refptr",
|
2021-02-10 14:31:24 +01:00
|
|
|
"../../api:sequence_checker",
|
2020-06-03 09:24:06 +02:00
|
|
|
"../../api/adaptation:resource_adaptation_api",
|
2020-06-01 17:59:05 +02:00
|
|
|
"../../api/task_queue:task_queue",
|
2020-04-17 14:40:39 +02:00
|
|
|
"../../api/video:video_adaptation",
|
2020-01-22 16:16:04 +01:00
|
|
|
"../../api/video:video_frame",
|
2020-04-17 12:10:59 +02:00
|
|
|
"../../api/video:video_stream_encoder",
|
2020-01-21 11:18:06 +01:00
|
|
|
"../../api/video_codecs:video_codecs_api",
|
2020-04-17 14:40:39 +02:00
|
|
|
"../../modules/video_coding:video_coding_utility",
|
2019-12-10 14:14:09 +01:00
|
|
|
"../../rtc_base:checks",
|
2022-04-04 15:06:30 +02:00
|
|
|
"../../rtc_base:logging",
|
2022-04-04 15:18:46 +02:00
|
|
|
"../../rtc_base:macromagic",
|
2022-04-05 02:54:12 +02:00
|
|
|
"../../rtc_base:refcount",
|
2019-12-10 14:14:09 +01:00
|
|
|
"../../rtc_base:rtc_base_approved",
|
2020-05-11 16:29:22 +02:00
|
|
|
"../../rtc_base:rtc_task_queue",
|
2022-04-04 17:04:37 +02:00
|
|
|
"../../rtc_base:safe_conversions",
|
2022-04-04 17:14:02 +02:00
|
|
|
"../../rtc_base:stringutils",
|
2020-04-17 14:40:39 +02:00
|
|
|
"../../rtc_base/experiments:balanced_degradation_settings",
|
2020-07-06 17:41:35 +02:00
|
|
|
"../../rtc_base/synchronization:mutex",
|
2020-11-23 13:19:32 +01:00
|
|
|
"../../rtc_base/system:no_unique_address",
|
2020-06-03 09:21:34 +02:00
|
|
|
"../../rtc_base/task_utils:to_queued_task",
|
2020-06-05 14:30:41 +02:00
|
|
|
]
|
|
|
|
|
absl_deps = [
|
2020-02-25 16:26:01 +01:00
|
|
|
"//third_party/abseil-cpp/absl/algorithm:container",
|
2019-12-10 14:14:09 +01:00
|
|
|
"//third_party/abseil-cpp/absl/types:optional",
|
2020-07-03 15:16:43 +02:00
|
|
|
"//third_party/abseil-cpp/absl/types:variant",
|
2019-12-10 14:14:09 +01:00
|
|
|
]
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (rtc_include_tests) {
|
|
|
|
|
rtc_library("resource_adaptation_tests") {
|
|
|
|
|
testonly = true
|
|
|
|
|
|
2020-04-17 14:40:39 +02:00
|
|
|
sources = [
|
2020-07-01 15:48:46 +02:00
|
|
|
"broadcast_resource_listener_unittest.cc",
|
2020-04-29 16:46:30 +02:00
|
|
|
"resource_adaptation_processor_unittest.cc",
|
2020-04-17 14:40:39 +02:00
|
|
|
"resource_unittest.cc",
|
2020-04-29 16:46:30 +02:00
|
|
|
"video_source_restrictions_unittest.cc",
|
2020-04-17 14:40:39 +02:00
|
|
|
"video_stream_adapter_unittest.cc",
|
2020-04-29 16:46:30 +02:00
|
|
|
"video_stream_input_state_provider_unittest.cc",
|
2020-04-17 14:40:39 +02:00
|
|
|
]
|
2019-12-10 14:14:09 +01:00
|
|
|
deps = [
|
|
|
|
|
":resource_adaptation",
|
|
|
|
|
":resource_adaptation_test_utilities",
|
2020-05-11 16:29:22 +02:00
|
|
|
"../../api:scoped_refptr",
|
2020-06-03 09:24:06 +02:00
|
|
|
"../../api/adaptation:resource_adaptation_api",
|
2020-05-12 18:49:07 +02:00
|
|
|
"../../api/task_queue:default_task_queue_factory",
|
|
|
|
|
"../../api/task_queue:task_queue",
|
2020-04-17 14:40:39 +02:00
|
|
|
"../../api/video:video_adaptation",
|
|
|
|
|
"../../api/video_codecs:video_codecs_api",
|
2019-12-10 14:14:09 +01:00
|
|
|
"../../rtc_base:checks",
|
2020-06-03 09:21:34 +02:00
|
|
|
"../../rtc_base:gunit_helpers",
|
2019-12-10 14:14:09 +01:00
|
|
|
"../../rtc_base:rtc_base_approved",
|
2022-04-04 16:57:52 +02:00
|
|
|
"../../rtc_base:rtc_event",
|
2020-05-12 18:49:07 +02:00
|
|
|
"../../rtc_base:rtc_task_queue",
|
2022-04-04 17:14:02 +02:00
|
|
|
"../../rtc_base:stringutils",
|
2020-05-12 18:49:07 +02:00
|
|
|
"../../rtc_base:task_queue_for_test",
|
2020-07-06 17:41:35 +02:00
|
|
|
"../../rtc_base/synchronization:mutex",
|
2020-04-17 14:40:39 +02:00
|
|
|
"../../test:field_trial",
|
|
|
|
|
"../../test:rtc_expect_death",
|
2022-03-09 15:12:07 +01:00
|
|
|
"../../test:scoped_key_value_config",
|
2019-12-10 14:14:09 +01:00
|
|
|
"../../test:test_support",
|
|
|
|
|
]
|
2020-06-05 14:30:41 +02:00
|
|
|
absl_deps = [ "//third_party/abseil-cpp/absl/types:optional" ]
|
2019-12-10 14:14:09 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
rtc_source_set("resource_adaptation_test_utilities") {
|
|
|
|
|
testonly = true
|
|
|
|
|
|
|
|
|
|
sources = [
|
2020-06-02 13:02:36 +02:00
|
|
|
"test/fake_adaptation_constraint.cc",
|
|
|
|
|
"test/fake_adaptation_constraint.h",
|
2020-04-29 16:46:30 +02:00
|
|
|
"test/fake_frame_rate_provider.cc",
|
|
|
|
|
"test/fake_frame_rate_provider.h",
|
2019-12-10 14:14:09 +01:00
|
|
|
"test/fake_resource.cc",
|
|
|
|
|
"test/fake_resource.h",
|
2020-12-04 09:37:47 +01:00
|
|
|
"test/fake_video_stream_input_state_provider.cc",
|
|
|
|
|
"test/fake_video_stream_input_state_provider.h",
|
2020-07-01 15:48:46 +02:00
|
|
|
"test/mock_resource_listener.h",
|
2019-12-10 14:14:09 +01:00
|
|
|
]
|
|
|
|
|
deps = [
|
|
|
|
|
":resource_adaptation",
|
2020-06-01 17:59:05 +02:00
|
|
|
"../../api:scoped_refptr",
|
2021-02-10 14:31:24 +01:00
|
|
|
"../../api:sequence_checker",
|
2020-06-03 09:24:06 +02:00
|
|
|
"../../api/adaptation:resource_adaptation_api",
|
2020-06-01 17:59:05 +02:00
|
|
|
"../../api/task_queue:task_queue",
|
2020-04-29 16:46:30 +02:00
|
|
|
"../../api/video:video_stream_encoder",
|
2022-04-05 02:54:12 +02:00
|
|
|
"../../rtc_base:refcount",
|
2019-12-10 14:14:09 +01:00
|
|
|
"../../rtc_base:rtc_base_approved",
|
2020-06-01 17:59:05 +02:00
|
|
|
"../../rtc_base/task_utils:to_queued_task",
|
2020-04-29 16:46:30 +02:00
|
|
|
"../../test:test_support",
|
2019-12-10 14:14:09 +01:00
|
|
|
]
|
2020-06-05 14:30:41 +02:00
|
|
|
absl_deps = [ "//third_party/abseil-cpp/absl/types:optional" ]
|
2019-12-10 14:14:09 +01:00
|
|
|
}
|
|
|
|
|
}
|