mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-26 19:51:11 +00:00
video-test-source: fix caps leak
This commit is contained in:
parent
0c5dfcf931
commit
b3114b6a4d
1 changed files with 5 additions and 2 deletions
|
@ -61,6 +61,7 @@ ges_video_test_source_init (GESVideoTestSource * self)
|
|||
static GstElement *
|
||||
ges_video_test_source_create_source (GESTrackElement * self)
|
||||
{
|
||||
GstCaps *caps;
|
||||
gint pattern;
|
||||
GstElement *testsrc, *capsfilter;
|
||||
const gchar *props[] = { "pattern", NULL };
|
||||
|
@ -70,8 +71,10 @@ ges_video_test_source_create_source (GESTrackElement * self)
|
|||
pattern = ((GESVideoTestSource *) self)->priv->pattern;
|
||||
|
||||
g_object_set (testsrc, "pattern", pattern, NULL);
|
||||
g_object_set (capsfilter, "caps", gst_caps_new_empty_simple ("video/x-raw"),
|
||||
NULL);
|
||||
|
||||
caps = gst_caps_new_empty_simple ("video/x-raw");
|
||||
g_object_set (capsfilter, "caps", caps, NULL);
|
||||
gst_caps_unref (caps);
|
||||
|
||||
ges_track_element_add_children_props (self, testsrc, NULL, NULL, props);
|
||||
|
||||
|
|
Loading…
Reference in a new issue