Exemple #1
0
        public void AppendSubEntry(Gst.TocEntry subentry)
        {
            IntPtr this_as_native = System.Runtime.InteropServices.Marshal.AllocHGlobal(System.Runtime.InteropServices.Marshal.SizeOf(this));

            System.Runtime.InteropServices.Marshal.StructureToPtr(this, this_as_native, false);
            IntPtr native_subentry = GLib.Marshaller.StructureToPtrAlloc(subentry);

            gst_toc_entry_append_sub_entry(this_as_native, native_subentry);
            ReadNative(this_as_native, ref this);
            System.Runtime.InteropServices.Marshal.FreeHGlobal(this_as_native);
            Marshal.FreeHGlobal(native_subentry);
        }
Exemple #2
0
        public Gst.TocEntry FindEntry(string uid)
        {
            IntPtr this_as_native = System.Runtime.InteropServices.Marshal.AllocHGlobal(System.Runtime.InteropServices.Marshal.SizeOf(this));

            System.Runtime.InteropServices.Marshal.StructureToPtr(this, this_as_native, false);
            IntPtr native_uid = GLib.Marshaller.StringToPtrGStrdup(uid);
            IntPtr raw_ret    = gst_toc_find_entry(this_as_native, native_uid);

            Gst.TocEntry ret = Gst.TocEntry.New(raw_ret);
            ReadNative(this_as_native, ref this);
            System.Runtime.InteropServices.Marshal.FreeHGlobal(this_as_native);
            GLib.Marshaller.Free(native_uid);
            return(ret);
        }
Exemple #3
0
 static void ReadNative(IntPtr native, ref Gst.TocEntry target)
 {
     target = New(native);
 }