From: <bi...@fr...> - 2005-12-20 11:16:45
|
CVS Root: /cvs/gstreamer Module: gst-python Changes by: bilboed Date: Tue Dec 20 2005 03:16:02 PST Log message: * gst/gst-types.defs: Added GstStaticCaps and GstStaticPadTemplate, using the new GType. * gst/gst.defs: Doesn't return a const anymore. * gst/gstelementfactory.override: Wrapped gst_element_factory_get_static_pad_templates() Modified files: . : ChangeLog gst : gst-types.defs gst.defs gstelementfactory.override Links: http://freedesktop.org/cgi-bin/viewcvs.cgi/gstreamer/gst-python/ChangeLog.diff?r1=1.385&r2=1.386 http://freedesktop.org/cgi-bin/viewcvs.cgi/gstreamer/gst-python/gst/gst-types.defs.diff?r1=1.46&r2=1.47 http://freedesktop.org/cgi-bin/viewcvs.cgi/gstreamer/gst-python/gst/gst.defs.diff?r1=1.100&r2=1.101 http://freedesktop.org/cgi-bin/viewcvs.cgi/gstreamer/gst-python/gst/gstelementfactory.override.diff?r1=1.1&r2=1.2 ====Begin Diffs==== Index: ChangeLog =================================================================== RCS file: /cvs/gstreamer/gst-python/ChangeLog,v retrieving revision 1.385 retrieving revision 1.386 diff -u -d -r1.385 -r1.386 --- ChangeLog 19 Dec 2005 17:49:30 -0000 1.385 +++ ChangeLog 20 Dec 2005 11:15:49 -0000 1.386 @@ -1,3 +1,12 @@ +2005-12-20 Edward Hervey <ed...@fl...> + + * gst/gst-types.defs: + Added GstStaticCaps and GstStaticPadTemplate, using the new GType. + * gst/gst.defs: + Doesn't return a const anymore. + * gst/gstelementfactory.override: + Wrapped gst_element_factory_get_static_pad_templates() 2005-12-19 Martin Soto <mar...@us...> * gst/gstbus.override (_wrap_gst_bus_add_watch): This function Index: gst-types.defs RCS file: /cvs/gstreamer/gst-python/gst/gst-types.defs,v retrieving revision 1.46 retrieving revision 1.47 diff -u -d -r1.46 -r1.47 --- gst-types.defs 30 Nov 2005 11:50:04 -0000 1.46 +++ gst-types.defs 20 Dec 2005 11:15:49 -0000 1.47 @@ -277,6 +277,28 @@ ) ) +(define-pointer StaticPadTemplate + (in-module "Gst") + (c-name "GstStaticPadTemplate") + (gtype-id "GST_TYPE_STATIC_PAD_TEMPLATE") + (fields + '("gchar*" "name_template") + '("GstPadDirection" "direction") + '("GstPadPresence" "presence") + '("GstStaticCaps" "static_caps") + ) +) +(define-pointer StaticCaps + (c-name "GstStaticCaps") + (gtype-id "GST_TYPE_STATIC_CAPS") + '("GstCaps" "caps") + '("const-gchar*" "string") ;; Enumerations and flags ... (define-flags BinFlags Index: gst.defs RCS file: /cvs/gstreamer/gst-python/gst/gst.defs,v retrieving revision 1.100 retrieving revision 1.101 diff -u -d -r1.100 -r1.101 --- gst.defs 18 Dec 2005 17:20:12 -0000 1.100 +++ gst.defs 20 Dec 2005 11:15:49 -0000 1.101 @@ -488,7 +488,7 @@ (define-method get (of-object "GstStaticCaps") (c-name "gst_static_caps_get") - (return-type "const-GstCaps*") + (return-type "GstCaps*") (define-method append Index: gstelementfactory.override RCS file: /cvs/gstreamer/gst-python/gst/gstelementfactory.override,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- gstelementfactory.override 13 Oct 2005 10:41:06 -0000 1.1 +++ gstelementfactory.override 20 Dec 2005 11:15:50 -0000 1.2 @@ -1,3 +1,4 @@ +/* -*- Mode: C; c-basic-offset: 4 -*- */ /* * gstelementfactory.override - gstreamer element factory override * Copyright (C) 2005 Alessandro Decina @@ -41,4 +42,23 @@ pygst_object_unref((GObject *)ret); return py_ret; } +%% +override gst_element_factory_get_static_pad_templates noargs +static PyObject * +_wrap_gst_element_factory_get_static_pad_templates(PyGObject *self) +{ + const GList *list; + GList *l; + PyObject *py_list; + int i = 0; + list = gst_element_factory_get_static_pad_templates (GST_ELEMENT_FACTORY (self->obj)); + py_list = PyList_New(g_list_length ((GList*) list)); + for (l = (GList*) list; l ; l = g_list_next(l), i++) { + GstStaticPadTemplate *templ = (GstStaticPadTemplate*) l->data; + PyList_SetItem(py_list, i, pyg_pointer_new(GST_TYPE_STATIC_PAD_TEMPLATE, (gpointer) templ)); + } + return py_list; +} |