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

Unified Diff: webrtc/modules/rtp_rtcp/source/receive_statistics_impl.cc

Issue 2296253002: Enable BWE logging to command line when rtc_enable_bwe_test_logging is set to true (Closed)
Patch Set: adding BWE_TEST_LOGGING_COMPILE_TIME_ENABLE to gn files Created 4 years, 4 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
Index: webrtc/modules/rtp_rtcp/source/receive_statistics_impl.cc
diff --git a/webrtc/modules/rtp_rtcp/source/receive_statistics_impl.cc b/webrtc/modules/rtp_rtcp/source/receive_statistics_impl.cc
index 4ec11b63452745cf1f8d772b0971575dc97e767b..a2dd1c28ff38e2de944ae91bf3edd2627d88bb5e 100644
--- a/webrtc/modules/rtp_rtcp/source/receive_statistics_impl.cc
+++ b/webrtc/modules/rtp_rtcp/source/receive_statistics_impl.cc
@@ -17,6 +17,8 @@
#include "webrtc/modules/rtp_rtcp/source/rtp_rtcp_config.h"
#include "webrtc/modules/rtp_rtcp/source/time_util.h"
+#include "webrtc/modules/remote_bitrate_estimator/test/bwe_test_logging.h"
stefan-webrtc 2016/09/01 14:07:36 Order alphabetically (should go before rtp_rtcp)
Gaetano Carlucci 2016/09/01 16:06:26 ok
+
namespace webrtc {
const int64_t kStatisticsTimeoutMs = 8000;
@@ -276,6 +278,12 @@ RtcpStatistics StreamStatisticianImpl::CalculateRtcpStatistics() {
receive_counters_.retransmitted.packets;
last_report_old_packets_ = receive_counters_.retransmitted.packets;
last_report_seq_max_ = received_seq_max_;
+ char str[80];
+ snprintf(str, sizeof(str), "%d cumulative_loss[pkts]", ssrc_);
+ BWE_TEST_LOGGING_PLOT(1, str, clock_->TimeInMilliseconds(), cumulative_loss_);
stefan-webrtc 2016/09/01 14:07:36 Instead of doing snprintf here I'd suggest you mak
Gaetano Carlucci 2016/09/01 16:06:26 ok
+ snprintf(str, sizeof(str), "%d received_seq_max[pkts]", ssrc_);
+ BWE_TEST_LOGGING_PLOT(1, str, clock_->TimeInMilliseconds(), \
+ (received_seq_max_ - received_seq_first_));
return stats;
}

Powered by Google App Engine
This is Rietveld 408576698