Intel® Integrated Performance Primitives
Deliberate problems developing high-performance vision, signal, security, and storage applications.

AAC - audio decoding and rendering

bharath322
Beginner
469 Views
Hi,

I am looking for the IPP usage examples for AAC- audio decoding andaudio rendering. Can anyone help please ? I tried searching the usage examples in the UMC manual. But i failed to find it. Can anyone attach the samples of how the AAC- audio decoding and rendering is done ?

Thanks
0 Kudos
2 Replies
bharath322
Beginner
469 Views
I have tried to do AAC - audio streaming from the camera using the IPP audio-video codecs samples
The following are the steps i have done.
1)
The initialization was done only once.

m_pAudioparams->m_info_in.sample_frequency = 8000;

m_pAudioparams->m_info_in.bitPerSample = 16;

m_pAudioparams->m_info_in.channels = 2;

m_pAudioparams->m_info_in.bitrate = 32000;

m_pAudioparams->m_info_in.stream_type = UMC::AAC_MPEG_STREAM;

m_pAudioparams->m_pData = rtspClient->m_pAudMediaIn;

// where m_pAudioparams is UMC::AudioCodecParams

if (UMC::UMC_OK = (m_pAudioDecoder->Init(m_pAudioparams)))
{
//initialization Sucess
}

2) Then

m_pAudMediaIn->SetBufferPointer((Ipp8u *)szData,len);

// m_pAudMediaIn is UMC::MediaData object ,szData is raw audio buffer from the camera i get everytime as it streams, len is length of the audio buffer.

m_pAudMediaIn->SetDataSize(len);

is set eveytime.

3)

UMC::Status stRes = m_pAudioDecoder->GetFrame(m_pAudMediaIn,m_pAudMediaOut);

if(UMC::UMC_OK == stRes)
{

if(!m_bFirst)

{
// Audio Renderer initialization is done only once

m_pAudioDecoder->GetInfo(m_pAudioparams);

m_bFirst =TRUE;

m_pAudioRenderParams->info = m_pAudioparams->m_info_out;
// At this point I got m_info_out.channels = 0,m_info_out.samplefrequency = 16000,m_info_out.bitrate = 0, m_info_out.bitpersample = 16,m_info_out.stream_type = PCM_AUDIO.

UMC::HWNDModuleContext hmcontext;

hmcontext.m_hWnd = (HWND)m_hWnd;

m_pAudioRenderParams->pModuleContext = &hmcontext;

UMC::Status stRes = m_pAudioRender->Init(m_pAudioRenderParams); //m_pAudioRender is UMC::WinMMAudioRender() HERE initialization is failing.

}

m_pAudioRender->SetVolume(1);

UMC::Status sta = m_pAudioRender->SendFrame(m_pAudMediaOut);

}

}

In this stepthe AACdecoder->getframe returns UMC::UMC_OK whenever it gets the frame.

But initializing the audio rendering is failing from the above for me.

Could anyone please help me out where I am doing wrong?

Please Help me?
0 Kudos
Reply