public static MidiInCaps GetDeviceCapabilities(int deviceID) { int result; MidiInCaps caps = new MidiInCaps(); IntPtr devID = (IntPtr)deviceID; result = midiInGetDevCaps(devID, ref caps, SizeOfMidiHeader); if (result != MidiDeviceException.MMSYSERR_NOERROR) { throw new InputDeviceException(result); } return(caps); }
private static extern int midiInGetDevCaps(IntPtr deviceID, ref MidiInCaps caps, int sizeOfMidiInCaps);