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

Unified Diff: media/audio/audio_low_latency_input_output_unittest.cc

Issue 9655023: Adding input and output audio backend to Android. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebased && addressed qinmin's comments Created 8 years, 9 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 side-by-side diff with in-line comments
Download patch
Index: media/audio/audio_low_latency_input_output_unittest.cc
diff --git a/media/audio/audio_low_latency_input_output_unittest.cc b/media/audio/audio_low_latency_input_output_unittest.cc
index 3a305b68c870b9a1db7f7f40fa013799664d7b93..70640637e7b417abd234c02eb56f333b5065ea4d 100644
--- a/media/audio/audio_low_latency_input_output_unittest.cc
+++ b/media/audio/audio_low_latency_input_output_unittest.cc
@@ -311,7 +311,11 @@ class StreamWrapper {
: com_init_(ScopedCOMInitializer::kMTA),
audio_manager_(audio_manager),
format_(AudioParameters::AUDIO_PCM_LOW_LATENCY),
+#if defined(OS_ANDROID)
+ channel_layout_(CHANNEL_LAYOUT_MONO),
+#else
channel_layout_(CHANNEL_LAYOUT_STEREO),
+#endif
bits_per_sample_(16) {
// Use native/mixing sample rate and N*10ms frame size as default,
// where N is platform dependent.
@@ -339,6 +343,8 @@ class StreamWrapper {
// ensure glitch-free output audio.
samples_per_packet_ = 3 * (sample_rate_ / 100);
}
+#elif defined(OS_ANDROID)
+ samples_per_packet_ = (sample_rate_ / 100);
#endif
}

Powered by Google App Engine
This is Rietveld 408576698