Re: Can Core Audio create m4a files?
Re: Can Core Audio create m4a files?
- Subject: Re: Can Core Audio create m4a files?
- From: William Stewart <email@hidden>
- Date: Mon, 1 Aug 2005 10:53:30 -0700
afconvert is a useful utility.
For instance, if you want to see what is available on your system at
any time, just do:
% afconvert
And you'll get something like:
afconvert [option...] input_file [output_file]
Options: (may appear before or after arguments)
{ -f | --file } file_format:
'adts' = AAC ADTS (.aac, .adts)
data_formats: 'aac '
'ac-3' = AC3 (.ac3)
data_formats: 'ac-3'
'AIFC' = AIFC (.aif, .aiff, .aifc)
data_formats: BEI8 BEI16 BEI24 BEI32 BEF32
BEF64 'ulaw' 'alaw' 'MAC3' 'MAC6'
'ima4'
'QDMC' 'QDM2' 'Qclp' 'agsm'
'AIFF' = AIFF (.aif, .aiff)
data_formats: BEI8 BEI16 BEI24 BEI32
'caff' = Apple CAF File (.caf)
data_formats: '.mp3' 'MAC3' 'MAC6' 'QDM2' 'QDMC'
'Qclp' 'Qclq' 'aac ' 'agsm' 'alac'
'alaw'
'drms' 'dvca' 'dvi ' 'ima2' 'ima4'
'lpc '
BEI8 BEI16 BEI24 BEI32 BEF32 BEF64
LEI16 LEI24 LEI32 LEF32 LEF64 'ms
\x00\x02'
'ms\x00\x11' 'ms\x001' 'ms\x00U'
'samr' 'ulaw' 'vdva'
'MPG3' = MPEG Layer 3 (.mpeg, .mp3)
data_formats: '.mp3'
'mp4f' = MPEG4 Audio (.mp4)
data_formats: 'aac '
'm4af' = MPEG4 Audio (.m4a)
data_formats: 'aac ' 'alac'
'NeXT' = NeXT/Sun (.snd, .au)
data_formats: BEI8 BEI16 BEI24 BEI32 BEF32
BEF64 'ulaw'
'*RAW' = RAW (.raw)
data_formats: BEI8 BEI16 BEI24 BEI32 BEF32
BEF64
'Sd2f' = Sound Designer II (.sd2)
data_formats: BEI8 BEI16 BEI24 BEI32
'WAVE' = WAVE (.wav)
data_formats: LEUI8 LEI16 LEI24 LEI32 LEF32
LEF64 'ulaw' 'alaw'
{ -d | --data } data_format[@sample_rate_hz][/format_flags]
[#frames_per_packet] :
[-][BE|LE]{F|[U]I}{8|16|24|32|64} (PCM)
e.g. BEI16 F32@44100
or a data format appropriate to file format, as above
format_flags: hex digits, e.g. '80'
bitdepth on non-PCM formats can be specified, e.g.: alac-24
Frames per packet can be specified for some encoders, e.g.:
samr#12
{ -c | --channels } number_of_channels
add/remove channels without regard to order
{ -l | --channellayout } layout_tag
layout_tag: name of a constant from CoreAudioTypes.h
(prefix "kAudioChannelLayoutTag_" may be omitted)
if specified once, applies to output file; if twice, the first
applies to the input file, the second to the output file
{ -b | --bitrate } bit_rate_bps
e.g. 128000
{ -q | --quality } quality
quality: 0-127
{ -v | --verbose }
print progress verbosely
{ -s | --strategy } strategy
bitrate strategy for encoded file
0 for CBR, 1 for ABR, 2 for VBR
You can see in the afconvert code how it is able to determine:
What file types are available to read/write
- can be more than Apple provides if there are 3rd party
AudioFileComponents installed
What data types (codecs) are available to encode/decode
- can be more than Apple provides if there are 3rd part
AudioCodecs installed
So, this part of afconvert shows you how to find this information out
Bill
On 30/07/2005, at 6:50 AM, Martin Hairer wrote:
I'm having a problem with opening and creating MPEG4 AAC audio
files in 10.3.9 using the CoreAudioFile API's. Does this feature
actually work? I can use the same method to open and create MP3
and AIFF files, but not AAC m4a files, so I know the code works.
AFAIK, this function works only under Tiger. Regards,
Martin
HairerSoft
http://www.hairersoft.com/
_______________________________________________
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
--
mailto:email@hidden
tel: +1 408 974 4056
________________________________________________________________________
__
"Much human ingenuity has gone into finding the ultimate Before.
The current state of knowledge can be summarized thus:
In the beginning, there was nothing, which exploded" - Terry Pratchett
________________________________________________________________________
__
_______________________________________________
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