Hi there. I’m very new to JUCE (and still getting used to C++), so any advice would be greatly appreciated. I would like to build a JUCE audio plug-in that generates MIDI data to be read by a DAW (like Logic or Ableton). I want my DAW to pick up the MIDI just like it would from a USB MIDI keyboard, except the data is generated by my tool.
To start with something simple, I have tried the following so far:
- created a new audio plugin in the projucer
- In PluginProcessor.cpp, in the Processblock, added
auto message = MidiMessage::noteOn (1, 5, (uint8) 100);
- As an alternative, I also tried
MidiMessage message = MidiMessage::noteOn (1, 5, (uint8) 100);
midiMessages.addEvent (message, 0);
I tried compiling each version, then opened Logic and put the plug-in onto an audio track. I then opened a MIDI instrument track, hoping that it might pick up the MIDI. It doesn’t. What am I doing wrong here?