From 8118f1861fbbcb4f2f450ad9b4a42d4b5c175840 Mon Sep 17 00:00:00 2001 From: "pbos@webrtc.org" Date: Wed, 12 Feb 2014 14:50:29 +0000 Subject: [PATCH] Set pacing bitrates in SetEncoder. Before the change no padding was allowed before the first remote bitrate estimation was received. This bitrate estimation is based on what's actually sent. In tests I set codec.startBitrate to 300 instead of 325, which incidentally means that only the first layer gets encoded. As we only send ~150kbps instead of 300, the first REMB will significantly pull down the remote bitrate estimate instead of keeping the existing rate, even though there's no problem with the link. This was detected in RampUpTest.PacingWithRtx, (send_config.codec.startBitrate=300), which caused the tests to become a lot slower, and flake out more. By allowing padding initially we're able to keep our initial bitrate estimate. R=stefan@webrtc.org TEST=Running RampUpTest.WithPacingAndRtx with startBandwidth=300. BUG= Review URL: https://webrtc-codereview.appspot.com/8529004 git-svn-id: http://webrtc.googlecode.com/svn/trunk@5534 4adac7df-926f-26a2-2b94-8c16560cd09d --- webrtc/video_engine/vie_encoder.cc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/webrtc/video_engine/vie_encoder.cc b/webrtc/video_engine/vie_encoder.cc index ee5da3857..c51e19965 100644 --- a/webrtc/video_engine/vie_encoder.cc +++ b/webrtc/video_engine/vie_encoder.cc @@ -442,6 +442,9 @@ int32_t ViEEncoder::SetEncoder(const webrtc::VideoCodec& video_codec) { kTransmissionMaxBitrateMultiplier * video_codec.maxBitrate * 1000); + paced_sender_->UpdateBitrate(video_codec.startBitrate, + video_codec.startBitrate, + video_codec.startBitrate); return 0; }