Plugin to standalone


I’ve searched the forum but couldn’t find a simple answer to this so here goes. Can I build the demo vst gain plugin as a standalone without changing the plugin code? I’ve tried setting JucePlugin_Build_Standalone in my preprocessor options but MSVC still outputs a plugin binary. Is there something else I need to do or is there a lot more work involved than there appears. I’m using juce 1.50, thanks and happy new year to you all.



You can’t build a standalone just by changing a few flags - building an exe is different to building a dll, so you’d need to create a new project for it.

I’ve provided utility classes to do this in the plugins/standalone folder, but haven’t got any example code. You basically just have to write a small app that uses the standalone classes to load the plugin object. It’s not hard at all.

Building standalone plugin in new JUCE

You can’t build a standalone just by changing a few flags - building an exe is different to building a dll, so you’d need to create a new project for it.

I was thinking as much! I’ll have a look in the folder you mentioned, perhaps some other jucers have some sample code they could share, otherwise don’t be surprised to see a few more questions on the topic.




Thanks Atom, I saw that thread but it didn’t answer the question I was asking, i.e., can a plugin be recompiled as a standalone without changing the code. I must take a look at utility classes Jules described and see if I can get my head around them. I assume that’s how you’ve done it with your applications?


I had a look through your code atom. Am I right now in assuming that I need to add a call to createPluginFilter(), as well as set the JucePlugin_Build_Standalone preprocessor directive in order to build as standalone or are there still plenty of steps I’m missing? I hope not, that sounds relatively straightforward!


no that’s it, but you have to create the window yourself like so Juce\PluginWrapper\Standalone\StandaloneFilterApp.cpp, but the plugin code stays the same.


I’m getting close now I hope. I created a new project as I would if I were building a standalone juce application. Into that project I dropped all the files from the juce filter plugin demo and the wrapper classes along with the utility standalonefilterwindow stuff. I then created a new JUCEApplication class and in it I place an initialise function as Atom has in his code. It will compile but it crashes on compile. I have JucePlugin_Build_Standalone set in the preprocessor directive options and createPluginFilter() is being called and is returning a DemoJuceFilter object. I’m terrible with debuggers so I’m hoping someone can spot the problem here without have to go near one? Am I missing something important?


take the JuceDemoPlugin project add a new solution configuration in the configuration manager, call it Debug-Standalone, in the project properties (alt+f7) in the General setcion change the Configuration Type from dll to exe, paste this code to a cpp file, and add it to the juce demo project

#include "Includes.h"
#include "juce_StandaloneFilterWindow.h"

class JuceDemoPlugin : public JUCEApplication

		void initialise(const String& commandLineParameters)
			ApplicationProperties::getInstance()->setStorageParameters (T("JuceDemoPlugin"), String::empty, T("JuceDemoPlugin"), 400, PropertiesFile::storeAsXML);
			filterWindow = new StandaloneFilterWindow (T("Ctrlr v4"), Colours::black);
			filterWindow->setTitleBarButtonsRequired (DocumentWindow::allButtons, false);
			filterWindow->setVisible (true);
			filterWindow->setResizable (true, true);

		void shutdown()
			deleteAndZero (filterWindow);

		const String getApplicationName()
			return T("JuceDemoPlugin");
		const String getApplicationVersion()
			return T("4.0");

		StandaloneFilterWindow *filterWindow;


set the preprocessor stuff, add the wrapper code for the standalone version (it’s in the wrapper directory) to your project (it’s not there by default), build, you’ll get an EXE file instead of a dll file. i also remove all the RTAS stuff cause i don’t have the RTAS sdk (apparently i don’t deserve it).


Thank you Atom, it’s easy when you know how! Is it this straightforward on all operating systems?


yes, i do it the same way on osx and linux.


I’m still getting my head around the way things are structured when building standalones using plugin type code. What I would like to do however is to pass information from my StandaloneFilterWindow class to my pluginEditor class, the one on which the GUI components get placed. Basically I want my StandaloneFilterWindow to open a text file and then I want that file passed to my pluginEditor class, can this be done and if so what’s the best way to do it, any suggestions are much appreciated.