From b83c7e0a0e229c447775a3a17417b65be771241e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tim-Philipp=20M=C3=BCller?= Date: Fri, 29 Jul 2011 10:22:26 +0100 Subject: [PATCH] docs: add documentation for GstTagMux --- docs/libs/gst-plugins-base-libs-docs.sgml | 1 + docs/libs/gst-plugins-base-libs-sections.txt | 15 ++++++++++ gst-libs/gst/tag/gsttagmux.c | 31 ++++++++++++++++++-- gst-libs/gst/tag/gsttagmux.h | 24 +++++++++++++-- 4 files changed, 67 insertions(+), 4 deletions(-) diff --git a/docs/libs/gst-plugins-base-libs-docs.sgml b/docs/libs/gst-plugins-base-libs-docs.sgml index fdceb38539..7ed534aac0 100644 --- a/docs/libs/gst-plugins-base-libs-docs.sgml +++ b/docs/libs/gst-plugins-base-libs-docs.sgml @@ -191,6 +191,7 @@ + diff --git a/docs/libs/gst-plugins-base-libs-sections.txt b/docs/libs/gst-plugins-base-libs-sections.txt index 2ae87c1c1c..dd3e691337 100644 --- a/docs/libs/gst-plugins-base-libs-sections.txt +++ b/docs/libs/gst-plugins-base-libs-sections.txt @@ -1821,6 +1821,21 @@ gst_tag_demux_get_type gst_tag_demux_result_get_type +
+gsttagmux +gst/tag/gsttagmux.h +GstTagMux +GstTagMuxClass + +GstTagMuxPrivate +GST_IS_TAG_MUX +GST_IS_TAG_MUX_CLASS +GST_TAG_MUX +GST_TAG_MUX_CLASS +GST_TYPE_TAG_MUX +gst_tag_demux_get_type +
+
gsttaglanguagecodes gst/tag/tag.h diff --git a/gst-libs/gst/tag/gsttagmux.c b/gst-libs/gst/tag/gsttagmux.c index 0432d07030..9c0d2345f2 100644 --- a/gst-libs/gst/tag/gsttagmux.c +++ b/gst-libs/gst/tag/gsttagmux.c @@ -21,9 +21,36 @@ */ /** - * FIXME: documentation + * SECTION:gsttagmux + * @see_also: GstApeMux, GstId3Mux + * @short_description: Base class for adding tags that are in one single chunk + * directly at the beginning or at the end of a file * - * Since: 0.10.36 + * + * + * Provides a base class for adding tags at the beginning or end of a + * stream. + * + * Deriving from GstTagMux + * + * Subclasses have to do the following things: + * + * + * In their base init function, they must add pad templates for the sink + * pad and the source pad to the element class, describing the media type + * they accept and output in the caps of the pad template. + * + * + * In their class init function, they must override the + * GST_TAG_MUX_CLASS(mux_klass)->render_start_tag and/or + * GST_TAG_MUX_CLASS(mux_klass)->render_end_tag vfuncs and set up a render + * function. + * + * + * + * + * + * Since 0.10.36 */ #ifdef HAVE_CONFIG_H #include diff --git a/gst-libs/gst/tag/gsttagmux.h b/gst-libs/gst/tag/gsttagmux.h index 4677c32f75..ddb5988c05 100644 --- a/gst-libs/gst/tag/gsttagmux.h +++ b/gst-libs/gst/tag/gsttagmux.h @@ -1,7 +1,6 @@ /* GStreamer tag muxer base class - * * Copyright (C) 2006 Christophe Fergeau - * Copyright (C) 2006 Tim-Philipp Müller + * Copyright (C) 2006,2011 Tim-Philipp Müller * Copyright (C) 2009 Pioneers of the Inevitable * * This library is free software; you can redistribute it and/or @@ -42,6 +41,14 @@ typedef struct _GstTagMux GstTagMux; typedef struct _GstTagMuxClass GstTagMuxClass; typedef struct _GstTagMuxPrivate GstTagMuxPrivate; +/** + * GstTagMux: + * @element: parent element + * + * Opaque #GstTagMux structure. + * + * Since: 0.10.36 + */ struct _GstTagMux { GstElement element; @@ -51,6 +58,19 @@ struct _GstTagMux { gpointer _gst_reserved[GST_PADDING]; }; +/** + * GstTagMuxClass: + * @parent_class: the parent class. + * @render_start_tag: create a tag buffer to add to the beginning of the + * input stream given a tag list, or NULL + * @render_end_tag: create a tag buffer to add to the end of the + * input stream given a tag list, or NULL + * + * The #GstTagMuxClass structure. Subclasses need to override at least one + * of the two render vfuncs. + * + * Since: 0.10.36 + */ struct _GstTagMuxClass { GstElementClass parent_class;