[gstreamermm] Wrapped ChildProxy::lookup() and BaseAudioSink::create_ring_buffer().



commit e5654176db53e93c9d9fecbe8245a03f495d023c
Author: José Alburquerque <jaalburqu svn gnome org>
Date:   Sun May 10 17:29:33 2009 -0400

    Wrapped ChildProxy::lookup() and BaseAudioSink::create_ring_buffer().
---
 ChangeLog                       |    9 +++++++++
 gstreamer/src/baseaudiosink.ccg |    1 +
 gstreamer/src/baseaudiosink.hg  |    5 +++--
 gstreamer/src/childproxy.ccg    |   11 +++++++++++
 gstreamer/src/childproxy.hg     |    4 +++-
 gstreamer/src/object.hg         |    1 +
 tools/m4/convert_gst.m4         |    3 +++
 7 files changed, 31 insertions(+), 3 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index fbae99a..432a893 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2009-05-10  José Alburquerque  <jaalburqu svn gnome org>
+
+	* gstreamer/src/childproxy.ccg:
+	* gstreamer/src/childproxy.hg: Wrapped lookup().
+	* gstreamer/src/object.hg: Added TODO about GParamSpec.
+	* gstreamer/src/baseaudiosink.ccg:
+	* gstreamer/src/baseaudiosink.hg: Wrapped create_ring_buffer().
+	* tools/m4/convert_gst.m4: Added GstRingBuffer conversion.
+
 2009-05-05  José Alburquerque  <jaalburqu svn gnome org>
 
 	* gstreamer/src/ringbuffer.ccg:
diff --git a/gstreamer/src/baseaudiosink.ccg b/gstreamer/src/baseaudiosink.ccg
index b403535..f1ef70f 100644
--- a/gstreamer/src/baseaudiosink.ccg
+++ b/gstreamer/src/baseaudiosink.ccg
@@ -18,4 +18,5 @@
  */
 
 #include <gst/audio/gstbaseaudiosink.h>
+#include <gstreamermm/ringbuffer.h>
 _PINCLUDE(gstreamermm/private/basesink_p.h)
diff --git a/gstreamer/src/baseaudiosink.hg b/gstreamer/src/baseaudiosink.hg
index d7640a5..f7dee5d 100644
--- a/gstreamer/src/baseaudiosink.hg
+++ b/gstreamer/src/baseaudiosink.hg
@@ -24,6 +24,8 @@ _DEFS(gstreamermm,gst)
 namespace Gst
 {
 
+class RingBuffer;
+
 _WRAP_ENUM(BaseAudioSinkSlaveMethod, GstBaseAudioSinkSlaveMethod)
 
 /** Gst::BaseAudioSink - Base class for audio sinks.
@@ -44,8 +46,7 @@ public:
    */
   _MEMBER_GET(provided_clock, provided_clock, Glib::RefPtr<Gst::Clock>, GstClock*)
 
-  //TODO: _WRAP_METHOD(Glib::RefPtr<Gst::RingBuffer> create_ring_buffer(), gst_base_audio_sink_create_ringbuffer)
-
+  _WRAP_METHOD(Glib::RefPtr<Gst::RingBuffer> create_ring_buffer(), gst_base_audio_sink_create_ringbuffer)
   _WRAP_METHOD(void set_provide_clock(bool provide), gst_base_audio_sink_set_provide_clock)
   _WRAP_METHOD(bool get_provide_clock() const, gst_base_audio_sink_get_provide_clock)
 
diff --git a/gstreamer/src/childproxy.ccg b/gstreamer/src/childproxy.ccg
index e4da9c8..c0efade 100644
--- a/gstreamer/src/childproxy.ccg
+++ b/gstreamer/src/childproxy.ccg
@@ -20,6 +20,17 @@
 namespace Gst
 {
 
+bool ChildProxy::lookup(const Glib::RefPtr<Gst::Object>& object,
+  const Glib::ustring& name, Glib::RefPtr<Gst::Object>& target,
+  GParamSpec*& pspec)
+{
+  GstObject* gst_object = 0;
+  bool const result = gst_child_proxy_lookup(object->gobj(), name.c_str(),
+    &gst_object, & pspec);
+  target = Glib::wrap(gst_object);
+  return result;
+}
+
 Glib::RefPtr<Gst::ChildProxy> ChildProxy::get_proxy_property(const Glib::ustring& name, Glib::ValueBase& value)
 {
   gst_child_proxy_get_property(GST_OBJECT(gobj()), name.c_str(), value.gobj());
diff --git a/gstreamer/src/childproxy.hg b/gstreamer/src/childproxy.hg
index 28765a4..adc62b1 100644
--- a/gstreamer/src/childproxy.hg
+++ b/gstreamer/src/childproxy.hg
@@ -52,7 +52,9 @@ public:
   _WRAP_METHOD(Glib::RefPtr<Gst::Object> get_child(guint index), gst_child_proxy_get_child_by_index)
   _WRAP_METHOD(Glib::RefPtr<const Gst::Object> get_child(guint index) const, gst_child_proxy_get_child_by_index)
 
-  //TODO: should gst_child_proxy_lookup() be wrapped?
+  _WRAP_METHOD_DOCS_ONLY(gst_child_proxy_lookup)
+  //TODO: Maybe GParamSpec should be wrapped in glibmm?
+  static bool lookup(const Glib::RefPtr<Gst::Object>& object, const Glib::ustring& name, Glib::RefPtr<Gst::Object>& target, GParamSpec*& pspec);
 
   /** Gets a single property using the Gst::ChildProxy mechanism.
    * @param name The property to get.
diff --git a/gstreamer/src/object.hg b/gstreamer/src/object.hg
index 161ee0f..7b951b7 100644
--- a/gstreamer/src/object.hg
+++ b/gstreamer/src/object.hg
@@ -103,6 +103,7 @@ public:
    * typically attached to the toplevel bin to receive notifications from all
    * the elements contained in that bin.
    */
+  //TODO: Maybe GParamSpec should be wrapped in glibmm?
   _WRAP_SIGNAL(void deep_notify(const Glib::RefPtr<Object>& prop_object, GParamSpec* prop), "deep-notify")
 
   /** Trigered whenever a new object is saved to XML. You can connect to this
diff --git a/tools/m4/convert_gst.m4 b/tools/m4/convert_gst.m4
index 28f35d7..d12d9bd 100644
--- a/tools/m4/convert_gst.m4
+++ b/tools/m4/convert_gst.m4
@@ -139,6 +139,9 @@ _CONVERSION(`const Glib::RefPtr<Gst::Query>&',`GstQuery*', `Gst::unwrap($3)')
 #Registry
 _CONVERSION(`GstRegistry*',`Glib::RefPtr<Gst::Registry>', `Glib::wrap($3)')
 
+#RingBuffer
+_CONVERSION(`GstRingBuffer*',`Glib::RefPtr<Gst::RingBuffer>',`Glib::wrap($3)')
+
 #Structure
 _CONVERSION(`Gst::Structure&',`GstStructure*',`$3.gobj()')
 



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