View Full Version : merge 2 h264 videos without reenconding


kartola
16th April 2012, 14:22
Hi, do you know if is possible to split a video in 2 or 3 parts (so i can encode one at a time with x264) and then join the files without reencoding?

I try with 'append' feature of mkvmerge but there is an interruption between the 2 videos...

LoRd_MuldeR
16th April 2012, 14:24
Actually you should be able to "join" raw H.264 streams with a simple:
copy /b file1.264 +file2.264 joined.264

However it should be clear that encoding a video in 3 (or more) parts will have negative effects on 2-Pass rate-control.

kartola
16th April 2012, 14:32
Thank you for the solution!
My problem is that to make an encoding with 'veryslow' preset i should occupy my pc for more than 14 hours... If i can't pause and resume the work, the only solution sadly is to split the video...

LoRd_MuldeR
16th April 2012, 14:36
Why you shouldn't be able to pause/resume the process?

It is correct that you can NOT resume an x264 encode, once you have aborted it. But you can, of course, suspend the encoder process and resume it later.

If you suspend a process, it will still occupy some memory. But it won't use any CPU cycles until you resume it.

But why do you need to suspend the encoding process at all? Why not just set its CPU priority to "idle" and let it run in the background?

And if you need to turn off your computer, simply make use of hibernation ;)

Atak_Snajpera
16th April 2012, 14:52
Unreleased Ripbot264 v1.17.1 has ability to resume encoding in Distributed Encoding mode.

http://i.imgur.com/ozg2d.png

Also make sure that your SourceFilter() is FRAME ACCURATE!

I use FFVideoSource("..",threads=1) plus I cut only at key-frames!

otherwise you may end up with either corrupted frame or with duplicated frame.

DiKey
18th April 2013, 15:57
Actually you should be able to "join" raw H.264 streams with a simple:
copy /b file1.264 +file2.264 joined.264

However it should be clear that encoding a video in 3 (or more) parts will have negative effects on 2-Pass rate-control.

If I made part1.264, then part2.264, then
copy /b part1.264+part2.264 joined.264

First file importing to Adobe Encore as "No Transcode", second - too. But "joined.264" marks as "Untranscoded". So, something is not so clear... :mad:

P.S. My videos are 1-pass coded.