[gst-devel] next patch needs approval

Ronald Bultje rbultje at ronald.bitfreak.net
Sat Feb 9 15:18:03 CET 2002


On Fri, 2002-02-08 at 20:03, Benjamin Otte wrote:
> This patch adds metadata to streams.
> It's a bit tricky to explain, I hope the attached doc/patch does that.
[..]
> @@ -165,6 +166,7 @@
>    gobject_class->get_property 	= gst_filesrc_get_property;
>  
>    gstelement_class->change_state = gst_filesrc_change_state;
> +  gstelement_class->get_metadata = gst_filesrc_get_metadata;
>  }
>  
>  static gint
[..]
> @@ -205,6 +207,8 @@
>    src->map_regions_lock = g_mutex_new();
>  
>    src->seek_happened = FALSE;
> +  src->metadata = gst_metadata_new (GST_ELEMENT (src));
> +  GST_OBJECT_NAME (src->metadata) = "Filesrc Metadata Object";
>  }
>  
>  static void

Why?

Why not just use the get_property() functions for metadata as well?

g_object_get_property(filesrc, "author", value);
g_object_get_property(filesrc, "title", value);
g_object_get_property(filesrc, "copyright", value);
etc.

Isn't that much easier??

Ronald

-- 
-   .-.
-   /V\    | Ronald Bultje <rbultje at ronald.bitfreak.net>
-  // \\   | Running: Linux 2.2.19 and OpenBSD 3.0
- /(   )\  | http://ronald.bitfreak.net/
-  ^^-^^





More information about the gstreamer-devel mailing list