summaryrefslogtreecommitdiff
path: root/ext/directfb
diff options
context:
space:
mode:
authorSebastian Dröge <sebastian@centricular.com>2016-04-13 10:25:32 +0300
committerSebastian Dröge <sebastian@centricular.com>2016-04-13 10:25:32 +0300
commit6c020b7f3c617814b6d36beef103492f814086b2 (patch)
tree32232653913bc5d3ae6fe112308cc8d030b3867d /ext/directfb
parentccc068576a96935dddbf453820beca0d6d5112b6 (diff)
downloadgstreamer-plugins-bad-6c020b7f3c617814b6d36beef103492f814086b2.tar.gz
meta: Initialize all remaining metas in their init function
https://bugzilla.gnome.org/show_bug.cgi?id=764902
Diffstat (limited to 'ext/directfb')
-rw-r--r--ext/directfb/dfbvideosink.c16
1 files changed, 15 insertions, 1 deletions
diff --git a/ext/directfb/dfbvideosink.c b/ext/directfb/dfbvideosink.c
index 4899147db..a6f433bfa 100644
--- a/ext/directfb/dfbvideosink.c
+++ b/ext/directfb/dfbvideosink.c
@@ -168,6 +168,19 @@ gst_meta_dfbsurface_api_get_type (void)
return type;
}
+static gboolean
+gst_meta_dfbsurface_init (GstMetaDfbSurface * meta, gpointer params,
+ GstBuffer * buf)
+{
+ meta->surface = NULL;
+ meta->width = meta->height = 0;
+ meta->locked = FALSE;
+ meta->pixel_format = 0;
+ meta->dfbvideosink = NULL;
+
+ return TRUE;
+}
+
/* our metadata */
const GstMetaInfo *
gst_meta_dfbsurface_get_info (void)
@@ -178,7 +191,8 @@ gst_meta_dfbsurface_get_info (void)
const GstMetaInfo *meta =
gst_meta_register (gst_meta_dfbsurface_api_get_type (),
"GstMetaDfbSurface", sizeof (GstMetaDfbSurface),
- (GstMetaInitFunction) NULL, (GstMetaFreeFunction) NULL,
+ (GstMetaInitFunction) gst_meta_dfbsurface_init,
+ (GstMetaFreeFunction) NULL,
(GstMetaTransformFunction) NULL);
g_once_init_leave (&meta_info, meta);
}