mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-20 23:36:38 +00:00
icles: Only accept plain subtitles in the playbin-text icles test
This commit is contained in:
parent
1d21ce0da2
commit
ac0f387add
1 changed files with 4 additions and 0 deletions
|
@ -126,6 +126,7 @@ main (int argc, char *argv[])
|
||||||
{
|
{
|
||||||
App *app = &s_app;
|
App *app = &s_app;
|
||||||
GstBus *bus;
|
GstBus *bus;
|
||||||
|
GstCaps *subcaps;
|
||||||
|
|
||||||
gst_init (&argc, &argv);
|
gst_init (&argc, &argv);
|
||||||
|
|
||||||
|
@ -146,6 +147,9 @@ main (int argc, char *argv[])
|
||||||
g_object_set (G_OBJECT (app->textsink), "ts-offset", 0 * GST_SECOND, NULL);
|
g_object_set (G_OBJECT (app->textsink), "ts-offset", 0 * GST_SECOND, NULL);
|
||||||
g_signal_connect (app->textsink, "new-buffer", G_CALLBACK (have_subtitle),
|
g_signal_connect (app->textsink, "new-buffer", G_CALLBACK (have_subtitle),
|
||||||
app);
|
app);
|
||||||
|
subcaps = gst_caps_from_string ("text/x-pango-markup; text/plain");
|
||||||
|
g_object_set (G_OBJECT (app->textsink), "caps", subcaps, NULL);
|
||||||
|
gst_caps_unref (subcaps);
|
||||||
|
|
||||||
g_object_set (G_OBJECT (app->playbin), "text-sink", app->textsink, NULL);
|
g_object_set (G_OBJECT (app->playbin), "text-sink", app->textsink, NULL);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue