0

I have some mp4 video files with me and i need to concatenate them one by one and make a single MP4 video file.

I came to know about FFMPEG through which we can concat files.

I tried doing

ffmpeg -i concat:'file1.mp4|file2.mp4' -vcodec copy -acodec copy  -y OutCome.mp4

But while executing the command i always get file2.mp4,no such file exists,but the file is there in the folder.

What i am doing wrong? or is there any other tool which can help me achieve this target through command line.

1
  • Try to use spaces around the "|" like this " | ".
    – user2448027
    Commented Jun 20, 2013 at 11:09

2 Answers 2

0

You can only concat files which "like" being concated

ffmpeg -i q.mp4 -c copy -bsf h264_mp4toannexb q.ts
ffmpeg -i r.mp4 -c copy -bsf h264_mp4toannexb r.ts
ffmpeg -i "concat:q.ts|r.ts" -c copy -bsf aac_adtstoasc qr.mp4

Joining H264 without re-encoding

Another option is the concat demuxer

How to concatenate (join, merge) media files

3
  • Thanks for the reply,i tried creating ts file from my mp4 but it not showing any video
    – Vipin Nair
    Commented Jun 20, 2013 at 7:46
  • i have tried this too but its not happening
    – Vipin Nair
    Commented Jun 20, 2013 at 7:51
  • Penny i have two ts files and i tried to concatenate them using ffpmeg.i am getting the combined file but i cant see the video in it.
    – Vipin Nair
    Commented Jun 20, 2013 at 7:54
0

Try using MP4Joiner. I have used this tool to accomplish exactly what you appear to be attempting.

PS sorry about the reply to the old question, but for others browsing here this tool works very well.

You must log in to answer this question.