summaryrefslogtreecommitdiff
path: root/sources/generated/Gst.App/AppSink.cs
blob: c9434dc6d3f652d6319242b59ffd9a3701998ee8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
// This file was generated by the Gtk# code generator.
// Any changes made will be lost if regenerated.

namespace Gst.App {

	using System;
	using System.Collections;
	using System.Collections.Generic;
	using System.Runtime.InteropServices;

#region Autogenerated code
	public partial class AppSink : Gst.Base.BaseSink, Gst.IURIHandler {

		public AppSink (IntPtr raw) : base(raw) {}

		protected AppSink() : base(IntPtr.Zero)
		{
			CreateNativeObject (new string [0], new GLib.Value [0]);
		}

		[GLib.Property ("buffer-list")]
		public bool BufferList {
			get {
				GLib.Value val = GetProperty ("buffer-list");
				bool ret = (bool) val;
				val.Dispose ();
				return ret;
			}
			set {
				GLib.Value val = new GLib.Value(value);
				SetProperty("buffer-list", val);
				val.Dispose ();
			}
		}

		[DllImport("libgstapp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern IntPtr gst_app_sink_get_caps(IntPtr raw);

		[DllImport("libgstapp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern void gst_app_sink_set_caps(IntPtr raw, IntPtr caps);

		[GLib.Property ("caps")]
		public Gst.Caps Caps {
			get  {
				IntPtr raw_ret = gst_app_sink_get_caps(Handle);
				Gst.Caps ret = raw_ret == IntPtr.Zero ? null : (Gst.Caps) GLib.Opaque.GetOpaque (raw_ret, typeof (Gst.Caps), true);
				return ret;
			}
			set  {
				gst_app_sink_set_caps(Handle, value == null ? IntPtr.Zero : value.Handle);
			}
		}

		[DllImport("libgstapp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern bool gst_app_sink_get_drop(IntPtr raw);

		[DllImport("libgstapp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern void gst_app_sink_set_drop(IntPtr raw, bool drop);

		[GLib.Property ("drop")]
		public bool Drop {
			get  {
				bool raw_ret = gst_app_sink_get_drop(Handle);
				bool ret = raw_ret;
				return ret;
			}
			set  {
				gst_app_sink_set_drop(Handle, value);
			}
		}

		[DllImport("libgstapp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern bool gst_app_sink_get_emit_signals(IntPtr raw);

		[DllImport("libgstapp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern void gst_app_sink_set_emit_signals(IntPtr raw, bool emit);

		[GLib.Property ("emit-signals")]
		public bool EmitSignals {
			get  {
				bool raw_ret = gst_app_sink_get_emit_signals(Handle);
				bool ret = raw_ret;
				return ret;
			}
			set  {
				gst_app_sink_set_emit_signals(Handle, value);
			}
		}

		[GLib.Property ("eos")]
		public bool EosProp
       {
			get {
				GLib.Value val = GetProperty ("eos");
				bool ret = (bool) val;
				val.Dispose ();
				return ret;
			}
		}

		[DllImport("libgstapp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern uint gst_app_sink_get_max_buffers(IntPtr raw);

		[DllImport("libgstapp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern void gst_app_sink_set_max_buffers(IntPtr raw, uint max);

		[GLib.Property ("max-buffers")]
		public uint MaxBuffers {
			get  {
				uint raw_ret = gst_app_sink_get_max_buffers(Handle);
				uint ret = raw_ret;
				return ret;
			}
			set  {
				gst_app_sink_set_max_buffers(Handle, value);
			}
		}

		[DllImport("libgstapp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern bool gst_app_sink_get_wait_on_eos(IntPtr raw);

		[DllImport("libgstapp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern void gst_app_sink_set_wait_on_eos(IntPtr raw, bool wait);

		[GLib.Property ("wait-on-eos")]
		public bool WaitOnEos {
			get  {
				bool raw_ret = gst_app_sink_get_wait_on_eos(Handle);
				bool ret = raw_ret;
				return ret;
			}
			set  {
				gst_app_sink_set_wait_on_eos(Handle, value);
			}
		}

		[GLib.Signal("try-pull-sample")]
		public event Gst.App.TryPullSampleEventHandler TryPullSampleEvent {
			add {
				this.AddSignalHandler ("try-pull-sample", value, typeof (Gst.App.TryPullSampleEventArgs));
			}
			remove {
				this.RemoveSignalHandler ("try-pull-sample", value);
			}
		}

		[GLib.Signal("eos")]
		public event System.EventHandler Eos {
			add {
				this.AddSignalHandler ("eos", value);
			}
			remove {
				this.RemoveSignalHandler ("eos", value);
			}
		}

		[GLib.Signal("try-pull-preroll")]
		public event Gst.App.TryPullPrerollEventHandler TryPullPrerollEvent {
			add {
				this.AddSignalHandler ("try-pull-preroll", value, typeof (Gst.App.TryPullPrerollEventArgs));
			}
			remove {
				this.RemoveSignalHandler ("try-pull-preroll", value);
			}
		}

		[GLib.Signal("new-preroll")]
		public event Gst.App.NewPrerollHandler NewPreroll {
			add {
				this.AddSignalHandler ("new-preroll", value, typeof (Gst.App.NewPrerollArgs));
			}
			remove {
				this.RemoveSignalHandler ("new-preroll", value);
			}
		}

		[GLib.Signal("new-sample")]
		public event Gst.App.NewSampleHandler NewSample {
			add {
				this.AddSignalHandler ("new-sample", value, typeof (Gst.App.NewSampleArgs));
			}
			remove {
				this.RemoveSignalHandler ("new-sample", value);
			}
		}

		static EosNativeDelegate Eos_cb_delegate;
		static EosNativeDelegate EosVMCallback {
			get {
				if (Eos_cb_delegate == null)
					Eos_cb_delegate = new EosNativeDelegate (Eos_cb);
				return Eos_cb_delegate;
			}
		}

		static void OverrideEos (GLib.GType gtype)
		{
			OverrideEos (gtype, EosVMCallback);
		}

		static void OverrideEos (GLib.GType gtype, EosNativeDelegate callback)
		{
			unsafe {
				IntPtr* raw_ptr = (IntPtr*)(((long) gtype.GetClassPtr()) + (long) class_abi.GetFieldOffset("eos"));
				*raw_ptr = Marshal.GetFunctionPointerForDelegate((Delegate) callback);
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate void EosNativeDelegate (IntPtr inst);

		static void Eos_cb (IntPtr inst)
		{
			try {
				AppSink __obj = GLib.Object.GetObject (inst, false) as AppSink;
				__obj.OnEos ();
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, false);
			}
		}

		[GLib.DefaultSignalHandler(Type=typeof(Gst.App.AppSink), ConnectionMethod="OverrideEos")]
		protected virtual void OnEos ()
		{
			InternalEos ();
		}

		private void InternalEos ()
		{
			EosNativeDelegate unmanaged = null;
			unsafe {
				IntPtr* raw_ptr = (IntPtr*)(((long) this.LookupGType().GetThresholdType().GetClassPtr()) + (long) class_abi.GetFieldOffset("eos"));
				unmanaged = (EosNativeDelegate) Marshal.GetDelegateForFunctionPointer(*raw_ptr, typeof(EosNativeDelegate));
			}
			if (unmanaged == null) return;

			unmanaged (this.Handle);
		}

		static NewPrerollNativeDelegate NewPreroll_cb_delegate;
		static NewPrerollNativeDelegate NewPrerollVMCallback {
			get {
				if (NewPreroll_cb_delegate == null)
					NewPreroll_cb_delegate = new NewPrerollNativeDelegate (NewPreroll_cb);
				return NewPreroll_cb_delegate;
			}
		}

		static void OverrideNewPreroll (GLib.GType gtype)
		{
			OverrideNewPreroll (gtype, NewPrerollVMCallback);
		}

		static void OverrideNewPreroll (GLib.GType gtype, NewPrerollNativeDelegate callback)
		{
			unsafe {
				IntPtr* raw_ptr = (IntPtr*)(((long) gtype.GetClassPtr()) + (long) class_abi.GetFieldOffset("new_preroll"));
				*raw_ptr = Marshal.GetFunctionPointerForDelegate((Delegate) callback);
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate int NewPrerollNativeDelegate (IntPtr inst);

		static int NewPreroll_cb (IntPtr inst)
		{
			try {
				AppSink __obj = GLib.Object.GetObject (inst, false) as AppSink;
				Gst.FlowReturn __result;
				__result = __obj.OnNewPreroll ();
				return (int) __result;
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, true);
				// NOTREACHED: above call does not return.
				throw e;
			}
		}

		[GLib.DefaultSignalHandler(Type=typeof(Gst.App.AppSink), ConnectionMethod="OverrideNewPreroll")]
		protected virtual Gst.FlowReturn OnNewPreroll ()
		{
			return InternalNewPreroll ();
		}

		private Gst.FlowReturn InternalNewPreroll ()
		{
			NewPrerollNativeDelegate unmanaged = null;
			unsafe {
				IntPtr* raw_ptr = (IntPtr*)(((long) this.LookupGType().GetThresholdType().GetClassPtr()) + (long) class_abi.GetFieldOffset("new_preroll"));
				unmanaged = (NewPrerollNativeDelegate) Marshal.GetDelegateForFunctionPointer(*raw_ptr, typeof(NewPrerollNativeDelegate));
			}
			if (unmanaged == null) return (Gst.FlowReturn) 0;

			int __result = unmanaged (this.Handle);
			return (Gst.FlowReturn) __result;
		}

		static NewSampleNativeDelegate NewSample_cb_delegate;
		static NewSampleNativeDelegate NewSampleVMCallback {
			get {
				if (NewSample_cb_delegate == null)
					NewSample_cb_delegate = new NewSampleNativeDelegate (NewSample_cb);
				return NewSample_cb_delegate;
			}
		}

		static void OverrideNewSample (GLib.GType gtype)
		{
			OverrideNewSample (gtype, NewSampleVMCallback);
		}

		static void OverrideNewSample (GLib.GType gtype, NewSampleNativeDelegate callback)
		{
			unsafe {
				IntPtr* raw_ptr = (IntPtr*)(((long) gtype.GetClassPtr()) + (long) class_abi.GetFieldOffset("new_sample"));
				*raw_ptr = Marshal.GetFunctionPointerForDelegate((Delegate) callback);
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate int NewSampleNativeDelegate (IntPtr inst);

		static int NewSample_cb (IntPtr inst)
		{
			try {
				AppSink __obj = GLib.Object.GetObject (inst, false) as AppSink;
				Gst.FlowReturn __result;
				__result = __obj.OnNewSample ();
				return (int) __result;
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, true);
				// NOTREACHED: above call does not return.
				throw e;
			}
		}

		[GLib.DefaultSignalHandler(Type=typeof(Gst.App.AppSink), ConnectionMethod="OverrideNewSample")]
		protected virtual Gst.FlowReturn OnNewSample ()
		{
			return InternalNewSample ();
		}

		private Gst.FlowReturn InternalNewSample ()
		{
			NewSampleNativeDelegate unmanaged = null;
			unsafe {
				IntPtr* raw_ptr = (IntPtr*)(((long) this.LookupGType().GetThresholdType().GetClassPtr()) + (long) class_abi.GetFieldOffset("new_sample"));
				unmanaged = (NewSampleNativeDelegate) Marshal.GetDelegateForFunctionPointer(*raw_ptr, typeof(NewSampleNativeDelegate));
			}
			if (unmanaged == null) return (Gst.FlowReturn) 0;

			int __result = unmanaged (this.Handle);
			return (Gst.FlowReturn) __result;
		}

		static TryPullPrerollEventNativeDelegate TryPullPrerollEvent_cb_delegate;
		static TryPullPrerollEventNativeDelegate TryPullPrerollEventVMCallback {
			get {
				if (TryPullPrerollEvent_cb_delegate == null)
					TryPullPrerollEvent_cb_delegate = new TryPullPrerollEventNativeDelegate (TryPullPrerollEvent_cb);
				return TryPullPrerollEvent_cb_delegate;
			}
		}

		static void OverrideTryPullPrerollEvent (GLib.GType gtype)
		{
			OverrideTryPullPrerollEvent (gtype, TryPullPrerollEventVMCallback);
		}

		static void OverrideTryPullPrerollEvent (GLib.GType gtype, TryPullPrerollEventNativeDelegate callback)
		{
			unsafe {
				IntPtr* raw_ptr = (IntPtr*)(((long) gtype.GetClassPtr()) + (long) class_abi.GetFieldOffset("try_pull_preroll"));
				*raw_ptr = Marshal.GetFunctionPointerForDelegate((Delegate) callback);
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate IntPtr TryPullPrerollEventNativeDelegate (IntPtr inst, ulong timeout);

		static IntPtr TryPullPrerollEvent_cb (IntPtr inst, ulong timeout)
		{
			try {
				AppSink __obj = GLib.Object.GetObject (inst, false) as AppSink;
				Gst.Sample __result;
				__result = __obj.OnTryPullPrerollEvent (timeout);
				return __result == null ? IntPtr.Zero : __result.OwnedCopy;
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, true);
				// NOTREACHED: above call does not return.
				throw e;
			}
		}

		[GLib.DefaultSignalHandler(Type=typeof(Gst.App.AppSink), ConnectionMethod="OverrideTryPullPrerollEvent")]
		protected virtual Gst.Sample OnTryPullPrerollEvent (ulong timeout)
		{
			return InternalTryPullPrerollEvent (timeout);
		}

		private Gst.Sample InternalTryPullPrerollEvent (ulong timeout)
		{
			TryPullPrerollEventNativeDelegate unmanaged = null;
			unsafe {
				IntPtr* raw_ptr = (IntPtr*)(((long) this.LookupGType().GetThresholdType().GetClassPtr()) + (long) class_abi.GetFieldOffset("try_pull_preroll"));
				unmanaged = (TryPullPrerollEventNativeDelegate) Marshal.GetDelegateForFunctionPointer(*raw_ptr, typeof(TryPullPrerollEventNativeDelegate));
			}
			if (unmanaged == null) return null;

			IntPtr __result = unmanaged (this.Handle, timeout);
			return __result == IntPtr.Zero ? null : (Gst.Sample) GLib.Opaque.GetOpaque (__result, typeof (Gst.Sample), true);
		}

		static TryPullSampleEventNativeDelegate TryPullSampleEvent_cb_delegate;
		static TryPullSampleEventNativeDelegate TryPullSampleEventVMCallback {
			get {
				if (TryPullSampleEvent_cb_delegate == null)
					TryPullSampleEvent_cb_delegate = new TryPullSampleEventNativeDelegate (TryPullSampleEvent_cb);
				return TryPullSampleEvent_cb_delegate;
			}
		}

		static void OverrideTryPullSampleEvent (GLib.GType gtype)
		{
			OverrideTryPullSampleEvent (gtype, TryPullSampleEventVMCallback);
		}

		static void OverrideTryPullSampleEvent (GLib.GType gtype, TryPullSampleEventNativeDelegate callback)
		{
			unsafe {
				IntPtr* raw_ptr = (IntPtr*)(((long) gtype.GetClassPtr()) + (long) class_abi.GetFieldOffset("try_pull_sample"));
				*raw_ptr = Marshal.GetFunctionPointerForDelegate((Delegate) callback);
			}
		}

		[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
		delegate IntPtr TryPullSampleEventNativeDelegate (IntPtr inst, ulong timeout);

		static IntPtr TryPullSampleEvent_cb (IntPtr inst, ulong timeout)
		{
			try {
				AppSink __obj = GLib.Object.GetObject (inst, false) as AppSink;
				Gst.Sample __result;
				__result = __obj.OnTryPullSampleEvent (timeout);
				return __result == null ? IntPtr.Zero : __result.OwnedCopy;
			} catch (Exception e) {
				GLib.ExceptionManager.RaiseUnhandledException (e, true);
				// NOTREACHED: above call does not return.
				throw e;
			}
		}

		[GLib.DefaultSignalHandler(Type=typeof(Gst.App.AppSink), ConnectionMethod="OverrideTryPullSampleEvent")]
		protected virtual Gst.Sample OnTryPullSampleEvent (ulong timeout)
		{
			return InternalTryPullSampleEvent (timeout);
		}

		private Gst.Sample InternalTryPullSampleEvent (ulong timeout)
		{
			TryPullSampleEventNativeDelegate unmanaged = null;
			unsafe {
				IntPtr* raw_ptr = (IntPtr*)(((long) this.LookupGType().GetThresholdType().GetClassPtr()) + (long) class_abi.GetFieldOffset("try_pull_sample"));
				unmanaged = (TryPullSampleEventNativeDelegate) Marshal.GetDelegateForFunctionPointer(*raw_ptr, typeof(TryPullSampleEventNativeDelegate));
			}
			if (unmanaged == null) return null;

			IntPtr __result = unmanaged (this.Handle, timeout);
			return __result == IntPtr.Zero ? null : (Gst.Sample) GLib.Opaque.GetOpaque (__result, typeof (Gst.Sample), true);
		}


		// Internal representation of the wrapped structure ABI.
		static GLib.AbiStruct _class_abi = null;
		static public new GLib.AbiStruct class_abi {
			get {
				if (_class_abi == null)
					_class_abi = new GLib.AbiStruct (new List<GLib.AbiField>{ 
						new GLib.AbiField("eos"
							, Gst.Base.BaseSink.class_abi.Fields
							, (uint) Marshal.SizeOf(typeof(IntPtr)) // eos
							, null
							, "new_preroll"
							, (uint) Marshal.SizeOf(typeof(IntPtr))
							, 0
							),
						new GLib.AbiField("new_preroll"
							, -1
							, (uint) Marshal.SizeOf(typeof(IntPtr)) // new_preroll
							, "eos"
							, "new_sample"
							, (uint) Marshal.SizeOf(typeof(IntPtr))
							, 0
							),
						new GLib.AbiField("new_sample"
							, -1
							, (uint) Marshal.SizeOf(typeof(IntPtr)) // new_sample
							, "new_preroll"
							, "pull_preroll"
							, (uint) Marshal.SizeOf(typeof(IntPtr))
							, 0
							),
						new GLib.AbiField("pull_preroll"
							, -1
							, (uint) Marshal.SizeOf(typeof(IntPtr)) // pull_preroll
							, "new_sample"
							, "pull_sample"
							, (uint) Marshal.SizeOf(typeof(IntPtr))
							, 0
							),
						new GLib.AbiField("pull_sample"
							, -1
							, (uint) Marshal.SizeOf(typeof(IntPtr)) // pull_sample
							, "pull_preroll"
							, "try_pull_preroll"
							, (uint) Marshal.SizeOf(typeof(IntPtr))
							, 0
							),
						new GLib.AbiField("try_pull_preroll"
							, -1
							, (uint) Marshal.SizeOf(typeof(IntPtr)) // try_pull_preroll
							, "pull_sample"
							, "try_pull_sample"
							, (uint) Marshal.SizeOf(typeof(IntPtr))
							, 0
							),
						new GLib.AbiField("try_pull_sample"
							, -1
							, (uint) Marshal.SizeOf(typeof(IntPtr)) // try_pull_sample
							, "try_pull_preroll"
							, "_gst_reserved"
							, (uint) Marshal.SizeOf(typeof(IntPtr))
							, 0
							),
						new GLib.AbiField("_gst_reserved"
							, -1
							, (uint) Marshal.SizeOf(typeof(IntPtr)) * 2 // _gst_reserved
							, "try_pull_sample"
							, null
							, (uint) Marshal.SizeOf(typeof(IntPtr))
							, 0
							),
					});

				return _class_abi;
			}
		}


		// End of the ABI representation.

		[DllImport("libgstapp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern IntPtr gst_app_sink_get_type();

		public static new GLib.GType GType { 
			get {
				IntPtr raw_ret = gst_app_sink_get_type();
				GLib.GType ret = new GLib.GType(raw_ret);
				return ret;
			}
		}

		[DllImport("libgstapp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern bool gst_app_sink_get_buffer_list_support(IntPtr raw);

		[DllImport("libgstapp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern void gst_app_sink_set_buffer_list_support(IntPtr raw, bool enable_lists);

		public bool BufferListSupport { 
			get {
				bool raw_ret = gst_app_sink_get_buffer_list_support(Handle);
				bool ret = raw_ret;
				return ret;
			}
			set {
				gst_app_sink_set_buffer_list_support(Handle, value);
			}
		}

		[DllImport("libgstapp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern bool gst_app_sink_is_eos(IntPtr raw);

		public bool IsEos { 
			get {
				bool raw_ret = gst_app_sink_is_eos(Handle);
				bool ret = raw_ret;
				return ret;
			}
		}

		[DllImport("libgstapp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern IntPtr gst_app_sink_pull_preroll(IntPtr raw);

		public Gst.Sample PullPreroll() {
			IntPtr raw_ret = gst_app_sink_pull_preroll(Handle);
			Gst.Sample ret = raw_ret == IntPtr.Zero ? null : (Gst.Sample) GLib.Opaque.GetOpaque (raw_ret, typeof (Gst.Sample), true);
			return ret;
		}

		[DllImport("libgstapp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern IntPtr gst_app_sink_pull_sample(IntPtr raw);

		public Gst.Sample PullSample() {
			IntPtr raw_ret = gst_app_sink_pull_sample(Handle);
			Gst.Sample ret = raw_ret == IntPtr.Zero ? null : (Gst.Sample) GLib.Opaque.GetOpaque (raw_ret, typeof (Gst.Sample), true);
			return ret;
		}

		[DllImport("libgstapp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern IntPtr gst_app_sink_try_pull_preroll(IntPtr raw, ulong timeout);

		public Gst.Sample TryPullPreroll(ulong timeout) {
			IntPtr raw_ret = gst_app_sink_try_pull_preroll(Handle, timeout);
			Gst.Sample ret = raw_ret == IntPtr.Zero ? null : (Gst.Sample) GLib.Opaque.GetOpaque (raw_ret, typeof (Gst.Sample), true);
			return ret;
		}

		[DllImport("libgstapp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern IntPtr gst_app_sink_try_pull_sample(IntPtr raw, ulong timeout);

		public Gst.Sample TryPullSample(ulong timeout) {
			IntPtr raw_ret = gst_app_sink_try_pull_sample(Handle, timeout);
			Gst.Sample ret = raw_ret == IntPtr.Zero ? null : (Gst.Sample) GLib.Opaque.GetOpaque (raw_ret, typeof (Gst.Sample), true);
			return ret;
		}

		[DllImport("libgstreamer-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern IntPtr gst_uri_handler_get_uri(IntPtr raw);

		public string Uri { 
			get {
				IntPtr raw_ret = gst_uri_handler_get_uri(Handle);
				string ret = GLib.Marshaller.PtrToStringGFree(raw_ret);
				return ret;
			}
		}

		[DllImport("libgstreamer-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern int gst_uri_handler_get_uri_type(IntPtr raw);

		public Gst.URIType UriType { 
			get {
				int raw_ret = gst_uri_handler_get_uri_type(Handle);
				Gst.URIType ret = (Gst.URIType) raw_ret;
				return ret;
			}
		}

		[DllImport("libgstreamer-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
		static extern bool gst_uri_handler_set_uri(IntPtr raw, IntPtr uri, out IntPtr error);

		public bool SetUri(string uri) {
			IntPtr native_uri = GLib.Marshaller.StringToPtrGStrdup (uri);
			IntPtr error = IntPtr.Zero;
			bool raw_ret = gst_uri_handler_set_uri(Handle, native_uri, out error);
			bool ret = raw_ret;
			GLib.Marshaller.Free (native_uri);
			if (error != IntPtr.Zero) throw new GLib.GException (error);
			return ret;
		}


		static AppSink ()
		{
			GtkSharp.GstreamerSharp.ObjectManager.Initialize ();
		}

		// Internal representation of the wrapped structure ABI.
		static GLib.AbiStruct _abi_info = null;
		static public new GLib.AbiStruct abi_info {
			get {
				if (_abi_info == null)
					_abi_info = new GLib.AbiStruct (new List<GLib.AbiField>{ 
						new GLib.AbiField("priv"
							, Gst.Base.BaseSink.abi_info.Fields
							, (uint) Marshal.SizeOf(typeof(IntPtr)) // priv
							, null
							, "_gst_reserved"
							, (uint) Marshal.SizeOf(typeof(IntPtr))
							, 0
							),
						new GLib.AbiField("_gst_reserved"
							, -1
							, (uint) Marshal.SizeOf(typeof(IntPtr)) * 4 // _gst_reserved
							, "priv"
							, null
							, (uint) Marshal.SizeOf(typeof(IntPtr))
							, 0
							),
					});

				return _abi_info;
			}
		}


		// End of the ABI representation.

#endregion
	}
}