[vlc-commits] demux: asf: preroll to seek time from index keyframes (fix #7890)
Francois Cartegnie
git at videolan.org
Fri Nov 22 13:33:56 CET 2013
vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Fri Nov 22 13:33:04 2013 +0100| [58c8f9f3cef168df4adfe5e1ca14cc745f4ba7fc] | committer: Francois Cartegnie
demux: asf: preroll to seek time from index keyframes (fix #7890)
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=58c8f9f3cef168df4adfe5e1ca14cc745f4ba7fc
---
modules/demux/asf/asf.c | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/modules/demux/asf/asf.c b/modules/demux/asf/asf.c
index fedc232..befcf59 100644
--- a/modules/demux/asf/asf.c
+++ b/modules/demux/asf/asf.c
@@ -261,7 +261,13 @@ static int SeekIndex( demux_t *p_demux, mtime_t i_date, float f_pos )
uint64_t i_offset = (uint64_t)p_index->index_entry[i_entry].i_packet_number *
p_sys->p_fp->i_min_data_packet_size;
- return stream_Seek( p_demux->s, p_sys->i_data_begin + i_offset );
+
+ if ( stream_Seek( p_demux->s, p_sys->i_data_begin + i_offset ) == VLC_SUCCESS )
+ {
+ es_out_Control( p_demux->out, ES_OUT_SET_NEXT_DISPLAY_TIME, VLC_TS_0 + i_date );
+ return VLC_SUCCESS;
+ }
+ else return VLC_EGENERIC;
}
static void SeekPrepare( demux_t *p_demux )
More information about the vlc-commits
mailing list