Example #1
0
 static void OverrideWaitAsync(GLib.GType gtype, WaitAsyncNativeDelegate callback)
 {
     unsafe {
         IntPtr *raw_ptr = (IntPtr *)(((long)gtype.GetClassPtr()) + (long)class_abi.GetFieldOffset("wait_async"));
         *raw_ptr = Marshal.GetFunctionPointerForDelegate((Delegate)callback);
     }
 }
Example #2
0
        private Gst.ClockReturn InternalWaitAsync(Gst.ClockEntry entry)
        {
            WaitAsyncNativeDelegate unmanaged = null;

            unsafe {
                IntPtr *raw_ptr = (IntPtr *)(((long)this.LookupGType().GetThresholdType().GetClassPtr()) + (long)class_abi.GetFieldOffset("wait_async"));
                unmanaged = (WaitAsyncNativeDelegate)Marshal.GetDelegateForFunctionPointer(*raw_ptr, typeof(WaitAsyncNativeDelegate));
            }
            if (unmanaged == null)
            {
                return((Gst.ClockReturn) 0);
            }

            int __result = unmanaged(this.Handle, entry == null ? IntPtr.Zero : entry.Handle);

            return((Gst.ClockReturn)__result);
        }
Example #3
0
		static void OverrideWaitAsync (Gst.GLib.GType gtype, WaitAsyncNativeDelegate callback)
		{
			GstClockClass class_iface = GetClassStruct (gtype, false);
			class_iface.WaitAsync = callback;
			OverrideClassStruct (gtype, class_iface);
		}