MP3 or MP4 recording with CMdaAudioRecorderUtility in S60 3rd
| Fri, 2008-09-05 09:17 | |
|
|
Hi, Have a problem with recording audio to MP3 format. When trying to do this, OpenFileL just leaves with -1 (KErrNotFound). When recording with MP4 format, recording works but playback sounds like Donald Duck (while I do not when I speak), it's way too fast. I tried setting the SetDestinationSampleRateL and SetDestinationBitRatesL but no success. Recording with wav with the same piece of code works perfectly. Any ideas how to fix? Is it just impossible to record MP3/4 on this platform? |






Forum posts: 116
Hi,
I suppose MP3 recording is not supported by the device you can check the supported data types by calling "GetSupportedDestinationDataTypesL" method.
Concerning the voice quality set the appropriate channel mode along with sample rate (SetDestinationNumberOfChannelsL).
Chao,
Raghav
Forum posts: 683
Thanks for the reply. Yes, I already checked the supported destination datatypes on the device and noticed mp3 is not supported. However, trying to set the number of channels to mono just caused a leave with KErrNotSupported.
Forum posts: 116
Hi,
Do you have any idea whether the encoding is accelerated or done by the soft codec?
The quality problem you mentioned seems like due to incorrect setting of sampling frequency and channels.
This can happen when the encoder is getting data with sampling rate lower than it is configured to receive. E.g: if it is configured to get data @ 16K stereo but instead it receives 8K stereo, then the playback will be garbled and usually twice as fast as original sound, also the play time will be half the original record time (this is just one of the possible possibilities
May be this will give you a hint about the correct configuration to be used.
You can also check the file properties for the bitrate, sampling freq and channels. This will give you a definitive hint about mismatch in config.
What sample rate you are using in your application? Is it higher than 8K?
Chao,
Raghav