Playing Mp3 in Feature Pack 1
is there any open API's for playing Mp3 in Feature Pack 1? can you tell me?
Thanks in Advance.
Nokia Developer Expert
normal audio recorder API should play MP3 files just fine.
What is "normal audio recorder API "? Can you talk about it in detail? I try to playback mp3 file on the emulator with Feature Pack 3, but failed. But from Feature Pack 1, mp3 playback should be supported by s60 platform. Does emulator support mp3 playback? Thank you!
Nokia Developer Expert
try it on the phone instead, emulators are known to not support all the stuff that is possible in the real phones.
Basically just test the app with wav files in the emulator, and as soon as you get it working, try it in the phone with the target format files.
Playing Mp3 in 6600
I am presently working to play the Mp3 file in 6600.
I am using the libmad library and integrated the code onto AudioStream example in order to play the MP3 file. My idea in implementation is as follows:
(1) open MP3 file and decode using DecodeOneFrame() function given by Libmad library, storing the decoded output into an HBufC.
(2) converting 16 bit data to 8 bit using ConvertFromUnicodeToUtf8() function and storing the resulting data into another HBufC8.
(3) writing decoded output into a temporary file
(4) reading the temporary file into the buffer as per the following code:
err = audiofile.Open(fs, _L("c:\\Stream.buf"), EFileRead|EFileStream);
// file opened ok, proceed reading
ShowMessageL(_L("Loading complete!"), true);
// failed to open file
ShowMessageL(_L("Error loading audio sample!"), true);
Still the program is not giving a proper audio response.
Is there any gross mistakes on following this procedure. Please help me to solve this problem. Any specific information if needed, please do ask.
Thanking you all in anticipation,
Waiting for your help,
Arun S L
Can you show me the detail on how to use Libmad library? I have got the source of Libmad and compile it to DLL, but there is no document on how to use it? Can you do me a favor? Thank you very much!
reply for foundwei
Try assessing the function DecodeOneFrame() of Libmad to convert the Mp3 data. Basically you will be accessing functions of Libmad via a Mp3Decoder.h header file. Hope it solves your problem.
Hopping to help you better,
Arun S L.