mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 12:11:13 +00:00
video-test-src: Force video/x-raw
Avoiding to hit errors with video/x-bayer
This commit is contained in:
parent
a2f8dbd3d1
commit
602f49f3e1
1 changed files with 11 additions and 5 deletions
|
@ -61,13 +61,18 @@ ges_video_test_source_init (GESVideoTestSource * self)
|
||||||
static GstElement *
|
static GstElement *
|
||||||
ges_video_test_source_create_element (GESTrackElement * self)
|
ges_video_test_source_create_element (GESTrackElement * self)
|
||||||
{
|
{
|
||||||
GstElement *ret;
|
|
||||||
gint pattern;
|
gint pattern;
|
||||||
|
GstElement *ret;
|
||||||
|
gchar *bin_desc;
|
||||||
|
|
||||||
|
|
||||||
pattern = ((GESVideoTestSource *) self)->priv->pattern;
|
pattern = ((GESVideoTestSource *) self)->priv->pattern;
|
||||||
|
bin_desc =
|
||||||
ret = gst_element_factory_make ("videotestsrc", NULL);
|
g_strdup_printf
|
||||||
g_object_set (ret, "pattern", (gint) pattern, NULL);
|
("videotestsrc pattern=%i name=testsrc ! capsfilter caps=video/x-raw",
|
||||||
|
pattern);
|
||||||
|
ret = gst_parse_bin_from_description (bin_desc, TRUE, NULL);
|
||||||
|
g_free (bin_desc);
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
@ -89,7 +94,8 @@ ges_video_test_source_set_pattern (GESVideoTestSource
|
||||||
self->priv->pattern = pattern;
|
self->priv->pattern = pattern;
|
||||||
|
|
||||||
if (element)
|
if (element)
|
||||||
g_object_set (element, "pattern", (gint) pattern, NULL);
|
gst_child_proxy_set (GST_CHILD_PROXY (element), "testsrc::pattern",
|
||||||
|
(gint) pattern, NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in a new issue