[vlc-devel] [PATCH] video_output: rename next_system_pts
Steve Lhomme
robux4 at ycbcr.xyz
Thu Feb 4 08:46:50 UTC 2021
It is a confusing name as it's now the system PTS of displayed.current.
Also rework the late test to be more readable.
---
src/video_output/video_output.c | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/src/video_output/video_output.c b/src/video_output/video_output.c
index 323b40c0846..cc24a74a5a7 100644
--- a/src/video_output/video_output.c
+++ b/src/video_output/video_output.c
@@ -1521,13 +1521,12 @@ static int ThreadDisplayPicture(vout_thread_sys_t *vout, vlc_tick_t *deadline)
}
else if (!paused)
{
- const vlc_tick_t next_system_pts =
+ const vlc_tick_t system_current_pts =
vlc_clock_ConvertToSystem(sys->clock, system_now,
sys->displayed.current->date, sys->rate);
- if (likely(next_system_pts != INT64_MAX))
+ if (likely(system_current_pts != INT64_MAX))
{
- vlc_tick_t date_next = next_system_pts - render_delay;
- if (date_next <= system_now)
+ if (system_now + render_delay >= system_current_pts)
{
// the current frame will be late, look for the next not late one
next =
--
2.29.2
More information about the vlc-devel
mailing list