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

Unified Diff: media/base/channel_mixer_unittest.cc

Issue 115413002: Enable platform echo cancellation through the AudioRecord path. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: . Created 7 years 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 | « media/base/android/java/src/org/chromium/media/AudioRecordInput.java ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/base/channel_mixer_unittest.cc
diff --git a/media/base/channel_mixer_unittest.cc b/media/base/channel_mixer_unittest.cc
index eddbc1b90baffbe2ecb153e35a0b0132cd2eebf7..e048f8d9fc5811d41be77da66f82607439077426 100644
--- a/media/base/channel_mixer_unittest.cc
+++ b/media/base/channel_mixer_unittest.cc
@@ -100,20 +100,26 @@ TEST_P(ChannelMixerTest, Mixing) {
scoped_ptr<AudioBus> input_bus = AudioBus::Create(input_channels, kFrames);
AudioParameters input_audio(AudioParameters::AUDIO_PCM_LINEAR,
input_layout,
+ input_layout == CHANNEL_LAYOUT_DISCRETE ?
+ input_channels :
+ ChannelLayoutToChannelCount(input_layout),
+ 0,
AudioParameters::kAudioCDSampleRate, 16,
- kFrames);
- if (input_layout == CHANNEL_LAYOUT_DISCRETE)
- input_audio.SetDiscreteChannels(input_channels);
+ kFrames,
+ AudioParameters::NO_EFFECTS);
ChannelLayout output_layout = GetParam().output_layout;
int output_channels = GetParam().output_channels;
scoped_ptr<AudioBus> output_bus = AudioBus::Create(output_channels, kFrames);
AudioParameters output_audio(AudioParameters::AUDIO_PCM_LINEAR,
output_layout,
+ output_layout == CHANNEL_LAYOUT_DISCRETE ?
+ output_channels :
+ ChannelLayoutToChannelCount(output_layout),
+ 0,
AudioParameters::kAudioCDSampleRate, 16,
- kFrames);
- if (output_layout == CHANNEL_LAYOUT_DISCRETE)
- output_audio.SetDiscreteChannels(output_channels);
+ kFrames,
+ AudioParameters::NO_EFFECTS);
const float* channel_values = GetParam().channel_values;
ASSERT_EQ(input_bus->channels(), GetParam().num_channel_values);
« no previous file with comments | « media/base/android/java/src/org/chromium/media/AudioRecordInput.java ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698