summaryrefslogtreecommitdiff
path: root/libs/ardour/session.cc
diff options
context:
space:
mode:
Diffstat (limited to 'libs/ardour/session.cc')
-rw-r--r--libs/ardour/session.cc25
1 files changed, 20 insertions, 5 deletions
diff --git a/libs/ardour/session.cc b/libs/ardour/session.cc
index 3c325ee538..ebdbea1fc4 100644
--- a/libs/ardour/session.cc
+++ b/libs/ardour/session.cc
@@ -98,9 +98,13 @@ Session::mix_buffers_with_gain_t Session::mix_buffers_with_gain = 0;
Session::mix_buffers_no_gain_t Session::mix_buffers_no_gain = 0;
sigc::signal<int> Session::AskAboutPendingState;
-sigc::signal<void> Session::SMPTEOffsetChanged;
sigc::signal<void> Session::SendFeedback;
+sigc::signal<void> Session::SMPTEOffsetChanged;
+sigc::signal<void> Session::SMPTETypeChanged;
+sigc::signal<void> Session::PullupChanged;
+sigc::signal<void> Session::StartTimeChanged;
+sigc::signal<void> Session::EndTimeChanged;
int
Session::find_session (string str, string& path, string& snapshot, bool& isnew)
@@ -298,6 +302,8 @@ Session::Session (AudioEngine &eng,
_state_of_the_state = StateOfTheState (_state_of_the_state & ~Dirty);
+ Config->ParameterChanged.connect (mem_fun (*this, &Session::handle_configuration_change));
+
if (was_dirty) {
DirtyChanged (); /* EMIT SIGNAL */
}
@@ -1435,8 +1441,9 @@ Session::set_frame_rate (jack_nframes_t frames_per_second)
here.
*/
- _current_frame_rate = frames_per_second;
- _frames_per_smpte_frame = (double) _current_frame_rate / (double) smpte_frames_per_second;
+ _base_frame_rate = frames_per_second;
+
+ sync_time_vars();
Route::set_automation_interval ((jack_nframes_t) ceil ((double) frames_per_second * 0.25));
@@ -2759,8 +2766,6 @@ Session::remove_region_from_region_list (boost::shared_ptr<Region> r)
void
Session::add_source (boost::shared_ptr<Source> source)
{
- cerr << "add new source " << source->name() << endl;
-
pair<SourceMap::key_type, SourceMap::mapped_type> entry;
pair<SourceMap::iterator,bool> result;
@@ -4084,6 +4089,16 @@ Session::set_xfade_model (CrossfadeModel xm)
}
void
+Session::handle_configuration_change (const char* parameter)
+{
+ if (!strcmp (parameter, "use-video-sync")) {
+ if (_transport_speed == 0.0f) {
+ waiting_for_sync_offset = true;
+ }
+ }
+}
+
+void
Session::add_curve(Curve *curve)
{
curves[curve->id()] = curve;