[vlc-devel] [PATCH v2 06/18] video_output: rename drop_next_frame to display_next_frame

Steve Lhomme robux4 at ycbcr.xyz
Wed Sep 16 13:14:32 CEST 2020


That's what it really does. It actually forces to render the next frame because
we skip the current one.
---
 src/video_output/video_output.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/src/video_output/video_output.c b/src/video_output/video_output.c
index a6428d9da04..a5bce8f824e 100644
--- a/src/video_output/video_output.c
+++ b/src/video_output/video_output.c
@@ -1500,7 +1500,7 @@ static int ThreadDisplayPicture(vout_thread_sys_t *vout, vlc_tick_t *deadline)
     const vlc_tick_t system_now = vlc_tick_now();
     const vlc_tick_t render_delay = vout_chrono_GetHigh(&sys->render) + VOUT_MWAIT_TOLERANCE;
 
-    bool drop_next_frame = frame_by_frame;
+    bool display_next_frame = frame_by_frame;
 
     /* FIXME/XXX we must redisplay the last decoded picture (because
      * of potential vout updated, or filters update or SPU update)
@@ -1530,7 +1530,7 @@ static int ThreadDisplayPicture(vout_thread_sys_t *vout, vlc_tick_t *deadline)
             if (date_next <= system_now)
             {
                 // the next frame is late, skip the current one
-                drop_next_frame = true;
+                display_next_frame = true;
             }
 
             if (deadline != NULL) {
@@ -1540,13 +1540,13 @@ static int ThreadDisplayPicture(vout_thread_sys_t *vout, vlc_tick_t *deadline)
         }
     }
 
-    bool force_refresh = !drop_next_frame && refresh;
+    bool force_refresh = !display_next_frame && refresh;
 
-    if (!first && !refresh && !drop_next_frame) {
+    if (!first && !refresh && !display_next_frame) {
         return VLC_EGENERIC;
     }
 
-    if (drop_next_frame) {
+    if (display_next_frame) {
         picture_Release(sys->displayed.current);
         if (first)
         {
-- 
2.26.2



More information about the vlc-devel mailing list