iTunes Plus

Discuss the current and future development of Max.
Post Reply
kai_h
Posts: 5
Joined: Wed Jan 09, 2013 11:35 am

iTunes Plus

Post by kai_h » Wed Jan 09, 2013 11:48 am

Apple have got their Apple Audio Mastering Tools, which are used to create a Mastered for iTunes high-quality AAC file from lossless masters. Just in case anyone's interested in the process it uses, I've dug into the toolkit and looked at how it works.

The caff files that are generated by afconvert as an intermediate step are 32-bit floating point audio files, and the sample-rate conversion can be done at a very high quality and it reduces or eliminates the need to dither the output when converting word sizes. This is then used as a direct input to afconvert once more to create an AAC file directly. afconvert is a standard command-line tool on OS X 10.6+ and will accept any file format that Core Audio understands (eg WAVE, AIFF, ALAC but not FLAC)

Internally, the tool checks the sample-rate. If it's using a sample rate greater than 44.1kHz, it runs this command:

Code: Select all

afconvert <input file> -d LEF32@44100 -f caff --soundcheck-generate --src-complexity bats -r 127 <output file.caf>
If the input file is sampled at 44.1kHz, it runs this command instead:

Code: Select all

afconvert <input file> <output file.caf> -d 0 -f caff --soundcheck-generate
It then gets this caff (Core Audio File Format) file and makes an AAC from it via the following command:

Code: Select all

afconvert <input file.caf> -d aac -f m4af -u pgcm 2 --soundcheck-read -b 256000 -q 127 -s 2 <output file.m4a>

User avatar
sbooth
Site Admin
Posts: 2445
Joined: Fri Dec 23, 2005 7:45 am
Location: USA
Contact:

Re: iTunes Plus

Post by sbooth » Thu Jan 10, 2013 4:37 am

Thanks for sharing this. Every time I see the converter quality of 'bats' I chuckle!

kai_h
Posts: 5
Joined: Wed Jan 09, 2013 11:35 am

Re: iTunes Plus

Post by kai_h » Thu Jan 10, 2013 8:18 am

I've given it a fair bit of thought.

line stands for Linear
norm stands for Normal

I can only assume that bats stands for Batshit Insane Settings, which is why it's not documented what it actually means. It really is more than a couple of orders of magnitude more processing to use the bats setting.

As an example, I timed a conversion on a short sample using each complexity setting:
bats - 3.588 seconds
normal - 0.144 seconds
linear - 0.017 seconds

Post Reply

Who is online

Users browsing this forum: Yahoo [Bot] and 2 guests