diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2015-05-13 10:39:24 -0400 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2015-06-29 14:18:14 -0400 |
commit | 289078f7f8224ec72fb23d81b0e2b53a09611cfa (patch) | |
tree | 063e0a4b9afd4655bac15d5fbe7d50dde779eff4 /libs | |
parent | a9f3ca6a81bf0f36356053fba9a9cbb387931fff (diff) |
merge in Tracks-derived session-end-is-N-seconds beyond last region end, but define N as zero for Ardour/Mixbus
Diffstat (limited to 'libs')
-rw-r--r-- | libs/ardour/ardour/session.h | 1 | ||||
-rw-r--r-- | libs/ardour/session.cc | 11 |
2 files changed, 11 insertions, 1 deletions
diff --git a/libs/ardour/ardour/session.h b/libs/ardour/ardour/session.h index 487437023c..5bbc069055 100644 --- a/libs/ardour/ardour/session.h +++ b/libs/ardour/ardour/session.h @@ -1811,6 +1811,7 @@ class LIBARDOUR_API Session : public PBD::StatefulDestructible, public PBD::Scop void save_as_bring_callback (uint32_t, uint32_t, std::string); static int get_session_info_from_path (XMLTree& state_tree, const std::string& xmlpath); + static const uint32_t session_end_shift; }; diff --git a/libs/ardour/session.cc b/libs/ardour/session.cc index e1eed879a5..c4d0b8c338 100644 --- a/libs/ardour/session.cc +++ b/libs/ardour/session.cc @@ -139,6 +139,13 @@ const framecnt_t Session::bounce_chunk_size = 65536; static void clean_up_session_event (SessionEvent* ev) { delete ev; } const SessionEvent::RTeventCallback Session::rt_cleanup (clean_up_session_event); +// seconds should be added afte the region exceeds end marker +#ifdef USE_TRACKS_CODE_FEATURES +const uint32_t Session::session_end_shift = 5; +#else +const uint32_t Session::session_end_shift = 0; +#endif + /** @param snapshot_name Snapshot name, without .ardour suffix */ Session::Session (AudioEngine &eng, const string& fullpath, @@ -3944,9 +3951,11 @@ Session::maybe_update_session_range (framepos_t a, framepos_t b) return; } + framepos_t session_end_marker_shift_samples = session_end_shift * _nominal_frame_rate; + if (_session_range_location == 0) { - set_session_range_location (a, b); + set_session_range_location (a, b + session_end_marker_shift_samples); } else { |