mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-11 23:54:18 +00:00
VST3: Fixed a hosting issue retrieving the parameters of plug-ins that need their IO configured first
This commit is contained in:
parent
6ee4117fed
commit
64c898d027
1 changed files with 16 additions and 5 deletions
|
|
@ -1774,11 +1774,22 @@ public:
|
|||
editController->setComponentHandler (holder->host);
|
||||
grabInformationObjects();
|
||||
interconnectComponentAndController();
|
||||
addParameters();
|
||||
synchroniseStates();
|
||||
syncProgramNames();
|
||||
|
||||
auto configureParameters = [this]
|
||||
{
|
||||
addParameters();
|
||||
synchroniseStates();
|
||||
syncProgramNames();
|
||||
};
|
||||
configureParameters();
|
||||
|
||||
setupIO();
|
||||
|
||||
// Some plug-ins don't present their parameters until after the IO has been
|
||||
// configured, so we need to jump though all these hoops again
|
||||
if (getParameters().isEmpty() && editController->getParameterCount() > 0)
|
||||
configureParameters();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
@ -2799,6 +2810,7 @@ private:
|
|||
|
||||
{
|
||||
int idx, num = editController->getParameterCount();
|
||||
|
||||
for (idx = 0; idx < num; ++idx)
|
||||
if (editController->getParameterInfo (idx, paramInfo) == kResultOk
|
||||
&& (paramInfo.flags & Steinberg::Vst::ParameterInfo::kIsProgramChange) != 0)
|
||||
|
|
@ -2845,8 +2857,7 @@ private:
|
|||
}
|
||||
}
|
||||
|
||||
if (editController != nullptr
|
||||
&& paramInfo.stepCount > 0)
|
||||
if (editController != nullptr && paramInfo.stepCount > 0)
|
||||
{
|
||||
auto numPrograms = paramInfo.stepCount + 1;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue