Index: webrtc/modules/congestion_controller/transport_feedback_adapter.cc |
diff --git a/webrtc/modules/congestion_controller/transport_feedback_adapter.cc b/webrtc/modules/congestion_controller/transport_feedback_adapter.cc |
index 7756fee365da2dd872be36bf028e525480b5abe3..7ffbe8d2da0f783b75cac8b5721b8dbfc76da258 100644 |
--- a/webrtc/modules/congestion_controller/transport_feedback_adapter.cc |
+++ b/webrtc/modules/congestion_controller/transport_feedback_adapter.cc |
@@ -19,6 +19,7 @@ |
#include "webrtc/modules/congestion_controller/delay_based_bwe.h" |
#include "webrtc/modules/rtp_rtcp/source/rtcp_packet/transport_feedback.h" |
#include "webrtc/modules/utility/include/process_thread.h" |
+#include "webrtc/system_wrappers/include/field_trial.h" |
namespace webrtc { |
@@ -59,6 +60,10 @@ void TransportFeedbackAdapter::AddPacket(uint16_t sequence_number, |
size_t length, |
int probe_cluster_id) { |
rtc::CritScope cs(&lock_); |
+ if (webrtc::field_trial::FindFullName("WebRTC-SendSideBwe-WithOverhead") == |
+ "Enabled") { |
+ length += transport_overhead_bytes_per_packet_; |
+ } |
send_time_history_.AddAndRemoveOld(sequence_number, length, probe_cluster_id); |
} |
@@ -73,6 +78,12 @@ void TransportFeedbackAdapter::SetMinBitrate(int min_bitrate_bps) { |
delay_based_bwe_->SetMinBitrate(min_bitrate_bps); |
} |
+void TransportFeedbackAdapter::SetTransportOverhead( |
+ int transport_overhead_bytes_per_packet) { |
+ rtc::CritScope cs(&lock_); |
+ transport_overhead_bytes_per_packet_ = transport_overhead_bytes_per_packet; |
+} |
+ |
int64_t TransportFeedbackAdapter::GetProbingIntervalMs() const { |
rtc::CritScope cs(&bwe_lock_); |
return delay_based_bwe_->GetProbingIntervalMs(); |