cmajor icon indicating copy to clipboard operation
cmajor copied to clipboard

Issues with "cmaj generate --target=juce" ( WIN11x64 / VS2022 / Ableton )

Open sorenjakobsen opened this issue 2 months ago • 1 comments

I have made a patch that I would really like to distribute as a VST3, but I have run into some problems when I build (with Visual Studio Community 2022 on 64-bit Windows 11 Home) the output that is generated with "cmaj generate --target=juce" - and try to load the generated VST3 with Ableton Live.

  • If the patch has any input parameters it immediately crashes (bringing Ableton down as well)
  • Adding "EDITOR_WANTS_KEYBOARD_FOCUS FALSE" inside the generated CMakeLists.txt has no effect - after I click inside the UI of the generated VST3 (loaded in Ableton) I am no longer able to use space bar to start playback. This makes my plugin practically useless.
  • Sometimes the plugin does not appear in Ableton's list of plugins. This is not such a big problem though, because it will appear if one searches for it using 'CTRL+F'. With earlier versions of Cmajor I never experienced this.
  • The plugin fails to load unless output stream 'out' is defined. My plugin only outputs MIDI but I can of course just ad that, which solves the problem.

Following is one way I have tried to define the input parameter:

input event float32 test [[ name: "test", min: 0.0f, max: 1.0f, init: 1.0f, step: 0.1f ]];

And following is how I have tried adding "EDITOR_WANTS_KEYBOARD_FOCUS FALSE" (with the SineSynth example):

juce_add_plugin(SineSynth
    FORMATS Standalone AU AUv3 VST3
    DESCRIPTION "A simple synth using the SineOscillator"
    PRODUCT_NAME "SineSynth"
    BUNDLE_ID "dev.cmajor.examples.sinesynth"
    PLUGIN_CODE "plug"
    PLUGIN_MANUFACTURER_CODE "Cmaj"
    COMPANY_NAME "Cmajor Software Ltd"
    COMPANY_WEBSITE ""
    NEEDS_MIDI_INPUT TRUE
    NEEDS_MIDI_OUTPUT FALSE
    MICROPHONE_PERMISSION_ENABLED FALSE
    IS_SYNTH TRUE
    EDITOR_WANTS_KEYBOARD_FOCUS FALSE
)

sorenjakobsen avatar Oct 27 '25 09:10 sorenjakobsen

I think requiring an output stream is a VST3 thing, not something we can fix (and maybe JUCE should warn you if you build a VST like that?)

julianstorer avatar Nov 07 '25 10:11 julianstorer