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

Side by Side Diff: webrtc/modules/audio_processing/audio_processing_impl.cc

Issue 1844583003: Only split into bands when the reverse stream is analyzed in the APM (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
« no previous file with comments | « webrtc/modules/audio_processing/audio_processing_impl.h ('k') | no next file » | 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) 2012 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 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 1128 matching lines...) Expand 10 before | Expand all | Expand 10 after
1139 // have super-wb. 1139 // have super-wb.
1140 return true; 1140 return true;
1141 } 1141 }
1142 return false; 1142 return false;
1143 } 1143 }
1144 1144
1145 bool AudioProcessingImpl::is_rev_processed() const { 1145 bool AudioProcessingImpl::is_rev_processed() const {
1146 return constants_.intelligibility_enabled; 1146 return constants_.intelligibility_enabled;
1147 } 1147 }
1148 1148
1149 bool AudioProcessingImpl::is_rev_analyzed() const {
1150 return is_rev_processed() ||
peah-webrtc 2016/03/30 13:01:11 As I see it, the purpose of this method is to avoi
aluebs-webrtc 2016/03/31 01:00:18 No, this change is to avoid doing reverse stream a
1151 public_submodules_->echo_cancellation->is_enabled() ||
1152 public_submodules_->echo_control_mobile->is_enabled() ||
1153 public_submodules_->gain_control->is_enabled();
1154 }
1155
1149 bool AudioProcessingImpl::rev_synthesis_needed() const { 1156 bool AudioProcessingImpl::rev_synthesis_needed() const {
1150 return (is_rev_processed() && 1157 return (is_rev_processed() &&
1151 is_multi_band(formats_.rev_proc_format.sample_rate_hz())); 1158 is_multi_band(formats_.rev_proc_format.sample_rate_hz()));
1152 } 1159 }
1153 1160
1154 bool AudioProcessingImpl::rev_analysis_needed() const { 1161 bool AudioProcessingImpl::rev_analysis_needed() const {
1155 return is_multi_band(formats_.rev_proc_format.sample_rate_hz()); 1162 return is_rev_analyzed() &&
1163 is_multi_band(formats_.rev_proc_format.sample_rate_hz());
1156 } 1164 }
1157 1165
1158 bool AudioProcessingImpl::render_check_rev_conversion_needed() const { 1166 bool AudioProcessingImpl::render_check_rev_conversion_needed() const {
1159 return rev_conversion_needed(); 1167 return rev_conversion_needed();
1160 } 1168 }
1161 1169
1162 bool AudioProcessingImpl::rev_conversion_needed() const { 1170 bool AudioProcessingImpl::rev_conversion_needed() const {
1163 return (formats_.api_format.reverse_input_stream() != 1171 return (formats_.api_format.reverse_input_stream() !=
1164 formats_.api_format.reverse_output_stream()); 1172 formats_.api_format.reverse_output_stream());
1165 } 1173 }
(...skipping 274 matching lines...) Expand 10 before | Expand all | Expand 10 after
1440 debug_dump_.capture.event_msg->mutable_config()->CopyFrom(config); 1448 debug_dump_.capture.event_msg->mutable_config()->CopyFrom(config);
1441 1449
1442 RETURN_ON_ERR(WriteMessageToDebugFile(debug_dump_.debug_file.get(), 1450 RETURN_ON_ERR(WriteMessageToDebugFile(debug_dump_.debug_file.get(),
1443 &debug_dump_.num_bytes_left_for_log_, 1451 &debug_dump_.num_bytes_left_for_log_,
1444 &crit_debug_, &debug_dump_.capture)); 1452 &crit_debug_, &debug_dump_.capture));
1445 return kNoError; 1453 return kNoError;
1446 } 1454 }
1447 #endif // WEBRTC_AUDIOPROC_DEBUG_DUMP 1455 #endif // WEBRTC_AUDIOPROC_DEBUG_DUMP
1448 1456
1449 } // namespace webrtc 1457 } // namespace webrtc
OLDNEW
« no previous file with comments | « webrtc/modules/audio_processing/audio_processing_impl.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698