diff options
author | Olivier CrĂȘte <olivier.crete@collabora.co.uk> | 2009-08-22 04:50:09 +0800 |
---|---|---|
committer | Olivier CrĂȘte <olivier.crete@collabora.co.uk> | 2009-08-22 04:50:09 +0800 |
commit | 1c989a207a5ef27f88b1c4a1a1b68cfcfd1d6efe (patch) | |
tree | e5d61bbc9437b79e21027b3a8cdf52d28aac7724 /libempathy-gtk/empathy-video-src.c | |
parent | 3803736b4326d4bc00d58ccd25f910907f0b4521 (diff) | |
download | gsoc2013-empathy-1c989a207a5ef27f88b1c4a1a1b68cfcfd1d6efe.tar gsoc2013-empathy-1c989a207a5ef27f88b1c4a1a1b68cfcfd1d6efe.tar.gz gsoc2013-empathy-1c989a207a5ef27f88b1c4a1a1b68cfcfd1d6efe.tar.bz2 gsoc2013-empathy-1c989a207a5ef27f88b1c4a1a1b68cfcfd1d6efe.tar.lz gsoc2013-empathy-1c989a207a5ef27f88b1c4a1a1b68cfcfd1d6efe.tar.xz gsoc2013-empathy-1c989a207a5ef27f88b1c4a1a1b68cfcfd1d6efe.tar.zst gsoc2013-empathy-1c989a207a5ef27f88b1c4a1a1b68cfcfd1d6efe.zip |
Properly register video source gstreamer element too
Diffstat (limited to 'libempathy-gtk/empathy-video-src.c')
-rw-r--r-- | libempathy-gtk/empathy-video-src.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/libempathy-gtk/empathy-video-src.c b/libempathy-gtk/empathy-video-src.c index bd014a5d9..96324e06c 100644 --- a/libempathy-gtk/empathy-video-src.c +++ b/libempathy-gtk/empathy-video-src.c @@ -137,7 +137,15 @@ empathy_video_src_finalize (GObject *object) GstElement * empathy_video_src_new (void) { - return GST_ELEMENT (g_object_new (EMPATHY_TYPE_GST_VIDEO_SRC, NULL)); + static gboolean registered = FALSE; + + if (!registered) { + if (!gst_element_register (NULL, "empathyvideosrc", + GST_RANK_NONE, EMPATHY_TYPE_GST_VIDEO_SRC)) + return NULL; + registered = TRUE; + } + return gst_element_factory_make ("empathyvideosrc", NULL); } void |