summaryrefslogtreecommitdiffstats
path: root/cmds
diff options
context:
space:
mode:
authorGlenn Kasten <gkasten@google.com>2012-03-19 07:31:58 -0700
committerAndroid (Google) Code Review <android-gerrit@google.com>2012-03-19 07:31:58 -0700
commit1746929ddc7592ab397c402724a61352e45df093 (patch)
tree1911bbd03adeac6bb6e8fa91de3ee1833a40e401 /cmds
parenteb76ff27c13386eb5a2dad73b1a8366f80eb0ff7 (diff)
parentab334fd351ae5a0e18903da123d63e565b536874 (diff)
downloadframeworks_av-1746929ddc7592ab397c402724a61352e45df093.zip
frameworks_av-1746929ddc7592ab397c402724a61352e45df093.tar.gz
frameworks_av-1746929ddc7592ab397c402724a61352e45df093.tar.bz2
Merge "audio_channel_in/out_mask_from_count"
Diffstat (limited to 'cmds')
-rw-r--r--cmds/stagefright/SimplePlayer.cpp3
-rw-r--r--cmds/stagefright/audioloop.cpp4
2 files changed, 2 insertions, 5 deletions
diff --git a/cmds/stagefright/SimplePlayer.cpp b/cmds/stagefright/SimplePlayer.cpp
index fac3a8c..0cfeb3e 100644
--- a/cmds/stagefright/SimplePlayer.cpp
+++ b/cmds/stagefright/SimplePlayer.cpp
@@ -583,8 +583,7 @@ status_t SimplePlayer::onOutputFormatChanged(
AUDIO_STREAM_MUSIC,
sampleRate,
AUDIO_FORMAT_PCM_16_BIT,
- (channelCount == 1)
- ? AUDIO_CHANNEL_OUT_MONO : AUDIO_CHANNEL_OUT_STEREO,
+ audio_channel_out_mask_from_count(channelCount),
0);
state->mNumFramesWritten = 0;
diff --git a/cmds/stagefright/audioloop.cpp b/cmds/stagefright/audioloop.cpp
index a6362a4..ed7d6cb 100644
--- a/cmds/stagefright/audioloop.cpp
+++ b/cmds/stagefright/audioloop.cpp
@@ -32,9 +32,7 @@ int main() {
sp<MediaSource> source = new AudioSource(
AUDIO_SOURCE_DEFAULT,
kSampleRate,
- kNumChannels == 1
- ? AUDIO_CHANNEL_IN_MONO
- : AUDIO_CHANNEL_IN_STEREO);
+ audio_channel_in_mask_from_count(kNumChannels));
#endif
sp<MetaData> meta = new MetaData;