diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2012-06-09 19:06:52 +0000 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2012-06-09 19:06:52 +0000 |
commit | 71427323ec851ee6271dcc93f26dfc3bc0a51b1f (patch) | |
tree | 5ebdec0eacb93ae391e247105a50c6ac8a897dcc /libs/surfaces/mackie/device_info.cc | |
parent | 94b6c7626c6e2b7ceda1ba1302aae2d10fd19e28 (diff) |
MCP: latest patch from Rodrigo:
* fixes Master Fader Touch button in the Mackie;
* implements a MasterFaderTouch global button;
* removes unused MackieControlProtocol::_transport_previously_rolling property;
* implements DeviceInfo::get_global_button() method;
* creates GlobalButtonsInfo and StripButtonsInfo types in DeviceInfo;
* implements Surface::_last_master_gain_written property to help master fader feedback;
* makes Surface respect _mcp.device_info().strip_cnt() to create master fader and when connecting signals for strips and master fader instead of using hardcoded 8;
* removed a few unnecessary updates in Surface::turn_it_on();
* included master_gain_changed() in Surface::periodic();
* implemented MackieControlProtocol::master_fader_touch_press and
* MackieControlProtocol::master_fader_touch_release;
git-svn-id: svn://localhost/ardour2/branches/3.0@12631 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/surfaces/mackie/device_info.cc')
-rw-r--r-- | libs/surfaces/mackie/device_info.cc | 18 |
1 files changed, 15 insertions, 3 deletions
diff --git a/libs/surfaces/mackie/device_info.cc b/libs/surfaces/mackie/device_info.cc index f12a467101..e8ec0af5dc 100644 --- a/libs/surfaces/mackie/device_info.cc +++ b/libs/surfaces/mackie/device_info.cc @@ -61,10 +61,20 @@ DeviceInfo::~DeviceInfo() { } +GlobalButtonInfo& +DeviceInfo::get_global_button(Button::ID id) +{ + GlobalButtonsInfo::iterator it; + + it = _global_buttons.find (id); + + return it->second; +} + std::string& DeviceInfo::get_global_button_name(Button::ID id) { - std::map<Button::ID,GlobalButtonInfo>::iterator it; + GlobalButtonsInfo::iterator it; it = _global_buttons.find (id); if (it == _global_buttons.end ()) { @@ -89,7 +99,6 @@ DeviceInfo::mackie_control_buttons () //TODO controller position value (0x00 to 0x7f) _strip_buttons[Button::RecEnable] = StripButtonInfo (0x0, "Rec"); - _strip_buttons[Button::FaderTouch] = StripButtonInfo (0xe0, "Fader Touch"); } void @@ -102,7 +111,6 @@ DeviceInfo::logic_control_buttons () _global_buttons[Button::UserB] = GlobalButtonInfo ("User Switch B", "user", 0x67); _strip_buttons[Button::RecEnable] = StripButtonInfo (0x0, "Rec/Rdy"); - _strip_buttons[Button::FaderTouch] = StripButtonInfo (0x68, "Fader Touch"); } void @@ -185,6 +193,10 @@ DeviceInfo::shared_buttons () _strip_buttons[Button::Mute] = StripButtonInfo (0x10, "Mute"); _strip_buttons[Button::Select] = StripButtonInfo (0x18, "Select"); _strip_buttons[Button::VSelect] = StripButtonInfo (0x20, "V-Select"); + + _strip_buttons[Button::FaderTouch] = StripButtonInfo (0x68, "Fader Touch"); + + _global_buttons[Button::MasterFaderTouch] = GlobalButtonInfo ("Master Fader Touch", "master", 0x70); } int |