コード例 #1
0
ファイル: Midi.cs プロジェクト: the-alex-mark/proglib-cs
        public static MIDIError MIDI_OutOpen(ref IntPtr handle, int deviceID, MIDIOUTPROC proc, IntPtr user)
        {
            MIDIFlags flags = MIDIFlags.MIDI_CALLBACK_FUNCTION;

            if (proc == null)
            {
                flags = MIDIFlags.MIDI_CALLBACK_NULL;
            }
            return(Midi.midiOutOpen(ref handle, new IntPtr(deviceID), proc, user, flags));
        }
コード例 #2
0
ファイル: Midi.cs プロジェクト: the-alex-mark/proglib-cs
 private static extern MIDIError midiOutOpen([In][Out] ref IntPtr handle, IntPtr deviceID, MIDIOUTPROC proc, IntPtr user, MIDIFlags flags);
コード例 #3
0
ファイル: Midi.cs プロジェクト: the-alex-mark/proglib-cs
 public static MIDIError MIDI_InOpen(ref IntPtr handle, int deviceID, MIDIINPROC proc, IntPtr user, MIDIFlags flags)
 {
     if (proc == null)
     {
         flags = MIDIFlags.MIDI_CALLBACK_NULL;
     }
     else
     {
         flags |= MIDIFlags.MIDI_CALLBACK_FUNCTION;
     }
     return(Midi.midiInOpen(ref handle, new IntPtr(deviceID), proc, user, flags));
 }