From df8ee18c0139f889bf7c697713a2205364845464 Mon Sep 17 00:00:00 2001 From: David Robillard Date: Fri, 25 Jan 2008 06:55:57 +0000 Subject: Overhaul SLV2 API to return/take SLV2Value (instead of strings or primitives) wherever possible. Make 'index' a fundemental property of ingen ports. git-svn-id: http://svn.drobilla.net/lad/ingen@1113 a436a847-0d15-0410-975c-d299462d15a1 --- src/libs/engine/LADSPANode.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'src/libs/engine/LADSPANode.cpp') diff --git a/src/libs/engine/LADSPANode.cpp b/src/libs/engine/LADSPANode.cpp index 71e40c9d..921e6304 100644 --- a/src/libs/engine/LADSPANode.cpp +++ b/src/libs/engine/LADSPANode.cpp @@ -171,20 +171,20 @@ LADSPANode::instantiate() } assert (LADSPA_IS_PORT_INPUT(_descriptor->PortDescriptors[j]) || LADSPA_IS_PORT_OUTPUT(_descriptor->PortDescriptors[j])); + + Sample default_val, min, max; + get_port_limits(j, default_val, min, max); if (LADSPA_IS_PORT_INPUT(_descriptor->PortDescriptors[j])) { - port = new InputPort(this, port_name, j, _polyphony, type, port_buffer_size); + port = new InputPort(this, port_name, j, _polyphony, type, default_val, port_buffer_size); _ports->at(j) = port; } else if (LADSPA_IS_PORT_OUTPUT(_descriptor->PortDescriptors[j])) { - port = new OutputPort(this, port_name, j, _polyphony, type, port_buffer_size); + port = new OutputPort(this, port_name, j, _polyphony, type, default_val, port_buffer_size); _ports->at(j) = port; } assert(port); assert(_ports->at(j) == port); - - Sample default_val, min, max; - get_port_limits(j, default_val, min, max); // Work around broke-ass crackhead plugins if (default_val < min) { -- cgit v1.2.1