projects
/
ardour.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
8b27c12
)
vst - fix effGetParameterProperties; label may be unset.
author
Robin Gareus
<robin@gareus.org>
Sat, 17 May 2014 15:01:02 +0000
(17:01 +0200)
committer
Robin Gareus
<robin@gareus.org>
Sat, 17 May 2014 15:01:02 +0000
(17:01 +0200)
libs/ardour/vst_plugin.cc
patch
|
blob
|
history
diff --git
a/libs/ardour/vst_plugin.cc
b/libs/ardour/vst_plugin.cc
index 52e139db84fab0bcc7ab722006271cac9b4e2931..a18cc07356106c1f4045dde35699005811ad4b47 100644
(file)
--- a/
libs/ardour/vst_plugin.cc
+++ b/
libs/ardour/vst_plugin.cc
@@
-250,6
+250,7
@@
VSTPlugin::get_parameter_descriptor (uint32_t which, ParameterDescriptor& desc)
{
VstParameterProperties prop;
{
VstParameterProperties prop;
+ memset (&prop, 0, sizeof (VstParameterProperties));
desc.min_unbound = false;
desc.max_unbound = false;
prop.flags = 0;
desc.min_unbound = false;
desc.max_unbound = false;
prop.flags = 0;
@@
-257,6
+258,7
@@
VSTPlugin::get_parameter_descriptor (uint32_t which, ParameterDescriptor& desc)
if (_plugin->dispatcher (_plugin, effGetParameterProperties, which, 0, &prop, 0)) {
/* i have yet to find or hear of a VST plugin that uses this */
if (_plugin->dispatcher (_plugin, effGetParameterProperties, which, 0, &prop, 0)) {
/* i have yet to find or hear of a VST plugin that uses this */
+ /* RG: faust2vsti does use this :) */
if (prop.flags & kVstParameterUsesIntegerMinMax) {
desc.lower = prop.minInteger;
if (prop.flags & kVstParameterUsesIntegerMinMax) {
desc.lower = prop.minInteger;
@@
-287,6
+289,10
@@
VSTPlugin::get_parameter_descriptor (uint32_t which, ParameterDescriptor& desc)
desc.largestep = desc.step * 10.0f;
}
desc.largestep = desc.step * 10.0f;
}
+ if (strlen(prop.label) == 0) {
+ _plugin->dispatcher (_plugin, effGetParamName, which, 0, prop.label, 0);
+ }
+
desc.toggled = prop.flags & kVstParameterIsSwitch;
desc.logarithmic = false;
desc.sr_dependent = false;
desc.toggled = prop.flags & kVstParameterIsSwitch;
desc.logarithmic = false;
desc.sr_dependent = false;