MCU: Update view modes for Cue, Foldback, and VCA
This changes the function of the Inputs, Instruments, and Outputs buttons as follows: Inputs = Cue Tracks Instruments = VCA Outputs = Foldback Busses
This commit is contained in:
parent
cc359b973f
commit
0b50bec6f4
|
@ -65,6 +65,7 @@
|
||||||
#include "ardour/track.h"
|
#include "ardour/track.h"
|
||||||
#include "ardour/types.h"
|
#include "ardour/types.h"
|
||||||
#include "ardour/audioengine.h"
|
#include "ardour/audioengine.h"
|
||||||
|
#include "ardour/vca.h"
|
||||||
#include "ardour/vca_manager.h"
|
#include "ardour/vca_manager.h"
|
||||||
|
|
||||||
#include "temporal/tempo.h"
|
#include "temporal/tempo.h"
|
||||||
|
@ -281,7 +282,7 @@ MackieControlProtocol::get_sorted_stripables()
|
||||||
// fetch all stripables
|
// fetch all stripables
|
||||||
StripableList stripables;
|
StripableList stripables;
|
||||||
|
|
||||||
session->get_stripables (stripables);
|
session->get_stripables (stripables, PresentationInfo::AllStripables);
|
||||||
|
|
||||||
// sort in presentation order, and exclude master, control and hidden stripables
|
// sort in presentation order, and exclude master, control and hidden stripables
|
||||||
// and any stripables that are already set.
|
// and any stripables that are already set.
|
||||||
|
@ -319,7 +320,7 @@ MackieControlProtocol::get_sorted_stripables()
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
} else {
|
} else {
|
||||||
if (!is_track(s) && !s->presentation_info().hidden()) {
|
if (!is_track (s) && !is_vca (s) && !is_foldback_bus (s) && !s->presentation_info().hidden()) {
|
||||||
sorted.push_back (s);
|
sorted.push_back (s);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -331,17 +332,16 @@ MackieControlProtocol::get_sorted_stripables()
|
||||||
break;
|
break;
|
||||||
case Auxes: // in ardour, for now aux and buss are same. for mixbus, "Busses" are mixbuses, "Auxes" are ardour buses
|
case Auxes: // in ardour, for now aux and buss are same. for mixbus, "Busses" are mixbuses, "Auxes" are ardour buses
|
||||||
#ifdef MIXBUS
|
#ifdef MIXBUS
|
||||||
if (!s->mixbus() && !is_track(s) && !s->presentation_info().hidden())
|
if (!s->mixbus() && !is_track(s) && !is_vca (s) && !is_foldback_bus (s) && !s->presentation_info().hidden())
|
||||||
#else
|
#else
|
||||||
if (!is_track(s) && !s->presentation_info().hidden())
|
if (!is_track (s) && !is_vca (s) && !is_foldback_bus (s) && !s->presentation_info().hidden())
|
||||||
#endif
|
#endif
|
||||||
{
|
{
|
||||||
sorted.push_back (s);
|
sorted.push_back (s);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case Outputs: // Show all the tracks we have hidden
|
case Outputs:
|
||||||
if (s->presentation_info().hidden()) {
|
if (is_foldback_bus (s) && !s->presentation_info().hidden()) {
|
||||||
// maybe separate groups
|
|
||||||
sorted.push_back (s);
|
sorted.push_back (s);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
@ -351,12 +351,14 @@ MackieControlProtocol::get_sorted_stripables()
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case AudioInstr:
|
case AudioInstr:
|
||||||
if (has_instrument (s)){
|
if (is_vca (s)){
|
||||||
sorted.push_back (s);
|
sorted.push_back (s);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case Inputs:
|
case Inputs:
|
||||||
// nothing to do right now
|
if (is_trigger_track (s) && !s->presentation_info().hidden()){
|
||||||
|
sorted.push_back (s);
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -2362,6 +2364,25 @@ MackieControlProtocol::is_midi_track (boost::shared_ptr<Stripable> r) const
|
||||||
return boost::dynamic_pointer_cast<MidiTrack>(r) != 0;
|
return boost::dynamic_pointer_cast<MidiTrack>(r) != 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool
|
||||||
|
MackieControlProtocol::is_trigger_track (boost::shared_ptr<Stripable> r) const
|
||||||
|
{
|
||||||
|
boost::shared_ptr<Track> trk = boost::dynamic_pointer_cast<Track>(r);
|
||||||
|
return (trk && (r)->presentation_info ().trigger_track ());
|
||||||
|
}
|
||||||
|
|
||||||
|
bool
|
||||||
|
MackieControlProtocol::is_foldback_bus (boost::shared_ptr<Stripable> r) const
|
||||||
|
{
|
||||||
|
return ((r)->presentation_info ().flags () & PresentationInfo::FoldbackBus);
|
||||||
|
}
|
||||||
|
|
||||||
|
bool
|
||||||
|
MackieControlProtocol::is_vca (boost::shared_ptr<Stripable> r) const
|
||||||
|
{
|
||||||
|
return boost::dynamic_pointer_cast<VCA>(r) != 0;
|
||||||
|
}
|
||||||
|
|
||||||
bool
|
bool
|
||||||
MackieControlProtocol::has_instrument (boost::shared_ptr<Stripable> r) const
|
MackieControlProtocol::has_instrument (boost::shared_ptr<Stripable> r) const
|
||||||
{
|
{
|
||||||
|
|
|
@ -135,6 +135,9 @@ class MackieControlProtocol
|
||||||
bool is_track (boost::shared_ptr<ARDOUR::Stripable>) const;
|
bool is_track (boost::shared_ptr<ARDOUR::Stripable>) const;
|
||||||
bool is_audio_track (boost::shared_ptr<ARDOUR::Stripable>) const;
|
bool is_audio_track (boost::shared_ptr<ARDOUR::Stripable>) const;
|
||||||
bool is_midi_track (boost::shared_ptr<ARDOUR::Stripable>) const;
|
bool is_midi_track (boost::shared_ptr<ARDOUR::Stripable>) const;
|
||||||
|
bool is_trigger_track (boost::shared_ptr<ARDOUR::Stripable>) const;
|
||||||
|
bool is_foldback_bus (boost::shared_ptr<ARDOUR::Stripable>) const;
|
||||||
|
bool is_vca (boost::shared_ptr<ARDOUR::Stripable>) const;
|
||||||
bool has_instrument (boost::shared_ptr<ARDOUR::Stripable>) const;
|
bool has_instrument (boost::shared_ptr<ARDOUR::Stripable>) const;
|
||||||
bool is_mapped (boost::shared_ptr<ARDOUR::Stripable>) const;
|
bool is_mapped (boost::shared_ptr<ARDOUR::Stripable>) const;
|
||||||
boost::shared_ptr<ARDOUR::Stripable> first_selected_stripable () const;
|
boost::shared_ptr<ARDOUR::Stripable> first_selected_stripable () const;
|
||||||
|
|
|
@ -1050,14 +1050,12 @@ MackieControlProtocol::miditracks_release (Mackie::Button&)
|
||||||
Mackie::LedState
|
Mackie::LedState
|
||||||
MackieControlProtocol::inputs_press (Mackie::Button&)
|
MackieControlProtocol::inputs_press (Mackie::Button&)
|
||||||
{
|
{
|
||||||
#ifdef MIXBUS
|
|
||||||
set_view_mode (Mixer); //in Mixbus, this is the same as Global View (avoid dead buttons)
|
|
||||||
#endif
|
|
||||||
return none;
|
return none;
|
||||||
}
|
}
|
||||||
Mackie::LedState
|
Mackie::LedState
|
||||||
MackieControlProtocol::inputs_release (Mackie::Button&)
|
MackieControlProtocol::inputs_release (Mackie::Button&)
|
||||||
{
|
{
|
||||||
|
set_view_mode (Inputs);
|
||||||
return none;
|
return none;
|
||||||
}
|
}
|
||||||
Mackie::LedState
|
Mackie::LedState
|
||||||
|
@ -1074,18 +1072,13 @@ MackieControlProtocol::audiotracks_release (Mackie::Button&)
|
||||||
Mackie::LedState
|
Mackie::LedState
|
||||||
MackieControlProtocol::audioinstruments_press (Mackie::Button& b)
|
MackieControlProtocol::audioinstruments_press (Mackie::Button& b)
|
||||||
{
|
{
|
||||||
#ifdef MIXBUS
|
|
||||||
set_view_mode (MidiTracks); //in Mixbus, we do the same thing as MIDI Tracks ( aviod dead buttons )
|
|
||||||
#endif
|
|
||||||
return none;
|
return none;
|
||||||
}
|
}
|
||||||
|
|
||||||
Mackie::LedState
|
Mackie::LedState
|
||||||
MackieControlProtocol::audioinstruments_release (Mackie::Button& b)
|
MackieControlProtocol::audioinstruments_release (Mackie::Button& b)
|
||||||
{
|
{
|
||||||
#ifndef MIXBUS
|
|
||||||
set_view_mode (AudioInstr);
|
set_view_mode (AudioInstr);
|
||||||
#endif
|
|
||||||
return none;
|
return none;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1356,9 +1356,9 @@ Surface::update_view_mode_display (bool with_helpful_text)
|
||||||
text = _("Auxes");
|
text = _("Auxes");
|
||||||
break;
|
break;
|
||||||
case MackieControlProtocol::Outputs:
|
case MackieControlProtocol::Outputs:
|
||||||
show_two_char_display ("HI");
|
show_two_char_display ("Fb");
|
||||||
id = Button::Outputs;
|
id = Button::Outputs;
|
||||||
text = _("Hidden Tracks");
|
text = _("Foldback Busses");
|
||||||
break;
|
break;
|
||||||
case MackieControlProtocol::Selected:
|
case MackieControlProtocol::Selected:
|
||||||
show_two_char_display ("SE");
|
show_two_char_display ("SE");
|
||||||
|
@ -1368,7 +1368,12 @@ Surface::update_view_mode_display (bool with_helpful_text)
|
||||||
case MackieControlProtocol::AudioInstr:
|
case MackieControlProtocol::AudioInstr:
|
||||||
show_two_char_display ("IS");
|
show_two_char_display ("IS");
|
||||||
id = Button::AudioInstruments;
|
id = Button::AudioInstruments;
|
||||||
text = _("Instruments");
|
text = _("VCAs");
|
||||||
|
break;
|
||||||
|
case MackieControlProtocol::Inputs:
|
||||||
|
show_two_char_display ("CU");
|
||||||
|
id = Button::Inputs;
|
||||||
|
text = _("Cue Tracks");
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Reference in New Issue