In order for Nuendo 13 to consider a plugin suitable as “Channel Panner”, the order of the VST3 categories has to be “Spatial|Fx” and not the other way around.
Unfortunately JUCEUtils.cmake always re-orders the categories to place “Fx” at the beginning, so when setting VST3_CATEGORIES Spatial Fx on juce_add_plugin the compile definition ends up being JucePlugin_Vst3Category="Fx|Spatial" instead of JucePlugin_Vst3Category="Spatial|Fx".
This is preventing the plugin from being used as a “Channel Panner” in Nuendo 13.
I’ve tried to replace the compile definition by doing this in CMake:
get_target_property(defs ${target} COMPILE_DEFINITIONS)
list(TRANSFORM defs REPLACE [[^JucePlugin_Vst3Category.+$]] "JucePlugin_Vst3Category=\"Spatial|Fx\"")
set_property(TARGET ${target} PROPERTY COMPILE_DEFINITIONS ${defs})
Which works and gets the job done, however this results in compiler warnings which I’d like to avoid:
[89/91] Building CXX object CMakeFiles/MyPlugin_VST3.dir/submodules/JUCE/modules/juce_audio_plugin_client/juce_audio_plugin_client_VST3.mm.o
In file included from <built-in>:503:
<command line>:75:9: warning: 'JucePlugin_Vst3Category' macro redefined [-Wmacro-redefined]
#define JucePlugin_Vst3Category "Spatial|Fx"
^
<command line>:74:9: note: previous definition is here
#define JucePlugin_Vst3Category "Fx|Spatial"
^
1 warning generated.
Similarly, doing this also results in the same warnings:
target_compile_definitions(MyPlugin PUBLIC JucePlugin_Vst3Category=\"Spatial|Fx\")
Is there another/better way of overriding or replacing the JucePlugin_Vst3Category compile definition?
Otherwise I’d like to ask the JUCE team to either remove the re-ordering logic in JUCEUtils.cmake and respect the ordering as specified by the VST3_CATEGORIES property, or come up with another customisation point or something.
Related to: Projucer: VST3 Category Order and Missing Category - #2 by ed95
