2005-09-25 14:42:24 -04:00
|
|
|
/*
|
2019-08-02 17:26:43 -04:00
|
|
|
* Copyright (C) 2005-2007 Taybin Rutkin <taybin@taybin.com>
|
|
|
|
* Copyright (C) 2005-2017 Paul Davis <paul@linuxaudiosystems.com>
|
|
|
|
* Copyright (C) 2007-2011 David Robillard <d@drobilla.net>
|
|
|
|
* Copyright (C) 2009-2012 Carl Hetherington <carl@carlh.net>
|
|
|
|
* Copyright (C) 2014-2019 Robin Gareus <robin@gareus.org>
|
|
|
|
*
|
|
|
|
* This program is free software; you can redistribute it and/or modify
|
|
|
|
* it under the terms of the GNU General Public License as published by
|
|
|
|
* the Free Software Foundation; either version 2 of the License, or
|
|
|
|
* (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU General Public License along
|
|
|
|
* with this program; if not, write to the Free Software Foundation, Inc.,
|
|
|
|
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
|
|
|
*/
|
2005-09-25 14:42:24 -04:00
|
|
|
|
|
|
|
#ifndef __ardour_route_params_ui_h__
|
|
|
|
#define __ardour_route_params_ui_h__
|
|
|
|
|
|
|
|
#include <list>
|
|
|
|
|
2005-10-06 14:24:23 -04:00
|
|
|
#include <gtkmm/box.h>
|
|
|
|
#include <gtkmm/button.h>
|
|
|
|
#include <gtkmm/eventbox.h>
|
|
|
|
#include <gtkmm/frame.h>
|
|
|
|
#include <gtkmm/label.h>
|
|
|
|
#include <gtkmm/scrolledwindow.h>
|
|
|
|
#include <gtkmm/togglebutton.h>
|
|
|
|
#include <gtkmm/treeview.h>
|
2005-09-25 14:42:24 -04:00
|
|
|
|
2009-02-25 13:26:51 -05:00
|
|
|
#include "pbd/stateful.h"
|
2009-12-19 15:26:31 -05:00
|
|
|
#include "pbd/signals.h"
|
2006-07-07 19:51:30 -04:00
|
|
|
|
2009-02-25 13:26:51 -05:00
|
|
|
#include "ardour/ardour.h"
|
2005-09-25 14:42:24 -04:00
|
|
|
|
2017-07-16 22:55:52 -04:00
|
|
|
#include <widgets/pane.h>
|
2016-05-26 10:46:28 -04:00
|
|
|
|
2011-11-18 19:56:35 -05:00
|
|
|
#include "ardour_window.h"
|
2007-06-27 16:23:48 -04:00
|
|
|
#include "processor_box.h"
|
2017-05-05 07:31:49 -04:00
|
|
|
#include "processor_selection.h"
|
2005-09-25 14:42:24 -04:00
|
|
|
|
|
|
|
namespace ARDOUR {
|
|
|
|
class Route;
|
|
|
|
class Send;
|
2007-06-27 16:23:48 -04:00
|
|
|
class Processor;
|
2005-09-25 14:42:24 -04:00
|
|
|
class Session;
|
|
|
|
class PortInsert;
|
|
|
|
class Connection;
|
|
|
|
class Plugin;
|
|
|
|
}
|
|
|
|
|
|
|
|
class PluginSelector;
|
2011-11-18 16:56:01 -05:00
|
|
|
class IOSelector;
|
2005-09-25 14:42:24 -04:00
|
|
|
|
2011-11-18 19:56:35 -05:00
|
|
|
class RouteParams_UI : public ArdourWindow, public PBD::ScopedConnectionList
|
2005-09-25 14:42:24 -04:00
|
|
|
{
|
2017-07-01 15:11:14 -04:00
|
|
|
public:
|
2007-03-13 12:17:29 -04:00
|
|
|
RouteParams_UI ();
|
2005-09-25 14:42:24 -04:00
|
|
|
~RouteParams_UI();
|
|
|
|
|
2009-12-17 13:24:23 -05:00
|
|
|
void set_session (ARDOUR::Session*);
|
|
|
|
void session_going_away ();
|
2019-05-24 18:12:55 -04:00
|
|
|
PluginSelector* plugin_selector();
|
2005-09-25 14:42:24 -04:00
|
|
|
|
2017-07-01 15:11:14 -04:00
|
|
|
private:
|
2005-09-25 14:42:24 -04:00
|
|
|
Gtk::VBox list_vpacker;
|
|
|
|
Gtk::ScrolledWindow route_select_scroller;
|
|
|
|
|
|
|
|
Gtk::Notebook notebook;
|
2017-09-18 14:45:56 -04:00
|
|
|
Gtk::Frame input_frame;
|
|
|
|
Gtk::Frame output_frame;
|
2017-07-16 22:55:52 -04:00
|
|
|
ArdourWidgets::HPane redir_hpane;
|
2007-06-27 18:06:35 -04:00
|
|
|
|
2017-09-18 14:45:56 -04:00
|
|
|
Gtk::Frame route_select_frame;
|
2005-09-25 14:42:24 -04:00
|
|
|
|
|
|
|
Gtk::HBox route_hpacker;
|
|
|
|
Gtk::VBox route_vpacker;
|
|
|
|
|
2009-07-12 20:26:28 -04:00
|
|
|
ProcessorBox* insert_box;
|
2009-10-14 12:10:01 -04:00
|
|
|
|
2017-07-16 22:55:52 -04:00
|
|
|
ArdourWidgets::HPane list_hpane;
|
2005-09-25 14:42:24 -04:00
|
|
|
|
2017-07-16 22:55:52 -04:00
|
|
|
ArdourWidgets::HPane right_hpane;
|
2009-10-14 12:10:01 -04:00
|
|
|
|
2017-09-18 14:45:56 -04:00
|
|
|
Gtk::Frame route_param_frame;
|
2005-09-25 14:42:24 -04:00
|
|
|
|
|
|
|
Gtk::VBox choice_vpacker;
|
2009-10-14 12:10:01 -04:00
|
|
|
|
|
|
|
|
2005-09-25 14:42:24 -04:00
|
|
|
Gtk::ToggleButton input_button;
|
|
|
|
Gtk::ToggleButton output_button;
|
|
|
|
Gtk::Label track_input_label;
|
2009-10-14 12:10:01 -04:00
|
|
|
|
2005-09-25 14:42:24 -04:00
|
|
|
Gtk::Label title_label;
|
2009-10-14 12:10:01 -04:00
|
|
|
|
2009-07-12 20:26:28 -04:00
|
|
|
Gtk::Container * _active_view;
|
2005-09-25 14:42:24 -04:00
|
|
|
IOSelector * _input_iosel;
|
|
|
|
IOSelector * _output_iosel;
|
2009-10-14 12:10:01 -04:00
|
|
|
|
2017-05-05 07:31:49 -04:00
|
|
|
ProcessorSelection _p_selection;
|
2005-09-25 14:42:24 -04:00
|
|
|
|
2023-02-16 18:33:28 -05:00
|
|
|
std::shared_ptr<ARDOUR::Route> _route;
|
2009-12-21 13:23:07 -05:00
|
|
|
PBD::ScopedConnection _route_processors_connection;
|
2014-06-03 18:27:01 -04:00
|
|
|
PBD::ScopedConnectionList route_connections;
|
2005-09-25 14:42:24 -04:00
|
|
|
|
2023-02-16 18:33:28 -05:00
|
|
|
std::shared_ptr<ARDOUR::Processor> _processor;
|
2009-12-21 13:23:07 -05:00
|
|
|
PBD::ScopedConnection _processor_going_away_connection;
|
2005-09-25 14:42:24 -04:00
|
|
|
|
2009-10-14 12:10:01 -04:00
|
|
|
|
2005-09-25 14:42:24 -04:00
|
|
|
enum ConfigView {
|
|
|
|
NO_CONFIG_VIEW = 0,
|
|
|
|
INPUT_CONFIG_VIEW,
|
|
|
|
OUTPUT_CONFIG_VIEW,
|
2009-10-14 12:10:01 -04:00
|
|
|
PLUGIN_CONFIG_VIEW,
|
2005-09-25 14:42:24 -04:00
|
|
|
PORTINSERT_CONFIG_VIEW,
|
|
|
|
SEND_CONFIG_VIEW
|
|
|
|
};
|
2009-10-14 12:10:01 -04:00
|
|
|
|
2005-09-25 14:42:24 -04:00
|
|
|
ConfigView _current_view;
|
2005-10-06 14:24:23 -04:00
|
|
|
|
|
|
|
|
|
|
|
/* treeview */
|
2009-10-22 13:17:34 -04:00
|
|
|
struct RouteDisplayModelColumns : public Gtk::TreeModel::ColumnRecord {
|
2005-10-06 14:24:23 -04:00
|
|
|
RouteDisplayModelColumns() {
|
|
|
|
add(text);
|
|
|
|
add(route);
|
|
|
|
}
|
2010-09-14 12:51:02 -04:00
|
|
|
Gtk::TreeModelColumn<std::string> text;
|
2023-02-16 18:33:28 -05:00
|
|
|
Gtk::TreeModelColumn<std::shared_ptr<ARDOUR::Route> > route;
|
2005-10-06 14:24:23 -04:00
|
|
|
};
|
|
|
|
|
|
|
|
RouteDisplayModelColumns route_display_columns ;
|
|
|
|
Gtk::TreeView route_display;
|
|
|
|
Glib::RefPtr<Gtk::ListStore> route_display_model;
|
|
|
|
|
2009-10-14 12:10:01 -04:00
|
|
|
|
2023-04-07 17:33:13 -04:00
|
|
|
void add_routes (ARDOUR::RouteList const&);
|
2005-09-25 14:42:24 -04:00
|
|
|
|
2023-02-16 18:33:28 -05:00
|
|
|
void route_property_changed (const PBD::PropertyChange&, std::weak_ptr<ARDOUR::Route> route);
|
|
|
|
void route_removed (std::weak_ptr<ARDOUR::Route> route);
|
2014-06-03 18:27:01 -04:00
|
|
|
void map_frozen ();
|
2005-09-25 14:42:24 -04:00
|
|
|
|
|
|
|
|
2005-10-06 14:24:23 -04:00
|
|
|
void route_selected();
|
|
|
|
//void route_unselected (gint row, gint col, GdkEvent *ev);
|
2005-09-25 14:42:24 -04:00
|
|
|
|
2019-04-08 16:14:09 -04:00
|
|
|
void setup_io_selector();
|
|
|
|
void cleanup_io_selector();
|
2009-07-12 20:26:28 -04:00
|
|
|
void cleanup_view(bool stopupdate = true);
|
2009-10-14 12:10:01 -04:00
|
|
|
|
2009-11-30 18:16:28 -05:00
|
|
|
void processors_changed (ARDOUR::RouteProcessorChange);
|
2009-10-14 12:10:01 -04:00
|
|
|
|
2007-06-27 16:23:48 -04:00
|
|
|
void setup_processor_boxes();
|
|
|
|
void cleanup_processor_boxes();
|
2005-09-25 14:42:24 -04:00
|
|
|
|
2023-02-16 18:33:28 -05:00
|
|
|
void redirect_selected (std::shared_ptr<ARDOUR::Processor>);
|
2009-10-14 12:10:01 -04:00
|
|
|
|
2006-08-24 21:07:15 -04:00
|
|
|
void plugin_going_away (ARDOUR::Placement);
|
2023-02-16 18:33:28 -05:00
|
|
|
void processor_going_away (std::weak_ptr<ARDOUR::Processor>);
|
2005-09-25 14:42:24 -04:00
|
|
|
|
|
|
|
gint edit_input_configuration (GdkEventButton *ev);
|
|
|
|
gint edit_output_configuration (GdkEventButton *ev);
|
2009-10-14 12:10:01 -04:00
|
|
|
|
2005-09-25 14:42:24 -04:00
|
|
|
void update_routeinfo (ARDOUR::Route * route);
|
2009-10-14 12:10:01 -04:00
|
|
|
|
2005-09-25 14:42:24 -04:00
|
|
|
Gtk::Menu *track_menu;
|
2005-10-06 14:24:23 -04:00
|
|
|
void show_track_menu();
|
2009-10-14 12:10:01 -04:00
|
|
|
|
2005-09-25 14:42:24 -04:00
|
|
|
void update_title ();
|
|
|
|
//void unselect_all_redirects ();
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
#endif /* __ardour_route_params_ui_h__ */
|