From 398a1efbd5cff9bb4c845935df8dab59529edc25 Mon Sep 17 00:00:00 2001 From: Ben Loftis Date: Tue, 3 Aug 2021 10:37:32 -0500 Subject: [PATCH] US2400: Fix send levels from joystick ("surround pan" on mixbuses 11,12) (Mixbus32C only) --- libs/surfaces/us2400/surface.cc | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/libs/surfaces/us2400/surface.cc b/libs/surfaces/us2400/surface.cc index 2f55c30d55..a2015d0935 100644 --- a/libs/surfaces/us2400/surface.cc +++ b/libs/surfaces/us2400/surface.cc @@ -29,6 +29,7 @@ #include "ardour/audioengine.h" #include "ardour/automation_control.h" +#include "ardour/dB.h" #include "ardour/debug.h" #include "ardour/route.h" #include "ardour/panner.h" @@ -627,11 +628,11 @@ Surface::handle_midi_controller_message (MIDI::Parser &, MIDI::EventTwoBytes* ev if (r && r->is_input_strip()) { boost::shared_ptr pc = r->send_level_controllable (10); if (pc) { - pc->set_value (-db_value , PBD::Controllable::NoGroup); + pc->set_value (dB_to_coefficient(-db_value) , PBD::Controllable::NoGroup); } pc = r->send_level_controllable (11); if (pc) { - pc->set_value (-inv_db, PBD::Controllable::NoGroup); + pc->set_value (dB_to_coefficient(-inv_db), PBD::Controllable::NoGroup); } } }