Appsrc seekable in Push Mode

Tim Müller tim at centricular.com
Sat May 31 03:54:38 PDT 2014


On Fri, 2014-05-30 at 22:27 -0700, Manoj89 wrote:

>    When using Appsrc  seekable in Push mode is it enough that we report new
> position from where appsrc has to push buffers using the gst_element_seek()/
> by creating new seek event or whether we have to start pushing data to
> appsrc from new position?

Not sure I understand your question. You should simply provide appsrc
with data. When the position changes, as signalled by the seek-data
signalled callback, you provide appsrc with data from the new position.

If you're operating in TIME format, you should but timestamps on the
buffers you push in. If you operate in BYTE format, you should set
GST_BUFFER_OFFSET() to the byte offset of the data you push in.


>  My doubt is new position from where appsrc must push buffers is from appsrc
> or from the exact source like file,frames we get from application thread?
> 
>           data from file or frames from n/w -> appsrc->rest of pipeline
> 
>   So new position is from the source which injects the data to appsrc or it
> is from appsrc after the data has been injected to appsrc.

If you are operating in BYTE format and a seek is requested, you should
push data from exactly the byte position requested. If you operate in
TIME format, it's ok to push data from before the position requested as
well, it will be clipped by downstream elements as required.

Not sure if that answered your questions.

Cheers
 -Tim

-- 
Tim Müller, Centricular Ltd - http://www.centricular.com



More information about the gstreamer-devel mailing list