videosink: Set processing deadline to 15ms
authorOlivier CrĂȘte <olivier.crete@collabora.com>
Fri, 20 Oct 2017 16:36:55 +0000 (18:36 +0200)
committerNicolas Dufresne <nicolas.dufresne@collabora.com>
Sat, 7 Jul 2018 12:59:30 +0000 (08:59 -0400)
This roughly corresponds to one frame at 60fps, and leave 5ms
of max_lateness to not change the existing behaviour.

https://bugzilla.gnome.org/show_bug.cgi?id=640610

gst-libs/gst/video/gstvideosink.c

index 819eea6..6130cf3 100644 (file)
@@ -142,7 +142,9 @@ gst_video_sink_init (GstVideoSink * videosink)
   videosink->height = 0;
 
   /* 20ms is more than enough, 80-130ms is noticable */
-  gst_base_sink_set_max_lateness (GST_BASE_SINK (videosink), 20 * GST_MSECOND);
+  gst_base_sink_set_processing_deadline (GST_BASE_SINK (videosink),
+      15 * GST_MSECOND);
+  gst_base_sink_set_max_lateness (GST_BASE_SINK (videosink), 5 * GST_MSECOND);
   gst_base_sink_set_qos_enabled (GST_BASE_SINK (videosink), TRUE);
 
   videosink->priv = gst_video_sink_get_instance_private (videosink);