check/Makefile.am: Use CHECK_CFLAGS and CHECK_LIBS
[platform/upstream/gstreamer.git] / docs / gst / tmpl / gstevent.sgml
1 <!-- ##### SECTION Title ##### -->
2 GstEvent
3
4 <!-- ##### SECTION Short_Description ##### -->
5 Structure describing events that are passed up and down a pipeline
6
7 <!-- ##### SECTION Long_Description ##### -->
8 <para>
9 The event classes are used to construct and query events.
10 </para>
11
12 <para>
13 Events are usually created with gst_event_new() which takes the event type as an argument.
14 properties specific to the event can be set afterwards with the provided macros. 
15 The event should be unreferenced with gst_event_unref().
16 </para>
17 <para>
18 gst_event_new_seek() is a usually used to create a seek event and it takes the 
19 needed parameters for a seek event. 
20 </para>
21 <para>
22 gst_event_new_flush() creates a new flush event.
23 </para>
24
25 <!-- ##### SECTION See_Also ##### -->
26 <para>
27 #GstPad, #GstElement
28 </para>
29
30 <!-- ##### SECTION Stability_Level ##### -->
31
32
33 <!-- ##### STRUCT GstEvent ##### -->
34 <para>
35
36 </para>
37
38 @mini_object: 
39 @type: 
40 @timestamp: 
41 @src: 
42 @structure: 
43
44 <!-- ##### ENUM GstEventType ##### -->
45 <para>
46
47 </para>
48
49 @GST_EVENT_UNKNOWN: 
50 @GST_EVENT_FLUSH_START: 
51 @GST_EVENT_FLUSH_STOP: 
52 @GST_EVENT_EOS: 
53 @GST_EVENT_NEWSEGMENT: 
54 @GST_EVENT_TAG: 
55 @GST_EVENT_FILLER: 
56 @GST_EVENT_QOS: 
57 @GST_EVENT_SEEK: 
58 @GST_EVENT_NAVIGATION: 
59 @GST_EVENT_CUSTOM_UP: 
60 @GST_EVENT_CUSTOM_DS: 
61 @GST_EVENT_CUSTOM_DS_OOB: 
62 @GST_EVENT_CUSTOM_BOTH: 
63 @GST_EVENT_CUSTOM_BOTH_OOB: 
64
65 <!-- ##### MACRO GST_EVENT_TRACE_NAME ##### -->
66 <para>
67 The name used for memory allocation tracing
68 </para>
69
70
71
72 <!-- ##### MACRO GST_EVENT_TYPE ##### -->
73 <para>
74 Get the event type.
75 </para>
76
77 @event: The event to query.
78
79
80 <!-- ##### MACRO GST_EVENT_TIMESTAMP ##### -->
81 <para>
82 Get the timestamp of the event.
83 </para>
84
85 @event: The event to query.
86
87
88 <!-- ##### MACRO GST_EVENT_SRC ##### -->
89 <para>
90 The source object that generated this event
91 </para>
92
93 @event: The event to query
94
95
96 <!-- ##### ENUM GstSeekType ##### -->
97 <para>
98 The different types of seek events. When constructing a seek event a format,
99 a seek method and optional flags are OR-ed together. The seek event is then
100 inserted into the graph with #gst_pad_send_event() or #gst_element_send_event().
101
102 Following example illustrates how to insert a seek event (1 second in the stream)
103 in a pipeline.
104 <example>
105 <title>Insertion of a seek event into a pipeline</title>
106   <programlisting>
107   gboolean res;
108   GstEvent *event;
109
110   event = gst_event_new_seek (
111             GST_FORMAT_TIME |           /* seek on time */
112             GST_SEEK_METHOD_SET |       /* set the absolute position */
113             GST_SEEK_FLAG_FLUSH,        /* flush any pending data */
114             1 * GST_SECOND);            /* the seek offset (1 second) */
115
116   res = gst_element_send_event (GST_ELEMENT (osssink), event);
117   if (!res) {
118     g_warning ("seek failed");
119   }
120   </programlisting>
121 </example>
122 </para>
123
124 @GST_SEEK_TYPE_NONE: 
125 @GST_SEEK_TYPE_CUR: 
126 @GST_SEEK_TYPE_SET: 
127 @GST_SEEK_TYPE_END: 
128
129 <!-- ##### MACRO gst_event_ref ##### -->
130 <para>
131 Increase the refcount of this event
132 </para>
133
134 @ev: The event to refcount
135
136
137 <!-- ##### MACRO gst_event_unref ##### -->
138 <para>
139 Decrease the refcount of an event, freeing it if the refcount reaches 0
140 </para>
141
142 @ev: The event to unref
143
144
145 <!-- ##### MACRO gst_event_copy ##### -->
146 <para>
147 Copy the event using the event specific copy function
148 </para>
149
150 @ev: The event to copy
151 @Returns: A new event that is a copy of the given input event
152
153
154 <!-- ##### FUNCTION gst_event_new_custom ##### -->
155 <para>
156
157 </para>
158
159 @type: 
160 @structure: 
161 @Returns: 
162
163
164 <!-- ##### FUNCTION gst_event_get_structure ##### -->
165 <para>
166
167 </para>
168
169 @event: 
170 @Returns: 
171
172
173 <!-- ##### FUNCTION gst_event_new_flush_start ##### -->
174 <para>
175
176 </para>
177
178 @Returns: 
179
180
181 <!-- ##### FUNCTION gst_event_new_flush_stop ##### -->
182 <para>
183
184 </para>
185
186 @Returns: 
187
188
189 <!-- ##### FUNCTION gst_event_new_eos ##### -->
190 <para>
191
192 </para>
193
194 @Returns: 
195
196
197 <!-- ##### FUNCTION gst_event_new_newsegment ##### -->
198 <para>
199
200 </para>
201
202 @rate: 
203 @format: 
204 @start_value: 
205 @stop_value: 
206 @base: 
207 @Returns: 
208
209
210 <!-- ##### FUNCTION gst_event_parse_newsegment ##### -->
211 <para>
212
213 </para>
214
215 @event: 
216 @rate: 
217 @format: 
218 @start_value: 
219 @end_value: 
220 @base: 
221
222
223 <!-- ##### FUNCTION gst_event_new_tag ##### -->
224 <para>
225
226 </para>
227
228 @taglist: 
229 @Returns: 
230
231
232 <!-- ##### FUNCTION gst_event_parse_tag ##### -->
233 <para>
234
235 </para>
236
237 @event: 
238 @taglist: 
239
240
241 <!-- ##### FUNCTION gst_event_new_filler ##### -->
242 <para>
243 Create a new dummy event that should be ignored
244 </para>
245
246 @Returns: 
247
248
249 <!-- ##### FUNCTION gst_event_new_qos ##### -->
250 <para>
251
252 </para>
253
254 @proportion: 
255 @diff: 
256 @timestamp: 
257 @Returns: 
258
259
260 <!-- ##### FUNCTION gst_event_parse_qos ##### -->
261 <para>
262
263 </para>
264
265 @event: 
266 @proportion: 
267 @diff: 
268 @timestamp: 
269
270
271 <!-- ##### FUNCTION gst_event_new_seek ##### -->
272 <para>
273
274 </para>
275
276 @rate: 
277 @format: 
278 @flags: 
279 @cur_type: 
280 @cur: 
281 @stop_type: 
282 @stop: 
283 @Returns: 
284 <!-- # Unused Parameters # -->
285 @type: 
286 @offset: 
287
288
289 <!-- ##### FUNCTION gst_event_parse_seek ##### -->
290 <para>
291
292 </para>
293
294 @event: 
295 @rate: 
296 @format: 
297 @flags: 
298 @cur_type: 
299 @cur: 
300 @stop_type: 
301 @stop: 
302
303
304 <!-- ##### FUNCTION gst_event_new_navigation ##### -->
305 <para>
306
307 </para>
308
309 @structure: 
310 @Returns: 
311
312