2002-01-15 00:41:22 +00:00
|
|
|
<!-- ##### SECTION Title ##### -->
|
|
|
|
GstEvent
|
|
|
|
|
|
|
|
<!-- ##### SECTION Short_Description ##### -->
|
2004-03-25 04:20:33 +00:00
|
|
|
Structure describing events that are passed up and down a pipeline
|
2002-01-15 00:41:22 +00:00
|
|
|
|
|
|
|
<!-- ##### SECTION Long_Description ##### -->
|
|
|
|
<para>
|
|
|
|
The event classes are used to construct and query events.
|
|
|
|
</para>
|
|
|
|
|
|
|
|
<para>
|
|
|
|
Events are usually created with gst_event_new() which takes the event type as an argument.
|
|
|
|
properties specific to the event can be set afterwards with the provided macros.
|
2002-09-23 08:44:35 +00:00
|
|
|
The event should be unreferenced with gst_event_unref().
|
2002-01-15 00:41:22 +00:00
|
|
|
</para>
|
|
|
|
<para>
|
|
|
|
gst_event_new_seek() is a usually used to create a seek event and it takes the
|
|
|
|
needed parameters for a seek event.
|
|
|
|
</para>
|
|
|
|
<para>
|
|
|
|
gst_event_new_flush() creates a new flush event.
|
|
|
|
</para>
|
|
|
|
|
|
|
|
<!-- ##### SECTION See_Also ##### -->
|
|
|
|
<para>
|
2003-02-11 20:38:41 +00:00
|
|
|
#GstPad, #GstElement
|
2002-01-15 00:41:22 +00:00
|
|
|
</para>
|
|
|
|
|
2005-08-05 10:02:44 +00:00
|
|
|
<!-- ##### SECTION Stability_Level ##### -->
|
|
|
|
|
|
|
|
|
2004-07-21 11:32:09 +00:00
|
|
|
<!-- ##### STRUCT GstEvent ##### -->
|
|
|
|
<para>
|
|
|
|
|
|
|
|
</para>
|
|
|
|
|
2005-05-16 21:17:14 +00:00
|
|
|
@mini_object:
|
2004-07-21 11:32:09 +00:00
|
|
|
@type:
|
|
|
|
@timestamp:
|
|
|
|
@src:
|
2005-08-01 16:17:31 +00:00
|
|
|
@structure:
|
2004-07-21 11:32:09 +00:00
|
|
|
|
2002-01-15 00:41:22 +00:00
|
|
|
<!-- ##### ENUM GstEventType ##### -->
|
|
|
|
<para>
|
|
|
|
The different major types of events.
|
|
|
|
</para>
|
|
|
|
|
|
|
|
@GST_EVENT_UNKNOWN: unknown event.
|
2005-08-01 16:17:31 +00:00
|
|
|
@GST_EVENT_FLUSH_START:
|
|
|
|
@GST_EVENT_FLUSH_STOP:
|
2002-01-15 00:41:22 +00:00
|
|
|
@GST_EVENT_EOS: an end-of-stream event.
|
2005-08-01 16:17:31 +00:00
|
|
|
@GST_EVENT_NEWSEGMENT:
|
|
|
|
@GST_EVENT_TAG:
|
|
|
|
@GST_EVENT_FILLER:
|
2002-06-12 22:27:18 +00:00
|
|
|
@GST_EVENT_QOS: a quality of service event
|
|
|
|
@GST_EVENT_SEEK: a seek event.
|
2003-10-08 18:21:41 +00:00
|
|
|
@GST_EVENT_NAVIGATION:
|
2005-08-01 16:17:31 +00:00
|
|
|
@GST_EVENT_CUSTOM_START:
|
2004-03-30 07:36:19 +00:00
|
|
|
|
2004-03-25 04:20:33 +00:00
|
|
|
<!-- ##### MACRO GST_EVENT_TRACE_NAME ##### -->
|
|
|
|
<para>
|
|
|
|
The name used for memory allocation tracing
|
|
|
|
</para>
|
|
|
|
|
|
|
|
|
|
|
|
|
2002-01-15 00:41:22 +00:00
|
|
|
<!-- ##### MACRO GST_EVENT_TYPE ##### -->
|
|
|
|
<para>
|
|
|
|
Get the event type.
|
|
|
|
</para>
|
|
|
|
|
|
|
|
@event: The event to query.
|
|
|
|
|
|
|
|
|
2004-03-25 04:20:33 +00:00
|
|
|
<!-- ##### MACRO GST_EVENT_TIMESTAMP ##### -->
|
|
|
|
<para>
|
|
|
|
Get the timestamp of the event.
|
|
|
|
</para>
|
|
|
|
|
|
|
|
@event: The event to query.
|
|
|
|
|
|
|
|
|
2002-01-15 00:41:22 +00:00
|
|
|
<!-- ##### MACRO GST_EVENT_SRC ##### -->
|
|
|
|
<para>
|
|
|
|
The source object that generated this event
|
|
|
|
</para>
|
|
|
|
|
|
|
|
@event: The event to query
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ##### ENUM GstSeekType ##### -->
|
|
|
|
<para>
|
2003-02-11 20:38:41 +00:00
|
|
|
The different types of seek events. When constructing a seek event a format,
|
|
|
|
a seek method and optional flags are OR-ed together. The seek event is then
|
|
|
|
inserted into the graph with #gst_pad_send_event() or #gst_element_send_event().
|
|
|
|
|
2004-07-14 15:06:31 +00:00
|
|
|
Following example illustrates how to insert a seek event (1 second in the stream)
|
|
|
|
in a pipeline.
|
|
|
|
<example>
|
|
|
|
<title>Insertion of a seek event into a pipeline</title>
|
2003-02-11 20:38:41 +00:00
|
|
|
<programlisting>
|
|
|
|
gboolean res;
|
|
|
|
GstEvent *event;
|
|
|
|
|
|
|
|
event = gst_event_new_seek (
|
|
|
|
GST_FORMAT_TIME | /* seek on time */
|
|
|
|
GST_SEEK_METHOD_SET | /* set the absolute position */
|
|
|
|
GST_SEEK_FLAG_FLUSH, /* flush any pending data */
|
|
|
|
1 * GST_SECOND); /* the seek offset (1 second) */
|
|
|
|
|
|
|
|
res = gst_element_send_event (GST_ELEMENT (osssink), event);
|
|
|
|
if (!res) {
|
|
|
|
g_warning ("seek failed");
|
|
|
|
}
|
|
|
|
</programlisting>
|
2004-07-14 15:06:31 +00:00
|
|
|
</example>
|
2002-01-15 00:41:22 +00:00
|
|
|
</para>
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
@GST_SEEK_TYPE_NONE:
|
|
|
|
@GST_SEEK_TYPE_CUR:
|
|
|
|
@GST_SEEK_TYPE_SET:
|
|
|
|
@GST_SEEK_TYPE_END:
|
2002-01-15 00:41:22 +00:00
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
<!-- ##### MACRO gst_event_ref ##### -->
|
2002-06-12 22:27:18 +00:00
|
|
|
<para>
|
2005-08-01 16:17:31 +00:00
|
|
|
Increase the refcount of this event
|
2002-06-12 22:27:18 +00:00
|
|
|
</para>
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
@ev: The event to refcount
|
2002-06-12 22:27:18 +00:00
|
|
|
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
<!-- ##### MACRO gst_event_unref ##### -->
|
2002-06-12 22:27:18 +00:00
|
|
|
<para>
|
2005-08-01 16:17:31 +00:00
|
|
|
Decrease the refcount of an event, freeing it if the refcount reaches 0
|
2002-06-12 22:27:18 +00:00
|
|
|
</para>
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
@ev: The event to unref
|
2002-06-12 22:27:18 +00:00
|
|
|
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
<!-- ##### MACRO gst_event_copy ##### -->
|
2002-06-12 22:27:18 +00:00
|
|
|
<para>
|
2005-08-01 16:17:31 +00:00
|
|
|
Copy the event using the event specific copy function
|
2002-06-12 22:27:18 +00:00
|
|
|
</para>
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
@ev: The event to copy
|
|
|
|
@Returns: A new event that is a copy of the given input event
|
2002-06-12 22:27:18 +00:00
|
|
|
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
<!-- ##### FUNCTION gst_event_new_custom ##### -->
|
2002-01-15 00:41:22 +00:00
|
|
|
<para>
|
|
|
|
|
|
|
|
</para>
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
@type:
|
|
|
|
@structure:
|
|
|
|
@Returns:
|
2002-06-12 22:27:18 +00:00
|
|
|
|
2002-01-15 00:41:22 +00:00
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
<!-- ##### FUNCTION gst_event_get_structure ##### -->
|
2002-06-12 22:27:18 +00:00
|
|
|
<para>
|
|
|
|
|
2002-01-15 00:41:22 +00:00
|
|
|
</para>
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
@event:
|
|
|
|
@Returns:
|
2002-06-12 22:27:18 +00:00
|
|
|
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
<!-- ##### FUNCTION gst_event_new_flush_start ##### -->
|
2002-06-12 22:27:18 +00:00
|
|
|
<para>
|
2002-01-15 00:41:22 +00:00
|
|
|
|
2002-07-12 23:21:20 +00:00
|
|
|
</para>
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
@Returns:
|
2002-07-12 23:21:20 +00:00
|
|
|
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
<!-- ##### FUNCTION gst_event_new_flush_stop ##### -->
|
2002-07-12 23:21:20 +00:00
|
|
|
<para>
|
|
|
|
|
2003-02-10 23:01:55 +00:00
|
|
|
</para>
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
@Returns:
|
2003-02-10 23:01:55 +00:00
|
|
|
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
<!-- ##### FUNCTION gst_event_new_eos ##### -->
|
2002-01-15 00:41:22 +00:00
|
|
|
<para>
|
|
|
|
|
|
|
|
</para>
|
|
|
|
|
|
|
|
@Returns:
|
|
|
|
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
<!-- ##### FUNCTION gst_event_new_newsegment ##### -->
|
2002-07-12 23:21:20 +00:00
|
|
|
<para>
|
|
|
|
|
|
|
|
</para>
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
@rate:
|
|
|
|
@format:
|
|
|
|
@start_value:
|
|
|
|
@stop_value:
|
|
|
|
@base:
|
|
|
|
@Returns:
|
2002-03-31 14:00:33 +00:00
|
|
|
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
<!-- ##### FUNCTION gst_event_parse_newsegment ##### -->
|
2004-03-25 04:20:33 +00:00
|
|
|
<para>
|
2005-08-01 16:17:31 +00:00
|
|
|
|
2004-03-25 04:20:33 +00:00
|
|
|
</para>
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
@event:
|
|
|
|
@rate:
|
|
|
|
@format:
|
|
|
|
@start_value:
|
|
|
|
@end_value:
|
|
|
|
@base:
|
2004-03-25 04:20:33 +00:00
|
|
|
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
<!-- ##### FUNCTION gst_event_new_tag ##### -->
|
2004-03-25 04:20:33 +00:00
|
|
|
<para>
|
|
|
|
|
|
|
|
</para>
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
@taglist:
|
2004-03-25 04:20:33 +00:00
|
|
|
@Returns:
|
|
|
|
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
<!-- ##### FUNCTION gst_event_parse_tag ##### -->
|
2002-01-15 00:41:22 +00:00
|
|
|
<para>
|
|
|
|
|
|
|
|
</para>
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
@event:
|
|
|
|
@taglist:
|
2002-01-15 00:41:22 +00:00
|
|
|
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
<!-- ##### FUNCTION gst_event_new_filler ##### -->
|
2002-07-12 23:21:20 +00:00
|
|
|
<para>
|
2005-08-01 16:17:31 +00:00
|
|
|
Create a new dummy event that should be ignored
|
2002-07-12 23:21:20 +00:00
|
|
|
</para>
|
|
|
|
|
|
|
|
@Returns:
|
|
|
|
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
<!-- ##### FUNCTION gst_event_new_qos ##### -->
|
2002-07-12 23:21:20 +00:00
|
|
|
<para>
|
|
|
|
|
|
|
|
</para>
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
@proportion:
|
|
|
|
@diff:
|
|
|
|
@timestamp:
|
2002-07-12 23:21:20 +00:00
|
|
|
@Returns:
|
|
|
|
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
<!-- ##### FUNCTION gst_event_parse_qos ##### -->
|
2002-01-15 00:41:22 +00:00
|
|
|
<para>
|
2002-06-12 22:27:18 +00:00
|
|
|
|
2002-01-15 00:41:22 +00:00
|
|
|
</para>
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
@event:
|
|
|
|
@proportion:
|
|
|
|
@diff:
|
|
|
|
@timestamp:
|
2002-01-15 00:41:22 +00:00
|
|
|
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
<!-- ##### FUNCTION gst_event_new_seek ##### -->
|
2004-03-25 04:20:33 +00:00
|
|
|
<para>
|
|
|
|
|
|
|
|
</para>
|
|
|
|
|
2005-04-06 11:08:07 +00:00
|
|
|
@rate:
|
2005-08-01 16:17:31 +00:00
|
|
|
@format:
|
|
|
|
@flags:
|
|
|
|
@cur_type:
|
|
|
|
@cur:
|
|
|
|
@stop_type:
|
|
|
|
@stop:
|
2004-03-25 04:20:33 +00:00
|
|
|
@Returns:
|
2005-04-06 11:08:07 +00:00
|
|
|
<!-- # Unused Parameters # -->
|
2005-08-01 16:17:31 +00:00
|
|
|
@type:
|
|
|
|
@offset:
|
2004-03-25 04:20:33 +00:00
|
|
|
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
<!-- ##### FUNCTION gst_event_parse_seek ##### -->
|
2002-01-15 00:41:22 +00:00
|
|
|
<para>
|
|
|
|
|
|
|
|
</para>
|
|
|
|
|
2002-06-12 22:27:18 +00:00
|
|
|
@event:
|
2005-08-01 16:17:31 +00:00
|
|
|
@rate:
|
2002-06-12 22:27:18 +00:00
|
|
|
@format:
|
2005-08-01 16:17:31 +00:00
|
|
|
@flags:
|
|
|
|
@cur_type:
|
|
|
|
@cur:
|
|
|
|
@stop_type:
|
|
|
|
@stop:
|
2002-01-15 00:41:22 +00:00
|
|
|
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
<!-- ##### FUNCTION gst_event_new_navigation ##### -->
|
2002-06-12 22:27:18 +00:00
|
|
|
<para>
|
|
|
|
|
|
|
|
</para>
|
|
|
|
|
2005-08-01 16:17:31 +00:00
|
|
|
@structure:
|
2005-03-29 10:55:39 +00:00
|
|
|
@Returns:
|
2002-06-12 22:27:18 +00:00
|
|
|
|
|
|
|
|