Index: webrtc/media/engine/webrtcvideoengine2.h |
diff --git a/webrtc/media/engine/webrtcvideoengine2.h b/webrtc/media/engine/webrtcvideoengine2.h |
index 8c05c60f6823606a951783a5485adebef2e3dc1b..511a8234b84ea741dea1b398a5307199690263f0 100644 |
--- a/webrtc/media/engine/webrtcvideoengine2.h |
+++ b/webrtc/media/engine/webrtcvideoengine2.h |
@@ -192,7 +192,9 @@ class WebRtcVideoChannel2 : public VideoMediaChannel, public webrtc::Transport { |
// These optionals are unset if not changed. |
rtc::Optional<VideoCodecSettings> codec; |
rtc::Optional<std::vector<webrtc::RtpExtension>> rtp_header_extensions; |
- rtc::Optional<int> max_bandwidth_bps; |
+ // The outer optional is unset if the bandwidth limit has not changed; |
+ // the inner optional indicates if a bandwidth limit is in effect. |
+ rtc::Optional<rtc::Optional<int>> max_bandwidth_bps; |
rtc::Optional<bool> conference_mode; |
rtc::Optional<webrtc::RtcpMode> rtcp_mode; |
}; |
@@ -239,7 +241,7 @@ class WebRtcVideoChannel2 : public VideoMediaChannel, public webrtc::Transport { |
const VideoOptions& options, |
WebRtcVideoEncoderFactory* external_encoder_factory, |
bool enable_cpu_overuse_detection, |
- int max_bitrate_bps, |
+ rtc::Optional<int> max_bitrate_bps, |
const rtc::Optional<VideoCodecSettings>& codec_settings, |
const std::vector<webrtc::RtpExtension>& rtp_extensions, |
const VideoSendParameters& send_params); |
@@ -274,11 +276,11 @@ class WebRtcVideoChannel2 : public VideoMediaChannel, public webrtc::Transport { |
VideoSendStreamParameters( |
const webrtc::VideoSendStream::Config& config, |
const VideoOptions& options, |
- int max_bitrate_bps, |
+ rtc::Optional<int> max_bitrate_bps, |
const rtc::Optional<VideoCodecSettings>& codec_settings); |
webrtc::VideoSendStream::Config config; |
VideoOptions options; |
- int max_bitrate_bps; |
+ rtc::Optional<int> max_bitrate_bps; |
bool conference_mode; |
rtc::Optional<VideoCodecSettings> codec_settings; |
// Sent resolutions + bitrates etc. by the underlying VideoSendStream, |
@@ -319,12 +321,12 @@ class WebRtcVideoChannel2 : public VideoMediaChannel, public webrtc::Transport { |
static std::vector<webrtc::VideoStream> CreateVideoStreams( |
const VideoCodec& codec, |
const VideoOptions& options, |
- int max_bitrate_bps, |
+ rtc::Optional<int> max_bitrate_bps, |
size_t num_streams); |
static std::vector<webrtc::VideoStream> CreateSimulcastVideoStreams( |
const VideoCodec& codec, |
const VideoOptions& options, |
- int max_bitrate_bps, |
+ rtc::Optional<int> max_bitrate_bps, |
size_t num_streams); |
void* ConfigureVideoEncoderSettings(const VideoCodec& codec) |