fix LTC alignment.
LTC-slave: offset the parsed LTC-frame instead of changing the frame's timestamp. This fixes an issue with freewheel timeout and delta-calculation. Align transport-time with output to match capture alignment: "with existing material". LTC-generator: follow suit. align clock with master-bus out. This is a semi-permanent workaround. Once [tracks feeding] the master-bus is/are delayed to align to output. The generator needs to use (worst_track_latency not worst_playback_latency)
This commit is contained in:
parent
7235ece898
commit
7f72e7d879
@ -381,6 +381,8 @@ LTC_Slave::process_ltc(framepos_t const /*now*/)
|
|||||||
timecode_negative_offset, timecode_offset
|
timecode_negative_offset, timecode_offset
|
||||||
);
|
);
|
||||||
|
|
||||||
|
ltc_frame += ltc_slave_latency.max + session.worst_playback_latency();
|
||||||
|
|
||||||
framepos_t cur_timestamp = frame.off_end + 1;
|
framepos_t cur_timestamp = frame.off_end + 1;
|
||||||
DEBUG_TRACE (DEBUG::LTC, string_compose ("LTC F: %1 LF: %2 N: %3 L: %4\n", ltc_frame, last_ltc_frame, cur_timestamp, last_timestamp));
|
DEBUG_TRACE (DEBUG::LTC, string_compose ("LTC F: %1 LF: %2 N: %3 L: %4\n", ltc_frame, last_ltc_frame, cur_timestamp, last_timestamp));
|
||||||
if (frame.off_end + 1 <= last_timestamp || last_timestamp == 0) {
|
if (frame.off_end + 1 <= last_timestamp || last_timestamp == 0) {
|
||||||
@ -463,7 +465,7 @@ LTC_Slave::speed_and_position (double& speed, framepos_t& pos)
|
|||||||
reset();
|
reset();
|
||||||
}
|
}
|
||||||
|
|
||||||
parse_ltc(nframes, in, now - ltc_slave_latency.max );
|
parse_ltc(nframes, in, now);
|
||||||
process_ltc(now);
|
process_ltc(now);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -261,9 +261,9 @@ Session::ltc_tx_send_time_code_for_cycle (framepos_t start_frame, framepos_t end
|
|||||||
framepos_t cycle_start_frame;
|
framepos_t cycle_start_frame;
|
||||||
|
|
||||||
if (current_speed < 0) {
|
if (current_speed < 0) {
|
||||||
cycle_start_frame = (start_frame - ltc_out_latency.max);
|
cycle_start_frame = (start_frame - ltc_out_latency.max + worst_playback_latency());
|
||||||
} else if (current_speed > 0) {
|
} else if (current_speed > 0) {
|
||||||
cycle_start_frame = (start_frame + ltc_out_latency.max);
|
cycle_start_frame = (start_frame + ltc_out_latency.max - worst_playback_latency());
|
||||||
} else {
|
} else {
|
||||||
/* There is no need to compensate for latency when not rolling
|
/* There is no need to compensate for latency when not rolling
|
||||||
* rather send the accurate NOW timecode
|
* rather send the accurate NOW timecode
|
||||||
|
Loading…
Reference in New Issue
Block a user