[vala] gstreamer-0.10: Fix Gst.Query bindings



commit 6ef55da3331393fc4454bcf452a0519e6d55b712
Author: Sebastian Dröge <sebastian droege collabora co uk>
Date:   Thu Jun 24 18:01:19 2010 +0200

    gstreamer-0.10: Fix Gst.Query bindings

 vapi/gstreamer-0.10.vapi                           |   40 ++++++++++----------
 .../gstreamer-0.10/gstreamer-0.10-custom.vala      |   17 ++++++++
 .../gstreamer-0.10/gstreamer-0.10.metadata         |   24 +++++++++++-
 3 files changed, 59 insertions(+), 22 deletions(-)
---
diff --git a/vapi/gstreamer-0.10.vapi b/vapi/gstreamer-0.10.vapi
index 8c2e20d..1c87f49 100644
--- a/vapi/gstreamer-0.10.vapi
+++ b/vapi/gstreamer-0.10.vapi
@@ -1027,7 +1027,7 @@ namespace Gst {
 		public weak Gst.Structure structure;
 		public Gst.QueryType type;
 		[CCode (has_construct_function = false)]
-		public Query.application (Gst.QueryType type, Gst.Structure structure);
+		public Query.application (Gst.QueryType type, owned Gst.Structure structure);
 		[CCode (has_construct_function = false)]
 		public Query.buffering (Gst.Format format);
 		[CCode (has_construct_function = false)]
@@ -1042,9 +1042,9 @@ namespace Gst {
 		public Query.latency ();
 		[ReturnsModifiedPointer]
 		public void make_writable ();
-		public void parse_buffering_percent (bool busy, int percent);
-		public void parse_buffering_range (Gst.Format format, int64 start, int64 stop, int64 estimated_total);
-		public void parse_buffering_stats (Gst.BufferingMode mode, int avg_in, int avg_out, int64 buffering_left);
+		public void parse_buffering_percent (out bool busy, out int percent);
+		public void parse_buffering_range (out Gst.Format format, out int64 start, out int64 stop, out int64 estimated_total);
+		public void parse_buffering_stats (out Gst.BufferingMode mode, out int avg_in, out int avg_out, out int64 buffering_left);
 		public void parse_convert (out Gst.Format src_format, out int64 src_value, out Gst.Format dest_format, out int64 dest_value);
 		public void parse_duration (out Gst.Format format, out int64 duration);
 		public void parse_formats_length (out uint n_formats);
@@ -1053,7 +1053,7 @@ namespace Gst {
 		public void parse_position (out Gst.Format format, out int64 cur);
 		public void parse_seeking (out Gst.Format format, out bool seekable, out int64 segment_start, out int64 segment_end);
 		public void parse_segment (out double rate, out Gst.Format format, out int64 start_value, out int64 stop_value);
-		public void parse_uri (string uri);
+		public void parse_uri (out string uri);
 		[CCode (has_construct_function = false)]
 		public Query.position (Gst.Format format);
 		public Gst.Query @ref ();
@@ -1066,31 +1066,18 @@ namespace Gst {
 		public void set_buffering_stats (Gst.BufferingMode mode, int avg_in, int avg_out, int64 buffering_left);
 		public void set_convert (Gst.Format src_format, int64 src_value, Gst.Format dest_format, int64 dest_value);
 		public void set_duration (Gst.Format format, int64 duration);
-		public void set_formats (int n_formats);
-		public void set_formatsv (int n_formats, Gst.Format formats);
+		public void set_formats (int n_formats, ...);
+		public void set_formatsv ([CCode (array_length_pos = 0.9)] Gst.Format[] formats);
 		public void set_latency (bool live, Gst.ClockTime min_latency, Gst.ClockTime max_latency);
 		public void set_position (Gst.Format format, int64 cur);
 		public void set_seeking (Gst.Format format, bool seekable, int64 segment_start, int64 segment_end);
 		public void set_segment (double rate, Gst.Format format, int64 start_value, int64 stop_value);
 		public void set_uri (string uri);
-		public static Gst.QueryType type_get_by_nick (string nick);
-		public static unowned Gst.QueryTypeDefinition type_get_details (Gst.QueryType type);
-		public static Gst.Iterator<Gst.QueryTypeDefinition> type_iterate_definitions ();
-		public static Gst.QueryType type_register (string nick, string description);
-		public static GLib.Quark type_to_quark (Gst.QueryType query);
 		public static bool types_contains (Gst.QueryType types, Gst.QueryType type);
 		public void unref ();
 		[CCode (has_construct_function = false)]
 		public Query.uri ();
 	}
-	[Compact]
-	[CCode (cheader_filename = "gst/gst.h")]
-	public class QueryTypeDefinition {
-		public weak string description;
-		public weak string nick;
-		public GLib.Quark quark;
-		public Gst.QueryType value;
-	}
 	[CCode (cheader_filename = "gst/gst.h")]
 	public class Registry : Gst.Object {
 		public weak GLib.HashTable basename_hash;
@@ -1549,6 +1536,13 @@ namespace Gst {
 		public static void ignored (Gst.Poll @set, Gst.PollFD fd);
 		public void init ();
 	}
+	[CCode (type_id = "GST_TYPE_QUERY_TYPE_DEFINITION", cheader_filename = "gst/gst.h")]
+	public struct QueryTypeDefinition {
+		public weak string description;
+		public weak string nick;
+		public GLib.Quark quark;
+		public Gst.QueryType value;
+	}
 	[CCode (type_id = "GST_TYPE_STATIC_CAPS", cheader_filename = "gst/gst.h")]
 	public struct StaticCaps {
 		[CCode (cname = "string")]
@@ -2052,6 +2046,12 @@ namespace Gst {
 		BUFFERING,
 		CUSTOM,
 		URI;
+		public GLib.Quark to_quark ();
+		public unowned string get_name ();
+		public Gst.QueryTypeDefinition get_details ();
+		public static Gst.QueryType get_by_nick ();
+		public static Gst.Iterator<Gst.QueryTypeDefinition> iterate_definitions ();
+		public static Gst.QueryType register (string nick, string description);
 		[CCode (cname = "gst_query_type_get_name")]
 		public unowned string to_string ();
 	}
diff --git a/vapi/packages/gstreamer-0.10/gstreamer-0.10-custom.vala b/vapi/packages/gstreamer-0.10/gstreamer-0.10-custom.vala
index 4ef399c..238c5ba 100644
--- a/vapi/packages/gstreamer-0.10/gstreamer-0.10-custom.vala
+++ b/vapi/packages/gstreamer-0.10/gstreamer-0.10-custom.vala
@@ -326,6 +326,23 @@ namespace Gst {
         	public Query copy ();
 	}
 
+	public enum QueryType {
+		SOME_RANDOM_VALUE_FOR_VAPIGEN;
+		public GLib.Quark to_quark ();
+		public unowned string get_name ();
+		public unowned QueryTypeDefinition get_details ();
+		public static QueryType get_by_nick ();
+		public static Iterator<QueryTypeDefinition> iterate_definitions ();
+		public static Gst.QueryType register (string nick, string description);
+	}
+
+	public struct QueryTypeDefinition {
+		public weak string description;
+		public weak string nick;
+		public GLib.Quark quark;
+		public Gst.QueryType value;
+	}
+
 	[Compact]
 	[Immutable]
 	[CCode (copy_function = "gst_structure_copy", type_id = "GST_TYPE_STRUCTURE", cheader_filename = "gst/gst.h")]
diff --git a/vapi/packages/gstreamer-0.10/gstreamer-0.10.metadata b/vapi/packages/gstreamer-0.10/gstreamer-0.10.metadata
index e84168b..e4f896c 100644
--- a/vapi/packages/gstreamer-0.10/gstreamer-0.10.metadata
+++ b/vapi/packages/gstreamer-0.10/gstreamer-0.10.metadata
@@ -442,7 +442,15 @@ gst_pipeline_use_clock.clock nullable="1"
 GstQuery base_class="GstMiniObject"
 GstQuery.mini_object hidden="1"
 GstQueryClass hidden="1"
+GstQueryTypeDefinition hidden="1"
 GstQueryType to_string="gst_query_type_get_name"
+gst_query_type_register hidden="1"
+gst_query_type_get_by_nick hidden="1"
+gst_query_type_get_details hidden="1"
+gst_query_type_to_quark hidden="1"
+gst_query_type_iterate_definitions hidden="1"
+gst_query_type_get_name hidden="1"
+gst_query_new_application.structure transfer_ownership="1"
 gst_query_make_writable hidden="1"
 gst_query_parse_convert.src_format is_out="1"
 gst_query_parse_convert.src_value is_out="1"
@@ -465,8 +473,20 @@ gst_query_parse_segment.rate is_out="1"
 gst_query_parse_segment.format is_out="1"
 gst_query_parse_segment.start_value is_out="1"
 gst_query_parse_segment.stop_value is_out="1"
-gst_query_type_get_name hidden="1"
-gst_query_type_iterate_definitions transfer_ownership="1" type_arguments="QueryTypeDefinition"
+gst_query_parse_buffering_percent.busy is_out="1"
+gst_query_parse_buffering_percent.percent is_out="1"
+gst_query_parse_buffering_range.format is_out="1"
+gst_query_parse_buffering_range.start is_out="1"
+gst_query_parse_buffering_range.stop is_out="1"
+gst_query_parse_buffering_range.estimated_total is_out="1"
+gst_query_parse_buffering_stats.mode is_out="1"
+gst_query_parse_buffering_stats.avg_in is_out="1"
+gst_query_parse_buffering_stats.avg_out is_out="1"
+gst_query_parse_buffering_stats.buffering_left is_out="1"
+gst_query_parse_uri.uri is_out="1" transfer_ownership="1"
+gst_query_set_formats ellipsis="1"
+gst_query_set_formatsv.n_formats hidden="1"
+gst_query_set_formatsv.formats is_array="1" array_length_pos="0.9"
 gst_registry_feature_filter.filter delegate_target_pos="2.1"
 gst_registry_feature_filter transfer_ownership="1" type_arguments="PluginFeature"
 gst_registry_get_feature_list transfer_ownership="1" type_arguments="PluginFeature"



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