[vlc-commits] [Git][videolan/vlc][master] video_output: flush static filters on picture drop

Jean-Baptiste Kempf (@jbk) gitlab at videolan.org
Wed May 25 14:13:33 UTC 2022



Jean-Baptiste Kempf pushed to branch master at VideoLAN / VLC


Commits:
8d390163 by Alexandre Janniaux at 2022-05-25T13:53:42+00:00
video_output: flush static filters on picture drop

Filters like deinterlacers are using timestamps interpolation to
generate intermediate frames, which might not work reliably when the
timestamps are not from consecutive frames.

When dropping a decoded picture, we were not notifying those filters and
the next frame was arbitrarily further than the one the filter might
expect.

Ideally, we would notify which frames has been dropped to the filter, so
that it can differentiate a real discontinuity from a drop and can
handle its history correctly, but flushing is still better than doing
nothing and history is not really well exposed for now anyway.

- - - - -


1 changed file:

- src/video_output/video_output.c


Changes:

=====================================
src/video_output/video_output.c
=====================================
@@ -919,6 +919,10 @@ static picture_t *PreparePicture(vout_thread_sys_t *vout, bool reuse_decoded,
                     {
                         picture_Release(decoded);
                         vout_statistic_AddLost(&sys->statistic, 1);
+
+                        /* A picture dropped means discontinuity for the
+                         * filters and we need to notify eg. deinterlacer. */
+                        filter_chain_VideoFlush(sys->filter.chain_static);
                         continue;
                     }
                 }



View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/8d390163d6c828830bde8520e05b874a34593f35

-- 
View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/8d390163d6c828830bde8520e05b874a34593f35
You're receiving this email because of your account on code.videolan.org.


VideoLAN code repository instance


More information about the vlc-commits mailing list