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

Unified Diff: webrtc/video/send_statistics_proxy.cc

Issue 2437323002: Add qp counter for H264 in SendStatisticsProxy. (Closed)
Patch Set: rebase 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 | « webrtc/video/send_statistics_proxy.h ('k') | webrtc/video/send_statistics_proxy_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/video/send_statistics_proxy.cc
diff --git a/webrtc/video/send_statistics_proxy.cc b/webrtc/video/send_statistics_proxy.cc
index 2da71eb6eced4ede4f5d72f462de8b481210d012..a996976e5d48aa8fa0ea33be0bba100f129ef94a 100644
--- a/webrtc/video/send_statistics_proxy.cc
+++ b/webrtc/video/send_statistics_proxy.cc
@@ -250,6 +250,13 @@ void SendStatisticsProxy::UmaSamplesContainer::UpdateHistograms(
<< spatial_idx;
}
}
+ int qp_h264 = it.second.h264.Avg(kMinRequiredMetricsSamples);
+ if (qp_h264 != -1) {
+ int spatial_idx = it.first;
+ RTC_DCHECK_EQ(-1, spatial_idx);
+ RTC_HISTOGRAMS_COUNTS_100(kIndex, uma_prefix_ + "Encoded.Qp.H264",
+ qp_h264);
+ }
}
if (first_rtcp_stats_time_ms_ != -1) {
@@ -520,6 +527,9 @@ void SendStatisticsProxy::OnSendEncodedImage(
? -1
: codec_info->codecSpecific.VP9.spatial_idx;
uma_container_->qp_counters_[spatial_idx].vp9.Add(encoded_image.qp_);
+ } else if (codec_info->codecType == kVideoCodecH264) {
+ int spatial_idx = -1;
+ uma_container_->qp_counters_[spatial_idx].h264.Add(encoded_image.qp_);
}
}
}
« no previous file with comments | « webrtc/video/send_statistics_proxy.h ('k') | webrtc/video/send_statistics_proxy_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698