+ _session->config.set_timecode_format (saved_tc_format);
+ }
+}
+
+void
+MTC_TransportMaster::init ()
+{
+ reset (true);
+}
+
+void
+MTC_TransportMaster::set_session (Session *s)
+{
+ config_connection.disconnect ();
+ port_connections.drop_connections();
+
+ _session = s;
+
+ if (_session) {
+
+ last_mtc_fps_byte = _session->get_mtc_timecode_bits ();
+ quarter_frame_duration = (double) (_session->samples_per_timecode_frame() / 4.0);
+ mtc_timecode = _session->config.get_timecode_format();
+ a3e_timecode = _session->config.get_timecode_format();
+
+ parse_timecode_offset ();
+ reset (true);
+
+ parser.mtc_time.connect_same_thread (port_connections, boost::bind (&MTC_TransportMaster::update_mtc_time, this, _1, _2, _3));
+ parser.mtc_qtr.connect_same_thread (port_connections, boost::bind (&MTC_TransportMaster::update_mtc_qtr, this, _1, _2, _3));
+ parser.mtc_status.connect_same_thread (port_connections, boost::bind (&MTC_TransportMaster::update_mtc_status, this, _1));
+
+ _session->config.ParameterChanged.connect_same_thread (config_connection, boost::bind (&MTC_TransportMaster::parameter_changed, this, _1));