Event.CopySegment not copy Segment
Submitted by morohe
Link to original bug (#795964)
Description
Current implementation write to unmanaged memory only. Not writeback to managed memory.
I propose the following implementation.
public Segment CopySegment()
{
Segment val = new Segment();
IntPtr native_segment = GLib.Marshaller.StructureToPtrAlloc(val);
gst_event_copy_segment(Handle, native_segment);
val = Marshal.PtrToStructure<Segment>
(native_segment);
Marshal.FreeHGlobal(native_segment);
return val;
}
Thank you.
Version: 1.14.0