Audio Converter
Audio Converter
- Subject: Audio Converter
- From: George Malayil-Philip <email@hidden>
- Date: Fri, 16 Dec 2005 03:26:58 -0500
- Thread-topic: Audio Converter
Hi,
I am trying to write a audio converter to convert from iTunes ripped
.m4a files to uncompressed audio. I tried setting up a audio converter with
the target audio format being set as
//fill in output format
OSType type;
StrToOSType("lpcm", type);
targetFormat.mFormatID = type;
targetFormat.mSampleRate = srcFileFormat.mSampleRate;
targetFormat.mChannelsPerFrame = srcFileFormat.mChannelsPerFrame;
UInt32 size = sizeof(targetFormat);
XThrowIfError(AudioFormatGetProperty(kAudioFormatProperty_FormatInfo, 0,
NULL, &size, &targetFormat),
"getting target format info");
While no errors are thrown with this, if I then try targetFormat.Print()
I crash with "terminate called after throwing an instance of 'CAXException'"
Calls to AudioConverterNew() also fail on account of this. I am not sure
what I am doing wrong and would appreciate some help on this.
Another thing that has me confused is when I do srcFileFormat.Print() it
prints
AudioStreamBasicDescription: 2 ch, 44100 Hz, 'lpcm' (0x0000002B) 32-bit
big-endian float, deinterleaved
Shouldn't the format be 'aac '? This has me a bit confused. Any help
much appreicated. Thanks.
Regards
George M.P.
_______________________________________________
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