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

Unified Diff: webrtc/media/engine/webrtcvoiceengine.cc

Issue 2532433002: Add overhead to audio bwe min, max. (Closed)
Patch Set: Created 4 years, 1 month 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/media/engine/webrtcvoiceengine.cc
diff --git a/webrtc/media/engine/webrtcvoiceengine.cc b/webrtc/media/engine/webrtcvoiceengine.cc
index 96f9ed70d403c6c464cc9b015f83190630a0b331..17175c4e14cb741c543a3829aa40b8543add6af6 100644
--- a/webrtc/media/engine/webrtcvoiceengine.cc
+++ b/webrtc/media/engine/webrtcvoiceengine.cc
@@ -1420,8 +1420,20 @@ class WebRtcVoiceMediaChannel::WebRtcAudioSendStream
"Enabled") {
// TODO(mflodman): Keep testing this and set proper values.
// Note: This is an early experiment currently only supported by Opus.
- config_.min_bitrate_bps = kOpusMinBitrateBps;
- config_.max_bitrate_bps = kOpusBitrateFbBps;
+ if (webrtc::field_trial::FindFullName(
+ "WebRTC-SendSideBwe-WithOverhead") == "Enabled") {
+ // OverheadPerPacket(58) = Ipv4(20B) + UDP(8B) + SRTP(10B) + RTP(12)
+ // + RTP_ext(8);
+ // kMaxOverheadBps = OverheadPerPacket * 8 * 1000ms / frame_length(20ms)
minyue-webrtc 2016/11/24 10:42:10 use 10ms I think due to https://cs.chromium.org/ch
michaelt 2016/11/24 10:51:24 I think we should not us 10ms frames since they ar
minyue-webrtc 2016/11/28 15:27:06 It does not sound convincing to me. Are we only de
+ // kMinOverheadBps = OverheadPerPacket * 8 * 1000ms / frame_length(60ms)
+ constexpr int kMaxOverheadBps = 23200;
+ constexpr int kMinOverheadBps = 7733;
stefan-webrtc 2016/11/24 10:48:27 This will be hard to maintain. can't we compute th
minyue-webrtc 2016/11/28 15:27:06 It looks like that the problem is that the min fra
stefan-webrtc 2016/12/22 09:06:25 I still don't really follow. How are they differen
+ config_.min_bitrate_bps = kOpusMinBitrateBps + kMinOverheadBps;
+ config_.max_bitrate_bps = kOpusBitrateFbBps + kMaxOverheadBps;
+ } else {
+ config_.min_bitrate_bps = kOpusMinBitrateBps;
+ config_.max_bitrate_bps = kOpusBitrateFbBps;
+ }
}
stream_ = call_->CreateAudioSendStream(config_);
RTC_CHECK(stream_);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698