コード例 #1
0
 RtMidiManager()
 {
     // These are used exclusively to get number of available ports for the given
     // type of device (input/output) as well as to provide port names
     _defaultInputDevice  = new RtMidiInputDevice(0);
     _defaultOutputDevice = new RtMidiOutputDevice(0);
 }
コード例 #2
0
 private RtMidiDeviceManager()
 {
     /*
      * These are used exlusively to get number of available ports for the given
      * type of device (input/output) as well as to provide port names
      */
     _defaultInputDevice  = new RtMidiInputDevice(0);
     _defaultOutputDevice = new RtMidiOutputDevice(0);
 }
コード例 #3
0
        public void RawDeviceCount()
        {
            var input  = new RtMidiInputDevice();
            int i      = input.PortCount;
            var output = new RtMidiOutputDevice();
            int o      = output.PortCount;

            // mmk exposed some bug with this code.
            output.OpenPort(0, "port0");

            Assert.AreEqual(i, input.PortCount, "#1");
            Assert.AreEqual(o, output.PortCount, "#2");
            output.Close();
        }
コード例 #4
0
 internal MidiInputDevice(RtMidiInputDevice rtMidiInputDevice, string name)
     : base(rtMidiInputDevice, name)
 {
     _inputDevice          = rtMidiInputDevice;
     _inputDevice.Message += RtMidiInputDevice_Message;
 }