diff options
author | Robin Gareus <robin@gareus.org> | 2014-11-30 15:03:36 +0100 |
---|---|---|
committer | Robin Gareus <robin@gareus.org> | 2014-11-30 15:05:39 +0100 |
commit | fb3f9033cfdb22e8d8651d95617cb51258eff3d4 (patch) | |
tree | 898bb25e7c8e6ff0bb9ae919f91ef06dfa252b0c /libs/ardour/ladspa_plugin.cc | |
parent | 0622fc9d4b3589ef00a09a5f69515d8619fa051f (diff) |
use update_steps() instead of custom function
Diffstat (limited to 'libs/ardour/ladspa_plugin.cc')
-rw-r--r-- | libs/ardour/ladspa_plugin.cc | 13 |
1 files changed, 1 insertions, 12 deletions
diff --git a/libs/ardour/ladspa_plugin.cc b/libs/ardour/ladspa_plugin.cc index fca37441af..8b2a4f75df 100644 --- a/libs/ardour/ladspa_plugin.cc +++ b/libs/ardour/ladspa_plugin.cc @@ -504,18 +504,6 @@ LadspaPlugin::get_parameter_descriptor (uint32_t which, ParameterDescriptor& des desc.upper = 4; /* completely arbitrary */ } - if (LADSPA_IS_HINT_INTEGER (prh.HintDescriptor)) { - desc.step = 1.0; - desc.smallstep = 0.1; - desc.largestep = 10.0; - } else { - float delta = desc.upper - desc.lower; - desc.step = delta / 1000.0f; - desc.smallstep = delta / 10000.0f; - desc.largestep = delta/10.0f; - } - - if (LADSPA_IS_HINT_HAS_DEFAULT (prh.HintDescriptor)) { desc.normal = _default_value(which); } else { @@ -534,6 +522,7 @@ LadspaPlugin::get_parameter_descriptor (uint32_t which, ParameterDescriptor& des desc.label = port_names()[which]; desc.scale_points = get_scale_points(which); + desc.update_steps(); return 0; } |