[FFmpeg-user] align audio and video using PTS

Roger Pack rogerdpack2 at gmail.com
Wed Sep 5 00:52:16 CEST 2012


> I have 2 TS files that have been split (by a vdr recorder): file1.ts and file2.ts.
> file1.ts ends with x miliseconds of video that don't have audio packets because they are actually at the beginning of file2.ts.
>
> How can I use ffmpeg to construct a synchronized file1 by taking the missing audio from file2.ts ?
> I hope this could be done intelligently by using the PTS information in each file, I just don't know how. Please bare in mind that x is variable for every split.

You may be able to use ffprobe -show_packets and use its extracted output.
-r


More information about the ffmpeg-user mailing list