[empathy] VideoSrc: add API to get the input device



commit aed7faf9c81e1ca54398d16988b890322bf09889
Author: Emilio Pozuelo Monfort <emilio pozuelo collabora co uk>
Date:   Mon Aug 1 17:27:47 2011 +0100

    VideoSrc: add API to get the input device

 src/empathy-video-src.c |   11 +++++++++++
 src/empathy-video-src.h |    1 +
 2 files changed, 12 insertions(+), 0 deletions(-)
---
diff --git a/src/empathy-video-src.c b/src/empathy-video-src.c
index 4017990..ceb3442 100644
--- a/src/empathy-video-src.c
+++ b/src/empathy-video-src.c
@@ -374,3 +374,14 @@ empathy_video_src_change_device (EmpathyGstVideoSrc *self,
   g_object_set (priv->src, "device", device, NULL);
   gst_element_set_state (priv->src, state);
 }
+
+gchar *
+empathy_video_src_dup_device (EmpathyGstVideoSrc *self)
+{
+  EmpathyGstVideoSrcPrivate *priv = EMPATHY_GST_VIDEO_SRC_GET_PRIVATE (self);
+  gchar *device;
+
+  g_object_get (priv->src, "device", &device, NULL);
+
+  return device;
+}
diff --git a/src/empathy-video-src.h b/src/empathy-video-src.h
index a652763..6a88b79 100644
--- a/src/empathy-video-src.h
+++ b/src/empathy-video-src.h
@@ -83,6 +83,7 @@ guint empathy_video_src_get_channel (GstElement *src,
 
 void empathy_video_src_change_device (EmpathyGstVideoSrc *self,
   const gchar *device);
+gchar * empathy_video_src_dup_device (EmpathyGstVideoSrc *self);
 
 G_END_DECLS
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]