How to add offset or delay to audio file with ffmpeg?

Viewed 4764

I need offset (some silence) in the start of file, so I tried:

./ffmpeg -itsoffset 100 -i 3.mp3 offset_test.mp3

But it doesn't work.

How to add offset to audio file with ffmpeg?

2 Answers

For formats without timestamps, you'll need to add silence, as @Brad mentioned.

ffmpeg -i 3.mp3 -af adelay=100000|100000 delayed.mp3

The adelay takes delay in milliseconds per channel, separated by |.

The easiest way I found so far for ffmpeg ver > 4.2:

ffmpeg -i audio_in.wav -af areverse,apad=pad_dur=1s,areverse audio_out.wav

This will add an offset of 1 second to the audio.

Related