Convert an MP3 from 48000 to 44100 Hz?

26

2

I have some MP3s that are in 48000 Hz sampling frequency. I'd like to burn them to CD, so I have to reduce the sampling frequency into 441000.

How to do that using ffmpeg?

anta40

Posted 2011-03-05T04:56:20.887

Reputation: 525

Answers

47

ffmpeg doesn't look to be the appropriate tool; I'd normally use sox for audio-only files.

$ sox file1.mpg -r 44100 file1-enc.mpg

If you want to try using ffmpeg anyway, I think the correct command would be

$ ffmpeg -i file1.mpg -ar 44100 file1-enc.mpg

geekosaur

Posted 2011-03-05T04:56:20.887

Reputation: 10 195

1sox didn't directly work with MP3s for me. I had to install libsox-fmt-mp3 – gsmafra – 2016-03-21T18:58:13.520

10ffmpeg is a perfectly appropriate tool, though it may be overkill in a way. – leftaroundabout – 2018-08-10T15:44:20.767

2

And if you need constant bitrate (CBR), you can add something like -b:a 64k (https://trac.ffmpeg.org/wiki/Encode/MP3).

– Ryan – 2019-02-18T15:41:36.380

Command to use sox resampler with the ffmpeg is ffmpeg -i file1.mpg -af aresample=resampler=soxr -ar 44100 file1-enc.mpg, see FFmpeg Wiki.

– Ivan Shatsky – 2019-11-17T12:13:05.877

Yes sox is much better for audio, thanks for the tip! – Michael Pliskin – 2012-01-04T11:17:08.680

6ffmpeg supports sox resampler since 1.1 – Benja – 2014-04-10T15:04:04.323