Add option to export track output to stem export dialog
This commit is contained in:
parent
b6c2dec8fa
commit
010a75d389
@ -527,13 +527,25 @@ RegionExportChannelSelector::handle_selection ()
|
||||
CriticalSelectionChanged ();
|
||||
}
|
||||
|
||||
/* Track export channel selector */
|
||||
|
||||
TrackExportChannelSelector::TrackExportChannelSelector (ARDOUR::Session * session, ProfileManagerPtr manager)
|
||||
: ExportChannelSelector(session, manager)
|
||||
, region_contents_button(source_group, _("Export region contents"))
|
||||
, track_output_button(source_group, _("Export track output"))
|
||||
{
|
||||
pack_start(main_layout);
|
||||
|
||||
// Options
|
||||
options_box.pack_start(region_contents_button);
|
||||
options_box.pack_start(track_output_button);
|
||||
main_layout.pack_start(options_box);
|
||||
|
||||
// Track scroller
|
||||
track_scroller.add (track_view);
|
||||
track_scroller.set_size_request (-1, 130);
|
||||
track_scroller.set_policy (Gtk::POLICY_AUTOMATIC, Gtk::POLICY_AUTOMATIC);
|
||||
pack_start(track_scroller);
|
||||
main_layout.pack_start(track_scroller);
|
||||
|
||||
// Track list
|
||||
track_list = Gtk::ListStore::create (track_cols);
|
||||
@ -613,22 +625,23 @@ TrackExportChannelSelector::update_config()
|
||||
|
||||
boost::shared_ptr<Route> route = row[track_cols.route];
|
||||
|
||||
/* Output of track code. TODO make this an option also
|
||||
uint32_t outs = route->n_ports().n_audio();
|
||||
for (uint32_t i = 0; i < outs; ++i) {
|
||||
AudioPort * port = route->audio (i);
|
||||
if (port) {
|
||||
ExportChannelPtr channel (new PortExportChannel ());
|
||||
PortExportChannel * pec = static_cast<PortExportChannel *> (channel.get());
|
||||
pec->add_port(port);
|
||||
state->config->register_channel(channel);
|
||||
if (track_output_button.get_active()) {
|
||||
uint32_t outs = route->n_outputs().n_audio();
|
||||
for (uint32_t i = 0; i < outs; ++i) {
|
||||
boost::shared_ptr<AudioPort> port = route->output()->audio (i);
|
||||
if (port) {
|
||||
ExportChannelPtr channel (new PortExportChannel ());
|
||||
PortExportChannel * pec = static_cast<PortExportChannel *> (channel.get());
|
||||
pec->add_port(port);
|
||||
state->config->register_channel(channel);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
std::list<ExportChannelPtr> list;
|
||||
RouteExportChannel::create_from_route (list, route);
|
||||
state->config->register_channels (list);
|
||||
}
|
||||
*/
|
||||
|
||||
std::list<ExportChannelPtr> list;
|
||||
RouteExportChannel::create_from_route (list, route);
|
||||
state->config->register_channels (list);
|
||||
state->config->set_name (route->name());
|
||||
}
|
||||
|
||||
|
@ -235,15 +235,17 @@ class TrackExportChannelSelector : public ExportChannelSelector
|
||||
private:
|
||||
|
||||
void fill_list();
|
||||
void add_track (boost::shared_ptr<ARDOUR::Route> route);
|
||||
void add_track (boost::shared_ptr<ARDOUR::Route> route);
|
||||
void update_config();
|
||||
|
||||
ChannelConfigList configs;
|
||||
|
||||
Gtk::VBox main_layout;
|
||||
|
||||
struct TrackCols : public Gtk::TreeModelColumnRecord
|
||||
{
|
||||
public:
|
||||
Gtk::TreeModelColumn<boost::shared_ptr<ARDOUR::Route> > route;
|
||||
Gtk::TreeModelColumn<boost::shared_ptr<ARDOUR::Route> > route;
|
||||
Gtk::TreeModelColumn<std::string> label;
|
||||
Gtk::TreeModelColumn<bool> selected;
|
||||
|
||||
@ -256,6 +258,10 @@ class TrackExportChannelSelector : public ExportChannelSelector
|
||||
|
||||
Gtk::ScrolledWindow track_scroller;
|
||||
|
||||
Gtk::HBox options_box;
|
||||
Gtk::RadioButton::Group source_group;
|
||||
Gtk::RadioButton region_contents_button;
|
||||
Gtk::RadioButton track_output_button;
|
||||
};
|
||||
|
||||
#endif /* __export_channel_selector_h__ */
|
||||
|
Loading…
Reference in New Issue
Block a user