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

Side by Side Diff: webrtc/api/statscollector.cc

Issue 1866983002: Add AEC filter divergence metric to StatsCollector. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 4 years, 8 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
OLDNEW
1 /* 1 /*
2 * Copyright 2012 The WebRTC project authors. All Rights Reserved. 2 * Copyright 2012 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 919 matching lines...) Expand 10 before | Expand all | Expand 10 after
930 auto audio_processor(track->GetAudioProcessor()); 930 auto audio_processor(track->GetAudioProcessor());
931 931
932 if (audio_processor.get()) { 932 if (audio_processor.get()) {
933 AudioProcessorInterface::AudioProcessorStats stats; 933 AudioProcessorInterface::AudioProcessorStats stats;
934 audio_processor->GetStats(&stats); 934 audio_processor->GetStats(&stats);
935 935
936 SetAudioProcessingStats( 936 SetAudioProcessingStats(
937 report, stats.typing_noise_detected, stats.echo_return_loss, 937 report, stats.typing_noise_detected, stats.echo_return_loss,
938 stats.echo_return_loss_enhancement, stats.echo_delay_median_ms, 938 stats.echo_return_loss_enhancement, stats.echo_delay_median_ms,
939 stats.aec_quality_min, stats.echo_delay_std_ms); 939 stats.aec_quality_min, stats.echo_delay_std_ms);
940
941 report->AddFloat(StatsReport::kStatsValueNameAecDivergentFilterFraction,
942 stats.aec_divergent_filter_fraction);
940 } 943 }
941 } 944 }
942 945
943 bool StatsCollector::GetTrackIdBySsrc(uint32_t ssrc, 946 bool StatsCollector::GetTrackIdBySsrc(uint32_t ssrc,
944 std::string* track_id, 947 std::string* track_id,
945 StatsReport::Direction direction) { 948 StatsReport::Direction direction) {
946 RTC_DCHECK(pc_->session()->signaling_thread()->IsCurrent()); 949 RTC_DCHECK(pc_->session()->signaling_thread()->IsCurrent());
947 if (direction == StatsReport::kSend) { 950 if (direction == StatsReport::kSend) {
948 if (!pc_->session()->GetLocalTrackIdBySsrc(ssrc, track_id)) { 951 if (!pc_->session()->GetLocalTrackIdBySsrc(ssrc, track_id)) {
949 LOG(LS_WARNING) << "The SSRC " << ssrc 952 LOG(LS_WARNING) << "The SSRC " << ssrc
(...skipping 21 matching lines...) Expand all
971 StatsReport* report = entry.second; 974 StatsReport* report = entry.second;
972 report->set_timestamp(stats_gathering_started_); 975 report->set_timestamp(stats_gathering_started_);
973 } 976 }
974 } 977 }
975 978
976 void StatsCollector::ClearUpdateStatsCacheForTest() { 979 void StatsCollector::ClearUpdateStatsCacheForTest() {
977 stats_gathering_started_ = 0; 980 stats_gathering_started_ = 0;
978 } 981 }
979 982
980 } // namespace webrtc 983 } // namespace webrtc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698