JuceDemoPlugin Problem

Hi Jules.

I checked again and again, the Windows version does not work.
The Mac version works well, but in Windows, the DAW (I checked a few) does not recognize the plug-in.

Here is what I did (several times)

  1. Downloaded the modules branch.
  2. Opened the JuceDemoPlugin.jucer
  3. Updated the ‘Module source folder’ in the Modules tab.
  4. Updated the ‘Local Juce folder’ in the Visual Studio 2008 tab.
  5. Updated the ‘VST Folder’ in the Visual Studio 2008 tab.
  6. pressed ‘Save project and open in Visual Studio’ button.

Then I compiled & tested it.

Ok, now I’m making some progress.

The file (juce_VST_Wrapper.cpp) is excluded from the build.

vcxproj file:

    <ClCompile Include="..\..\..\SDKs\juce\modules\juce_audio_plugin_client\VST\juce_VST_Wrapper.cpp">
      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Standalone-D|Win32'">true</ExcludedFromBuild>
      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Standalone-R|Win32'">true</ExcludedFromBuild>
    </ClCompile>

This happens whether I check the ‘Create Local Copy’ or not.
When I change the Properties->Excluded From Build combo to ‘No’, it works.

Aha, thanks! Looks like a bug in the introjucer, I’ll get that sorted out.

I just tried to build a vst plugin created by introjoucer, and it didn’t have the vst wrapper c++ file. excluding it from the project allows the project to build however it can’t be loaded by the audio plugin host due to this yes?

I tried this on 12/2/2011, using visual studio 2010 - after having the introjoucer download a the latest copy of juce…can anyone confirm if this is operator error on my part, and perhaps suggest a workaround?

Thanks,
Kurt

The VST plugin project needs to be compiled together the VST SDK, make sure you have it in your include path.

Thanks for the reply Shlomi, unfortunately for me however the issue seems more related to the missing vst_Wrapper.cpp file and it’s role in initializing the dll. The demo plugin, which does compile, and which I can copy/modify includes this file among others - which the introjoucer doesn’t seem to be supplying to the project it creates. Am I missing a step when using the introjoucer perhaps? Perhaps forgetting to set an option or something? I tried forcing the usage of ‘vst’ and ‘direct sound’ to no avail.

If I tell visual studio to ‘exclude’ the vst_Wrapper.cpp file then the project does compile (after putting the vst sdk in the included files path) - and it does generate a dll, it’s just that the dll won’t load!

Thanks,
Kurt

Hi Kurt

The vst_wrapper exposes the dll functions that the host calls in order to load the plugin (main() / VSTPluginMain()).
You don’t really need the Introjucer to compile the project, just take a fresh git copy and load the sln project.
I just did it to check the JuceDemoPlugin, and It works fine.

With which host are you trying to load the plugin?
I did found the juce_VST_wrapper.cpp under JuceDemoPlugin -> JuceLibraryCode .

HI Shalomi,

Thanks for all the help…and fyi I did try to add the vst_Wrapper.cpp file into the project but it’s like pulling a loose thread! - It’s imports were misplaced etc…I’m still new to juce and that was getting ugly in a hurry…

The real issue as I see it is that I wanted to write a platform independent plugin, or at least get a starting point and see what issues are involved as I’ve not done this before. If the introjoucer created project had worked then it would have laid out all the platform specific variants for me which would have given me a comfortable feeling starting point…But it didn’t work, so I copied the juice demo plugin, renamed it etc. and then blasted off, and that’s working ok, at least I’m off and running.

The problem with this approach however is that, perhaps due to being a simple ‘weenie’ is that I can’t seem to use jucer, or introjoucer to help me write the code. I’ll be doing more learning about those tools today. But it doesn’t feel good to start with - for example. In the demo plugin project is a .jucer file - but juicer.exe doesn’t recognize it, nor is it able to load any of the demo project .cpp files. It say’s it doesn’t recognize them…So…I’m confused about 1) how to use the jucer and introjucer, and 2) don’t understand how their meant to be used after the initial creation of a project, or .cpp files within a project…

So, I’ll be hitting the forum hard over the next couple of days to try and understand the usage of the tools, and how I might apply them to a vst plugin project, as well as their ability to modify the juce vst host program…At this point I have to manually code all the user interface changes - yuk!

So I’m off to the forums now to see what I can do about advancing towards ‘uber weenie’ status…Perhaps after I figure out the tools I’ll create two new projects whose user interfaces I can modify with the tools as much as possible, and then cut-copy-n-paste the guts of the plugin-host and demo plugin into my new projects…

Thanks Again,
Kurt

I should mention that juce is a GREAT starting point. Thanks Jules! At this point I may be coding user interface changes manually, but at least the api’s are beautiful, what I want to type - I can type! And juce understands what I mean. In comparison to doing the user interface changes using MFC, and to a lesser extent the java swing api’s - Both of which seem better suited for use by the aliens that late night tv keeps insisting are visiting our planet. Well, if aliens are visiting and using mfc and swing to code their ‘take over the world applications’ then the jucers will win the productivity war…All will be well eventually…

I think choosing Juce as your platform for developing a plugin is like getting a code ninja in your team for free (with a British accent).

It may be a good thing to get your hands dirty with the code though for me the Introjucer is a great tool when I add files
to my project, I no longer need to remember which files I’ve added and what sort of refactoring I did when switching platforms.

I also found the example host project and the JuceDemo project very useful, your can see how a typical host is loading a plugin
and the JuceDemo project is a nice display of the Juce capabilities, and you have the source code to snap whatever you want.