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

Side by Side Diff: webrtc/video/send_delay_stats.cc

Issue 2326843003: Remove RTC_LOGGED_* macro. (Closed)
Patch Set: rebase Created 4 years, 3 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 unified diff | Download patch
« no previous file with comments | « webrtc/video/rtp_stream_receiver.cc ('k') | webrtc/video/send_statistics_proxy.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2016 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2016 The WebRTC project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 26 matching lines...) Expand all
37 << ". Number of streams " << send_delay_counters_.size(); 37 << ". Number of streams " << send_delay_counters_.size();
38 } 38 }
39 UpdateHistograms(); 39 UpdateHistograms();
40 } 40 }
41 41
42 void SendDelayStats::UpdateHistograms() { 42 void SendDelayStats::UpdateHistograms() {
43 rtc::CritScope lock(&crit_); 43 rtc::CritScope lock(&crit_);
44 for (const auto& it : send_delay_counters_) { 44 for (const auto& it : send_delay_counters_) {
45 AggregatedStats stats = it.second->GetStats(); 45 AggregatedStats stats = it.second->GetStats();
46 if (stats.num_samples >= kMinRequiredPeriodicSamples) { 46 if (stats.num_samples >= kMinRequiredPeriodicSamples) {
47 RTC_LOGGED_HISTOGRAM_COUNTS_10000("WebRTC.Video.SendDelayInMs", 47 RTC_HISTOGRAM_COUNTS_10000("WebRTC.Video.SendDelayInMs", stats.average);
48 stats.average);
49 } 48 }
50 } 49 }
51 } 50 }
52 51
53 void SendDelayStats::AddSsrcs(const VideoSendStream::Config& config) { 52 void SendDelayStats::AddSsrcs(const VideoSendStream::Config& config) {
54 rtc::CritScope lock(&crit_); 53 rtc::CritScope lock(&crit_);
55 if (ssrcs_.size() > kMaxSsrcMapSize) 54 if (ssrcs_.size() > kMaxSsrcMapSize)
56 return; 55 return;
57 for (const auto& ssrc : config.rtp.ssrcs) 56 for (const auto& ssrc : config.rtp.ssrcs)
58 ssrcs_.insert(ssrc); 57 ssrcs_.insert(ssrc);
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
110 auto it = packets->begin(); 109 auto it = packets->begin();
111 if (now - it->second.capture_time_ms < kMaxSentPacketDelayMs) 110 if (now - it->second.capture_time_ms < kMaxSentPacketDelayMs)
112 break; 111 break;
113 112
114 packets->erase(it); 113 packets->erase(it);
115 ++num_old_packets_; 114 ++num_old_packets_;
116 } 115 }
117 } 116 }
118 117
119 } // namespace webrtc 118 } // namespace webrtc
OLDNEW
« no previous file with comments | « webrtc/video/rtp_stream_receiver.cc ('k') | webrtc/video/send_statistics_proxy.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698