diff options
author | aarti jadhav-gaikwad <agaikwad@nvidia.com> | 2014-06-18 15:25:26 +0530 |
---|---|---|
committer | Eric Laurent <elaurent@google.com> | 2014-07-11 09:53:16 -0700 |
commit | 2829edccd7d2bb8244246f316face82b650b8949 (patch) | |
tree | 485dbd465bc203b2227c87fe582abeffd1ece08c /media/libstagefright/AudioPlayer.cpp | |
parent | 7bad72237b49ac47e77ffe2a89fd26f3d171324c (diff) | |
download | frameworks_av-2829edccd7d2bb8244246f316face82b650b8949.zip frameworks_av-2829edccd7d2bb8244246f316face82b650b8949.tar.gz frameworks_av-2829edccd7d2bb8244246f316face82b650b8949.tar.bz2 |
stagefright: Pass audio aac sub formats in offloadinfo
Pass audio aac sub formats in offloadinfo according to
aac profile. Audio HAL can take decision about offload
using DSP capabilities
Change-Id: If269a3654b5d2b09c183212b0646ef03e06f2d8f
Diffstat (limited to 'media/libstagefright/AudioPlayer.cpp')
-rw-r--r-- | media/libstagefright/AudioPlayer.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/media/libstagefright/AudioPlayer.cpp b/media/libstagefright/AudioPlayer.cpp index fdac8fc..04fc88b 100644 --- a/media/libstagefright/AudioPlayer.cpp +++ b/media/libstagefright/AudioPlayer.cpp @@ -23,6 +23,7 @@ #include <binder/IPCThreadState.h> #include <media/AudioTrack.h> +#include <media/openmax/OMX_Audio.h> #include <media/stagefright/foundation/ADebug.h> #include <media/stagefright/foundation/ALooper.h> #include <media/stagefright/AudioPlayer.h> @@ -141,6 +142,12 @@ status_t AudioPlayer::start(bool sourceAlreadyStarted) { } else { ALOGV("Mime type \"%s\" mapped to audio_format 0x%x", mime, audioFormat); } + + int32_t aacaot = -1; + if ((audioFormat == AUDIO_FORMAT_AAC) && format->findInt32(kKeyAACAOT, &aacaot)) { + // Redefine AAC format corrosponding to aac profile + mapAACProfileToAudioFormat(audioFormat,(OMX_AUDIO_AACPROFILETYPE) aacaot); + } } int avgBitRate = -1; |