chromium/third_party/webrtc/rtc_base/experiments/encoder_info_settings.cc

/*
 *  Copyright 2021 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.
 */

#include "rtc_base/experiments/encoder_info_settings.h"

#include <stdio.h>

#include "absl/strings/string_view.h"
#include "api/field_trials_view.h"
#include "rtc_base/experiments/field_trial_list.h"
#include "rtc_base/logging.h"

namespace webrtc {
namespace {

std::vector<VideoEncoder::ResolutionBitrateLimits> ToResolutionBitrateLimits(
    const std::vector<EncoderInfoSettings::BitrateLimit>& limits) {}
constexpr float kDefaultMinBitratebps =;
}  // namespace

// Default bitrate limits for simulcast with one active stream:
// {frame_size_pixels, min_start_bitrate_bps, min_bitrate_bps, max_bitrate_bps}.
std::vector<VideoEncoder::ResolutionBitrateLimits>
EncoderInfoSettings::GetDefaultSinglecastBitrateLimits(
    VideoCodecType codec_type) {}

absl::optional<VideoEncoder::ResolutionBitrateLimits>
EncoderInfoSettings::GetDefaultSinglecastBitrateLimitsForResolution(
    VideoCodecType codec_type,
    int frame_size_pixels) {}

// Return the suitable bitrate limits for specified resolution when qp is
// untrusted, they are experimental values.
// TODO(bugs.webrtc.org/12942): Maybe we need to add other codecs(VP8/VP9)
// experimental values.
std::vector<VideoEncoder::ResolutionBitrateLimits>
EncoderInfoSettings::GetDefaultSinglecastBitrateLimitsWhenQpIsUntrusted() {}

// Through linear interpolation, return the bitrate limit corresponding to the
// specified |frame_size_pixels|.
absl::optional<VideoEncoder::ResolutionBitrateLimits>
EncoderInfoSettings::GetSinglecastBitrateLimitForResolutionWhenQpIsUntrusted(
    absl::optional<int> frame_size_pixels,
    const std::vector<VideoEncoder::ResolutionBitrateLimits>&
        resolution_bitrate_limits) {}

EncoderInfoSettings::EncoderInfoSettings(const FieldTrialsView& field_trials,
                                         absl::string_view name)
    :{}

absl::optional<uint32_t> EncoderInfoSettings::requested_resolution_alignment()
    const {}

EncoderInfoSettings::~EncoderInfoSettings() {}

SimulcastEncoderAdapterEncoderInfoSettings::
    SimulcastEncoderAdapterEncoderInfoSettings(
        const FieldTrialsView& field_trials)
    :{}

LibvpxVp8EncoderInfoSettings::LibvpxVp8EncoderInfoSettings(
    const FieldTrialsView& field_trials)
    :{}

LibvpxVp9EncoderInfoSettings::LibvpxVp9EncoderInfoSettings(
    const FieldTrialsView& field_trials)
    :{}

LibaomAv1EncoderInfoSettings::LibaomAv1EncoderInfoSettings(
    const FieldTrialsView& field_trials)
    :{}

}  // namespace webrtc