AAC won't play on RZR V3C | developer.brewmp.com AAC won't play on RZR V3C | developer.brewmp.com

Developer

AAC won't play on RZR V3C

Forums:

I'm writing a multimedia application and part of the requirements are that it play AAC formatted media files. When I test on app on the emulator it plays fine, but when I move it to the V3C handset it fails. I get the following status codes back from the IMEDIA(in order):
MM_STATUS_DONE
MM_STATUS_START
MM_STATUS_MEDIA_SPEC (The spec is actually null)
MM_STATUS_ABORT

Here is a code snippet (All the pointers are valid, i've removed the error checking for space considerations, and everything returns 0 for the error codes) but I never hear anything (as would be expected from recieving a MM_STATUS_ABORT):

int nRet;
myapp* pMe= notifyData;

ISHELL_CreateInstance(pMe->pIShell,AEECLSID_MEDIAMP3,&(pMe->pMedia));
nRet = ISHELL_CreateInstance(pMe->pIShell,AEECLSID_MEDIAAAC ,&(pMe->pMedia));
DBGPRINTF("IMEDIA: The value of N is %x",nRet);

pMe->md.clsData = MMD_FILE_NAME;//AEECLSID_MEDIAMP3;
pMe->md.pData = "aac12k08khz.mp4";
pMe->md.dwSize = 0;

nRet = IMEDIA_SetMediaData(pMe->pMedia,&pMe->md);

if(nRet == 0){
nRet = IMEDIA_RegisterNotify(pMe->pMedia, (PFNMEDIANOTIFY)*MediaPlayCB, pMe);
nRet = IMEDIA_SetVolume(pMe->pMedia, AEE_MAX_VOLUME );
DBGPRINTF("Volume: The Value of N is %x", nRet);
nRet = IMEDIA_Play(pMe->pMedia);
DBGPRINTF("Play: The Value of N is %x", nRet);

I've tried using CreateMedia instead of SetMedia, but I get a ENOMEMORY error on both the handset and the emulator(where it correctly plays with SetMedia) when I call it. (According to the emulator I have plenty of free memory, and I only have a int and a few pointers allocated by me on the stack )I've also tried with AAC files with several different extensions (m4a,3gp,and mp4) all with the same failures.

Did you try a standalone AAC file?

Did you try a standalone AAC file?

Max
Thanks for the help. Using the bare AAC file worked for playing from the filesystem. (Although it won't play in the emulator) Unfortunately, when I download the same file from the web into a buffer to play I get the same problem as before:
MM_STATUS_DONE
MM_STATUS_START
MM_STATUS_ABORT
I would guess that IMEDIA is having a difficult time figuring out what codec it is from the buffer, but can't be sure. Any ideas.
Eric

Max
Thanks for the help. Using the bare AAC file worked for playing from the filesystem. (Although it won't play in the emulator) Unfortunately, when I download the same file from the web into a buffer to play I get the same problem as before:
MM_STATUS_DONE
MM_STATUS_START
MM_STATUS_ABORT
I would guess that IMEDIA is having a difficult time figuring out what codec it is from the buffer, but can't be sure. Any ideas.
Eric

Just a couple comments:
1. You should not be hardcoding any AEECLSID_MEDIA* class IDs into your application. Instead, you should be using ISHELL_GetHandler() or IMediaUtil to query for the proper class handler.
2. Our most recent tests on this device show that AAC playback from file and buffer is supported on both standalone AAC files and AAC files within mp4 (both 3gp and 3g2).
You might want to try the MediaPlayer app to see if the playback is working fine on there.

Just a couple comments:
1. You should not be hardcoding any AEECLSID_MEDIA* class IDs into your application. Instead, you should be using ISHELL_GetHandler() or IMediaUtil to query for the proper class handler.
2. Our most recent tests on this device show that AAC playback from file and buffer is supported on both standalone AAC files and AAC files within mp4 (both 3gp and 3g2).
You might want to try the MediaPlayer app to see if the playback is working fine on there.

I had given up on IMEDIAUTIL_CreateMedia on the emulator, but gave it another try on the handset and it seems to have cleared up my problems with playing from buffers and playing files in mp4 and .3gp containers. Thanks.

I had given up on IMEDIAUTIL_CreateMedia on the emulator, but gave it another try on the handset and it seems to have cleared up my problems with playing from buffers and playing files in mp4 and .3gp containers. Thanks.