[mythtv-users] Vedr: Vedr: Mythccextractor does not create a .srt file

Jim Stichnoth stichnot at gmail.com
Mon Mar 25 16:01:52 UTC 2013


On Thu, Mar 21, 2013 at 4:08 PM, Trond Nystuen <trond_nystuen at yahoo.no>wrote:

> On 21/03/13 1:00, Jim Stichnoth wrote:
>
>
> > The file names look like this:
> >>
> >> 0_52633905-to-52635705.png
> >> 1_52635825-to-52639705.png
> >> 2_52639825-to-52642185.png
> >> 3_52642985-to-52646265.png
> >> 4_52646425-to-52649145.png
> >>
> >> I suppose the first part of the filename is a sequence number, and the
> two other ones are frame numbers.
> >>
> >>
> > The latter numbers are supposed to be millisecond timestamps where the
> first frame has a timestamp of 0.  The relative numbers look OK, but the
>
> > absolute numbers do not.
>
>
> It makes sense that the subtitles are om the screen for about 3-4 seconds.
>
> This recording was started in the middle of the program, and may be the
> reason for the high timestamps. It will probably be difficult to line up
> the subtitles to the video.
>
>
I looked a little further and I see that the mythccextractor code is using
the initial pts of the video as the starting timestamp.  You can get the
initial pts by looking at the ffprobe output, e.g.:

Input #0, mpegts, from '/tmp/test.mpg':
  Duration: 00:00:40.04, start: 50077.909289, bitrate: 10229 kb/s

In this case the initial pts is 50077.909289 and therefore I would subtract
50077909 from all the timestamps in the subtitle filenames to get the true
millisecond offsets of the subtitles.

Jim
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.mythtv.org/pipermail/mythtv-users/attachments/20130325/6fec3c59/attachment.html>


More information about the mythtv-users mailing list