Hi all, I'm develop an AACDecoder in my application using UMC::AACDecoder. I have to decode RTP AAC packet. I have already have a look to




And was very useful. I can decode and hear audio. Anyway I think the documentation is still missing of clear information about that: I mean it's not clear that you have to initialize the decoder in AAC_MPEG4_STREAM mode giving to the init a 2byte buffer from RTSP negotiation.

Anyway the problem is that documentation explain the "Typical Usage" that fill the input buffer with m_SuggestedInputSize and give it to the GetFrame. The problem is that in AAC_MPEG4_STREAM, after the decoding is performed the MediaData input buffer has always the GetDataSize=0 because of these decoder lines:

if (AAC_MPEG4_STREAM == m_info.m_init_stream_type) {
} else {

So, why you do a in->MoveDataPointer((Ipp32s)in->GetDataSize()); even if nDecodedBytes is less then in->GetDataSize()? this way I can't fill it with m_SuggestedInputSize but I have to fill exactly 1 AAC packet otherwise I do not know if you have some remain size inside.

Can I walk around this? and Why there's in->MoveDataPointer((Ipp32s)in->GetDataSize()); line?


5 posts / 0 new
Last post
For more complete information about compiler optimizations, see our Optimization Notice.

Good day.

AAC_MPEG4_STREAM is suppose to be decoded in pair with MP4 splitter and splitter always returns one data packet.
In 7.1.1 samples there is umc_audio_dec_con sample where you can see example of audio decoding pipeline for various formats.

Have a nice day.

Ok I understand AAC_MPEG4_STREAM stay for MP4 stream...but I can't understand why you have nDecodedBytes but you move the pointer of in size (probably for mp4 stream behavior). Anyway if you want to decode the AAC audio from a RTP source you have to do some tricks, like 2 byte buffer decoder initialization or change the m_info.m_init_stream_type after initialize: now I do that, for correctly decode AAC stream

This is very old workaround for some MP4 streams. Probably it has no value anymore, I think it is better to comment out this condition and use only actual decoded size value.

Have a nice day.

I think it's a good idea ;) just for future release so I don't have to subclass the AACDecoder to change the stream type

Leave a Comment

Please sign in to add a comment. Not a member? Join today