I did not use the Project Generator, since it is not able to create a single-component version and vst 2.4 compatibility.
Sadly there is no example in MyPlugins which is a single-component.
So I started with the ‘Again simple’ example (it’s the only one which is a single-component) and rewrote everything. It was pretty confusing here, since ‘Again’ and ‘Again simple’ share some source-codes. Then I added VST 2.4 compatibility. There was still a name conflict with vstkeycode which is double-defines in the 2.4 and 3.7 SDK. I do not longer remember how i sloved it.
When you want to be VST 2.4 compatible:
- run copy_vst2_to_vst3_sdk.bat
- Run CMakeGUI
- Select C:/VST_SDK/VST3_SDK as ‘Where is the source code’
- Select C:/VST_SDK/build as ‘Where to build the binaries’
- Run File->delete cache
- Click ‘configure’
- Make sure that you disable SMT_CREATE_BUNDLE_FOR_WINDOWS
- activate SMTG_CREATE_VST2_AGAIN_SAMPLE_VERSION.
- click Generate
- place aeffect.h, aeffectx.h and vstfxstore.h from the VST 2.4 SDK to VST3_SDK\pluginterfaces\vst2.x
- open C:\VST_SDK\vstsdk.sln
- select again (the only one that has vst 2.4 output)
- Open project settings and add a post build event like this
@echo Postbuild script — copy VST3 files —
copy /Y “D:\VST_SDK_3.7\build\VST3\Release\Warlock.vst3” “C:\Program Files\Common Files\VST3\Warlock.vst3”
copy /Y “D:\VST_SDK_3.7\build\VST3\Release\Warlock.vst3” “C:\Program Files\Steinberg\Vstplugins\Warlock.dll”
@echo — copy finished —
@echo PostBuild script: — Running Validator.exe start —
“D:\VST_SDK_3.7\build\bin\Debug\validator.exe” “D:\VST_SDK_3.7\build\VST3\Release\Warlock.vst3”
@echo PostBuild script: — Running Validator.exe finished —
Please note this bug:
When you disable SMT_CREATE_BUNDLE_FOR_WINDOWS in the VST 3.7 SDK the examples that use the VSTGUI do no longer work properly. Instead they just show a black window without a GUI. To fix this open plug.rc . Then add the missing resources (in this case plug.rc in Helloworld_with vstgui)
#include <windows.h>
#include “…/include/version.h”#define APSTUDIO_READONLY_SYMBOLS
plug.uidesc DATA “plug.uidesc”
background.png PNG “background.png”
animation_knob.png PNG “animation_knob.png”
onoff_button.png PNG “onoff_button.png”background_2x.png PNG “background_2x.png”
/////////////////////////////////////////////////////////////////////////////
// Version
…