diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-15 03:35:49 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-15 03:35:49 +0000 |
commit | d8bbc7858622b6d9c278469aab701ca0b609cddf (patch) | |
tree | eff41dc61d9f714852212739e6b3738b82a2af87 /third_party/libwebrtc/rtc_base/experiments | |
parent | Releasing progress-linux version 125.0.3-1~progress7.99u1. (diff) | |
download | firefox-d8bbc7858622b6d9c278469aab701ca0b609cddf.tar.xz firefox-d8bbc7858622b6d9c278469aab701ca0b609cddf.zip |
Merging upstream version 126.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'third_party/libwebrtc/rtc_base/experiments')
3 files changed, 11 insertions, 23 deletions
diff --git a/third_party/libwebrtc/rtc_base/experiments/BUILD.gn b/third_party/libwebrtc/rtc_base/experiments/BUILD.gn index 185d5931f7..d44eefd4fc 100644 --- a/third_party/libwebrtc/rtc_base/experiments/BUILD.gn +++ b/third_party/libwebrtc/rtc_base/experiments/BUILD.gn @@ -16,10 +16,9 @@ rtc_library("alr_experiment") { deps = [ "..:logging", "../../api:field_trials_view", - "../../api/transport:field_trial_based_config", ] absl_deps = [ - "//third_party/abseil-cpp/absl/strings:strings", + "//third_party/abseil-cpp/absl/strings:string_view", "//third_party/abseil-cpp/absl/types:optional", ] } diff --git a/third_party/libwebrtc/rtc_base/experiments/alr_experiment.cc b/third_party/libwebrtc/rtc_base/experiments/alr_experiment.cc index f5d36f6867..5370de5452 100644 --- a/third_party/libwebrtc/rtc_base/experiments/alr_experiment.cc +++ b/third_party/libwebrtc/rtc_base/experiments/alr_experiment.cc @@ -16,21 +16,16 @@ #include <string> #include "absl/strings/string_view.h" -#include "api/transport/field_trial_based_config.h" +#include "api/field_trials_view.h" #include "rtc_base/logging.h" namespace webrtc { +namespace { -const char AlrExperimentSettings::kScreenshareProbingBweExperimentName[] = - "WebRTC-ProbingScreenshareBwe"; -const char AlrExperimentSettings::kStrictPacingAndProbingExperimentName[] = - "WebRTC-StrictPacingAndProbing"; -const char kDefaultProbingScreenshareBweSettings[] = "1.0,2875,80,40,-60,3"; +constexpr absl::string_view kDefaultProbingScreenshareBweSettings = + "1.0,2875,80,40,-60,3"; -bool AlrExperimentSettings::MaxOneFieldTrialEnabled() { - return AlrExperimentSettings::MaxOneFieldTrialEnabled( - FieldTrialBasedConfig()); -} +} // namespace bool AlrExperimentSettings::MaxOneFieldTrialEnabled( const FieldTrialsView& key_value_config) { @@ -40,12 +35,6 @@ bool AlrExperimentSettings::MaxOneFieldTrialEnabled( } absl::optional<AlrExperimentSettings> -AlrExperimentSettings::CreateFromFieldTrial(absl::string_view experiment_name) { - return AlrExperimentSettings::CreateFromFieldTrial(FieldTrialBasedConfig(), - experiment_name); -} - -absl::optional<AlrExperimentSettings> AlrExperimentSettings::CreateFromFieldTrial( const FieldTrialsView& key_value_config, absl::string_view experiment_name) { diff --git a/third_party/libwebrtc/rtc_base/experiments/alr_experiment.h b/third_party/libwebrtc/rtc_base/experiments/alr_experiment.h index 048fd90cab..9914828827 100644 --- a/third_party/libwebrtc/rtc_base/experiments/alr_experiment.h +++ b/third_party/libwebrtc/rtc_base/experiments/alr_experiment.h @@ -30,14 +30,14 @@ struct AlrExperimentSettings { // reserved value to indicate absence of experiment. int group_id; - static const char kScreenshareProbingBweExperimentName[]; - static const char kStrictPacingAndProbingExperimentName[]; - static absl::optional<AlrExperimentSettings> CreateFromFieldTrial( - absl::string_view experiment_name); + static constexpr absl::string_view kScreenshareProbingBweExperimentName = + "WebRTC-ProbingScreenshareBwe"; + static constexpr absl::string_view kStrictPacingAndProbingExperimentName = + "WebRTC-StrictPacingAndProbing"; + static absl::optional<AlrExperimentSettings> CreateFromFieldTrial( const FieldTrialsView& key_value_config, absl::string_view experiment_name); - static bool MaxOneFieldTrialEnabled(); static bool MaxOneFieldTrialEnabled(const FieldTrialsView& key_value_config); private: |