• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Writing little-endian AIFF/AIFC files
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Writing little-endian AIFF/AIFC files


  • Subject: Re: Writing little-endian AIFF/AIFC files
  • From: Stephen Davis <email@hidden>
  • Date: Sun, 29 Mar 2009 11:45:57 -0700

It looks like the CoreAudio audio file routines don't support little- endian AIFC. If you type "afconvert" in Terminal, you'll see the list of formats that are supported:

Usage:
afconvert [option...] input_file [output_file]

Options: (may appear before or after arguments)
{ -f | --file } file_format:
'3gpp' = 3GP Audio (.3gp)
data_formats: 'aac ' 'samr'
'3gp2' = 3GPP2 Audio (.3g2)
data_formats: 'aac ' 'samr'
'adts' = AAC ADTS (.aac, .adts)
data_formats: 'aac '
'ac-3' = AC3 (.ac3)
data_formats: 'ac-3'
'AIFC' = AIFC (.aifc, .aiff, .aif)
data_formats: I8 BEI16 BEI24 BEI32 BEF32
BEF64 UI8 'ulaw' 'alaw' 'MAC3' 'MAC6'
'ima4' 'QDMC' 'QDM2' 'Qclp' 'agsm'
'AIFF' = AIFF (.aiff, .aif)
data_formats: I8 BEI16 BEI24 BEI32
'amrf' = AMR (.amr)
data_formats: 'samr'
'caff' = Apple CAF (.caf)
data_formats: '.mp1' '.mp2' '.mp3' 'MAC3' 'MAC6'
'QDM2' 'QDMC' 'Qclp' 'Qclq' 'aac ' 'aacl'
'agsm' 'alac' 'alaw' 'drms' 'dvca' 'dvi '
'dvi8' 'ilbc' 'ima4' 'lpc ' I8 BEI16
BEI24 BEI32 BEF32 BEF64 LEI16 LEI24
LEI32 LEF32 LEF64 'ms\x00\x02' 'ms \x00\x11' 'ms\x001'
'ms\x00U' 'samr' 'ulaw' 'vdva'
'MPG1' = MPEG Layer 1 (.mp1, .mpeg, .mpa)
data_formats: '.mp1'
'MPG2' = MPEG Layer 2 (.mp2, .mpeg, .mpa)
data_formats: '.mp2'
'MPG3' = MPEG Layer 3 (.mp3, .mpeg, .mpa)
data_formats: '.mp3'
'mp4f' = MPEG4 Audio (.mp4)
data_formats: 'aac ' 'aacl'
'm4af' = MPEG4 Audio (.m4a)
data_formats: 'aac ' 'aacl' 'alac'
'NeXT' = NeXT/Sun (.snd, .au)
data_formats: I8 BEI16 BEI24 BEI32 BEF32
BEF64 'ulaw'
'Sd2f' = Sound Designer II (.sd2)
data_formats: I8 BEI16 BEI24 BEI32
'WAVE' = WAVE (.wav)
data_formats: UI8 LEI16 LEI24 LEI32 LEF32
LEF64 'ulaw' 'alaw'


As for when you would see little-endian AIFC files in practice, the files visible in the Finder when you insert an audio CD are little- endian AIFC files.

hth,
stephen

On Mar 29, 2009, at 8:44 AM, tahome izwah wrote:

AFAIK, only AIFC supports compressed sound files and little-endian
data counts as compression. AIFF does not support compression (and
therefore no little endian data). Personally I don't think there is
any reason why you would want to support little endian AIFC files
because you could as well use WAV which is little endian. I never
encountered little endian formatted AIFC files in practice so I'm not
sure who uses it and why (maybe it is faster to decode on Intel Macs
but I doubt that this makes a big difference on today's systems) .

Just my 2 cents though,
--th

2009/3/29 Adriaan van Os <email@hidden>:
I have been trying to write little-endian AIFF/AIFC files, so far without
success.


The documentation on the subject seems to be sparse and I couldn't find any
sample code. What I did find is:


General info
<http://en.wikipedia.org/wiki/Aiff> which mentions the 'sowt'
semi-compressor

CoreAudio
<http://developer.apple.com/DOCUMENTATION/MusicAudio/Conceptual/CoreAudioOverview/SupportedAudioConverterFormats/SupportedAudioConverterFormats.html >
which seems to imply that CoreAudio doesn't support little-endian AIFF/AIFC
data nor the 'sowt' semi-compressor


QuickTime
<http://developer.apple.com/documentation/QuickTime/QTFF/QTFFChap3/qtff3.html >
which suggests that QuickTime does
support the 'sowt' semi-compressor
<http://developer.apple.com/DOCUMENTATION/QuickTime/Conceptual/QT7UpdateGuide/Chapter03/03QT7_Update_Guide.html >
which
describes the kQTSCAudioPropertyID_ClientRestrictedPCMFlags constant.


QuickTime Player
The "Show Movie Inspector" of the QuickTime Player indicates if an AIFF/AIFC
file (or at least its content data) is
little-endian or big-endian. This also shows that the system software may
choose to write little-endian rather than
big-endian AIFF/AIFC files.


First, I tried to wite little-endian AIFC/AIFF files with CoreAudio.
Whatever I do, I get a "fmt?" error. Then, I tried
QuickTime and had no success with either StandardCompressionSubTypeSound or
StandardCompressionSubTypeAudio.


So, my questions are:

1. Why and under which circumstances does the system software choose to
write little-endian AIFF/AIFC files ?
2. How do application programmers write little-endian AIFF/AIFC files ?
3. Did I miss something or where is this documented ?


SIncerely,

Adriaan van Os
www.microbizz.nl

_______________________________________________
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

_______________________________________________ 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
References: 
 >Writing little-endian AIFF/AIFC files (From: Adriaan van Os <email@hidden>)
 >Re: Writing little-endian AIFF/AIFC files (From: tahome izwah <email@hidden>)

  • Prev by Date: Re: Writing little-endian AIFF/AIFC files
  • Next by Date: Re: Writing little-endian AIFF/AIFC files
  • Previous by thread: Re: Writing little-endian AIFF/AIFC files
  • Next by thread: Re: Writing little-endian AIFF/AIFC files
  • Index(es):
    • Date
    • Thread