Seeking of Subtitle along with video

Tim-Philipp Müller t.i.m at zen.co.uk
Sun Nov 6 06:05:27 PST 2011


On Fri, 2011-11-04 at 01:48 -0700, kirrthana wrote:

Hi,
 
> I’m using gstreamer to develop a video player with subtitle enabled. I’m
> using playbin2 with suburi set. I have a requirement to seek the video at
> the beginning and start playback. And I found that video is playing from the
> new position after seek, but the subtitle starts from the beginning and it
> hangs. I’m sending a seek event to seek the video, but I’m not sending any
> event for text . Do I need to do something to seek the subtitle file as well
> or that will be taken care internally.

If you're using playbin(2), just use gst_element_seek() or
gst_element_seek_simple() to initiate a seek. If things don't work as
expected after that, that's probably a bug of some sort.

(If you have external subtitles, the subparse element (or whatever is
used) may start reading things from the beginning again, but of course
the subtitles matching the video should show up after seek.) 

 Cheers
  -Tim



More information about the gstreamer-devel mailing list