Error in converting WAV to AAC
Error in converting WAV to AAC
- Subject: Error in converting WAV to AAC
- From: Andrew Davis <email@hidden>
- Date: Tue, 20 Jan 2009 21:43:55 +0530 (IST)
Hi,
I am trying to convert few file formats to WAVE file format. The code works fine for MP3 and AIFF file formats. But, when i use the MIDI format, i am not able to open the audiofile itself. And, when i use AAC audio files, the converter throws an error. Error code is 1718449215.
Code:
OSStatus err = AudioConverterNew (&inputFormat, &outputFormat, &converter);
where, inputFormat, outputFormat -> AudioStreamBasicDescription and converter -> AudioConverterRef. This err = 1718449215
I am setting the following values for the outputFormat. This is the same format that i have used with MP3 and AIFF files.
mBitsPerChannel - 16
mBytesPerFrame - 4
mBytesPerPacket - 4
mChannelsPerFrame - 2
mFormatFlags - 12 ( kLinearPCMFormatFlagIsSignedInteger |
kLinearPCMFormatFlagIsPacked )
mFormatID - 1819304813 ( kAudioFormatLinearPCM )
mFramesPerPacket - 1
mReserved - 0
mSampleRate - 44100
Please tell me where i have gone wrong and if i needed to add something else along with this.
Thanks,
Andrew
Add more friends to your messenger and enjoy! Go to http://messenger.yahoo.com/invite/
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Coreaudio-api mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden