Porting from VST 2 API to JUCE


#1

I’m being commissioned to rewrite an old (2012) VST 2/RTMIDI plugin in JUCE and so far I’m able to comprehend a good amount of it from the docs, but at the same time, there’s still a lot I can’t wrap my mind around. I’ve been requested to target AU and VST 3 with this. I’m new to coding stuff for MIDI also. I’m good with format parsing but the whole message sending architecture is foreign to me. The answer might be staring right at me in the docs, but even the most professional coders can overlook something.

My big issue at the moment is that there seems to be two components, VstEvent and VstMidiEvent, for loading message data into. I’m guessing with JUCE, MidiBuffer is involved. However, I’m not sure where this MidiBuffer object would come from: do I take it as a parameter? If so, from where? Or if I create a temporary one in the function, how do I send out data with it?

I appreciate the help given! Thank you.


#2

make a new Audio Plugin project in ProJucer, and build around the processBlock() in the generated pluginProcessor.cpp.
If you don’t know how to do that, check out this tutorial: https://docs.juce.com/master/tutorial_create_projucer_basic_plugin.html


#3

Hmm… well this seems a lot less hassle-y than VST. Thanks! If I have any more issues, I’ll let you know.

I just realised there’s nothing here about receiving MIDI data, just sending it. My plugin does both, so… I’m once again stuck.


#4

The MIDI input data comes through the MidiBuffer given to the processBlock method. The same buffer is used to output MIDI from the plugin.


#5

I think I may have the idea now. I’ll do my best, but most likely I get the feeling I’ll post a code sample and someone will go “oh dear, wow… that’s not right at all”