From 76870d17645271ef3fa333d183d64db9b489ee48 Mon Sep 17 00:00:00 2001 From: jp9000 Date: Thu, 4 Jun 2015 17:10:00 -0700 Subject: [PATCH] libobs: Increase async jitter compensation Due to the fact that async timestamps themselves can be susceptible to minor jitter from certain types of inputs, increase the allowable jitter compensation value to ensure that the rendered frame timing from async video sources is always as close as possible to the compositor. When the framerate of the source is the same as the framerate as the compositor, this (combined with the fact that clamped video timing now being used with async video frames) helps ensure that buffered async video sources will sync up their rendering to the compositor as accurately as possible despite jitter from the source's timestamps. If there is no jitter in the source's timestamps then it'll always sync up perfectly with the compositor, thanks to clamped video timing. --- libobs/obs-source.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libobs/obs-source.c b/libobs/obs-source.c index 91b86c845..ddc88d9c8 100644 --- a/libobs/obs-source.c +++ b/libobs/obs-source.c @@ -2154,7 +2154,7 @@ static bool ready_async_frame(obs_source_t *source, uint64_t sys_time) * helps smooth out async rendering to frame boundaries. In * other words, tries to keep the framerate as smooth as * possible */ - if ((source->last_frame_ts - next_frame->timestamp) < 1000000) + if ((source->last_frame_ts - next_frame->timestamp) < 2000000) break; if (frame)