blob: f95ab7cb6e8a58165e09948e08cc23965f3bf347 [file] [log] [blame]
Niels Möller0c4f7be2018-05-07 14:01:37 +02001/*
2 * Copyright (c) 2018 The WebRTC project authors. All Rights Reserved.
3 *
4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree.
9 */
10
11#ifndef API_TRANSPORT_BITRATE_SETTINGS_H_
12#define API_TRANSPORT_BITRATE_SETTINGS_H_
13
Danil Chapovalov0bc58cf2018-06-21 13:32:56 +020014#include "absl/types/optional.h"
Mirko Bonadei66e76792019-04-02 11:33:59 +020015#include "rtc_base/system/rtc_export.h"
Niels Möller0c4f7be2018-05-07 14:01:37 +020016
17namespace webrtc {
18
19// Configuration of send bitrate. The |start_bitrate_bps| value is
20// used for multiple purposes, both as a prior in the bandwidth
21// estimator, and for initial configuration of the encoder. We may
22// want to create separate apis for those, and use a smaller struct
23// with only the min and max constraints.
Mirko Bonadei66e76792019-04-02 11:33:59 +020024struct RTC_EXPORT BitrateSettings {
Niels Möller0c4f7be2018-05-07 14:01:37 +020025 BitrateSettings();
26 ~BitrateSettings();
27 BitrateSettings(const BitrateSettings&);
28 // 0 <= min <= start <= max should hold for set parameters.
Danil Chapovalov0bc58cf2018-06-21 13:32:56 +020029 absl::optional<int> min_bitrate_bps;
30 absl::optional<int> start_bitrate_bps;
31 absl::optional<int> max_bitrate_bps;
Niels Möller0c4f7be2018-05-07 14:01:37 +020032};
33
34} // namespace webrtc
35
36#endif // API_TRANSPORT_BITRATE_SETTINGS_H_