I have been tasked to create an audio plugin for a research project through the university. I have a few preliminary goals for the project but I seem to be too much of a novice at JUCE and plugin development to accomplish my goals. Using the auto-generated PluginEditor and PluginProcessor I hope to be able to do the following 3 thing by using child components:
Use the plugin to access the sample library in my DAW (Cubase). [This could also be achieved by creating a directory which can open a sample library from Finder (Mac) and display it inside the plugin’s interface. But I think it would be better to access the sample library already used in Cubase rather than develop a component to do the same thing in my plugin]
Swap out a recording/sample in the workspace with a new sample found in the Cubase sample library. [the user matkatmusic referred me to this function to do so
processBlock(AudioBuffer,MidiBuffer)] this function would be similar to drum sample replacement software.
Include a Python model (because the algorithm is based on this model it would be difficult to convert the model to C++) as the backend of the plugin (processes the audio input).
Any advice on any of these topics would be appreciated. Also any advice on plugin development would be helpful too, I have some experience in C++ programming but am relatively new to JUCE.
- and 2) are not part of standard plugin functionality. It will depend on the host application whether those kinds of things are possible at all and JUCE does not directly have any support for those kinds of things. (You can only do pretty standard audio effect and instrument plugins with JUCE. Matkatmusic has unfortunately probably misunderstood what you have been asking and the advice about processBlock() does not apply to your use case if you actually want to swap audio on the host’s timeline.)
As for 3), embedding Python is a quite complicated task and JUCE does not have any helper classes for that. You might want to look for some existing Python embedding C++ library. (For example Boost has a Python support library.)
Thank you for the information but now I am sort of curious about 2 things:
Wouldn’t a virtual instrument need a sample library? If these samples are not found in the DAW’s sample library where would they be found?
How do drum sample replacement plugins (like Steven Slate Drums) work?
I am simply curious because I believe that if there was a way to understand implementing these 2 softwares using JUCE it can possibly help me come up with alternative approaches to my project.
Thank you for the information. Do you also happen to know any open source examples that implement these things so that I can have some code to reference?
you should have continued your original thread, not started a new one. doing the latter clutters the forum.
sorry I will note that and try to be more cautious in the future