I’m writing a program that can send out MIDI messages to other software, like DAWs and other audio applications. What I want to do is essentially create a virtual MIDI output for my program.
I’m currently just using the Midi Through Output, that is always available on Linux - it works just fine, I just select Midi Through as my input in my DAW as well, and it just passes it through - but I noticed that whenever I run my program, a ‘Juce Midi Output’ device shows up in my Midi device list (in my DAW), and everything I send from my app over Midi Through, is also sent over Juce Midi Output. (see image)
However, this output does not show up in the
This seems to be the behavior of the
MidiOutput::createNewDevice() function, but I don’t call it anywhere in my code. All I’m doing right now (related to Midi) is this:
MidiOutput* midithrough = MidiOutput::openDevice(0); if(type == 0x90) midithrough->sendMessageNow(MidiMessage::noteOn(channel,note,(float)velocity/127)); if(type == 0x80) midithrough->sendMessageNow(MidiMessage::noteOff(channel,note,(float)velocity/127));
Is it possible to get rid of the Midi Through, and directly send it out from the Juce Midi Output that is created?
Will this work on all three OSs? I read that the MidiOutput::createNewDevice() function is not available on Windows, does this have anything to do with this virtual device?
Thanks in advance