Mercurial > mplayer.hg
changeset 19430:de5065d3ce74
Fix seeking in matroska files when timecodes do not start from zero.
author | eugeni |
---|---|
date | Fri, 18 Aug 2006 12:20:43 +0000 |
parents | 3fb0eb698ce8 |
children | ac69ba536915 |
files | libmpdemux/demux_mkv.c |
diffstat | 1 files changed, 1 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/libmpdemux/demux_mkv.c Fri Aug 18 02:23:44 2006 +0000 +++ b/libmpdemux/demux_mkv.c Fri Aug 18 12:20:43 2006 +0000 @@ -3606,7 +3606,7 @@ for (i=0; i < mkv_d->num_indexes; i++) if (mkv_d->indexes[i].tnum == demuxer->video->id) { - diff = target_timecode - (int64_t) mkv_d->indexes[i].timecode; + diff = target_timecode + mkv_d->first_tc - (int64_t) mkv_d->indexes[i].timecode; if ((flags & 1 || target_timecode <= mkv_d->last_pts*1000) && diff >= 0 && diff < min_diff)