diff options
Diffstat (limited to 'libs/ardour')
-rw-r--r-- | libs/ardour/ardour/value_as_string.h | 2 | ||||
-rw-r--r-- | libs/ardour/automatable.cc | 4 | ||||
-rw-r--r-- | libs/ardour/automation_list.cc | 1 | ||||
-rw-r--r-- | libs/ardour/event_type_map.cc | 4 | ||||
-rw-r--r-- | libs/ardour/gain_control.cc | 2 | ||||
-rw-r--r-- | libs/ardour/luabindings.cc | 1 | ||||
-rw-r--r-- | libs/ardour/parameter_descriptor.cc | 2 | ||||
-rw-r--r-- | libs/ardour/send.cc | 2 |
8 files changed, 14 insertions, 4 deletions
diff --git a/libs/ardour/ardour/value_as_string.h b/libs/ardour/ardour/value_as_string.h index 861f8bfa93..2b95eb9141 100644 --- a/libs/ardour/ardour/value_as_string.h +++ b/libs/ardour/ardour/value_as_string.h @@ -53,7 +53,7 @@ value_as_string(const ARDOUR::ParameterDescriptor& desc, // Value is not a scale point, print it normally if (desc.unit == ARDOUR::ParameterDescriptor::MIDI_NOTE) { snprintf(buf, sizeof(buf), "%s", ParameterDescriptor::midi_note_name (rint(v)).c_str()); - } else if (desc.type == GainAutomation || desc.type == TrimAutomation || desc.type == EnvelopeAutomation) { + } else if (desc.type == GainAutomation || desc.type == BusSendLevel || desc.type == TrimAutomation || desc.type == EnvelopeAutomation) { snprintf(buf, sizeof(buf), "%.1f dB", accurate_coefficient_to_dB (v)); } else if (desc.type == PanWidthAutomation) { snprintf (buf, sizeof (buf), "%d%%", (int) floor (100.0 * v)); diff --git a/libs/ardour/automatable.cc b/libs/ardour/automatable.cc index d77aac71dd..3486812443 100644 --- a/libs/ardour/automatable.cc +++ b/libs/ardour/automatable.cc @@ -190,6 +190,8 @@ Automatable::describe_parameter (Evoral::Parameter param) if (param == Evoral::Parameter(GainAutomation)) { return _("Fader"); + } else if (param.type() == BusSendLevel) { + return _("Send"); } else if (param.type() == TrimAutomation) { return _("Trim"); } else if (param.type() == MuteAutomation) { @@ -542,6 +544,8 @@ Automatable::control_factory(const Evoral::Parameter& param) control = new GainControl(_a_session, param); } else if (param.type() == TrimAutomation) { control = new GainControl(_a_session, param); + } else if (param.type() == BusSendLevel) { + control = new GainControl(_a_session, param); } else if (param.type() == PanAzimuthAutomation || param.type() == PanWidthAutomation || param.type() == PanElevationAutomation) { Pannable* pannable = dynamic_cast<Pannable*>(this); if (pannable) { diff --git a/libs/ardour/automation_list.cc b/libs/ardour/automation_list.cc index fa7854873c..1a3c1cc406 100644 --- a/libs/ardour/automation_list.cc +++ b/libs/ardour/automation_list.cc @@ -153,6 +153,7 @@ AutomationList::create_curve_if_necessary() { switch (_parameter.type()) { case GainAutomation: + case BusSendLevel: case TrimAutomation: case PanAzimuthAutomation: case PanElevationAutomation: diff --git a/libs/ardour/event_type_map.cc b/libs/ardour/event_type_map.cc index 17a1daef07..6b79c7825f 100644 --- a/libs/ardour/event_type_map.cc +++ b/libs/ardour/event_type_map.cc @@ -135,6 +135,8 @@ EventTypeMap::from_symbol(const string& str) const if (str == "gain") { p_type = GainAutomation; + } else if (str == "send") { + p_type = BusSendLevel; } else if (str == "trim") { p_type = TrimAutomation; } else if (str == "solo") { @@ -235,6 +237,8 @@ EventTypeMap::to_symbol(const Evoral::Parameter& param) const if (t == GainAutomation) { return "gain"; + } else if (t == BusSendLevel) { + return "send"; } else if (t == TrimAutomation) { return "trim"; } else if (t == PanAzimuthAutomation) { diff --git a/libs/ardour/gain_control.cc b/libs/ardour/gain_control.cc index 2e552813a9..370627b3ea 100644 --- a/libs/ardour/gain_control.cc +++ b/libs/ardour/gain_control.cc @@ -38,7 +38,7 @@ using namespace std; GainControl::GainControl (Session& session, const Evoral::Parameter ¶m, boost::shared_ptr<AutomationList> al) : SlavableAutomationControl (session, param, ParameterDescriptor(param), al ? al : boost::shared_ptr<AutomationList> (new AutomationList (param)), - param.type() == GainAutomation ? X_("gaincontrol") : X_("trimcontrol"), + (param.type() == GainAutomation || param.type() == BusSendLevel) ? X_("gaincontrol") : X_("trimcontrol"), Controllable::GainLike) { } diff --git a/libs/ardour/luabindings.cc b/libs/ardour/luabindings.cc index 691c32ddd3..73c503feb8 100644 --- a/libs/ardour/luabindings.cc +++ b/libs/ardour/luabindings.cc @@ -1865,6 +1865,7 @@ LuaBindings::common (lua_State* L) .beginNamespace ("AutomationType") .addConst ("GainAutomation", ARDOUR::AutomationType(GainAutomation)) + .addConst ("BusSendLevel", ARDOUR::AutomationType(BusSendLevel)) .addConst ("PluginAutomation", ARDOUR::AutomationType(PluginAutomation)) .addConst ("SoloAutomation", ARDOUR::AutomationType(SoloAutomation)) .addConst ("SoloIsolateAutomation", ARDOUR::AutomationType(SoloIsolateAutomation)) diff --git a/libs/ardour/parameter_descriptor.cc b/libs/ardour/parameter_descriptor.cc index 1269d69d1a..d959072fb5 100644 --- a/libs/ardour/parameter_descriptor.cc +++ b/libs/ardour/parameter_descriptor.cc @@ -195,7 +195,7 @@ ParameterDescriptor::update_steps() if (unit == ParameterDescriptor::MIDI_NOTE) { step = smallstep = 1; // semitone largestep = 12; // octave - } else if (type == GainAutomation || type == TrimAutomation) { + } else if (type == GainAutomation || type == TrimAutomation || type == BusSendLevel) { /* dB_coeff_step gives a step normalized for [0, max_gain]. This is like "slider position", so we convert from "slider position" to gain to have the correct unit here. */ diff --git a/libs/ardour/send.cc b/libs/ardour/send.cc index 950ee0b74d..78246eca82 100644 --- a/libs/ardour/send.cc +++ b/libs/ardour/send.cc @@ -101,7 +101,7 @@ Send::Send (Session& s, boost::shared_ptr<Pannable> p, boost::shared_ptr<MuteMas //boost_debug_shared_ptr_mark_interesting (this, "send"); boost::shared_ptr<AutomationList> gl (new AutomationList (Evoral::Parameter (GainAutomation))); - _gain_control = boost::shared_ptr<GainControl> (new GainControl (_session, Evoral::Parameter(GainAutomation), gl)); + _gain_control = boost::shared_ptr<GainControl> (new GainControl (_session, Evoral::Parameter(BusSendLevel), gl)); add_control (_gain_control); _amp.reset (new Amp (_session, _("Fader"), _gain_control, true)); |