gentoo at dhaller
May 3, 2012, 4:30 PM
Post #17 of 17
Re: Video editing advice on formats and size of file
[In reply to]
On Fri, 23 Dec 2011, Michael Mol wrote:
>I'd suggest you give the other tools a try, too. The other tools
>brought up will do essentially the same thing as avidemux; they're
>just ripping the audio and video streams out of the source container
>files and placing them into a new container file.
mkvmerge has the -y option where you can specify
- an offset for a specific track (e.g. delay the audio track by
- and specify a ratio how one track is faster/slower than the other.
For example: I recently had a subtitle track declared as PAL (25fps)
but it was actually NTSC (23.97fps). Additionally, there was an
offset. So, I used:
mkvmerge -o output.mkv --language 1:en input1.avi --language 0:de \
-D input_sound2.ac3 \
-y 0:-7000,23.97/25 subtitle1.srt
| ^^|^^ ^^^^^^^^- delay ratio / skew
| `- absolute offset (-7s)
`- track 0 of the input file (i.e. subtitle1.srt), with the
usual video+audio in one file, it'd be Track 1: for the
audio, use mkvinfo/mediainfo on the input to find out.
(or the other way around resp. PAL/NTCS rates, anyway, according to my
~/.bash_history the above gave me the correct output ;)
By that feature, you can offset one track (e.g. sound or subs) by an
absolute time and skew it at a relative ratio (when one track is
"faster" than the other, usually PAL vs. NTSC or 24fps. Anyway, try
those ratios ,23.97/25 or ,25/23.97 first ;) After determining the
"absolute offset" as early in the file as possible.
When stitching files together, it might be that just one file has that
problem, so, remux that one file with an -y 0:offset,skew into a
temp-file and then append the temp to the other input (or vice versa).
Takes a bit of testing etc., but you should be able to solve all
You're lost if the desync varies over one file (e.g. +1s at the start,
+2 at 25%, in sync at 50%, +3s at 60%, -2s at 75%, +1s at the end...)
> Good. now let's bash PHP. -- Satya
I thought we were talking about programming languages? -- Peter Corlett