Browse Source

Fix unused parameters preventing real ones showing up

Signed-off-by: falkTX <falktx@falktx.com>
tags/v2.4.1
falkTX 3 years ago
parent
commit
eab801201f
Signed by: falkTX <falktx@falktx.com> GPG Key ID: CDBAA37ABC74FBA0
1 changed files with 12 additions and 5 deletions
  1. +12
    -5
      source/frontend/carla_widgets.py

+ 12
- 5
source/frontend/carla_widgets.py View File

@@ -1047,21 +1047,28 @@ class PluginEdit(QDialog):
paramOutputList = []
paramInputWidth = 0
paramOutputWidth = 0
unusedParameters = 0

paramInputListFull = [] # ([params], width)
paramOutputListFull = [] # ([params], width)

for i in range(min(parameterCount, self.host.maxParameters)):
paramInfo = self.host.get_parameter_info(self.fPluginId, i)
paramData = self.host.get_parameter_data(self.fPluginId, i)
paramRanges = self.host.get_parameter_ranges(self.fPluginId, i)
paramValue = self.host.get_current_parameter_value(self.fPluginId, i)
for i in range(parameterCount):
if i - unusedParameters == self.host.maxParameters:
break
paramData = self.host.get_parameter_data(self.fPluginId, i)

if paramData['type'] not in (PARAMETER_INPUT, PARAMETER_OUTPUT):
unusedParameters += 1
continue
if (paramData['hints'] & PARAMETER_IS_ENABLED) == 0:
unusedParameters += 1
continue

paramInfo = self.host.get_parameter_info(self.fPluginId, i)
paramRanges = self.host.get_parameter_ranges(self.fPluginId, i)
paramValue = self.host.get_current_parameter_value(self.fPluginId, i)

parameter = {
'type': paramData['type'],
'hints': paramData['hints'],


Loading…
Cancel
Save