v4l2object: Add gst_v4l2_object_open_shared()
authorNicolas Dufresne <nicolas.dufresne@collabora.com>
Thu, 28 Nov 2013 22:09:26 +0000 (17:09 -0500)
committerNicolas Dufresne <nicolas.dufresne@collabora.com>
Fri, 10 Jan 2014 22:13:22 +0000 (17:13 -0500)
https://bugzilla.gnome.org/show_bug.cgi?id=720568

sys/v4l2/gstv4l2object.c
sys/v4l2/gstv4l2object.h

index 55f2b00..e62b049 100644 (file)
@@ -920,6 +920,20 @@ gst_v4l2_object_open (GstV4l2Object * v4l2object)
 }
 
 gboolean
+gst_v4l2_object_open_shared (GstV4l2Object * v4l2object, GstV4l2Object * other)
+{
+  gboolean ret;
+
+  ret = gst_v4l2_dup (v4l2object, other);
+
+#ifdef HAVE_XVIDEO
+  gst_v4l2_video_overlay_start (v4l2object);
+#endif
+
+  return ret;
+}
+
+gboolean
 gst_v4l2_object_close (GstV4l2Object * v4l2object)
 {
 #ifdef HAVE_XVIDEO
index 02b4309..fb5007d 100644 (file)
@@ -229,6 +229,7 @@ gboolean     gst_v4l2_object_get_property_helper       (GstV4l2Object *v4l2objec
                                                         GParamSpec * pspec);
 /* open/close */
 gboolean     gst_v4l2_object_open            (GstV4l2Object *v4l2object);
+gboolean     gst_v4l2_object_open_shared     (GstV4l2Object *v4l2object, GstV4l2Object *other);
 gboolean     gst_v4l2_object_close           (GstV4l2Object *v4l2object);
 
 /* probing */