1

I have 3 flv files which I wish to merge. I used the answer in this post:

Merge multiple flv files?

which suggested this option:

mencoder -forceidx -ovc copy -oac pcm -o output.flv input1.flv input2.flv

It seems to have worked except that the merged file is 400meg in size whereas the original 3 files were about 33meg each.

Is this expected? Is there a way to join the 3 files without the massive increase in size?

  • I can't explain the massive increase in size. Check my answer for a solution using ffmpeg. – Patrick Jan 18 '13 at 15:09
  • Hmmm, with mencoder, isn't that actually making an AVI file (but with a .flv suffix)? – derobert Jan 18 '13 at 15:49
1

Create a file mylist.txt with all the files you want to have concatenated in the following form:

    # this is a comment
    file '/path/to/file1'
    file '/path/to/file2'
    file '/path/to/file3'

Then you can encode your files with:

    ffmpeg -f concat -i mylist.txt -c copy output

Edit: You may need to compile ffmpeg from source to get a recent enough version.

Source: http://ffmpeg.org/trac/ffmpeg/wiki/How%20to%20concatenate%20(join,%20merge)%20media%20files

  • thanks. Unfortunately I am getting: Unknown input format: 'concat' – Carl Jan 19 '13 at 22:18
  • okay, wait. I think I have an old ffmpeg version – Carl Jan 19 '13 at 22:22
  • confirmation that it works except you do need ffmpeg 1.1 which I had to install from source. Even the repository holding the latest latest for Debian only had 1.0.1 – Carl Jan 19 '13 at 23:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.