- cycles_t cnow = get_cycles ();
- nframes_t now = session.engine().frame_time();
- nframes_t qtr;
- static cycles_t last_qtr = 0;
-
- qtr = (long) (session.frames_per_smpte_frame() / 4);
- mtc_frame += qtr;
- last_qtr = cnow;
-
- current.guard1++;
- current.position = mtc_frame;
- current.timestamp = now;
- current.guard2++;
+ DEBUG_TRACE (DEBUG::MTC, string_compose ("qtr frame %1 at %2, valid-for-time? %3\n", which_qtr, now, qtr_frame_messages_valid_for_time));
+
+ if (qtr_frame_messages_valid_for_time) {
+
+ if (which_qtr != 7) {
+
+ /* leave position and speed updates for the last
+ qtr frame message of the 8 to be taken
+ care of in update_mtc_time(), invoked
+ by the Parser right after this.
+ */
+
+ nframes_t qtr;
+
+ qtr = (long) (session.frames_per_timecode_frame() / 4);
+ mtc_frame += qtr;
+
+ double speed = compute_apparent_speed (now);
+
+ current.guard1++;
+ current.position = mtc_frame;
+ current.timestamp = now;
+ current.speed = speed;
+ current.guard2++;
+ }