Mercurial > hg > sonic-visualiser
changeset 58:f7cb156508cc
* Avoid showing input selection and channel selection for generator plugins
author | Chris Cannam |
---|---|
date | Tue, 17 Oct 2006 11:41:56 +0000 |
parents | 684b17ff7fee |
children | 1016a8ceceda |
files | transform/TransformFactory.cpp |
diffstat | 1 files changed, 10 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/transform/TransformFactory.cpp Mon Oct 16 20:41:34 2006 +0000 +++ b/transform/TransformFactory.cpp Tue Oct 17 11:41:56 2006 +0000 @@ -480,6 +480,7 @@ bool frequency = false; bool effect = false; + bool generator = false; if (FeatureExtractionPluginFactory::instanceFor(id)) { @@ -515,6 +516,10 @@ effect = true; } + if (desc->audioInputPortCount == 0) { + generator = true; + } + if (output != "A") { int outputNo = output.toInt(); if (outputNo >= 0 && outputNo < desc->controlOutputPortCount) { @@ -568,12 +573,14 @@ PluginParameterDialog *dialog = new PluginParameterDialog(plugin); - if (candidateModelNames.size() > 1) { + if (candidateModelNames.size() > 1 && !generator) { dialog->setCandidateInputModels(candidateModelNames); } - dialog->setChannelArrangement(sourceChannels, targetChannels, - defaultChannel); + if (targetChannels > 0) { + dialog->setChannelArrangement(sourceChannels, targetChannels, + defaultChannel); + } dialog->setOutputLabel(outputLabel);