Remove per-track mono option, as it seems somewhat useless now that we have a mix mono button in the monitor section.
git-svn-id: svn://localhost/ardour2/branches/3.0@8675 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
parent
04724c21b6
commit
1b0b7849ee
|
@ -1358,8 +1358,6 @@ MixerStrip::build_route_ops_menu ()
|
||||||
|
|
||||||
MenuList& items = route_ops_menu->items();
|
MenuList& items = route_ops_menu->items();
|
||||||
|
|
||||||
items.push_back (CheckMenuElem (_("Mono"), sigc::mem_fun (*this, &MixerStrip::toggle_mono)));
|
|
||||||
_mono_menu_item = dynamic_cast<CheckMenuItem*> (&items.back ());
|
|
||||||
items.push_back (CheckMenuElem (_("Comments..."), sigc::mem_fun (*this, &MixerStrip::toggle_comment)));
|
items.push_back (CheckMenuElem (_("Comments..."), sigc::mem_fun (*this, &MixerStrip::toggle_comment)));
|
||||||
_comment_menu_item = dynamic_cast<CheckMenuItem*> (&items.back ());
|
_comment_menu_item = dynamic_cast<CheckMenuItem*> (&items.back ());
|
||||||
items.push_back (MenuElem (_("Save As Template..."), sigc::mem_fun(*this, &RouteUI::save_as_template)));
|
items.push_back (MenuElem (_("Save As Template..."), sigc::mem_fun(*this, &RouteUI::save_as_template)));
|
||||||
|
@ -1893,12 +1891,6 @@ MixerStrip::on_leave_notify_event (GdkEventCrossing* ev)
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
|
||||||
MixerStrip::toggle_mono ()
|
|
||||||
{
|
|
||||||
panners.set_mono (_mono_menu_item->get_active ());
|
|
||||||
}
|
|
||||||
|
|
||||||
PluginSelector*
|
PluginSelector*
|
||||||
MixerStrip::plugin_selector()
|
MixerStrip::plugin_selector()
|
||||||
{
|
{
|
||||||
|
|
|
@ -191,7 +191,6 @@ class MixerStrip : public RouteUI, public Gtk::EventBox
|
||||||
void comment_editor_done_editing ();
|
void comment_editor_done_editing ();
|
||||||
void setup_comment_editor ();
|
void setup_comment_editor ();
|
||||||
void toggle_comment ();
|
void toggle_comment ();
|
||||||
void toggle_mono ();
|
|
||||||
|
|
||||||
Gtk::Button group_button;
|
Gtk::Button group_button;
|
||||||
Gtk::Label group_label;
|
Gtk::Label group_label;
|
||||||
|
@ -217,7 +216,6 @@ class MixerStrip : public RouteUI, public Gtk::EventBox
|
||||||
void diskstream_changed ();
|
void diskstream_changed ();
|
||||||
|
|
||||||
Gtk::Menu *send_action_menu;
|
Gtk::Menu *send_action_menu;
|
||||||
Gtk::CheckMenuItem* _mono_menu_item;
|
|
||||||
Gtk::CheckMenuItem* _comment_menu_item;
|
Gtk::CheckMenuItem* _comment_menu_item;
|
||||||
Gtk::MenuItem* rename_menu_item;
|
Gtk::MenuItem* rename_menu_item;
|
||||||
void build_send_action_menu ();
|
void build_send_action_menu ();
|
||||||
|
|
|
@ -424,7 +424,7 @@ PannerUI::effective_pan_display ()
|
||||||
void
|
void
|
||||||
PannerUI::update_pan_sensitive ()
|
PannerUI::update_pan_sensitive ()
|
||||||
{
|
{
|
||||||
bool const sensitive = !(_panner->is_mono()) && !(_panner->pannable()->automation_state() & Play);
|
bool const sensitive = !(_panner->pannable()->automation_state() & Play);
|
||||||
|
|
||||||
#ifdef PANNER_HACKS
|
#ifdef PANNER_HACKS
|
||||||
pan_vbox.set_sensitive (sensitive);
|
pan_vbox.set_sensitive (sensitive);
|
||||||
|
@ -584,13 +584,6 @@ PannerUI::_astyle_string (AutoStyle style, bool shrt)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
|
||||||
PannerUI::set_mono (bool yn)
|
|
||||||
{
|
|
||||||
_panner->set_mono (yn);
|
|
||||||
update_pan_sensitive ();
|
|
||||||
}
|
|
||||||
|
|
||||||
void
|
void
|
||||||
PannerUI::show_width ()
|
PannerUI::show_width ()
|
||||||
{
|
{
|
||||||
|
|
|
@ -79,7 +79,6 @@ class PannerUI : public Gtk::HBox, public ARDOUR::SessionHandlePtr
|
||||||
void set_meter_strip_name (std::string name);
|
void set_meter_strip_name (std::string name);
|
||||||
boost::shared_ptr<PBD::Controllable> get_controllable();
|
boost::shared_ptr<PBD::Controllable> get_controllable();
|
||||||
|
|
||||||
void set_mono (bool);
|
|
||||||
void on_size_allocate (Gtk::Allocation &);
|
void on_size_allocate (Gtk::Allocation &);
|
||||||
|
|
||||||
static void setup_slider_pix ();
|
static void setup_slider_pix ();
|
||||||
|
|
|
@ -83,9 +83,6 @@ class Panner : public PBD::Stateful, public PBD::ScopedConnectionList
|
||||||
virtual bool bypassed() const { return _bypassed; }
|
virtual bool bypassed() const { return _bypassed; }
|
||||||
virtual void set_bypassed (bool yn);
|
virtual void set_bypassed (bool yn);
|
||||||
|
|
||||||
virtual bool is_mono () const { return _mono; }
|
|
||||||
virtual void set_mono (bool);
|
|
||||||
|
|
||||||
void set_automation_state (AutoState);
|
void set_automation_state (AutoState);
|
||||||
AutoState automation_state() const;
|
AutoState automation_state() const;
|
||||||
void set_automation_style (AutoStyle);
|
void set_automation_style (AutoStyle);
|
||||||
|
@ -128,8 +125,7 @@ class Panner : public PBD::Stateful, public PBD::ScopedConnectionList
|
||||||
* @param nframes Number of frames in the input.
|
* @param nframes Number of frames in the input.
|
||||||
*
|
*
|
||||||
* Derived panners can choose to implement these if they need to gain more control over the panning algorithm.
|
* Derived panners can choose to implement these if they need to gain more control over the panning algorithm.
|
||||||
* the default is to (1) check if _mono is true, and if so, just deliver .. (2) otherwise, call
|
* the default is to call distribute_one() or distribute_one_automated() on each input buffer to deliver it to each output
|
||||||
* distribute_one() or distribute_one_automated() on each input buffer to deliver it to each output
|
|
||||||
* buffer.
|
* buffer.
|
||||||
*
|
*
|
||||||
* If a panner does not need to override this default behaviour, it can just implement
|
* If a panner does not need to override this default behaviour, it can just implement
|
||||||
|
@ -141,7 +137,7 @@ class Panner : public PBD::Stateful, public PBD::ScopedConnectionList
|
||||||
pan_t** buffers);
|
pan_t** buffers);
|
||||||
|
|
||||||
PBD::Signal0<void> Changed; /* for positional info */
|
PBD::Signal0<void> Changed; /* for positional info */
|
||||||
PBD::Signal0<void> StateChanged; /* for mute, mono */
|
PBD::Signal0<void> StateChanged; /* for mute */
|
||||||
|
|
||||||
int set_state (const XMLNode&, int version);
|
int set_state (const XMLNode&, int version);
|
||||||
virtual XMLNode& state (bool full_state) = 0;
|
virtual XMLNode& state (bool full_state) = 0;
|
||||||
|
@ -162,7 +158,6 @@ class Panner : public PBD::Stateful, public PBD::ScopedConnectionList
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
boost::shared_ptr<Pannable> _pannable;
|
boost::shared_ptr<Pannable> _pannable;
|
||||||
bool _mono;
|
|
||||||
bool _bypassed;
|
bool _bypassed;
|
||||||
|
|
||||||
XMLNode& get_state ();
|
XMLNode& get_state ();
|
||||||
|
|
|
@ -29,7 +29,6 @@ using namespace ARDOUR;
|
||||||
|
|
||||||
Panner::Panner (boost::shared_ptr<Pannable> p)
|
Panner::Panner (boost::shared_ptr<Pannable> p)
|
||||||
: _pannable (p)
|
: _pannable (p)
|
||||||
, _mono (0)
|
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -46,25 +45,12 @@ Panner::set_bypassed (bool yn)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
|
||||||
Panner::set_mono (bool yn)
|
|
||||||
{
|
|
||||||
if (yn != _mono) {
|
|
||||||
_mono = yn;
|
|
||||||
StateChanged ();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
int
|
int
|
||||||
Panner::set_state (const XMLNode& node, int version)
|
Panner::set_state (const XMLNode& node, int version)
|
||||||
{
|
{
|
||||||
const XMLProperty* prop;
|
const XMLProperty* prop;
|
||||||
XMLNodeConstIterator iter;
|
XMLNodeConstIterator iter;
|
||||||
|
|
||||||
if ((prop = node.property (X_("mono")))) {
|
|
||||||
set_mono (string_is_affirmative (prop->value()));
|
|
||||||
}
|
|
||||||
|
|
||||||
if ((prop = node.property (X_("bypassed"))) != 0) {
|
if ((prop = node.property (X_("bypassed"))) != 0) {
|
||||||
set_bypassed (string_is_affirmative (prop->value()));
|
set_bypassed (string_is_affirmative (prop->value()));
|
||||||
}
|
}
|
||||||
|
@ -77,7 +63,6 @@ Panner::get_state ()
|
||||||
{
|
{
|
||||||
XMLNode* node = new XMLNode (X_("Panner"));
|
XMLNode* node = new XMLNode (X_("Panner"));
|
||||||
|
|
||||||
node->add_property (X_("mono"), (_mono ? "yes" : "no"));
|
|
||||||
node->add_property (X_("bypassed"), (bypassed() ? "yes" : "no"));
|
node->add_property (X_("bypassed"), (bypassed() ? "yes" : "no"));
|
||||||
|
|
||||||
return *node;
|
return *node;
|
||||||
|
@ -89,15 +74,7 @@ Panner::distribute (BufferSet& ibufs, BufferSet& obufs, gain_t gain_coeff, pfram
|
||||||
uint32_t which = 0;
|
uint32_t which = 0;
|
||||||
|
|
||||||
for (BufferSet::audio_iterator src = ibufs.audio_begin(); src != ibufs.audio_end(); ++src, ++which) {
|
for (BufferSet::audio_iterator src = ibufs.audio_begin(); src != ibufs.audio_end(); ++src, ++which) {
|
||||||
if (_mono) {
|
distribute_one (*src, obufs, gain_coeff, nframes, which);
|
||||||
/* we're in mono mode, so just pan the input to all outputs equally (XXX should we scale?) */
|
|
||||||
for (BufferSet::audio_iterator o = obufs.audio_begin(); o != obufs.audio_end(); ++o) {
|
|
||||||
mix_buffers_with_gain ((*o).data(), (*src).data(), nframes, gain_coeff);
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
/* normal mode, call the `real' distribute method */
|
|
||||||
distribute_one (*src, obufs, gain_coeff, nframes, which);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -108,15 +85,7 @@ Panner::distribute_automated (BufferSet& ibufs, BufferSet& obufs,
|
||||||
uint32_t which = 0;
|
uint32_t which = 0;
|
||||||
|
|
||||||
for (BufferSet::audio_iterator src = ibufs.audio_begin(); src != ibufs.audio_end(); ++src, ++which) {
|
for (BufferSet::audio_iterator src = ibufs.audio_begin(); src != ibufs.audio_end(); ++src, ++which) {
|
||||||
if (_mono) {
|
distribute_one_automated (*src, obufs, start, end, nframes, buffers, which);
|
||||||
/* we're in mono mode, so just pan the input to all outputs equally (XXX should we scale?) */
|
|
||||||
for (BufferSet::audio_iterator o = obufs.audio_begin(); o != obufs.audio_end(); ++o) {
|
|
||||||
mix_buffers_with_gain ((*o).data(), (*src).data(), nframes, 1.0);
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
/* normal mode, call the `real' distribute method */
|
|
||||||
distribute_one_automated (*src, obufs, start, end, nframes, buffers, which);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user