user3108268
user3108268

Reputation: 1083

How to join 2 audio files into one using either ffmpeg or eac3to?

Not merge or mux into each other, because this is what I found so far, but take 2 .mp3 files e.g. 1 hour long each and join them and it becomes 1 .mp3 file with total of 2 hour long?

I did this:

ffmpeg -i audio.mp3 -i 1.mp3  -filter_complex amerge -c:a libmp3lame -q:a 4 audiofinal.mp3

But I think it encode both files into each other or something.

And there's nothing about this at https://en.wikibooks.org/wiki/Eac3to/How_to_Use

I'd like to prefer command line solution and not Audacity or mp3DirectCut.

edit: i tried eac3to m1.mp3+m2.mp3 1.mp3 but it doesn't join them, output audio is the length of first file.

Upvotes: 0

Views: 856

Answers (2)

riamu
riamu

Reputation: 1

Found that when merging flacs their times won't sum. This works:

ffmpeg -f concat -i concat.txt alltogether.flac

concat.txt looks like this:

file 01.flac

file 02.flac

file 03.flac

file 04.flac

file 05.flac

Upvotes: 0

Gyan
Gyan

Reputation: 93008

What you need to do is concat.

ffmpeg -i audio.mp3 -i 1.mp3  -filter_complex concat=a=1:v=0 -c:a libmp3lame -q:a 4 audiofinal.mp3

Upvotes: 1

Related Questions