Adjust the time needed to allow the clock to settle and the lead time.

This commit is contained in:
Mike Brady
2021-12-21 15:32:16 +00:00
parent fc736cd12f
commit 8656149d68
2 changed files with 4 additions and 1 deletions
+3
View File
@@ -1067,6 +1067,9 @@ static abuf_t *buffer_get_frame(rtsp_conn_info *conn) {
debug(1, "Connection %d: Short lead time for first frame %" PRId64 ": %f seconds. Flushing 0.5 seconds",
conn->connection_number, conn->first_packet_timestamp, lt * 0.000000001);
do_flush(conn->first_packet_timestamp + 5 * 4410, conn);
} else {
debug(1, "Connection %d: Lead time for first frame %" PRId64 ": %f seconds.",
conn->connection_number, conn->first_packet_timestamp, lt * 0.000000001);
}
/*
int64_t lateness = local_time_now - conn->first_packet_time_to_play;
+1 -1
View File
@@ -1305,7 +1305,7 @@ int get_ptp_anchor_local_time_info(rtsp_conn_info *conn, uint32_t *anchorRTP,
// if the master clock and the anchor clock are the same
// wait at least this time before using the new master clock
// note that mastershipo may be backdated
if (duration_of_mastership < 2000000000) {
if (duration_of_mastership < 1500000000) {
debug(3, "master not old enough yet: %f ms", 0.000001 * duration_of_mastership);
response = clock_not_ready;
} else if ((duration_of_mastership > 5000000000) ||