+2007-06-08 Edward Hervey <edward@fluendo.com>
+
+ * configure.ac:
+ * gst/Makefile.am:
+ * gst/gst-0.10.12.ignore:
+ * gst/gst-0.10.13.ignore:
+ * gst/gstversion.override.in:
+ Updating ignores for API additions
+ * gst/base.defs:
+ * gst/gst-types.defs:
+ * gst/gst.defs:
+ * gst/interfaces.defs:
+ * gst/libs.defs:
+ Massive wrapping of new API additions
+ * gst/gstbase.override:
+ * gst/gstevent.override:
+ * gst/gstmessage.override:
+ * gst/gstquery.override:
+ Overrides for methods with return values as arguments.
+ * gst/xwindowlistener.defs:
+ What the $#@# is this file still doing here ?? Removing it.
+
2007-05-23 Edward Hervey <edward@fluendo.com>
* configure.ac:
IGNORE_GST_0_10_12=""
fi
+ if test $GST_MINOR_VERSION -lt "13"
+ then
+ IGNORE_GST_0_10_13="gst-0.10.13.ignore"
+ else
+ IGNORE_GST_0_10_13=""
+ fi
+
dnl plugins base
if test $GST_PB_MINOR_VERSION -lt "11"
then
IGNORE_GST_0_10_10=""
IGNORE_GST_0_10_11=""
IGNORE_GST_0_10_12=""
+ IGNORE_GST_0_10_13=""
IGNORE_GST_PB_0_10_11=""
AC_DEFINE_UNQUOTED(HAVE_VIDEO_ORIENTATION_INTERFACE, 1, [We can use the videoorientation interface])
fi
AC_SUBST(IGNORE_GST_0_10_10)
AC_SUBST(IGNORE_GST_0_10_11)
AC_SUBST(IGNORE_GST_0_10_12)
+AC_SUBST(IGNORE_GST_0_10_13)
AC_SUBST(IGNORE_GST_PB_0_10_11)
AC_SUBST(HAVE_VIDEO_ORIENTATION)
gst-0.10.10.ignore \
gst-0.10.11.ignore \
gst-0.10.12.ignore \
+ gst-0.10.13.ignore \
gst-pb-0.10.11.ignore \
gst-disable-loadsave.ignore
interfaces_la_SOURCES = interfacesmodule.c
nodist_interfaces_la_SOURCES = interfaces.c
INTERFACES_OVERRIDES = interfaces.override xoverlay.override
-INTERFACES_DEFS = interfaces.defs xoverlay.defs xwindowlistener.defs
+INTERFACES_DEFS = interfaces.defs xoverlay.defs
CLEANFILES += interfaces.c
EXTRA_DIST += $(INTERFACES_DEFS) $(INTERFACES_OVERRIDES)
interfaces.c: $(INTERFACES_DEFS) $(INTERFACES_OVERRIDES) $(GEN_FILES)
(return-type "gboolean")
)
+(define-method query_latency
+ (of-object "GstBaseSink")
+ (c-name "gst_base_sink_query_latency")
+ (return-type "gboolean")
+ (parameters
+ '("gboolean*" "live")
+ '("gboolean*" "upstream_live")
+ '("GstClockTime*" "min_latency")
+ '("GstClockTime*" "max_latency")
+ )
+)
+
+(define-method get_latency
+ (of-object "GstBaseSink")
+ (c-name "gst_base_sink_get_latency")
+ (return-type "GstClockTime")
+)
+
(define-virtual get_caps
(of-object "GstBaseSink")
(return-type "GstCaps*")
)
)
+(define-virtual activate_pull
+ (of-object "GstBaseSink")
+ (return-type "gboolean")
+ (parameters
+ '("gboolean" "active")
+ )
+)
+
+(define-virtual fixate
+ (of-object "GstBaseSink")
+ (return-type "none")
+ (parameters
+ '("GstCaps*" "caps")
+ )
+)
+
+(define-virtual unlock_stop
+ (of-object "GstBaseSink")
+ (return-type "gboolean")
+)
+
;; From ../gstreamer/libs/gst/base/gstbasesrc.h
(define-function gst_base_src_get_type
)
)
+(define-method query_latency
+ (of-object "GstBaseSrc")
+ (c-name "gst_base_src_query_latency")
+ (return-type "gboolean")
+ (parameters
+ '("gboolean*" "live")
+ '("GstClockTime*" "min_latency")
+ '("GstClockTime*" "max_latency")
+ )
+)
+
(define-virtual get_caps
(of-object "GstBaseSrc")
(return-type "GstCaps*")
(return-type "gboolean")
)
+(define-virtual fixate
+ (of-object "GstBaseSrc")
+ (return-type "none")
+ (parameters
+ '("GstCaps*" "caps")
+ )
+)
+
+(define-virtual unlock_stop
+ (of-object "GstBaseSrc")
+ (return-type "gboolean")
+)
+
+(define-virtual prepare_seek_segment
+ (of-object "GstBaseSrc")
+ (return-type "gboolean")
+ (parameters
+ '("GstEvent*" "seek")
+ '("GstSegment*" "segment")
+ )
+)
+
+
;; From ../gstreamer/libs/gst/base/gstbasetransform.h
(define-function gst_base_transform_get_type
)
)
+(define-virtual src_event
+ (of-object "GstBaseTransform")
+ (return-type "gboolean")
+ (parameters
+ '("GstEvent*" "event")
+ )
+)
;; From ../gstreamer/libs/gst/base/gstcollectpads.h
)
)
+(define-method add_pad_full
+ (of-object "GstCollectPads")
+ (c-name "gst_collect_pads_add_pad_full")
+ (return-type "GstCollectData*")
+ (parameters
+ '("GstPad*" "pad")
+ '("guint" "size")
+ '("GstCollectDataDestroyNotify" "destroy_notify")
+ )
+)
+
(define-method remove_pad
(of-object "GstCollectPads")
(c-name "gst_collect_pads_remove_pad")
ignore
gst_update_registry
gst_adapter_copy
+ gst_query_new_latency
+ gst_query_set_latency
+ gst_query_parse_latency
+ gst_message_new_lost_preroll
+ gst_message_parse_lost_preroll
+ gst_message_new_prerolled
+ gst_message_new_latency
+ gst_event_new_latency
+ gst_event_parse_latency
+ gst_base_sink_query_latency
+ gst_base_sink_get_latency
+ gst_bus_timed_pop
+ gst_message_new_info
+ gst_message_parse_info
%%
--- /dev/null
+%%
+ignore
+
+%%
)
)
+(define-flags BufferCopyFlags
+ (in-module "Gst")
+ (c-name "GstBufferCopyFlags")
+ (gtype-id "GST_TYPE_BUFFER_COPY_FLAGS")
+ (values
+ '("flags" "GST_BUFFER_COPY_FLAGS")
+ '("timestamps" "GST_BUFFER_COPY_TIMESTAMPS")
+ '("caps" "GST_BUFFER_COPY_CAPS")
+ )
+)
+
(define-flags BusFlags
(in-module "Gst")
(c-name "GstBusFlags")
'("tag" "GST_CORE_ERROR_TAG")
'("missing-plugin" "GST_CORE_ERROR_MISSING_PLUGIN")
'("clock" "GST_CORE_ERROR_CLOCK")
+ '("disabled" "GST_CORE_ERROR_DISABLED")
'("num-errors" "GST_CORE_ERROR_NUM_ERRORS")
)
)
'("qos" "GST_EVENT_QOS")
'("seek" "GST_EVENT_SEEK")
'("navigation" "GST_EVENT_NAVIGATION")
- '("set-latency" "GST_EVENT_SET_LATENCY")
+ '("latency" "GST_EVENT_LATENCY")
'("custom-upstream" "GST_EVENT_CUSTOM_UPSTREAM")
'("custom-downstream" "GST_EVENT_CUSTOM_DOWNSTREAM")
'("custom-downstream-oob" "GST_EVENT_CUSTOM_DOWNSTREAM_OOB")
'("segment-start" "GST_MESSAGE_SEGMENT_START")
'("segment-done" "GST_MESSAGE_SEGMENT_DONE")
'("duration" "GST_MESSAGE_DURATION")
+ '("latency" "GST_MESSAGE_LATENCY")
+ '("async-start" "GST_MESSAGE_ASYNC_START")
+ '("async-done" "GST_MESSAGE_ASYNC_DONE")
'("any" "GST_MESSAGE_ANY")
)
)
)
)
+(define-function buffer_try_new_and_alloc
+ (c-name "gst_buffer_try_new_and_alloc")
+ (return-type "GstBuffer*")
+ (caller-owns-return #t)
+ (parameters
+ '("guint" "size")
+ )
+)
+
(define-method is_metadata_writable
(of-object "GstBuffer")
(c-name "gst_buffer_is_metadata_writable")
(caller-owns-return #t)
)
+(define-method timed_pop
+ (of-object "GstBus")
+ (c-name "gst_bus_timed_pop")
+ (return-type "GstMessage*")
+ (caller-owns-return #t)
+ (parameters
+ '("GstClockTime" "timeout")
+ )
+)
+
(define-method set_flushing
(of-object "GstBus")
(c-name "gst_bus_set_flushing")
)
)
+(define-method unadjust_unlocked
+ (of-object "GstClock")
+ (c-name "gst_clock_unadjust_unlocked")
+ (return-type "GstClockTime")
+ (parameters
+ '("GstClockTime" "external")
+ )
+)
+
(define-method new_single_shot_id
(of-object "GstClock")
(c-name "gst_clock_new_single_shot_id")
(return-type "none")
)
+(define-method change_state
+ (of-object "GstElement")
+ (c-name "gst_element_change_state")
+ (return-type "GstStateChangeReturn")
+ (parameters
+ '("GstStateChange" "transition")
+ )
+)
+
(define-method continue_state
(of-object "GstElement")
(c-name "gst_element_continue_state")
(return-type "GType")
)
+(define-function gst_buffer_copy_flags_get_type
+ (c-name "gst_buffer_copy_flags_get_type")
+ (return-type "GType")
+)
+
(define-function bus_flags_get_type
(c-name "gst_bus_flags_get_type")
(return-type "GType")
)
+(define-function event_new_latency
+ (c-name "gst_event_new_latency")
+ (return-type "GstEvent*")
+ (caller-owns-return #t)
+ (parameters
+ '("GstClockTime" "latency")
+ )
+)
+
+(define-method parse_latency
+ (of-object "GstEvent")
+ (c-name "gst_event_parse_latency")
+ (return-type "none")
+ (parameters
+ '("GstClockTime*" "latency")
+ )
+)
+
;; From ../gstreamer/gst/gstfilter.h
(define-function filter_run
)
)
+(define-function message_new_info
+ (c-name "gst_message_new_info")
+ (return-type "GstMessage*")
+ (caller-owns-return #t)
+ (parameters
+ '("GstObject*" "src")
+ '("GError*" "error")
+ '("gchar*" "debug")
+ )
+)
+
(define-function message_new_tag
(c-name "gst_message_new_tag")
(return-type "GstMessage*")
)
)
-(define-function gst_message_new_buffering
+(define-function message_new_buffering
(c-name "gst_message_new_buffering")
(return-type "GstMessage*")
(parameters
)
)
+(define-function message_new_async_start
+ (c-name "gst_message_new_async_start")
+ (return-type "GstMessage*")
+ (caller-owns-return #t)
+ (parameters
+ '("GstObject*" "src")
+ '("gboolean" "new_base_time")
+ )
+)
+
+(define-function message_new_async_done
+ (c-name "gst_message_new_async_done")
+ (return-type "GstMessage*")
+ (caller-owns-return #t)
+ (parameters
+ '("GstObject*" "src")
+ )
+)
+
+(define-function message_new_latency
+ (c-name "gst_message_new_latency")
+ (return-type "GstMessage*")
+ (caller-owns-return #t)
+ (parameters
+ '("GstObject*" "src")
+ )
+)
+
(define-function message_new_custom
(c-name "gst_message_new_custom")
(return-type "GstMessage*")
)
)
+(define-method parse_info
+ (of-object "GstMessage")
+ (c-name "gst_message_parse_info")
+ (return-type "none")
+ (parameters
+ '("GError**" "gerror")
+ '("gchar**" "debug")
+ )
+)
+
(define-method parse_tag
(of-object "GstMessage")
(c-name "gst_message_parse_tag")
)
)
+(define-method parse_async_start
+ (of-object "GstMessage")
+ (c-name "gst_message_parse_async_start")
+ (return-type "none")
+ (parameters
+ '("gboolean*" "new_base_time")
+ )
+)
+
(define-method get_structure
(of-object "GstMessage*")
(c-name "gst_message_get_structure")
)
)
+(define-function gst_param_spec_fraction
+ (c-name "gst_param_spec_fraction")
+ (return-type "GParamSpec*")
+ (parameters
+ '("const-gchar*" "name")
+ '("const-gchar*" "nick")
+ '("const-gchar*" "blurb")
+ '("gint" "min_num")
+ '("gint" "min_denom")
+ '("gint" "max_num")
+ '("gint" "max_denom")
+ '("gint" "default_num")
+ '("gint" "default_denom")
+ '("GParamFlags" "flags")
+ )
+)
+
+
(define-function value_set_mini_object
(c-name "gst_value_set_mini_object")
(return-type "none")
)
)
-(define-function gst_parse_bin_from_description
+(define-function parse_bin_from_description
(c-name "gst_parse_bin_from_description")
(return-type "GstElement*")
(parameters
)
)
+(define-function query_new_latency
+ (c-name "gst_query_new_latency")
+ (caller-owns-return #t)
+ (return-type "GstQuery*")
+)
+
+(define-method set_latency
+ (of-object "GstQuery")
+ (c-name "gst_query_set_latency")
+ (return-type "none")
+ (parameters
+ '("gboolean" "live")
+ '("GstClockTime" "min_latency")
+ '("GstClockTime" "max_latency")
+ )
+)
+
+(define-method parse_latency
+ (of-object "GstQuery")
+ (c-name "gst_query_parse_latency")
+ (return-type "none")
+ (parameters
+ '("gboolean*" "live")
+ '("GstClockTime*" "min_latency")
+ '("GstClockTime*" "max_latency")
+ )
+)
+
(define-function query_new_convert
(c-name "gst_query_new_convert")
(return-type "GstQuery*")
)
)
+(define-function uri_protocol_is_supported
+ (c-name "gst_uri_protocol_is_supported")
+ (return-type "gboolean")
+ (parameters
+ '("GstURIType" "type")
+ '("const-gchar*" "protocol")
+ )
+)
+
(define-function uri_is_valid
(c-name "gst_uri_is_valid")
(return-type "gboolean")
return py_ret;
}
+%%
+override gst_base_sink_query_latency noargs
+static PyObject *
+_wrap_gst_base_sink_query_latency (PyGObject *self)
+{
+ gboolean res, live = FALSE, upstream_live = FALSE;
+ GstClockTime minlat = GST_CLOCK_TIME_NONE, maxlat = GST_CLOCK_TIME_NONE;
+
+ res = gst_base_sink_query_latency (GST_BASE_SINK (self->obj), &live, &upstream_live,
+ &minlat, &maxlat);
+ return Py_BuildValue("(OOOKK)",
+ PyBool_FromLong(res),
+ PyBool_FromLong(live),
+ PyBool_FromLong(upstream_live),
+ minlat, maxlat);
+}
+%%
+override gst_base_src_query_latency noargs
+static PyObject *
+_wrap_gst_base_src_query_latency (PyGObject *self)
+{
+ gboolean res, live = FALSE;
+ GstClockTime minlat = GST_CLOCK_TIME_NONE, maxlat = GST_CLOCK_TIME_NONE;
+
+ res = gst_base_src_query_latency (GST_BASE_SRC (self->obj), &live,
+ &minlat, &maxlat);
+ return Py_BuildValue("(OOKK)",
+ PyBool_FromLong(res),
+ PyBool_FromLong(live),
+ minlat, maxlat);
+}
minsize, maxsize,
PyBool_FromLong(async));
}
+%%
+override gst_event_parse_latency noargs
+static PyObject *
+_wrap_gst_event_parse_latency (PyGstMiniObject * self)
+{
+ GstClockTime ctime = GST_CLOCK_TIME_NONE;
+
+ if (GST_EVENT_TYPE (self->obj) != GST_EVENT_LATENCY) {
+ PyErr_SetString(PyExc_TypeError, "Event is not a 'latency' event");
+ return NULL;
+ }
+
+ gst_event_parse_latency (GST_EVENT (self->obj), &ctime);
+
+ return PyLong_FromUnsignedLongLong(ctime);
+}
_wrap_gst_message_parse_warning (PyGstMiniObject *self)
{
PyObject *ret;
- GError *warning;
+ GError *warning = NULL;
gchar *debug;
if (GST_MESSAGE_TYPE(self->obj) != GST_MESSAGE_WARNING) {
gst_message_parse_warning (GST_MESSAGE(self->obj), &warning, &debug);
- ret = PyList_New(1);
+ ret = PyList_New(2);
PyList_SetItem(ret, 0, pyg_boxed_new (GST_TYPE_G_ERROR, warning, TRUE, TRUE));
- if (debug != NULL)
- PyList_Append(ret, PyString_FromString(debug));
+ if (warning)
+ g_error_free (warning);
+ if (debug != NULL) {
+ PyList_SetItem(ret, 1, PyString_FromString(debug));
+ } else {
+ Py_INCREF (Py_None);
+ PyList_SetItem(ret, 1, Py_None);
+ }
+ g_free(debug);
+ return ret;
+}
+%%
+override gst_message_parse_info noargs
+static PyObject *
+_wrap_gst_message_parse_info (PyGstMiniObject *self)
+{
+ PyObject *ret;
+ GError *info = NULL;
+ gchar *debug;
+
+ if (GST_MESSAGE_TYPE(self->obj) != GST_MESSAGE_INFO) {
+ PyErr_SetString(PyExc_TypeError, "Message is not an info message");
+ return NULL;
+ }
+ gst_message_parse_info (GST_MESSAGE(self->obj), &info, &debug);
+
+ ret = PyList_New(2);
+ PyList_SetItem(ret, 0, pyg_boxed_new (GST_TYPE_G_ERROR, info, TRUE, TRUE));
+ if (info)
+ g_error_free (info);
+ if (debug != NULL) {
+ PyList_SetItem(ret, 1, PyString_FromString(debug));
+ } else {
+ Py_INCREF (Py_None);
+ PyList_SetItem(ret, 1, Py_None);
+ }
+ g_free(debug);
return ret;
}
%%
pyg_enum_from_gtype (GST_TYPE_FORMAT, format),
duration);
}
+%%
+override gst_message_parse_async_start noargs
+static PyObject *
+_wrap_gst_message_parse_async_start (PyGstMiniObject *self)
+{
+ gboolean res = FALSE;
+
+ if (GST_MESSAGE(self->obj)->type != GST_MESSAGE_ASYNC_START) {
+ PyErr_SetString(PyExc_TypeError, "Message is not an 'async-start' message");
+ return NULL;
+ }
+
+ gst_message_parse_async_start (GST_MESSAGE(self->obj), &res);
+
+ return PyBool_FromLong (res);
+}
g_free(formats);
return ret;
}
+%%
+override gst_query_get_structure noargs
+static PyObject *
+_wrap_gst_query_get_structure(PyGstMiniObject *self)
+{
+ GstStructure *ret;
+
+ pyg_begin_allow_threads;
+ ret = gst_query_get_structure(GST_QUERY(self->obj));
+ pyg_end_allow_threads;
+ /* pyg_boxed_new handles NULL checking */
+ return pyg_boxed_new(GST_TYPE_STRUCTURE, ret, FALSE, FALSE);
+}
+%%
+override gst_query_parse_latency noargs
+static PyObject *
+_wrap_gst_query_parse_latency (PyGstMiniObject * self)
+{
+ gboolean islive;
+ GstClockTime minlat, maxlat;
+
+ if (GST_QUERY_TYPE (self->obj) != GST_QUERY_LATENCY) {
+ PyErr_SetString(PyExc_TypeError, "Query is not a 'latency' query");
+ return NULL;
+ }
+
+ gst_query_parse_latency (GST_QUERY (self->obj), &islive, &minlat, &maxlat);
+
+ return Py_BuildValue("(OKK)",
+ PyBool_FromLong(islive),
+ minlat, maxlat);
+}
@IGNORE_GST_0_10_11@
@IGNORE_GST_PB_0_10_11@
@IGNORE_GST_0_10_12@
+@IGNORE_GST_0_10_13@
@IGNORE_GST_LOADSAVE@
%%
)
)
-
-
-;; From /opt/gnome/include/gstreamer-0.7/gst/xwindowlistener/xwindowlistener.h
-
-(define-function gst_x_window_listener_get_type
- (c-name "gst_x_window_listener_get_type")
- (return-type "GType")
-)
-
-(define-function gst_x_window_listener_new
- (c-name "gst_x_window_listener_new")
- (is-constructor-of "GstXWindowListener")
- (return-type "GstXWindowListener*")
- (parameters
- '("gchar*" "display")
- '("MapWindowFunc" "map_window_func")
- '("SetWindowFunc" "set_window_func")
- '("gpointer" "private_data")
- )
-)
-
-(define-method set_xid
- (of-object "GstXWindowListener")
- (c-name "gst_x_window_listener_set_xid")
- (return-type "none")
- (parameters
- '("XID" "id")
- )
-)
-
-
;; -*- scheme -*-
; object definitions ...
;; Enumerations and flags ...
)
)
+(define-method suggest_next_sync
+ (of-object "GstController")
+ (c-name "gst_controller_suggest_next_sync")
+ (return-type "GstClockTime")
+)
+
(define-method sync_values
(of-object "GstController")
(c-name "gst_controller_sync_values")
)
)
+(define-function object_suggest_next_sync
+ (c-name "gst_object_suggest_next_sync")
+ (return-type "GstClockTime")
+ (parameters
+ '("GObject*" "object")
+ )
+)
+
(define-function object_sync_values
(c-name "gst_object_sync_values")
(return-type "gboolean")
(define-function object_get_control_rate
(c-name "gst_object_get_control_rate")
- (return-type "guint")
+ (return-type "GstClockTime")
(parameters
'("GObject*" "object")
)
(return-type "none")
(parameters
'("GObject*" "object")
- '("guint" "control_rate")
+ '("GstClockTime" "control_rate")
)
)
+++ /dev/null
-;; -*- scheme -*-
-; object definitions ...
-(define-object XWindowListener
- (in-module "Gst")
- (parent "GObject")
- (c-name "GstXWindowListener")
- (gtype-id "GST_TYPE_XWINDOW_LISTENER")
-)
-
-;; Enumerations and flags ...
-
-
-;; From /opt/gnome/include/gstreamer-0.7/gst/xwindowlistener/xwindowlistener.h
-
-(define-function gst_x_window_listener_get_type
- (c-name "gst_x_window_listener_get_type")
- (return-type "GType")
-)
-
-(define-function gst_x_window_listener_new
- (c-name "gst_x_window_listener_new")
- (is-constructor-of "GstXWindowListener")
- (return-type "GstXWindowListener*")
- (parameters
- '("gchar*" "display")
- '("MapWindowFunc" "map_window_func")
- '("SetWindowFunc" "set_window_func")
- '("gpointer" "private_data")
- )
-)
-
-(define-method set_xid
- (of-object "GstXWindowListener")
- (c-name "gst_x_window_listener_set_xid")
- (return-type "none")
- (parameters
- '("XID" "id")
- )
-)
-
-