playsink: do not store more than a second of subtitles
authorThiago Santos <thiago.sousa.santos@collabora.com>
Mon, 14 May 2012 14:52:12 +0000 (11:52 -0300)
committerThiago Santos <thiago.sousa.santos@collabora.com>
Wed, 6 Jun 2012 19:31:08 +0000 (16:31 -0300)
Use a shorter queue for subtitles to avoid switches for subtitles
taking longer than they already take.

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

gst/playback/gstplaysink.c

index b772ba32aa5d8130f65857f5602f35e34fc3e7ee..24872a67ffcae579ca3489bfe8c19de169fec686 100644 (file)
@@ -1890,7 +1890,7 @@ gen_text_chain (GstPlaySink * playsink)
                   "queue"), ("rendering might be suboptimal"));
         } else {
           g_object_set (G_OBJECT (chain->queue), "max-size-buffers", 3,
-              "max-size-bytes", 0, "max-size-time", (gint64) 0,
+              "max-size-bytes", 0, "max-size-time", (gint64) GST_SECOND,
               "silent", TRUE, NULL);
           gst_bin_add (bin, chain->queue);
         }
@@ -1979,7 +1979,7 @@ gen_text_chain (GstPlaySink * playsink)
                   "queue"), ("rendering might be suboptimal"));
         } else {
           g_object_set (G_OBJECT (element), "max-size-buffers", 3,
-              "max-size-bytes", 0, "max-size-time", (gint64) 0,
+              "max-size-bytes", 0, "max-size-time", (gint64) GST_SECOND,
               "silent", TRUE, NULL);
           gst_bin_add (bin, element);
           if (gst_element_link_pads_full (element, "src", chain->overlay,