コード例 #1
0
        public MusicPlayerStatus AddMidiRawDataEvent(double timestamp, MidiRawData rawData)
        {
            if (rawData == null)
            {
                throw new ArgumentNullException("rawData");
            }

            var native = rawData.ToUnmanaged();
            var r      = MusicTrackNewMIDIRawDataEvent(handle, timestamp, native);

            Marshal.FreeHGlobal(native);
            return(r);
        }
コード例 #2
0
ファイル: MusicTrack.cs プロジェクト: xamarin/xamarin-macios
        public MusicPlayerStatus AddMidiRawDataEvent(double timestamp, MidiRawData rawData)
        {
            if (rawData is null)
            {
                ObjCRuntime.ThrowHelper.ThrowArgumentNullException(nameof(rawData));
            }

            var native = rawData.ToUnmanaged();
            var r      = MusicTrackNewMIDIRawDataEvent(Handle, timestamp, native);

            Marshal.FreeHGlobal(native);
            return(r);
        }