hits counter

Stitch MP4 files in Ubuntu

I recently found myself with a number of smaller MP4 video files that I really wanted to stitch together into a single, longer video.  My first thought was to download one of the many highly capable video editors from the Ubuntu repositories.  It turns out there is an even easier way:

First, you’ll need to make sure you have the gpac library installed:


sudo apt-get install gpac

Then you’re going to use the MP4Box utility that comes with gpac like so:(note the large number of uppercase letters):

MP4Box -cat video1.mp4 -cat video2.mp4 -cat video3.mp4 (...) -new newvideo.mp4

Just throw in another “-cat “filename.mp4” for each file you want to stitch, and the file specified after the “-new” will be your new video.

Easy as can be!

Leave a Reply

You can use these HTML tags

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>