Browse Source

Only expose state-interface to host with JucePlugin_WantsLV2State

Signed-off-by: falkTX <falktx@falktx.com>
tags/2020-07-14
falkTX 3 years ago
parent
commit
c013bba461
Signed by: falkTX <falktx@falktx.com> GPG Key ID: CDBAA37ABC74FBA0
1 changed files with 4 additions and 0 deletions
  1. +4
    -0
      libs/juce-legacy/source/modules/juce_audio_plugin_client/LV2/juce_LV2_Wrapper.cpp

+ 4
- 0
libs/juce-legacy/source/modules/juce_audio_plugin_client/LV2/juce_LV2_Wrapper.cpp View File

@@ -1642,14 +1642,18 @@ static const void* juceLV2_ExtensionData (const char* uri)
{
static const LV2_Options_Interface options = { juceLV2_getOptions, juceLV2_setOptions };
static const LV2_Programs_Interface programs = { juceLV2_getProgram, juceLV2_selectProgram };
#if JucePlugin_WantsLV2State
static const LV2_State_Interface state = { juceLV2_SaveState, juceLV2_RestoreState };
#endif

if (strcmp(uri, LV2_OPTIONS__interface) == 0)
return &options;
if (strcmp(uri, LV2_PROGRAMS__Interface) == 0)
return &programs;
#if JucePlugin_WantsLV2State
if (strcmp(uri, LV2_STATE__interface) == 0)
return &state;
#endif

return nullptr;
}


Loading…
Cancel
Save