Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(80)

Unified Diff: webrtc/video/video_send_stream.cc

Issue 2106183002: Fix bug where min transmit bitrate wasn't working (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Add min transmit bitrate to Call::Stats, update test Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« webrtc/video/end_to_end_tests.cc ('K') | « webrtc/video/end_to_end_tests.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/video/video_send_stream.cc
diff --git a/webrtc/video/video_send_stream.cc b/webrtc/video/video_send_stream.cc
index 01c2fc836c7d4a35dde12d1a13b4cd2fbb8e5cf0..cad5a5a21efdf9f1e6dae63e30b5d15b7dacef3c 100644
--- a/webrtc/video/video_send_stream.cc
+++ b/webrtc/video/video_send_stream.cc
@@ -588,6 +588,14 @@ void VideoSendStream::EncoderProcess() {
current_encoder_settings_->video_codec.startBitrate = std::max(
bitrate_allocator_->GetStartBitrate(this) / 1000,
static_cast<int>(current_encoder_settings_->video_codec.minBitrate));
+
+ bitrate_allocator_->AddObserver(
perkj_webrtc 2016/07/04 07:24:49 We should not add as observer unless the stream i
sprang_webrtc 2016/07/04 09:08:47 Done.
+ this, current_encoder_settings_->video_codec.minBitrate * 1000,
+ current_encoder_settings_->video_codec.maxBitrate * 1000,
+ CalulcateMaxPadBitrateBps(current_encoder_settings_->config,
+ config_.suspend_below_min_bitrate),
+ !config_.suspend_below_min_bitrate);
+
payload_router_.SetSendStreams(current_encoder_settings_->config.streams);
vie_encoder_.SetEncoder(current_encoder_settings_->video_codec,
payload_router_.MaxPayloadLength());
« webrtc/video/end_to_end_tests.cc ('K') | « webrtc/video/end_to_end_tests.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698