How can I convert FLAC to other formats in OS X?

11

3

I have a few FLAC files that I'd like to play with iTunes. I would like to retain the metadata if possible.

How can I convert the files to a format supported by iTunes?

jweede

Posted 2010-05-19T19:37:14.847

Reputation: 6 325

Normally I'd say SoundConverter, but getting gstreamer running on OS X is No Fun. – Ignacio Vazquez-Abrams – 2010-05-19T19:40:09.523

Answers

13

You can always convert media via FFmpeg, available as a static build for OS X from the downloads page.

ffmpeg -i in.flac -c:a libmp3lame -q:a 4 -map_metadata 0 out.mp3

Set the quality via -q:a, which corresponds to LAME's VBR options, 4 being default and 0 being the best quality.

akira

Posted 2010-05-19T19:37:14.847

Reputation: 52 754

6

aac:

ffmpeg -i file.flac -acodec libfaac -aq 250 file.m4a

-aq 400 ≈ 270 kb/s for music, 200 ≈ 210 kb/s, 100 ≈ 130 kb/s.

alac:

for f in *.flac; do ffmpeg -i "$f" -acodec alac "${f%flac}m4a"; done

mp3:

ffmpeg -i file.flac -aq 0 file.mp3

-aq 0 corresponds to -V0 in lame.

ffmpeg preserves tags by default but not cover art.

Lri

Posted 2010-05-19T19:37:14.847

Reputation: 34 501

4

I've used Max with success in the past.

Hank Gay

Posted 2010-05-19T19:37:14.847

Reputation: 297

2

Assuming you have ffmpeg installed (brew install ffmpeg)

Go into the directory in terminal. Run:

for f in *.flac; do ff=${f%.flac}.mp3; ffmpeg -i "$f" -c:a libmp3lame -q:a 0 -map_metadata 0 "$ff"; done

This should produce a directory of mp3 as well as flac in v0 format

Jotham

Posted 2010-05-19T19:37:14.847

Reputation: 438

2

I've recently used xACT, a front end to several audio manipulation and tagging programs. It can do conversion from FLAC to MP3, AAC and Opus. Here you can see the tab from which you perform the conversion:

xACT screenshot

The metadata are preserved, as you can see from the Media Information dialogs (taken in VLC) for a FLAC file and its conversion in MP3:

FLAC metadata MP3 details

P.S.: the linked site uses frames, to read a comprehensive description of the program follow this link.

edymtt

Posted 2010-05-19T19:37:14.847

Reputation: 551

0

X Lossless Decoder

This only converts to lossless and non-lossless formats.

You can use it to convert to Apple Lossless that iTunes can play then play that or rip it to whatever lossy format you prefer that iTunes supports.

ghoppe

Posted 2010-05-19T19:37:14.847

Reputation: 6 124

The link seems to be dead. – xApple – 2016-02-02T17:51:10.253