Cascading plug-in tutorial - issue regarding convert to application

Hi there

I’m finding a couple of issues with the “Convert the plugin into an application” section of the “Cascading plug-in effects” tutorial:

https://docs.juce.com/master/tutorial_audio_processor_graph.html

There are two things:

a) Nasty oscillator on start up/first use
When I run it based on the completed converted code (AudioProcessorGraphTutorial_02.h) and apply an Oscillator I get a gnarly distorted tone. Switch it to (for example) Gain, and then back again and I get the expected nice clean Sine wave tone.
This issue is replicable for me on MacOS, iOS and Windows. I’ve tried a few things but haven’t yet managed to solve it.

b) Missing “Empty” from the selection
Unlike the plugin version, the application version doesn’t start up with Empty for each of the slots. In fact there’s no option for it. To fix this I did the following:

Line 448 change to: (adding Empty as an option)
juce::StringArray processorChoices { "Empty", "Oscillator", "Gain", "Filter" };

Lines 320, 329, 342, 355 change: (offsetting the drop down selection behaviour)
else if (choice->getSelectedId() == . . .
to
else if (choice->getSelectedId()-1 == . . .

Line 211 insert: (preselecting Empty as the start up choice)
processorSlot1.setSelectedId(1);
processorSlot2.setSelectedId(1);
processorSlot3.setSelectedId(1);

I hope my part b) section is of some help. As for a), the Oscillator issue itself, it would be great to get some thoughts on how best to fix this please.

Cheers

Jeff

1 Like

Hey there, has anyone got any thoughts on this please?
As JUCE tutorials go this one was a little bit confusing/frustrating in this regard. @t0m might it be worth addressing?

Cheers

Jeff