[gstreamermm] Gst::Caps: move inline _CONVERSION definitions to convert_gst.m4



commit 64dd2b735ea9f98df3295b04535c11e6b1c9b261
Author: Michał Wróbel <michal wrobel flytronic pl>
Date:   Mon Jul 6 11:43:56 2015 +0200

    Gst::Caps: move inline _CONVERSION definitions to convert_gst.m4
    
        * gstreamer/src/basesink.hg:
        * gstreamer/src/basesrc.hg:
        * gstreamer/src/basetransform.hg: remove inline _CONVERSION
          definitions.
        * tools/m4/convert_gst.m4: add _CONVERSION definitions globally.

 gstreamer/src/basesink.hg      |    2 --
 gstreamer/src/basesrc.hg       |    3 ---
 gstreamer/src/basetransform.hg |    2 --
 tools/m4/convert_gst.m4        |    2 ++
 4 files changed, 2 insertions(+), 7 deletions(-)
---
diff --git a/gstreamer/src/basesink.hg b/gstreamer/src/basesink.hg
index 0b7d2c8..8d9a8a7 100644
--- a/gstreamer/src/basesink.hg
+++ b/gstreamer/src/basesink.hg
@@ -233,8 +233,6 @@ public:
   _WRAP_PROPERTY("max-bitrate", guint64)
 
 
-#m4 _CONVERSION(`Glib::RefPtr<Gst::Caps>', `GstCaps*', `Glib::unwrap($3)')
-#m4 _CONVERSION(`GstCaps*', `const Glib::RefPtr<Gst::Caps>&', `Glib::wrap($3, true)')
   /** Called to get sink pad caps from the subclass.
    */
   _WRAP_VFUNC(Glib::RefPtr<Gst::Caps> get_caps(const Glib::RefPtr<Gst::Caps>& caps) const, "get_caps", 
refreturn_ctype)
diff --git a/gstreamer/src/basesrc.hg b/gstreamer/src/basesrc.hg
index 6ab8741..10d9fc6 100644
--- a/gstreamer/src/basesrc.hg
+++ b/gstreamer/src/basesrc.hg
@@ -178,9 +178,6 @@ public:
   _WRAP_PROPERTY("num-buffers", int)
   _WRAP_PROPERTY("typefind", bool)
 
-#m4 _CONVERSION(`Glib::RefPtr<Gst::Caps>', `GstCaps*', `Glib::unwrap($3)')
-#m4 _CONVERSION(`GstCaps*', `const Glib::RefPtr<Gst::Caps>&', `Glib::wrap($3, true)')
-
   /** Called to get the caps to report.
    */
   _WRAP_VFUNC(Glib::RefPtr<Gst::Caps> get_caps(const Glib::RefPtr<Gst::Caps>& caps) const, "get_caps", 
refreturn_ctype)
diff --git a/gstreamer/src/basetransform.hg b/gstreamer/src/basetransform.hg
index 003e76f..f9dc859 100644
--- a/gstreamer/src/basetransform.hg
+++ b/gstreamer/src/basetransform.hg
@@ -166,7 +166,6 @@ public:
 
   _WRAP_PROPERTY("qos", bool)
 
-#m4 _CONVERSION(`GstCaps*', `const Glib::RefPtr<Gst::Caps>&', `Glib::wrap($3, true)')
   /** Optional. Given the pad in this direction and the given caps, what caps
    * are allowed on the other pad in this element ?
    */
@@ -226,7 +225,6 @@ public:
    */
   _WRAP_VFUNC(void before_transform(const Glib::RefPtr<Gst::Buffer>& buffer), "before_transform")
 
-#m4 _CONVERSION(`GstCaps*', `const Glib::RefPtr<const Gst::Caps>&', `Glib::wrap($3, true)')
   /** Optional. Since 0.10.30 Subclasses can override this method to check if
    * the caps can be handled by the element. The default implementation might
    * not be the most optimal way to check this in all cases.
diff --git a/tools/m4/convert_gst.m4 b/tools/m4/convert_gst.m4
index 8ecb922..8204571 100644
--- a/tools/m4/convert_gst.m4
+++ b/tools/m4/convert_gst.m4
@@ -90,6 +90,8 @@ _CONVERSION(`GstBus*',`Glib::RefPtr<Gst::Bus>',`Glib::wrap($3)')
 dnl Caps
 _CONVERSION(`GstCaps*',`Glib::RefPtr<Gst::Caps>',`Glib::wrap($3)')
 _CONVERSION(`GstCaps*',`Glib::RefPtr<const Gst::Caps>',`Glib::wrap($3)')
+_CONVERSION(`GstCaps*',`const Glib::RefPtr<Gst::Caps>&',`Glib::wrap($3, true)')
+_CONVERSION(`GstCaps*',`const Glib::RefPtr<const Gst::Caps>&',`Glib::wrap($3, true)')
 _CONVERSION(`const GstCaps*',`const Glib::RefPtr<const Gst::Caps>&',`Glib::wrap(const_cast<GstCaps*>($3))')
 _CONVERSION(`Glib::RefPtr<Gst::Caps>',`GstCaps*',`Glib::unwrap($3)')
 _CONVERSION(`const Glib::RefPtr<Gst::Caps>&',`GstCaps*', `Glib::unwrap($3)')


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