diff options
author | James Dong <jdong@google.com> | 2012-05-02 11:01:59 -0700 |
---|---|---|
committer | James Dong <jdong@google.com> | 2012-05-02 11:01:59 -0700 |
commit | 2d94235a343151bed9aa74e86697fa01241ea5cf (patch) | |
tree | 369bc288b56bedc9bb22ddf6941adadedab62836 /media/libstagefright/AACWriter.cpp | |
parent | 2c3297ab6c4daaaa7b27eed8418c64cf168fe2a1 (diff) | |
download | frameworks_av-2d94235a343151bed9aa74e86697fa01241ea5cf.zip frameworks_av-2d94235a343151bed9aa74e86697fa01241ea5cf.tar.gz frameworks_av-2d94235a343151bed9aa74e86697fa01241ea5cf.tar.bz2 |
The presence of the kKeyAACProfile is optional, we should not mandate its presence in AACWriter.
o related-to-bug: 6421833
Change-Id: Ia1d75e73270430177d3010e8024b48c88eb7b430
Diffstat (limited to 'media/libstagefright/AACWriter.cpp')
-rw-r--r-- | media/libstagefright/AACWriter.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/media/libstagefright/AACWriter.cpp b/media/libstagefright/AACWriter.cpp index 21c5428..284ba01 100644 --- a/media/libstagefright/AACWriter.cpp +++ b/media/libstagefright/AACWriter.cpp @@ -98,9 +98,13 @@ status_t AACWriter::addSource(const sp<MediaSource> &source) { CHECK(!strcasecmp(mime, MEDIA_MIMETYPE_AUDIO_AAC)); CHECK(meta->findInt32(kKeyChannelCount, &mChannelCount)); CHECK(meta->findInt32(kKeySampleRate, &mSampleRate)); - CHECK(meta->findInt32(kKeyAACProfile, &mAACProfile)); CHECK(mChannelCount >= 1 && mChannelCount <= 2); + // Optionally, we want to check whether AACProfile is also set. + if (meta->findInt32(kKeyAACProfile, &mAACProfile)) { + ALOGI("AAC profile is changed to %d", mAACProfile); + } + mSource = source; return OK; } |