Styling the Standalone plugin window?

Oh yes, can you please add AsyncQuitRetrier() to the Standalone code so it doesn’t crash if you quit while the Audio/MIDI Setup dialog is open?

Thanks,

Rail

1 Like

OK the standalone code won’t assert anymore when quitting. Fix is on develop with commit b78ce1f.

1 Like

Thanks!

Hi fabian,

So this kinda works… If I change my code for testing to:

MyProcessor:: MyProcessor() : AudioProcessor (BusesProperties().withOutput ("Out", AudioChannelSet::discreteChannels (32), true))
{
:
}

The Audio/MIDI Setup for SoundFlower64 now shows all the outputs and if I leave everything as the default with all outputs enabled/selected then all my routing works perfectly… the problem is if I try and change anything in the Audio/MIDI Setup… say I de-select Output 3+4 then I need to get a callback to indicate that Out 3+4 is disabled to my plug-in so I can modify my graph connections (otherwise everything is offset by the 2 disabled Outputs - personally I’d prefer that they get disabled and everything else stay constant)… is there a callback for that? The other thing is that if you do disable Output 3+4 you hit two asserts in the code in AudioProcessor::setPlayConfigDetails() and if you then try and re-enable Output 3+4 it does… but after that the options in the Setup don’t respond to any Output selections after that (even if you select a different output device and switch back to SoundFlower64).

Any thoughts?

Thanks,

Rail

I assume this is when you run your plug-in in standalone mode, right? To be honest, we’ve never really tried this with more than two channels. I’ve just tried this now with Loopback instead of SoundFlower and I can confirm that the standalone target works well if everything is left as default.

How are you disabling outputs? In JUCE’s audio settings screen or in Apple’s Audio/MIDI Setup? I can’t seem to disable any of the channels in both.

Correct, this is only an issue for Standalone. Everything works perfectly fine in all the other formats.

I changed some code slightly to allow disabling the outputs… I’ll be sending you a PM soon showing the issue(s) and another company’s Standalone JUCE based plug-in trying to do the same thing as I’m trying to do (and failing on and off).

Rail

Thinking about this… perhaps it’s correct to not allow the user to remove/change the Outputs for the device… which means this will be fine with the change… If it is, other than relying on the preprocessor defined JucePlugin_Build_Standalone at compile time to set up the output buses which would mean building the Standalone separately… is there any way to change the BusesProperties at run time when the AudioProcessor is created?

Thanks,

Rail

Hi fabian. I’m having real trouble getting this to work without causing lots of redefinition problems on OSX and Windows.

Here is my class:

Which is essentially a copy of juce_StandaloneFilterApp.cpp with a mainWindow->setUsingNativeTitleBar (true) added to initialise() to set native windows.

I think I’ve followed your instructions, though obviously the HelloWorldApplication doesn’t contain any of the standalone filter window code contained in the juce_StandaloneFilterApp.cpp default app. I managed to get this working for debug on OSX but ran in to lots of redefinitions for release on OSX - now trying to get it working on Windows and hitting lots of re definitions again. Feels like I’m doing something wrong just to be able to call setUsingNativeTitleBar (true).

Thx

I just got this working yesterday… PM me if you need help… It took a little work to get it working right.

I’ll be watching the game and handing out candy… so it may be a slower response :wink:

EDIT: See Reference to point is ambiguous

Rail

Sorry for the late reply! You shouldn’t simply be copying the whole juce_StandaloneFilterApp.cpp with all the headers etc. Just add the include for the JuceHeader.h as you would with any other .cpp file that you would add to your project.

1 Like

That almost works… except that StandalonePluginHolder in juce_StandaloneFilterWindow.h needs

#if JUCE_MODULE_AVAILABLE_juce_audio_plugin_client

    #include <juce_audio_plugin_client/utility/juce_IncludeModuleHeaders.h>

#endif

or it’ll choke on not finding the definition for createPluginFilterOfType

Rail

1 Like

OK thanks @Rail_Jon_Rogut. A fix for this is now on develop with commit 853b93b.

1 Like

thx!

Hi,

Do you have an idea how to add an item in the menu for standalone plugins? I found this as starting point Extra macOS menu items to respect disabled flag

Cheers

Take a look in juce_StandaloneFilterWindow.h and look for void buttonClicked(Button*). That’s where it builds the PopupMenu.