jeudi 22 janvier 2015

Android MediaCodec for AC-3

I am trying to decode AC3 audio with the Android MediaCodec API. I can successfully decode AAC provided I set csd-0 to the elementary stream descriptor.


Attempting to decode AC3, I use the following MediaFormat in my configuration:



AMEDIAFORMAT_KEY_MIME: "audio/ac3"
AMEDIAFORMAT_KEY_CHANNEL_COUNT: 6
AMEDIAFORMAT_KEY_SAMPLE_RATE: 48000
AMEDIAFORMAT_KEY_IS_ADTS: 0


On the call to AMediaCodec_configure I get the following error messages:



01-22 12:37:58.760: E/ACodec(10548): [OMX.Nvidia.bypass.decoder] configureCodec returning error -2147483648
01-22 12:37:58.760: E/ACodec(10548): signalError(omxError 0x80001001, internalError -2147483648)
01-22 12:37:58.760: E/MediaCodec(10548): Codec reported err 0x80001001, actionCode 0, while in state 3
01-22 12:37:58.760: E/MediaCodec(10548): configure failed with err 0x80001001, resetting...


Is there some extra data I need to provide the decoder? I am unfamiliar with the AC3 standard, perhaps there is an equivalent to the elementary stream descriptor that must be provided in csd-0?


Aucun commentaire:

Enregistrer un commentaire