I am new to programming with JUCE and Im looking at Tracktion as a candidate as the main framework for a project. Just to test it out I wanted to do something (presumably) very simple:
- Instantiate a VST instrument and a track
- Load a midi clip onto that track
- Have the Instrument play the midi clip and render the audio output as an .wav file
However I am no where near my goal, stuck at step #1. Specifically I need to go from a file path pointing to the VST instrument to an instance of this instrument (Its a CLI project that takes the file path as a parameter). But honestly I don’t even know where to start as I find the API very confusing. Hoping to get some help from some of the gifted minds in this forum.
My plan was to first create an Edit. And place a Track in that Edit. Then load the Instrument onto the Track from the path. Then load the MidiClip to that Track (also from a path). And then finally Render the whole thing… So far I have only managed to create the Edit and Inserted an AudioTrack onto it… I can also render the whole edit with an audio file loaded onto the audio track (just to mock the plugin)… But I don’t know how to put the instrument in there and play a midi clip. I thought there would be some kind of Plugin Class with a “load_plugin_from_path(string pathToVst)” method. But it seems like the road is a bit tricky’er.
I already build the example projects and their code and I looked through this fora. The closest thing I could find was this thread: AudioProcessorGraph stops working after loading plugin instance in host but the authors code is from 2018 and maybe the API changed a bit since, but I cannot get that working either.
If someone could assist in figuring out
a) What track class to load a plugin onto (given I also need to play midi later on…)
b) What plugin class to use and how to initialise it
I think Tracktion looks awesome and really like to learn this better so hoping someone can pitch in with some thoughts of this.