Re: Audio data format and file type - how to match?
Re: Audio data format and file type - how to match?
- Subject: Re: Audio data format and file type - how to match?
- From: "tahome izwah" <email@hidden>
- Date: Sat, 22 Jul 2006 23:39:21 +0200
Thanks... but... isn't there a simpler way to determine a compatibility matrix?
Something like...
CAGetCompatibleFileTypesFromStreamType(char *fileType, AudioFileTypeID
*type, long *numTypes);
...or CAGetCompatibleStreamTypesFromFileType() for doing the reverse?
In my humble opinion, this whole CoreAudio business seems overly
complicated and has a pretty steep learning curve. ExtAudioFile is a
step in the right direction, but some things (like matching file type
and stream format) are still very inconvenient and require a lot of
coding...
Thanks for listening,
--th
2006/7/21, Doug Wyatt <email@hidden>:
On Jul 20, 2006, at 23:13 , tahome izwah wrote:
> Hi all,
>
> I have a question about the four char codes describing the audio data
> format and the actual file types of the files that can hold such
> data... is there any call that tells me from such a four char code
> what the right file type(s) should/can be?
>
> For instance, if I let the user select from a list of encoding options
> in a save-as dialog box and he selects "MPEG-4 AAC" (corresponding to
> the four char code kAudioFormatMPEG4AAC in an
> AudioStreamBasicDescription that I set up), how do I know what file
> type I have to pass to ExtAudioFileCreateNew() to create the correct
> audio file (in this case kAudioFileM4AType)?
>
> To be future-proof, I'd not like to go through all the available file
> types manually so I guess there must be an option/call that I can
> use...?
Have a look at /Developer/Examples/CoreAudio/PublicUtility/
CAAudioFileFormats.cpp
Also in /Developer/Examples/CoreAudio/PublicUtility/Services/
AudioFileTools, try the "audioformats" tool.
Doug
--
Doug Wyatt
Core Audio, Apple
_______________________________________________
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