somewhat illogical and temporary workaround to the problems with consolidate & bounceable. it turns out that region bouncing never replaces the in-place region, so bounceable() doesn't matter; range bouncing only needs to check bounceable() if we're going to replace material in place and the op is with-processing. reword the error dialog too
git-svn-id: svn://localhost/ardour2/branches/3.0@9606 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
parent
e4a9202926
commit
f87baef1e7
|
@ -227,7 +227,8 @@
|
|||
<menuitem action='remove-region-sync'/>
|
||||
<menuitem action='play-selected-regions'/>
|
||||
<menuitem action='export-region'/>
|
||||
<menuitem action='bounce-region'/>
|
||||
<menuitem action='bounce-regions-processed'/>
|
||||
<menuitem action='bounce-regions-unprocessed'/>
|
||||
<menuitem action='combine-regions'/>
|
||||
<menuitem action='uncombine-regions'/>
|
||||
<menuitem action='analyze-region'/>
|
||||
|
@ -577,11 +578,16 @@
|
|||
<popup name='PopupRegionMenu' action='PopupRegionMenu'>
|
||||
<menuitem action='rename-region'/>
|
||||
<menuitem action='show-region-properties'/>
|
||||
<menuitem action='combine-regions'/>
|
||||
<menuitem action='uncombine-regions'/>
|
||||
<menuitem action='split-region'/>
|
||||
<menuitem action='split-multichannel-region'/>
|
||||
<menuitem action='set-region-sync-position'/>
|
||||
<menuitem action='remove-region-sync'/>
|
||||
<menuitem action='play-selected-regions'/>
|
||||
<menuitem action='export-region'/>
|
||||
<menuitem action='bounce-region'/>
|
||||
<menuitem action='bounce-regions-processed'/>
|
||||
<menuitem action='bounce-regions-unprocessed'/>
|
||||
<menuitem action='analyze-region'/>
|
||||
<menuitem action='toggle-region-lock'/>
|
||||
<menuitem action='toggle-region-lock-style'/>
|
||||
|
@ -590,18 +596,14 @@
|
|||
<menuitem action='pitch-shift-region'/>
|
||||
<menuitem action='transpose-region'/>
|
||||
<menuitem action='naturalize-region'/>
|
||||
<menuitem action='combine-regions'/>
|
||||
<menuitem action='uncombine-regions'/>
|
||||
<menuitem action='split-region'/>
|
||||
<menuitem action='split-multichannel-region'/>
|
||||
<menuitem action='remove-region'/>
|
||||
<menuitem action='reverse-region'/>
|
||||
<menuitem action='loop-region'/>
|
||||
<menuitem action='snap-regions-to-grid'/>
|
||||
<menuitem action='close-region-gaps'/>
|
||||
<menuitem action='place-transient' />
|
||||
<menuitem action='show-rhythm-ferret'/>
|
||||
<menuitem action='strip-region-silence'/>
|
||||
<menuitem action='reverse-region'/>
|
||||
<menuitem action='remove-region'/>
|
||||
<menu action='RegionMenuLayering'>
|
||||
<menuitem action='raise-region-to-top'/>
|
||||
<menuitem action='raise-region'/>
|
||||
|
|
|
@ -1751,7 +1751,7 @@ class Editor : public PublicEditor, public PBD::ScopedConnectionList, public ARD
|
|||
|
||||
int write_region_selection(RegionSelection&);
|
||||
bool write_region (std::string path, boost::shared_ptr<ARDOUR::AudioRegion>);
|
||||
void bounce_region_selection ();
|
||||
void bounce_region_selection (bool with_processing);
|
||||
void bounce_range_selection (bool replace, bool enable_processing);
|
||||
void external_edit_region ();
|
||||
|
||||
|
|
|
@ -1371,7 +1371,8 @@ Editor::register_region_actions ()
|
|||
|
||||
reg_sens (_region_actions, "play-selected-regions", _("Play"), sigc::mem_fun(*this, &Editor::play_selected_region));
|
||||
|
||||
reg_sens (_region_actions, "bounce-region", _("Bounce"), sigc::mem_fun (*this, &Editor::bounce_region_selection));
|
||||
reg_sens (_region_actions, "bounce-regions-unprocessed", _("Bounce (with processing)"), (sigc::bind (sigc::mem_fun (*this, &Editor::bounce_region_selection), true)));
|
||||
reg_sens (_region_actions, "bounce-regions-processed", _("Bounce (without processing)"), (sigc::bind (sigc::mem_fun (*this, &Editor::bounce_region_selection), false)));
|
||||
reg_sens (_region_actions, "combine-regions", _("Combine"), sigc::mem_fun (*this, &Editor::combine_regions));
|
||||
reg_sens (_region_actions, "uncombine-regions", _("Uncombine"), sigc::mem_fun (*this, &Editor::uncombine_regions));
|
||||
|
||||
|
|
|
@ -145,23 +145,11 @@ Editor::write_region_selection (RegionSelection& regions)
|
|||
}
|
||||
|
||||
void
|
||||
Editor::bounce_region_selection ()
|
||||
Editor::bounce_region_selection (bool with_processing)
|
||||
{
|
||||
for (RegionSelection::iterator i = selection->regions.begin(); i != selection->regions.end(); ++i) {
|
||||
|
||||
RouteTimeAxisView* rtv = dynamic_cast<RouteTimeAxisView*> (&(*i)->get_time_axis_view());
|
||||
boost::shared_ptr<Track> track = boost::dynamic_pointer_cast<Track> (rtv->route());
|
||||
|
||||
if (!track->bounceable()) {
|
||||
MessageDialog d (
|
||||
_("One or more of the selected regions' tracks cannot be bounced because it has more outputs than inputs. "
|
||||
"You can fix this by increasing the number of inputs on that track.")
|
||||
);
|
||||
d.set_title (_("Cannot bounce"));
|
||||
d.run ();
|
||||
return;
|
||||
}
|
||||
}
|
||||
/* no need to check for bounceable() because this operation never puts
|
||||
* its results back in the playlist (only in the region list).
|
||||
*/
|
||||
|
||||
for (RegionSelection::iterator i = selection->regions.begin(); i != selection->regions.end(); ++i) {
|
||||
|
||||
|
@ -171,12 +159,7 @@ Editor::bounce_region_selection ()
|
|||
|
||||
InterThreadInfo itt;
|
||||
|
||||
boost::shared_ptr<Region> r = track->bounce_range (region->position(), region->position() + region->length(), itt);
|
||||
cerr << "Result of bounce of "
|
||||
<< region->name() << " len = " << region->length()
|
||||
<< " was "
|
||||
<< r->name() << " len = " << r->length()
|
||||
<< endl;
|
||||
boost::shared_ptr<Region> r = track->bounce_range (region->position(), region->position() + region->length(), itt, with_processing);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -3319,10 +3319,11 @@ Editor::bounce_range_selection (bool replace, bool enable_processing)
|
|||
|
||||
for (TrackViewList::iterator i = views.begin(); i != views.end(); ++i) {
|
||||
RouteTimeAxisView* rtv = dynamic_cast<RouteTimeAxisView*> (*i);
|
||||
if (rtv && rtv->track() && !rtv->track()->bounceable()) {
|
||||
if (rtv && rtv->track() && replace && enable_processing && !rtv->track()->bounceable()) {
|
||||
MessageDialog d (
|
||||
_("One or more selected tracks cannot be bounced because it has more outputs than inputs. "
|
||||
"You can fix this by increasing the number of inputs on that track.")
|
||||
_("You can't perform this operation because the processing of the signal "
|
||||
"will cause one or more of the tracks will end up with a region with more channels than this track has inputs.\n\n"
|
||||
"You can do this without processing, which is a different operation.")
|
||||
);
|
||||
d.set_title (_("Cannot bounce"));
|
||||
d.run ();
|
||||
|
|
Loading…
Reference in New Issue