diff --git a/gtk2_ardour/add_route_dialog.cc b/gtk2_ardour/add_route_dialog.cc
index e0e5c70798..8837e9f468 100644
--- a/gtk2_ardour/add_route_dialog.cc
+++ b/gtk2_ardour/add_route_dialog.cc
@@ -56,6 +56,7 @@ AddRouteDialog::AddRouteDialog ()
, configuration_label (_("Configuration:"))
, mode_label (_("Track mode:"))
, instrument_label (_("Instrument:"))
+ , reasonable_synth_id(0)
{
set_name ("AddRouteDialog");
set_modal (true);
@@ -82,7 +83,7 @@ AddRouteDialog::AddRouteDialog ()
build_instrument_list ();
instrument_combo.set_model (instrument_list);
instrument_combo.pack_start (instrument_list_columns.name);
- instrument_combo.set_active (0);
+ instrument_combo.set_active (reasonable_synth_id);
instrument_combo.set_button_sensitivity (Gtk::SENSITIVITY_AUTO);
VBox* vbox = manage (new VBox);
@@ -587,6 +588,7 @@ AddRouteDialog::build_instrument_list ()
row[instrument_list_columns.info_ptr] = PluginInfoPtr ();
row[instrument_list_columns.name] = _("-none-");
+ uint32_t n = 1;
for (PluginInfoList::const_iterator i = all_plugs.begin(); i != all_plugs.end(); ++i) {
if (manager.get_status (*i) == PluginManager::Hidden) continue;
@@ -595,6 +597,10 @@ AddRouteDialog::build_instrument_list ()
row = *(instrument_list->append());
row[instrument_list_columns.name] = (*i)->name;
row[instrument_list_columns.info_ptr] = *i;
+ if ((*i)->unique_id == "https://community.ardour.org/node/7596") {
+ reasonable_synth_id = n;
+ }
+ n++;
}
}
}
diff --git a/gtk2_ardour/add_route_dialog.h b/gtk2_ardour/add_route_dialog.h
index 31b746ac76..7cd3307d48 100644
--- a/gtk2_ardour/add_route_dialog.h
+++ b/gtk2_ardour/add_route_dialog.h
@@ -122,6 +122,7 @@ class AddRouteDialog : public ArdourDialog
InstrumentListColumns instrument_list_columns;
void build_instrument_list ();
+ uint32_t reasonable_synth_id;
};
#endif /* __gtk_ardour_add_route_dialog_h__ */
diff --git a/gtk2_ardour/ardour3_styles.rc.in b/gtk2_ardour/ardour3_styles.rc.in
index 8b5b5e4c99..8314e9dc36 100644
--- a/gtk2_ardour/ardour3_styles.rc.in
+++ b/gtk2_ardour/ardour3_styles.rc.in
@@ -731,6 +731,19 @@ style "midi_track_base" = "default"
bg[SELECTED] = @@COLPREFIX@_bg
}
+style "audio_track_fader" = "gain_fader"
+{
+ bg[PRELIGHT] = @@COLPREFIX@_audio_track
+}
+style "audio_bus_fader" = "gain_fader"
+{
+ bg[PRELIGHT] = @@COLPREFIX@_audio_bus
+}
+style "midi_track_fader" = "gain_fader"
+{
+ bg[PRELIGHT] = @@COLPREFIX@_midi_track
+}
+
style "audio_track_metrics" = "audio_track_base"
{
font_name = "@FONT_TINY@"
@@ -815,7 +828,9 @@ style "plugin_slider"
bg[ACTIVE] = shade (0.6, @@COLPREFIX@_lightest)
bg[INSENSITIVE] = shade (0.6, @@COLPREFIX@_lightest)
bg[SELECTED] = shade (0.6, @@COLPREFIX@_lightest)
- bg[PRELIGHT] = shade (0.6, @@COLPREFIX@_lightest)
+
+ # outer round-corner-background (pixslider does its own hover prelight)
+ bg[PRELIGHT] = @@COLPREFIX@_bg
# the numeric display
@@ -826,6 +841,16 @@ style "plugin_slider"
text[PRELIGHT] = @@COLPREFIX@_text
}
+style "processor_control_button" = "very_small_text"
+{
+}
+
+style "processor_control_slider" = "plugin_slider"
+{
+ bg[PRELIGHT] = @@COLPREFIX@_darkest
+ bg[NORMAL] = @@COLPREFIX@_bg
+}
+
style "track_list_display" = "small_bold_text"
{
text[NORMAL] = @@COLPREFIX@_text
diff --git a/gtk2_ardour/ardour3_ui_default.conf b/gtk2_ardour/ardour3_ui_default.conf
index 619874982d..371ea9a731 100644
--- a/gtk2_ardour/ardour3_ui_default.conf
+++ b/gtk2_ardour/ardour3_ui_default.conf
@@ -187,12 +187,12 @@
-
-
-
-
-
-
+
+
+
+
+
+
diff --git a/gtk2_ardour/ardour3_widget_list.rc b/gtk2_ardour/ardour3_widget_list.rc
index 0e7075cef4..582871d87f 100644
--- a/gtk2_ardour/ardour3_widget_list.rc
+++ b/gtk2_ardour/ardour3_widget_list.rc
@@ -186,9 +186,13 @@ widget "*AudioMidiTrackMetricsInactive" style:highest "midi_track_metrics_inacti
widget "*TimeAxisViewControlsBaseUnselected" style:highest "audio_track_base"
widget "*AudioTrackControlsBaseUnselected" style:highest "audio_track_base"
widget "*MidiTrackControlsBaseUnselected" style:highest "midi_track_base"
-widget "*AudioTrackFader" style:highest "gain_fader"
-widget "*MidiTrackFader" style:highest "gain_fader"
-widget "*AudioBusFader" style:highest "gain_fader"
+
+widget "*SendUIFader" style:highest "plugin_slider"
+widget "*ReturnUIFader" style:highest "plugin_slider"
+
+widget "*AudioTrackFader" style:highest "audio_track_fader"
+widget "*MidiTrackFader" style:highest "midi_track_fader"
+widget "*AudioBusFader" style:highest "audio_bus_fader"
widget "*BusControlsBaseUnselected" style:highest "audio_bus_base"
widget "*TrackSeparator" style:highest "track_separator"
@@ -234,6 +238,8 @@ widget "*MotionControllerValue*" style:highest "small_entry"
widget "*ParameterValueDisplay" style:highest "medium_bold_entry"
widget "*PluginUIClickBox" style:highest "medium_bold_entry"
widget "*PluginUIClickBox*" style:highest "medium_bold_entry"
+widget "*ProcessorControlSlider" style:highest "processor_control_slider"
+widget "*processor control button" style:highest "processor_control_button"
widget "*PluginSlider" style:highest "plugin_slider"
widget "*GainFader" style:highest "plugin_slider"
widget "*MixerTrackCommentArea" style:highest "option_entry"
diff --git a/gtk2_ardour/ardour_button.cc b/gtk2_ardour/ardour_button.cc
index 3f118921d6..f1f45e90c3 100644
--- a/gtk2_ardour/ardour_button.cc
+++ b/gtk2_ardour/ardour_button.cc
@@ -302,6 +302,9 @@ ArdourButton::render (cairo_t* cr)
}
if ( ((_elements & Text)==Text) && !_text.empty()) {
+ cairo_save (cr);
+ cairo_rectangle (cr, 2, 1, get_width()-4, get_height()-2);
+ cairo_clip(cr);
cairo_new_path (cr);
cairo_set_source_rgba (cr, text_r, text_g, text_b, text_a);
@@ -342,7 +345,7 @@ ArdourButton::render (cairo_t* cr)
/* use old center'ed layout for follow up items - until rotation/aligment code is completed */
cairo_move_to (cr, (get_width() - _text_width)/2.0, get_height()/2.0 - _text_height/2.0);
}
-
+ cairo_restore (cr);
}
if (((_elements & Indicator)==Indicator)) {
@@ -472,6 +475,7 @@ ArdourButton::on_size_request (Gtk::Requisition* req)
req->height = _text_height + ypad;
}
}
+ req->width += _corner_radius;
}
void
diff --git a/gtk2_ardour/editor_mixer.cc b/gtk2_ardour/editor_mixer.cc
index 128767fa9b..67e749de50 100644
--- a/gtk2_ardour/editor_mixer.cc
+++ b/gtk2_ardour/editor_mixer.cc
@@ -133,17 +133,19 @@ Editor::show_editor_mixer (bool yn)
if (current_mixer_strip == 0) {
create_editor_mixer ();
}
-
- current_mixer_strip->set_route (r);
- current_mixer_strip->set_width_enum (editor_mixer_strip_width, (void*) this);
}
- if (current_mixer_strip->get_parent() == 0) {
+ if (current_mixer_strip && current_mixer_strip->get_parent() == 0) {
global_hpacker.pack_start (*current_mixer_strip, Gtk::PACK_SHRINK );
global_hpacker.reorder_child (*current_mixer_strip, 0);
current_mixer_strip->show ();
}
+ if (r) {
+ current_mixer_strip->set_route (r);
+ current_mixer_strip->set_width_enum (editor_mixer_strip_width, (void*) this);
+ }
+
} else {
if (current_mixer_strip) {
diff --git a/gtk2_ardour/processor_box.cc b/gtk2_ardour/processor_box.cc
index 08079f4f91..daab501daa 100644
--- a/gtk2_ardour/processor_box.cc
+++ b/gtk2_ardour/processor_box.cc
@@ -38,6 +38,7 @@
#include
#include
#include
+#include
#include "ardour/amp.h"
#include "ardour/audio_track.h"
@@ -91,6 +92,9 @@ RefPtr ProcessorBox::rename_action;
RefPtr ProcessorBox::edit_action;
RefPtr ProcessorBox::edit_generic_action;
+static const uint32_t audio_port_color = 0x4A8A0EFF; // Green
+static const uint32_t midi_port_color = 0x960909FF; //Red
+
ProcessorEntry::ProcessorEntry (ProcessorBox* parent, boost::shared_ptr p, Width w)
: _button (ArdourButton::led_default_elements)
, _position (PreFader)
@@ -98,6 +102,8 @@ ProcessorEntry::ProcessorEntry (ProcessorBox* parent, boost::shared_ptractive());
+
+ _routing_icon.set_no_show_all(true);
+ _input_icon.set_no_show_all(true);
+
_button.show ();
+ _routing_icon.set_visible(false);
+ _input_icon.hide();
+ _output_icon.show();
_processor->ActiveChanged.connect (active_connection, invalidator (*this), boost::bind (&ProcessorEntry::processor_active_changed, this), gui_context());
_processor->PropertyChanged.connect (name_connection, invalidator (*this), boost::bind (&ProcessorEntry::processor_property_changed, this, _1), gui_context());
+ _processor->ConfigurationChanged.connect (config_connection, invalidator (*this), boost::bind (&ProcessorEntry::processor_configuration_changed, this, _1, _2), gui_context());
set p = _processor->what_can_be_automated ();
for (set::iterator i = p.begin(); i != p.end(); ++i) {
- Control* c = new Control (_processor->automation_control (*i), _processor->describe_parameter (*i));
+ std::string label = _processor->describe_parameter (*i);
+
+ if (boost::dynamic_pointer_cast (_processor)) {
+ label = _("Send");
+ } else if (boost::dynamic_pointer_cast (_processor)) {
+ label = _("Return");
+ }
+
+ Control* c = new Control (_processor->automation_control (*i), label);
_controls.push_back (c);
@@ -128,13 +153,14 @@ ProcessorEntry::ProcessorEntry (ProcessorBox* parent, boost::shared_ptrbox);
}
-
- if (boost::dynamic_pointer_cast (_processor)) {
- /* Don't label send faders */
- c->hide_label ();
- }
}
+ _input_icon.set_ports(_processor->input_streams());
+ _output_icon.set_ports(_processor->output_streams());
+
+ _routing_icon.set_sources(_processor->input_streams());
+ _routing_icon.set_sinks(_processor->output_streams());
+
setup_tooltip ();
setup_visuals ();
} else {
@@ -168,9 +194,17 @@ ProcessorEntry::drag_text () const
}
void
-ProcessorEntry::set_position (Position p)
+ProcessorEntry::set_position (Position p, uint32_t num)
{
_position = p;
+ _position_num = num;
+
+ if (_position_num == 0 || _routing_icon.get_visible()) {
+ _input_icon.show();
+ } else {
+ _input_icon.hide();
+ }
+
setup_visuals ();
}
@@ -245,6 +279,18 @@ ProcessorEntry::processor_property_changed (const PropertyChange& what_changed)
}
}
+void
+ProcessorEntry::processor_configuration_changed (const ChanCount in, const ChanCount out)
+{
+ _input_icon.set_ports(in);
+ _output_icon.set_ports(out);
+ _routing_icon.set_sources(in);
+ _routing_icon.set_sinks(out);
+ _input_icon.queue_draw();
+ _output_icon.queue_draw();
+ _routing_icon.queue_draw();
+}
+
void
ProcessorEntry::setup_tooltip ()
{
@@ -402,18 +448,19 @@ ProcessorEntry::Control::Control (boost::shared_ptr c, string
, _adjustment (gain_to_slider_position_with_max (1.0, Config->get_max_gain()), 0, 1, 0.01, 0.1)
, _slider (&_adjustment, 0, 13, false)
, _slider_persistant_tooltip (&_slider)
- , _button (ArdourButton::Element (ArdourButton::Text | ArdourButton::Indicator))
+ , _button (ArdourButton::led_default_elements)
, _ignore_ui_adjustment (false)
, _visible (false)
, _name (n)
{
_slider.set_controllable (c);
+ box.set_padding(0, 0, 4, 4);
if (c->toggled()) {
_button.set_text (_name);
_button.set_led_left (true);
_button.set_name ("processor control button");
- box.pack_start (_button);
+ box.add (_button);
_button.show ();
_button.signal_clicked.connect (sigc::mem_fun (*this, &Control::button_clicked));
@@ -422,10 +469,10 @@ ProcessorEntry::Control::Control (boost::shared_ptr c, string
} else {
- _slider.set_name ("PluginSlider");
+ _slider.set_name ("ProcessorControlSlider");
_slider.set_text (_name);
- box.pack_start (_slider);
+ box.add (_slider);
_slider.show ();
double const lo = c->internal_to_interface (c->lower ());
@@ -470,7 +517,6 @@ ProcessorEntry::Control::set_tooltip ()
string sm = Glib::Markup::escape_text (s.str());
- ARDOUR_UI::instance()->set_tip (_label, sm);
_slider_persistant_tooltip.set_tip (sm);
ARDOUR_UI::instance()->set_tip (_button, sm);
}
@@ -505,6 +551,7 @@ ProcessorEntry::Control::button_clicked ()
c->set_value (n ? 0 : 1);
_button.set_active (!n);
+ set_tooltip ();
}
void
@@ -578,12 +625,6 @@ ProcessorEntry::Control::hide_things ()
}
}
-void
-ProcessorEntry::Control::hide_label ()
-{
- _label.hide ();
-}
-
string
ProcessorEntry::Control::state_id () const
{
@@ -593,11 +634,6 @@ ProcessorEntry::Control::state_id () const
return string_compose (X_("control %1"), c->id().to_s ());
}
-BlankProcessorEntry::BlankProcessorEntry (ProcessorBox* b, Width w)
- : ProcessorEntry (b, boost::shared_ptr(), w)
-{
-}
-
PluginInsertProcessorEntry::PluginInsertProcessorEntry (ProcessorBox* b, boost::shared_ptr p, Width w)
: ProcessorEntry (b, p, w)
, _plugin_insert (p)
@@ -606,31 +642,52 @@ PluginInsertProcessorEntry::PluginInsertProcessorEntry (ProcessorBox* b, boost::
_splitting_connection, invalidator (*this), boost::bind (&PluginInsertProcessorEntry::plugin_insert_splitting_changed, this), gui_context()
);
- _splitting_icon.set_size_request (-1, 12);
-
- _vbox.pack_start (_splitting_icon);
- _vbox.reorder_child (_splitting_icon, 0);
-
plugin_insert_splitting_changed ();
}
void
PluginInsertProcessorEntry::plugin_insert_splitting_changed ()
{
- _splitting_icon.set_inputs(_plugin_insert->input_streams());
- _splitting_icon.set_outputs(_plugin_insert->output_streams());
+ _output_icon.set_ports(_plugin_insert->output_streams());
+ _routing_icon.set_splitting(_plugin_insert->splitting ());
- if (_plugin_insert->splitting () || (
- _plugin_insert->input_streams().n_midi() == 0
- && _plugin_insert->input_streams().n_audio() < _plugin_insert->output_streams().n_audio()
- )
+ ChanCount sources = _plugin_insert->input_streams();
+ ChanCount sinks = _plugin_insert->natural_input_streams();
+
+ /* replicated instances */
+ if (!_plugin_insert->splitting () && _plugin_insert->get_count() > 1) {
+ for (DataType::iterator t = DataType::begin(); t != DataType::end(); ++t) {
+ sinks.set(*t, sinks.get(*t) * _plugin_insert->get_count());
+ }
+ }
+ /* MIDI bypass */
+ if (_plugin_insert->natural_output_streams().n_midi() == 0 &&
+ _plugin_insert->output_streams().n_midi() == 1) {
+ sinks.set(DataType::MIDI, 1);
+ sources.set(DataType::MIDI, 1);
+ }
+
+ _input_icon.set_ports(sinks);
+ _routing_icon.set_sinks(sinks);
+ _routing_icon.set_sources(sources);
+
+ if (_plugin_insert->splitting () ||
+ _plugin_insert->input_streams().n_audio() < _plugin_insert->natural_input_streams().n_audio()
)
{
- _splitting_icon.show ();
- _splitting_icon.queue_draw();
+ _routing_icon.set_size_request (-1, 7);
+ _routing_icon.set_visible(true);
+ _input_icon.show();
} else {
- _splitting_icon.hide ();
+ _routing_icon.set_visible(false);
+ if (_position_num != 0) {
+ _input_icon.hide();
+ }
}
+
+ _input_icon.queue_draw();
+ _output_icon.queue_draw();
+ _routing_icon.queue_draw();
}
void
@@ -640,35 +697,78 @@ PluginInsertProcessorEntry::hide_things ()
plugin_insert_splitting_changed ();
}
-void
-PluginInsertProcessorEntry::setup_visuals ()
-{
- switch (_position) {
- case PreFader:
- _splitting_icon.set_name ("ProcessorPreFader");
- break;
-
- case Fader:
- _splitting_icon.set_name ("ProcessorFader");
- break;
-
- case PostFader:
- _splitting_icon.set_name ("ProcessorPostFader");
- break;
- }
-
- ProcessorEntry::setup_visuals ();
-}
bool
-PluginInsertProcessorEntry::SplittingIcon::on_expose_event (GdkEventExpose* ev)
+ProcessorEntry::PortIcon::on_expose_event (GdkEventExpose* ev)
{
cairo_t* cr = gdk_cairo_create (get_window()->gobj());
cairo_rectangle (cr, ev->area.x, ev->area.y, ev->area.width, ev->area.height);
cairo_clip (cr);
- cairo_set_line_width (cr, 1.5);
+ cairo_set_line_width (cr, 5.0);
+ cairo_set_line_cap (cr, CAIRO_LINE_CAP_ROUND);
+
+ Gtk::Allocation a = get_allocation();
+ double const width = a.get_width();
+ double const height = a.get_height();
+
+ Gdk::Color const bg = get_style()->get_bg (STATE_NORMAL);
+ cairo_set_source_rgb (cr, bg.get_red_p (), bg.get_green_p (), bg.get_blue_p ());
+
+ cairo_rectangle (cr, 0, 0, width, height);
+ cairo_fill (cr);
+
+ const double y0 = _input ? height-.5 : .5;
+
+ if (_ports.n_total() > 1) {
+ for (uint32_t i = 0; i < _ports.n_total(); ++i) {
+ if (i < _ports.n_midi()) {
+ cairo_set_source_rgb (cr,
+ UINT_RGBA_R_FLT(midi_port_color),
+ UINT_RGBA_G_FLT(midi_port_color),
+ UINT_RGBA_B_FLT(midi_port_color));
+ } else {
+ cairo_set_source_rgb (cr,
+ UINT_RGBA_R_FLT(audio_port_color),
+ UINT_RGBA_G_FLT(audio_port_color),
+ UINT_RGBA_B_FLT(audio_port_color));
+ }
+ const float x = rintf(width * (.2f + .6f * i / (_ports.n_total() - 1.f))) + .5f;
+ cairo_move_to (cr, x, y0);
+ cairo_close_path(cr);
+ cairo_stroke(cr);
+ }
+ } else if (_ports.n_total() == 1) {
+ if (_ports.n_midi() == 1) {
+ cairo_set_source_rgb (cr,
+ UINT_RGBA_R_FLT(midi_port_color),
+ UINT_RGBA_G_FLT(midi_port_color),
+ UINT_RGBA_B_FLT(midi_port_color));
+ } else {
+ cairo_set_source_rgb (cr,
+ UINT_RGBA_R_FLT(audio_port_color),
+ UINT_RGBA_G_FLT(audio_port_color),
+ UINT_RGBA_B_FLT(audio_port_color));
+ }
+ cairo_move_to (cr, rintf(width * .5) + .5f, y0);
+ cairo_close_path(cr);
+ cairo_stroke(cr);
+ }
+
+ cairo_destroy(cr);
+ return true;
+}
+
+bool
+ProcessorEntry::RoutingIcon::on_expose_event (GdkEventExpose* ev)
+{
+ cairo_t* cr = gdk_cairo_create (get_window()->gobj());
+
+ cairo_rectangle (cr, ev->area.x, ev->area.y, ev->area.width, ev->area.height);
+ cairo_clip (cr);
+
+ cairo_set_line_width (cr, 1.0);
cairo_set_line_cap (cr, CAIRO_LINE_CAP_ROUND);
Gtk::Allocation a = get_allocation();
@@ -684,54 +784,64 @@ PluginInsertProcessorEntry::SplittingIcon::on_expose_event (GdkEventExpose* ev)
Gdk::Color const fg = get_style()->get_fg (STATE_NORMAL);
cairo_set_source_rgb (cr, fg.get_red_p (), fg.get_green_p (), fg.get_blue_p ());
- const uint32_t inputs = _inputs.n_audio();
- const uint32_t outputs = _outputs.n_audio();
+ const uint32_t sources = _sources.n_total();
+ const uint32_t sinks = _sinks.n_total();
- const float si_m = rintf(height * 0.5) + .5f;
+ /* MIDI */
+ const uint32_t midi_sources = _sources.n_midi();
+ const uint32_t midi_sinks = _sinks.n_midi();
- if (inputs == 1) {
- const float si_l = rintf(width * 0.2) + .5f;
- const float si_c = rintf(width * 0.5) + .5f;
- const float si_r = rintf(width * 0.8) + .5f;
-
- cairo_move_to (cr, si_l, height);
- cairo_line_to (cr, si_l, si_m);
- cairo_line_to (cr, si_r, si_m);
- cairo_line_to (cr, si_r, height);
- cairo_stroke (cr);
-
- cairo_set_line_cap (cr, CAIRO_LINE_CAP_BUTT);
-
- const uint32_t outputs = _outputs.n_audio();
- for (uint32_t i = 2; i < outputs; ++i) {
- const float si_b = rintf(width * (.2f + .6f * (i - 1.f) / (outputs - 1.f))) + .5f;
- cairo_move_to (cr, si_b, height);
- cairo_line_to (cr, si_b, si_m);
+ cairo_set_source_rgb (cr,
+ UINT_RGBA_R_FLT(midi_port_color),
+ UINT_RGBA_G_FLT(midi_port_color),
+ UINT_RGBA_B_FLT(midi_port_color));
+ if (midi_sources > 0 && midi_sinks > 0 && sinks > 1 && sources > 1) {
+ for (uint32_t i = 0 ; i < midi_sources; ++i) {
+ const float si_x = rintf(width * (.2f + .6f * i / (sinks - 1.f))) + .5f;
+ const float si_x0 = rintf(width * (.2f + .6f * i / (sources - 1.f))) + .5f;
+ cairo_move_to (cr, si_x, height);
+ cairo_curve_to (cr, si_x, 0, si_x0, height, si_x0, 0);
cairo_stroke (cr);
}
-
- cairo_move_to (cr, si_c, si_m);
- cairo_line_to (cr, si_c, 0);
+ } else if (midi_sources == 1 && midi_sinks == 1 && sinks == 1 && sources == 1) {
+ const float si_x = rintf(width * .5f) + .5f;
+ cairo_move_to (cr, si_x, height);
+ cairo_line_to (cr, si_x, 0);
cairo_stroke (cr);
- } else {
- cairo_set_line_cap (cr, CAIRO_LINE_CAP_ROUND);
- for (uint32_t i = 0 ; i < outputs; ++i) {
- const float si_x = rintf(width * (.2f + .6f * i / (outputs - 1.f))) + .5f;
- if (i < inputs) {
- cairo_move_to (cr, si_x, height);
- cairo_line_to (cr, si_x, 0);
- cairo_stroke (cr);
- } else {
- cairo_move_to (cr, si_x, si_m);
- cairo_line_to (cr, si_x, height);
- cairo_stroke (cr);
- cairo_move_to (cr, si_x+4, si_m);
- cairo_line_to (cr, si_x-4, si_m);
- cairo_stroke (cr);
- }
- }
}
+ /* AUDIO */
+ const uint32_t audio_sources = _sources.n_audio();
+ const uint32_t audio_sinks = _sinks.n_audio();
+ cairo_set_source_rgb (cr,
+ UINT_RGBA_R_FLT(audio_port_color),
+ UINT_RGBA_G_FLT(audio_port_color),
+ UINT_RGBA_B_FLT(audio_port_color));
+
+ if (_splitting) {
+ assert(audio_sinks > 1);
+ const float si_x0 = rintf(width * .5f) + .5f;
+ for (uint32_t i = midi_sinks; i < sinks; ++i) {
+ const float si_x = rintf(width * (.2f + .6f * i / (sinks - 1.f))) + .5f;
+ cairo_move_to (cr, si_x, height);
+ cairo_curve_to (cr, si_x, 0, si_x0, height, si_x0, 0);
+ cairo_stroke (cr);
+ }
+ } else if (audio_sources > 1) {
+ for (uint32_t i = 0 ; i < audio_sources; ++i) {
+ const float si_x = rintf(width * (.2f + .6f * (i + midi_sinks) / (sinks - 1.f))) + .5f;
+ const float si_x0 = rintf(width * (.2f + .6f * (i + midi_sources) / (sources - 1.f))) + .5f;
+ cairo_move_to (cr, si_x, height);
+ cairo_curve_to (cr, si_x, 0, si_x0, height, si_x0, 0);
+ cairo_stroke (cr);
+ }
+ } else if (audio_sources == 1 && audio_sinks == 1) {
+ const float si_x = rintf(width * .5f) + .5f;
+ cairo_move_to (cr, si_x, height);
+ cairo_line_to (cr, si_x, 0);
+ cairo_stroke (cr);
+ }
+ cairo_destroy(cr);
return true;
}
@@ -761,7 +871,7 @@ ProcessorBox::ProcessorBox (ARDOUR::Session* sess, boost::function* source, ProcessorEntry* posit
`dropped on' processor */
list c = processor_display.children ();
list::iterator i = c.begin ();
- while (dynamic_cast (*i)) {
- assert (i != c.end ());
- ++i;
- }
assert (i != c.end ());
p = (*i)->processor ();
@@ -1427,11 +1533,6 @@ ProcessorBox::redisplay_processors ()
_route->foreach_processor (sigc::bind (sigc::mem_fun (*this, &ProcessorBox::help_count_visible_prefader_processors),
&_visible_prefader_processors, &fader_seen));
- if (_visible_prefader_processors == 0) { // fader only
- BlankProcessorEntry* bpe = new BlankProcessorEntry (this, _width);
- processor_display.add_child (bpe);
- }
-
_route->foreach_processor (sigc::mem_fun (*this, &ProcessorBox::add_processor_to_display));
for (ProcessorWindowProxies::iterator i = _processor_window_info.begin(); i != _processor_window_info.end(); ++i) {
@@ -1612,15 +1713,16 @@ ProcessorBox::setup_entry_positions ()
list children = processor_display.children ();
bool pre_fader = true;
+ uint32_t num = 0;
for (list::iterator i = children.begin(); i != children.end(); ++i) {
if (boost::dynamic_pointer_cast((*i)->processor())) {
pre_fader = false;
- (*i)->set_position (ProcessorEntry::Fader);
+ (*i)->set_position (ProcessorEntry::Fader, num++);
} else {
if (pre_fader) {
- (*i)->set_position (ProcessorEntry::PreFader);
+ (*i)->set_position (ProcessorEntry::PreFader, num++);
} else {
- (*i)->set_position (ProcessorEntry::PostFader);
+ (*i)->set_position (ProcessorEntry::PostFader, num++);
}
}
}
diff --git a/gtk2_ardour/processor_box.h b/gtk2_ardour/processor_box.h
index 6aed08d17e..d25710392e 100644
--- a/gtk2_ardour/processor_box.h
+++ b/gtk2_ardour/processor_box.h
@@ -125,7 +125,7 @@ public:
PostFader
};
- void set_position (Position);
+ void set_position (Position, uint32_t);
boost::shared_ptr processor () const;
void set_enum_width (Width);
@@ -143,6 +143,7 @@ protected:
ArdourButton _button;
Gtk::VBox _vbox;
Position _position;
+ uint32_t _position_num;
virtual void setup_visuals ();
@@ -150,6 +151,7 @@ private:
void led_clicked();
void processor_active_changed ();
void processor_property_changed (const PBD::PropertyChange&);
+ void processor_configuration_changed (const ARDOUR::ChanCount in, const ARDOUR::ChanCount out);
std::string name (Width) const;
void setup_tooltip ();
@@ -159,6 +161,7 @@ private:
Gtk::StateType _visual_state;
PBD::ScopedConnection active_connection;
PBD::ScopedConnection name_connection;
+ PBD::ScopedConnection config_connection;
class Control : public sigc::trackable {
public:
@@ -168,7 +171,6 @@ private:
void add_state (XMLNode *) const;
void set_state (XMLNode const *);
void hide_things ();
- void hide_label ();
bool visible () const {
return _visible;
@@ -178,7 +180,7 @@ private:
return _name;
}
- Gtk::VBox box;
+ Gtk::Alignment box;
private:
void slider_adjusted ();
@@ -191,7 +193,6 @@ private:
/* things for a slider */
Gtk::Adjustment _adjustment;
Gtkmm2ext::HSliderController _slider;
- Gtk::Label _label;
Gtkmm2ext::PersistentTooltip _slider_persistant_tooltip;
/* things for a button */
ArdourButton _button;
@@ -204,12 +205,43 @@ private:
std::list _controls;
void toggle_control_visibility (Control *);
-};
-class BlankProcessorEntry : public ProcessorEntry
-{
- public:
- BlankProcessorEntry (ProcessorBox *, Width w);
+ class PortIcon : public Gtk::DrawingArea {
+ public:
+ PortIcon(bool input) {
+ _input = input;
+ _ports = ARDOUR::ChanCount(ARDOUR::DataType::AUDIO, 1);
+ set_size_request (-1, 3);
+ }
+ void set_ports(ARDOUR::ChanCount const ports) { _ports = ports; }
+ private:
+ bool on_expose_event (GdkEventExpose *);
+ bool _input;
+ ARDOUR::ChanCount _ports;
+ };
+
+ class RoutingIcon : public Gtk::DrawingArea {
+ public:
+ RoutingIcon() {
+ _sources = ARDOUR::ChanCount(ARDOUR::DataType::AUDIO, 1);
+ _sinks = ARDOUR::ChanCount(ARDOUR::DataType::AUDIO, 1);
+ _splitting = false;
+ set_size_request (-1, 4);
+ }
+ void set_sources(ARDOUR::ChanCount const sources) { _sources = sources; }
+ void set_sinks(ARDOUR::ChanCount const sinks) { _sinks = sinks; }
+ void set_splitting(const bool splitting) { _splitting = splitting; }
+ private:
+ bool on_expose_event (GdkEventExpose *);
+ ARDOUR::ChanCount _sources; // signals available to feed into the processor(s)
+ ARDOUR::ChanCount _sinks; // combined number of outputs of the processor
+ bool _splitting;
+ };
+
+protected:
+ RoutingIcon _routing_icon;
+ PortIcon _input_icon;
+ PortIcon _output_icon;
};
class PluginInsertProcessorEntry : public ProcessorEntry
@@ -220,25 +252,9 @@ public:
void hide_things ();
private:
- void setup_visuals ();
void plugin_insert_splitting_changed ();
-
- class SplittingIcon : public Gtk::DrawingArea {
- public:
- SplittingIcon() {
- _inputs = ARDOUR::ChanCount(ARDOUR::DataType::AUDIO, 1);
- _outputs = ARDOUR::ChanCount(ARDOUR::DataType::AUDIO, 2);
- }
- void set_inputs(ARDOUR::ChanCount const inputs) { _inputs = inputs; }
- void set_outputs(ARDOUR::ChanCount const outputs) { _outputs = outputs; }
- private:
- bool on_expose_event (GdkEventExpose *);
- ARDOUR::ChanCount _inputs;
- ARDOUR::ChanCount _outputs;
- };
-
boost::shared_ptr _plugin_insert;
- SplittingIcon _splitting_icon;
+
PBD::ScopedConnection _splitting_connection;
};
@@ -434,6 +450,7 @@ class ProcessorBox : public Gtk::HBox, public PluginInterestedObject, public ARD
void mixer_strip_delivery_changed (boost::weak_ptr);
XMLNode* entry_gui_object_state (ProcessorEntry *);
+ PBD::ScopedConnection amp_config_connection;
};
#endif /* __ardour_gtk_processor_box__ */
diff --git a/gtk2_ardour/return_ui.cc b/gtk2_ardour/return_ui.cc
index 592fff0a0e..92846af469 100644
--- a/gtk2_ardour/return_ui.cc
+++ b/gtk2_ardour/return_ui.cc
@@ -42,7 +42,7 @@ ReturnUI::ReturnUI (Gtk::Window* parent, boost::shared_ptr r, Session* s
_gpm.set_controls (boost::shared_ptr(), r->meter(), r->amp());
_hbox.pack_start (_gpm, true, true);
- set_name ("ReturnUIFrame");
+ set_name (X_("ReturnUIFrame"));
_vbox.set_spacing (5);
_vbox.set_border_width (5);
@@ -61,7 +61,7 @@ ReturnUI::ReturnUI (Gtk::Window* parent, boost::shared_ptr r, Session* s
_return->input()->changed.connect (input_change_connection, invalidator (*this), boost::bind (&ReturnUI::ins_changed, this, _1, _2), gui_context());
_gpm.setup_meters ();
- _gpm.set_fader_name ("ReturnUIFrame");
+ _gpm.set_fader_name (X_("ReturnUIFader"));
// screen_update_connection = ARDOUR_UI::instance()->RapidScreenUpdate.connect (sigc::mem_fun (*this, &ReturnUI::update));
fast_screen_update_connection = ARDOUR_UI::instance()->SuperRapidScreenUpdate.connect (sigc::mem_fun (*this, &ReturnUI::fast_update));
diff --git a/gtk2_ardour/send_ui.cc b/gtk2_ardour/send_ui.cc
index 1bc4e031f0..1fead73084 100644
--- a/gtk2_ardour/send_ui.cc
+++ b/gtk2_ardour/send_ui.cc
@@ -46,7 +46,7 @@ SendUI::SendUI (Gtk::Window* parent, boost::shared_ptr s, Session* session
_gpm.set_controls (boost::shared_ptr(), s->meter(), s->amp());
_hbox.pack_start (_gpm, true, true);
- set_name ("SendUIFrame");
+ set_name (X_("SendUIFrame"));
_vbox.set_spacing (5);
_vbox.set_border_width (5);
@@ -77,7 +77,7 @@ SendUI::SendUI (Gtk::Window* parent, boost::shared_ptr s, Session* session
_panners.setup_pan ();
_gpm.setup_meters ();
- _gpm.set_fader_name ("SendUIFrame");
+ _gpm.set_fader_name (X_("SendUIFader"));
// screen_update_connection = ARDOUR_UI::instance()->RapidScreenUpdate.connect (
// sigc::mem_fun (*this, &SendUI::update));
diff --git a/gtk2_ardour/sfdb_ui.cc b/gtk2_ardour/sfdb_ui.cc
index 4944ef41a0..9b3d78e86d 100644
--- a/gtk2_ardour/sfdb_ui.cc
+++ b/gtk2_ardour/sfdb_ui.cc
@@ -707,7 +707,7 @@ SoundFileBrowser::add_gain_meter ()
boost::shared_ptr r = _session->the_auditioner ();
gm->set_controls (r, r->shared_peak_meter(), r->amp());
- gm->set_fader_name (X_("AudioTrackFader"));
+ gm->set_fader_name (X_("GainFader"));
meter_packer.set_border_width (12);
meter_packer.pack_start (*gm, false, true);
diff --git a/libs/ardour/lv2_plugin.cc b/libs/ardour/lv2_plugin.cc
index a1d9de1e53..dc7805c273 100644
--- a/libs/ardour/lv2_plugin.cc
+++ b/libs/ardour/lv2_plugin.cc
@@ -1093,7 +1093,12 @@ LV2Plugin::do_save_preset(string name)
lilv_state_free(state);
- return Glib::filename_to_uri(Glib::build_filename(bundle, file_name));
+ std::string uri = Glib::filename_to_uri(Glib::build_filename(bundle, file_name));
+ LilvNode *node = lilv_new_uri(_world.world, uri.c_str());
+ lilv_world_load_bundle(_world.world, node);
+ lilv_world_load_resource(_world.world, node);
+ lilv_node_free(node);
+ return uri;
}
void
diff --git a/libs/ardour/plugin_insert.cc b/libs/ardour/plugin_insert.cc
index c25f8962ac..10368bfb42 100644
--- a/libs/ardour/plugin_insert.cc
+++ b/libs/ardour/plugin_insert.cc
@@ -1212,10 +1212,23 @@ double
PluginInsert::PluginControl::internal_to_interface (double val) const
{
if (_logarithmic) {
+ /* some plugins have a log-scale range "0.."
+ * ideally we'd map the range down to infinity somehow :)
+ *
+ * one solution could be to use
+ * val = exp(lower + log(range) * value);
+ * (log(val) - lower) / range)
+ * This approach would require access to the actual range (ie
+ * Plugin::ParameterDescriptor) and also require handling
+ * of unbound ranges..
+ *
+ * currently an arbitrarly low number is assumed to represnt
+ * log(0) as hot-fix solution.
+ */
if (val > 0) {
val = log (val);
} else {
- val = 0;
+ val = -8; // ~ -70dB = 20 * log10(exp(-8))
}
}
@@ -1226,7 +1239,12 @@ double
PluginInsert::PluginControl::interface_to_internal (double val) const
{
if (_logarithmic) {
- val = exp (val);
+ if (val <= -8) {
+ /* see note in PluginInsert::PluginControl::internal_to_interface() */
+ val= 0;
+ } else {
+ val = exp (val);
+ }
}
return val;
diff --git a/libs/ardour/session.cc b/libs/ardour/session.cc
index 40123e0670..115fcd750a 100644
--- a/libs/ardour/session.cc
+++ b/libs/ardour/session.cc
@@ -1985,9 +1985,9 @@ Session::auto_connect_route (boost::shared_ptr route, ChanCount& existing
for (uint32_t i = output_start.get(*t); i < route->n_outputs().get(*t); ++i) {
string port;
- if ((*t) == DataType::MIDI || Config->get_output_auto_connect() & AutoConnectPhysical) {
+ if ((*t) == DataType::MIDI && (Config->get_output_auto_connect() & AutoConnectPhysical)) {
port = physoutputs[(out_offset.get(*t) + i) % nphysical_out];
- } else if ((*t) == DataType::AUDIO && Config->get_output_auto_connect() & AutoConnectMaster) {
+ } else if ((*t) == DataType::AUDIO && (Config->get_output_auto_connect() & AutoConnectMaster)) {
/* master bus is audio only */
if (_master_out && _master_out->n_inputs().get(*t) > 0) {
port = _master_out->input()->ports().port(*t,
diff --git a/libs/ardour/session_process.cc b/libs/ardour/session_process.cc
index 18dfbf2f2e..6d8c0f9f70 100644
--- a/libs/ardour/session_process.cc
+++ b/libs/ardour/session_process.cc
@@ -421,7 +421,9 @@ Session::process_with_events (pframes_t nframes)
check_declick_out ();
}
- _engine.split_cycle (this_nframes);
+ if (nframes > 0) {
+ _engine.split_cycle (this_nframes);
+ }
/* now handle this event and all others scheduled for the same time */
diff --git a/libs/ardour/wscript b/libs/ardour/wscript
index d2281e4261..18c2188f6a 100644
--- a/libs/ardour/wscript
+++ b/libs/ardour/wscript
@@ -245,7 +245,7 @@ def configure(conf):
'LIBARDOUR_API', 'ardour/libardour_visibility.h')
autowaf.configure(conf)
autowaf.check_pkg(conf, 'aubio', uselib_store='AUBIO',
- atleast_version='0.3.2')
+ exact_version='0.3.2')
autowaf.check_pkg(conf, 'libxml-2.0', uselib_store='XML')
autowaf.check_pkg(conf, 'lrdf', uselib_store='LRDF',
atleast_version='0.4.0')
diff --git a/libs/backends/jack/jack_audiobackend.cc b/libs/backends/jack/jack_audiobackend.cc
index f34cd746f0..62ed00952b 100644
--- a/libs/backends/jack/jack_audiobackend.cc
+++ b/libs/backends/jack/jack_audiobackend.cc
@@ -1094,6 +1094,8 @@ JACKAudioBackend::control_app_name () const
appname = "hdspconf";
} else if (_target_device == "M Audio Delta 1010") {
appname = "mudita24";
+ } else if (_target_device == "M2496") {
+ appname = "mudita24";
}
}
} else {
diff --git a/libs/clearlooks-newer/clearlooks_draw_glossy.c b/libs/clearlooks-newer/clearlooks_draw_glossy.c
index 62f17f3f95..a0e250ee64 100644
--- a/libs/clearlooks-newer/clearlooks_draw_glossy.c
+++ b/libs/clearlooks-newer/clearlooks_draw_glossy.c
@@ -746,7 +746,7 @@ clearlooks_glossy_draw_tab (cairo_t *cr,
if (params->active)
{
- CairoColor shadow, hilight, f1, f2;
+ CairoColor shadow, f1, f2;
pattern = cairo_pattern_create_linear (tab->gap_side == CL_GAP_LEFT ? width-1 : 0,
tab->gap_side == CL_GAP_TOP ? height-2 : 1,
diff --git a/libs/clearlooks-newer/clearlooks_rc_style.c b/libs/clearlooks-newer/clearlooks_rc_style.c
index c9a30ff6b4..9f8fbd4945 100644
--- a/libs/clearlooks-newer/clearlooks_rc_style.c
+++ b/libs/clearlooks-newer/clearlooks_rc_style.c
@@ -306,7 +306,7 @@ clearlooks_gtk2_rc_parse_style (GtkSettings *settings,
static guint
clearlooks_gtk2_rc_parse_dummy (GtkSettings *settings,
GScanner *scanner,
- gchar *name)
+ const gchar *name)
{
(void) settings;
diff --git a/libs/gtkmm2ext/gtkmm2ext/dndvbox.h b/libs/gtkmm2ext/gtkmm2ext/dndvbox.h
index e41437fbcc..232b5b50a7 100644
--- a/libs/gtkmm2ext/gtkmm2ext/dndvbox.h
+++ b/libs/gtkmm2ext/gtkmm2ext/dndvbox.h
@@ -298,7 +298,7 @@ private:
/* make up an icon for the drag */
_drag_icon = new Gtk::Window (Gtk::WINDOW_POPUP);
- Gtk::Allocation a = child->widget().get_allocation ();
+ Gtk::Allocation a = child->action_widget().get_allocation ();
_drag_icon->set_size_request (a.get_width(), a.get_height());
_drag_icon->signal_expose_event().connect (sigc::mem_fun (*this, &DnDVBox::icon_expose));
@@ -328,7 +328,7 @@ private:
cairo_t* cr = gdk_cairo_create (_drag_icon->get_window()->gobj ());
- Glib::RefPtr p = _drag_child->widget().get_snapshot();
+ Glib::RefPtr p = _drag_child->action_widget().get_snapshot();
gdk_cairo_set_source_pixmap (cr, p->gobj(), 0, 0);
cairo_rectangle (cr, 0, 0, w, h);
cairo_fill (cr);
diff --git a/libs/gtkmm2ext/pixfader.cc b/libs/gtkmm2ext/pixfader.cc
index 0185550259..ef1dffc1dd 100644
--- a/libs/gtkmm2ext/pixfader.cc
+++ b/libs/gtkmm2ext/pixfader.cc
@@ -33,7 +33,9 @@ using namespace Gtk;
using namespace std;
#define CORNER_RADIUS 4
-#define FADER_RESERVE (2*CORNER_RADIUS)
+#define CORNER_SIZE 2
+#define CORNER_OFFSET 1
+#define FADER_RESERVE 5
std::list PixFader::_patterns;
@@ -54,6 +56,12 @@ PixFader::PixFader (Gtk::Adjustment& adj, int orientation, int fader_length, int
adjustment.signal_value_changed().connect (mem_fun (*this, &PixFader::adjustment_changed));
adjustment.signal_changed().connect (mem_fun (*this, &PixFader::adjustment_changed));
+
+ if (_orien == VERT) {
+ DrawingArea::set_size_request(girth, span);
+ } else {
+ DrawingArea::set_size_request(span, girth);
+ }
}
PixFader::~PixFader ()
@@ -105,11 +113,8 @@ PixFader::create_patterns ()
cairo_surface_t* surface;
cairo_t* tc = 0;
- float radius = CORNER_RADIUS;
- double w = get_width();
-
- if (w <= 1 || get_height() <= 1) {
+ if (get_width() <= 1 || get_height() <= 1) {
return;
}
@@ -136,13 +141,12 @@ PixFader::create_patterns ()
/* paint lower shade */
- w -= 2.0;
-
- shade_pattern = cairo_pattern_create_linear (0.0, 0.0, w, 0);
+ shade_pattern = cairo_pattern_create_linear (0.0, 0.0, get_width() - 2 - CORNER_OFFSET , 0);
cairo_pattern_add_color_stop_rgba (shade_pattern, 0, fr*0.8,fg*0.8,fb*0.8, 1.0);
cairo_pattern_add_color_stop_rgba (shade_pattern, 1, fr*0.6,fg*0.6,fb*0.6, 1.0);
cairo_set_source (tc, shade_pattern);
- Gtkmm2ext::rounded_top_half_rectangle (tc, 1.0, get_height(), w, get_height(), radius-1.5);
+ Gtkmm2ext::rounded_top_half_rectangle (tc, CORNER_OFFSET, get_height() + CORNER_OFFSET,
+ get_width() - CORNER_SIZE, get_height(), CORNER_RADIUS);
cairo_fill (tc);
cairo_pattern_destroy (shade_pattern);
@@ -169,7 +173,8 @@ PixFader::create_patterns ()
cairo_pattern_add_color_stop_rgba (shade_pattern, 0, fr*0.8,fg*0.8,fb*0.8, 1.0);
cairo_pattern_add_color_stop_rgba (shade_pattern, 1, fr*0.6,fg*0.6,fb*0.6, 1.0);
cairo_set_source (tc, shade_pattern);
- Gtkmm2ext::rounded_right_half_rectangle (tc, 0, 1, get_width(), get_height() - 2.0, radius-1.5);
+ Gtkmm2ext::rounded_right_half_rectangle (tc, CORNER_OFFSET, CORNER_OFFSET,
+ get_width() - CORNER_OFFSET, get_height() - CORNER_SIZE, CORNER_RADIUS);
cairo_fill (tc);
cairo_pattern_destroy (shade_pattern);
@@ -212,7 +217,6 @@ PixFader::on_expose_event (GdkEventExpose* ev)
cairo_set_source_rgb (cr, br, bg, bb);
cairo_rectangle (cr, ev->area.x, ev->area.y, ev->area.width, ev->area.height);
cairo_fill (cr);
-
return true;
}
@@ -223,18 +227,27 @@ PixFader::on_expose_event (GdkEventExpose* ev)
float w = get_width();
float h = get_height();
+ Gdk::Color c = get_style()->get_bg (Gtk::STATE_PRELIGHT);
+ cairo_set_source_rgb (cr, c.get_red_p(), c.get_green_p(), c.get_blue_p());
+ cairo_rectangle (cr, 0, 0, w, h);
+ cairo_fill(cr);
+
+ cairo_set_line_width (cr, 1);
+ cairo_set_source_rgba (cr, 0, 0, 0, 1.0);
+
cairo_matrix_t matrix;
+ Gtkmm2ext::rounded_rectangle (cr, CORNER_OFFSET, CORNER_OFFSET, w-CORNER_SIZE, h-CORNER_SIZE, CORNER_RADIUS);
+ cairo_stroke_preserve(cr);
if (_orien == VERT) {
- if (ds > h - FADER_RESERVE) {
- ds = h - FADER_RESERVE;
+ if (ds > h - FADER_RESERVE - CORNER_OFFSET) {
+ ds = h - FADER_RESERVE - CORNER_OFFSET;
}
cairo_set_source (cr, pattern);
cairo_matrix_init_translate (&matrix, 0, (h - ds));
cairo_pattern_set_matrix (pattern, &matrix);
- Gtkmm2ext::rounded_rectangle (cr, 0, 0, w, h, CORNER_RADIUS-1.5);
cairo_fill (cr);
} else {
@@ -258,7 +271,6 @@ PixFader::on_expose_event (GdkEventExpose* ev)
cairo_set_source (cr, pattern);
cairo_matrix_init_translate (&matrix, w - ds, 0);
cairo_pattern_set_matrix (pattern, &matrix);
- Gtkmm2ext::rounded_rectangle (cr, 0, 0, w, h, CORNER_RADIUS-1.5);
cairo_fill (cr);
}
@@ -270,14 +282,14 @@ PixFader::on_expose_event (GdkEventExpose* ev)
context->set_source_rgba (c.get_red_p()*1.5, c.get_green_p()*1.5, c.get_blue_p()*1.5, 0.85);
if ( _orien == VERT) {
if (unity_loc < h ) {
- context->move_to (1.5, unity_loc + .5);
- context->line_to (girth - 1.5, unity_loc + .5);
+ context->move_to (1.5, unity_loc + CORNER_OFFSET + .5);
+ context->line_to (girth - 1.5, unity_loc + CORNER_OFFSET + .5);
context->stroke ();
}
} else {
if ( unity_loc < w ){
- context->move_to (unity_loc + .5, 1.5);
- context->line_to (unity_loc + .5, girth - 1.5);
+ context->move_to (unity_loc - CORNER_OFFSET + .5, 1.5);
+ context->line_to (unity_loc - CORNER_OFFSET + .5, girth - 1.5);
context->stroke ();
}
}
@@ -293,11 +305,11 @@ PixFader::on_expose_event (GdkEventExpose* ev)
}
if (!get_sensitive()) {
- Gtkmm2ext::rounded_rectangle (cr, 0, 0, get_width(), get_height(), 3);
+ Gtkmm2ext::rounded_rectangle (cr, CORNER_OFFSET, CORNER_OFFSET, w-CORNER_SIZE, h-CORNER_SIZE, CORNER_RADIUS);
cairo_set_source_rgba (cr, 0.505, 0.517, 0.525, 0.4);
cairo_fill (cr);
} else if (_hovering) {
- Gtkmm2ext::rounded_rectangle (cr, 0, 0, get_width(), get_height(), 3);
+ Gtkmm2ext::rounded_rectangle (cr, CORNER_OFFSET, CORNER_OFFSET, w-CORNER_SIZE, h-CORNER_SIZE, CORNER_RADIUS);
cairo_set_source_rgba (cr, 0.905, 0.917, 0.925, 0.1);
cairo_fill (cr);
}
@@ -546,9 +558,9 @@ void
PixFader::update_unity_position ()
{
if (_orien == VERT) {
- unity_loc = (int) rint (span * (1 - (default_value / (adjustment.get_upper() - adjustment.get_lower())))) - 1;
+ unity_loc = (int) rint (span * (1 - ((default_value - adjustment.get_lower()) / (adjustment.get_upper() - adjustment.get_lower())))) - 1;
} else {
- unity_loc = (int) rint (default_value * span / (adjustment.get_upper() - adjustment.get_lower()));
+ unity_loc = (int) rint ((default_value - adjustment.get_lower()) * span / (adjustment.get_upper() - adjustment.get_lower()));
}
queue_draw ();
@@ -614,6 +626,7 @@ PixFader::on_state_changed (Gtk::StateType old_state)
{
Widget::on_state_changed (old_state);
create_patterns ();
+ queue_draw ();
}
void
@@ -630,4 +643,5 @@ PixFader::on_style_changed (const Glib::RefPtr&)
*/
pattern = 0;
+ queue_draw ();
}
diff --git a/libs/vamp-plugins/wscript b/libs/vamp-plugins/wscript
index 46198cc18e..9568e96367 100644
--- a/libs/vamp-plugins/wscript
+++ b/libs/vamp-plugins/wscript
@@ -26,7 +26,8 @@ def configure(conf):
conf.load('compiler_cxx')
autowaf.configure(conf)
autowaf.check_pkg(conf, 'fftw3f', uselib_store='FFTW3F', mandatory=True)
- autowaf.check_pkg(conf, 'aubio', uselib_store='AUBIO', mandatory=False)
+ autowaf.check_pkg(conf, 'aubio', uselib_store='AUBIO', mandatory=False,
+ exact_version='0.3.2')
conf.write_config_header('libvampplugins-config.h', remove=False)
def build(bld):
diff --git a/patchfiles/Moog_MF-104M_Analog_Delay.midnam b/patchfiles/Moog_MF-104M_Analog_Delay.midnam
new file mode 100644
index 0000000000..a6c9855508
--- /dev/null
+++ b/patchfiles/Moog_MF-104M_Analog_Delay.midnam
@@ -0,0 +1,213 @@
+
+
+
+ David Robillard
+
+ Moog
+ MF-104M Analog Delay
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/patchfiles/Moog_MF-108M_Cluster_Flux.midnam b/patchfiles/Moog_MF-108M_Cluster_Flux.midnam
new file mode 100644
index 0000000000..d217648e7f
--- /dev/null
+++ b/patchfiles/Moog_MF-108M_Cluster_Flux.midnam
@@ -0,0 +1,181 @@
+
+
+
+ David Robillard
+
+ Moog
+ MF-108M Cluster Flux
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/patchfiles/Moog_Minitaur.midnam b/patchfiles/Moog_Minitaur.midnam
index eade7af9b2..2852e9b9ff 100644
--- a/patchfiles/Moog_Minitaur.midnam
+++ b/patchfiles/Moog_Minitaur.midnam
@@ -121,6 +121,20 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -129,21 +143,94 @@
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
+
+
+
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -174,20 +261,48 @@
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
+
diff --git a/wscript b/wscript
index 411c3ed4c0..2a577eaf90 100644
--- a/wscript
+++ b/wscript
@@ -163,6 +163,11 @@ def set_compiler_flags (conf,opt):
# Prevents visibility issues in standard headers
conf.define("_DARWIN_C_SOURCE", 1)
+ if conf.options.asan:
+ conf.check_cxx(cxxflags=["-fsanitize=address"], linkflags=["-fsanitize=address"])
+ cxx_flags.append('-fsanitize=address')
+ linker_flags.append('-fsanitize=address')
+
if is_clang and platform == "darwin":
# Silence warnings about the non-existing osx clang compiler flags
# -compatibility_version and -current_version. These are Waf
@@ -505,6 +510,8 @@ def options(opt):
help='Do not ask questions that require confirmation during the build')
opt.add_option('--cxx11', action='store_true', default=False, dest='cxx11',
help='Turn on c++11 compiler flags (-std=c++11)')
+ opt.add_option('--address-sanitizer', action='store_true', default=False, dest='asan',
+ help='Turn on AddressSanitizer (requires GCC >= 4.8 or clang)')
for i in children:
opt.recurse(i)