mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-10 23:44:24 +00:00
Fix for auval fail with parameter strings in plugins with old-style parameter implementations.
This commit is contained in:
parent
c19df0cc20
commit
c1dbb8684a
1 changed files with 16 additions and 8 deletions
|
|
@ -343,11 +343,14 @@ public:
|
|||
{
|
||||
if (juceFilter != nullptr)
|
||||
{
|
||||
const String text (String::fromCFString (pv->inString));
|
||||
|
||||
if (AudioProcessorParameter* param = juceFilter->getParameters() [(int) pv->inParamID])
|
||||
{
|
||||
pv->outValue = param->getValueForText (String::fromCFString (pv->inString));
|
||||
return noErr;
|
||||
}
|
||||
pv->outValue = param->getValueForText (text);
|
||||
else
|
||||
pv->outValue = text.getFloatValue();
|
||||
|
||||
return noErr;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -359,11 +362,16 @@ public:
|
|||
{
|
||||
if (juceFilter != nullptr)
|
||||
{
|
||||
const float value = (float) *(pv->inValue);
|
||||
String text;
|
||||
|
||||
if (AudioProcessorParameter* param = juceFilter->getParameters() [(int) pv->inParamID])
|
||||
{
|
||||
pv->outString = param->getText ((float) *(pv->inValue), 0).toCFString();
|
||||
return noErr;
|
||||
}
|
||||
text = param->getText ((float) *(pv->inValue), 0);
|
||||
else
|
||||
text = String (value);
|
||||
|
||||
pv->outString = text.toCFString();
|
||||
return noErr;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue