mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-21 15:56:42 +00:00
2b1ce5f29e
Original commit message from CVS: * docs/design/part-dynamic.txt: * docs/design/part-events.txt: * docs/design/part-seeking.txt: Some more docs in the works. * gst/base/gstbasetransform.c: (gst_base_transform_transform_caps), (gst_base_transform_getcaps), (gst_base_transform_configure_caps), (gst_base_transform_setcaps), (gst_base_transform_get_size), (gst_base_transform_buffer_alloc), (gst_base_transform_event), (gst_base_transform_handle_buffer), (gst_base_transform_sink_activate_push), (gst_base_transform_src_activate_pull), (gst_base_transform_set_passthrough), (gst_base_transform_is_passthrough): Refcounting fixes. * gst/gstbus.c: (gst_bus_source_dispatch), (gst_bus_poll): Cleanups. * gst/gstevent.c: (gst_event_finalize): Set SRC to NULL. * gst/gstutils.c: (gst_element_unlink), (gst_pad_get_parent_element), (gst_pad_proxy_getcaps), (gst_pad_proxy_setcaps): * gst/gstutils.h: Add _get_parent_element() to get a pads parent as an element.
70 lines
1.9 KiB
Text
70 lines
1.9 KiB
Text
Seeking
|
|
-------
|
|
|
|
Seeking in GStreamer means configuring the pipeline for playback of the
|
|
media between a certain start and stop time.
|
|
|
|
Different kinds of seeking exist:
|
|
|
|
- immeditate seeking with low latency (FLUSH seek)
|
|
- seeking without flush, playback will start from the new
|
|
position after all the queues are emptied with old data.
|
|
- segment seeking with and without FLUSH, this can be used to
|
|
implement seamless looping or NLE functionality.
|
|
|
|
Seeking can be performed in different formats such as time, frames
|
|
or samples.
|
|
|
|
Seeking can be performed to an absolute position or relative to the
|
|
current playback position.
|
|
|
|
For seeking to work reliably, all plugins in the pipeline need to follow
|
|
the well-defined rules in this document.
|
|
|
|
Non segment seeking will make the pipeline emit EOS when the configured
|
|
playback range has been played.
|
|
|
|
Segment seeking will not emit an EOS at the end of the range but will
|
|
post a SEGMENT_STOP message on the bus. This message is posted by the
|
|
earliest element in the pipeline, typically a demuxer. After receiving
|
|
the message, the application can reconnect the pipeline or issue other
|
|
seek events in the pipeline.
|
|
|
|
|
|
Generating seeking events
|
|
-------------------------
|
|
|
|
|
|
|
|
|
|
|
|
The different kinds of seeking methods and their internal workings are
|
|
described below.
|
|
|
|
|
|
FLUSH seeking
|
|
-------------
|
|
|
|
This is the most common way of performing a seek in a playback application.
|
|
The application issues a seek on the pipeline and the new media is immediatly
|
|
played after the seek calls returns.
|
|
|
|
|
|
seeking without FLUSH
|
|
---------------------
|
|
|
|
This seek type is typically performed after issuing segment seeks to finish
|
|
the playback of the pipeline.
|
|
|
|
|
|
segment seeking with FLUSH
|
|
--------------------------
|
|
|
|
This seek is typically performed when starting seamless looping.
|
|
|
|
|
|
segment seeking without FLUSH
|
|
-----------------------------
|
|
|
|
This seek is typically performed when continuing seamless looping.
|
|
|