Converting Audio to AAC using ffmpeg

I have the following setup for FFmpeg:

ffmpeg version N-54790-g1816f55-syslint Copyright (c) 2000-2013 the FFmpeg developers
  built on Jul 17 2013 21:34:32 with gcc 4.4.7 (GCC) 20120313 (Red Hat 4.4.7-3)
  configuration: --prefix=/usr/local/cpffmpeg --enable-shared --enable-nonfree --enable-gpl --enable-pthreads --enable-libopencore-amrnb --enable-decoder=liba52 --enable-libopencore-amrwb --enable-libfaac --enable-libmp3lame --enable-libtheora --enable-libvorbis --enable-libx264 --enable-libxvid --extra-cflags=-I/usr/local/cpffmpeg/include/ --extra-ldflags=-L/usr/local/cpffmpeg/lib --enable-version3 --extra-version=syslint
  libavutil      52. 40.100 / 52. 40.100
  libavcodec     55. 18.102 / 55. 18.102
  libavformat    55. 12.102 / 55. 12.102
  libavdevice    55.  3.100 / 55.  3.100
  libavfilter     3. 81.101 /  3. 81.101
  libswscale      2.  4.100 /  2.  4.100
  libswresample   0. 17.102 /  0. 17.102
  libpostproc    52.  3.100 / 52.  3.100

I am trying to use FFmpeg to convert my m4a or mp3 files to

AAC, Low Complexity Profile (LC)

I am really struggling to find a command line that works for me. Is it even possible with my FFmpeg setup?

Thanks


AAC-LC is the default for all of the AAC encoders supported by ffmpeg.

Example:

ffmpeg -i input.m4a -codec:a aac output.aac

See FFmpeg Wiki: AAC Encoding Guide for more details and examples.


To re-encode any format to AAC-LC in an ADTS container (.aac file) using FFmpegs's native AAC encoder (second best after non-free Fraunhofer's libfdk_aac according to https://trac.ffmpeg.org/wiki/Encode/AAC -- doesn't support any HE-AAC though), you also need to specify -strict experimental (or -strict -2):

ffmpeg -i input.mp3 -strict experimental -c:a aac -b:a 128k output.aac

When converting to .aac from a source in m4a/mp4, you don't even need to re-encode:

ffmpeg -i input.m4a -c:a copy output.aac

Note: FFmpeg tries to guess the output format from the output file name. If you need to force the format for ADTS (.aac file), use -f adts (e.g. when working with piped streams instead of files):

cat input.wav | ffmpeg -i pipe:0 -c:a aac -c:b 128k -f adts pipe:1 ­> output.aac