From 81c32bc56e7a3ca50763ce9966a9d94849cb0f3b Mon Sep 17 00:00:00 2001 From: Stefan Kost Date: Thu, 28 Apr 2011 15:05:28 +0300 Subject: [PATCH 01/14] docs: we don't need to document private members in opaque structs --- gst/gstbufferlist.c | 1 - gst/gstsystemclock.h | 1 - 2 files changed, 2 deletions(-) diff --git a/gst/gstbufferlist.c b/gst/gstbufferlist.c index e59c56fe3d..721c4c3ca1 100644 --- a/gst/gstbufferlist.c +++ b/gst/gstbufferlist.c @@ -132,7 +132,6 @@ static gconstpointer STOLEN = ""; /** * GstBufferList: - * @mini_object: the parent structure * * Opaque list of grouped buffers. * diff --git a/gst/gstsystemclock.h b/gst/gstsystemclock.h index 4c7e8b92f7..4f372de78d 100644 --- a/gst/gstsystemclock.h +++ b/gst/gstsystemclock.h @@ -57,7 +57,6 @@ typedef enum { /** * GstSystemClock: - * @clock: The parent clock * * The default implementation of a #GstClock that uses the system time. */ From 4699cafe9043df59957fca390fa37a3694febdc2 Mon Sep 17 00:00:00 2001 From: Stefan Kost Date: Thu, 28 Apr 2011 15:37:02 +0300 Subject: [PATCH 02/14] docs: remove non existing symbol --- docs/gst/gstreamer-sections.txt | 1 - 1 file changed, 1 deletion(-) diff --git a/docs/gst/gstreamer-sections.txt b/docs/gst/gstreamer-sections.txt index 3a87827bdd..20ba68adbe 100644 --- a/docs/gst/gstreamer-sections.txt +++ b/docs/gst/gstreamer-sections.txt @@ -2695,7 +2695,6 @@ gst_date_time_get_time_zone_offset gst_date_time_get_second gst_date_time_get_year gst_date_time_new -gst_date_time_new_from_unix_epoch gst_date_time_new_from_unix_epoch_local_time gst_date_time_new_from_unix_epoch_utc gst_date_time_new_local_time From 801d89e26fa6c60047c725275f5bb7ec4e6eaa1d Mon Sep 17 00:00:00 2001 From: Stefan Kost Date: Mon, 2 May 2011 15:30:13 +0300 Subject: [PATCH 03/14] docs: don't duplicate info that we take from element-details --- plugins/elements/gstfunnel.c | 1 - 1 file changed, 1 deletion(-) diff --git a/plugins/elements/gstfunnel.c b/plugins/elements/gstfunnel.c index bf5e8c1896..4cb8c35da2 100644 --- a/plugins/elements/gstfunnel.c +++ b/plugins/elements/gstfunnel.c @@ -24,7 +24,6 @@ /** * SECTION:element-funnel - * @short_description: N-to-1 simple funnel * * Takes packets from various input sinks into one output source. * From a482babf5590e72a3277fcd05a8e122e9717e3b0 Mon Sep 17 00:00:00 2001 From: Stefan Kost Date: Mon, 2 May 2011 15:35:52 +0300 Subject: [PATCH 04/14] docs: fix gtk-doc syntax --- gst/gstatomicqueue.h | 1 + 1 file changed, 1 insertion(+) diff --git a/gst/gstatomicqueue.h b/gst/gstatomicqueue.h index 51c10b908b..6d71010c6b 100644 --- a/gst/gstatomicqueue.h +++ b/gst/gstatomicqueue.h @@ -29,6 +29,7 @@ G_BEGIN_DECLS /** * GstAtomicQueue: + * * Opaque atomic data queue. * * Use the acessor functions to get the stored values. From eaebf37c00c8753117e3161af6f558f51e3ccfc4 Mon Sep 17 00:00:00 2001 From: Stefan Kost Date: Mon, 2 May 2011 15:46:59 +0300 Subject: [PATCH 05/14] docs: add new api to -section.txt --- docs/gst/gstreamer-sections.txt | 12 ++++++++++++ docs/libs/gstreamer-libs-sections.txt | 8 ++++++++ 2 files changed, 20 insertions(+) diff --git a/docs/gst/gstreamer-sections.txt b/docs/gst/gstreamer-sections.txt index 20ba68adbe..e1eba92c66 100644 --- a/docs/gst/gstreamer-sections.txt +++ b/docs/gst/gstreamer-sections.txt @@ -272,8 +272,10 @@ GST_IS_BUFFER_LIST_CLASS GST_TYPE_BUFFER_LIST GST_BUFFER_LIST_CAST GST_TYPE_BUFFER_LIST_ITEM +GST_TYPE_BUFFER_LIST_ITERATOR gst_buffer_list_item_get_type +gst_buffer_list_iterator_get_type gst_buffer_list_get_type @@ -282,6 +284,7 @@ gst_buffer_list_get_type GstCaps GstCaps GstStaticCaps +GstCapsIntersectMode GstCapsFlags GST_CAPS_ANY @@ -322,6 +325,7 @@ gst_caps_is_always_compatible gst_caps_is_subset gst_caps_can_intersect gst_caps_intersect +gst_caps_intersect_full gst_caps_union gst_caps_normalize gst_caps_do_simplify @@ -340,9 +344,11 @@ GST_CAPS GST_IS_CAPS GST_TYPE_CAPS GST_TYPE_CAPS_FLAGS +GST_TYPE_CAPS_INTERSECT_MODE gst_caps_flags_get_type gst_caps_get_type +gst_caps_intersect_mode_get_type
@@ -671,6 +677,10 @@ gst_element_factory_create gst_element_factory_make gst_element_factory_can_sink_caps gst_element_factory_can_src_caps +gst_element_factory_can_sink_all_caps +gst_element_factory_can_src_all_caps +gst_element_factory_can_sink_any_caps +gst_element_factory_can_src_any_caps gst_element_factory_get_static_pad_templates GstElementFactoryListType GST_ELEMENT_FACTORY_TYPE_ANY @@ -1764,7 +1774,9 @@ gst_parse_context_get_missing_elements GST_TYPE_PARSE_ERROR GST_TYPE_PARSE_FLAGS +GST_TYPE_PARSE_CONTEXT +gst_parse_context_get_type gst_parse_error_get_type gst_parse_flags_get_type
diff --git a/docs/libs/gstreamer-libs-sections.txt b/docs/libs/gstreamer-libs-sections.txt index 6f1a5dfe56..1a43266590 100644 --- a/docs/libs/gstreamer-libs-sections.txt +++ b/docs/libs/gstreamer-libs-sections.txt @@ -239,6 +239,7 @@ gst_base_parse_set_frame_rate gst_base_parse_convert_default gst_base_parse_add_index_entry +GstBaseParseFrame GstBaseParseFrameFlags gst_base_parse_frame_new gst_base_parse_frame_init @@ -246,6 +247,13 @@ gst_base_parse_frame_free gst_base_parse_push_frame +GST_BASE_PARSE_DRAINING +GST_BASE_PARSE_FLAG_DRAINING +GST_BASE_PARSE_FLAG_LOST_SYNC +GST_BASE_PARSE_FLOW_DROPPED +GST_BASE_PARSE_FLOW_QUEUED +GST_BASE_PARSE_LOST_SYNC +GST_BASE_PARSE_SINK_PAD GST_BASE_PARSE_SRC_PAD GstBaseParsePrivate From 41754faaaf22553a45c7d52b0d47036f7f2f9675 Mon Sep 17 00:00:00 2001 From: Stefan Kost Date: Mon, 2 May 2011 15:48:01 +0300 Subject: [PATCH 06/14] docs: fixup broken xref --- gst/gstelement.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gst/gstelement.c b/gst/gstelement.c index 41cc8b2f87..12fc6fac8a 100644 --- a/gst/gstelement.c +++ b/gst/gstelement.c @@ -206,7 +206,7 @@ gst_element_class_init (GstElementClass * klass) * usually be emitted from the context of the streaming thread. Also keep in * mind that if you add new elements to the pipeline in the signal handler * you will need to set them to the desired target state with - * gst_element_set() or gst_element_sync_state_with_parent(). + * gst_element_set_state() or gst_element_sync_state_with_parent(). */ gst_element_signals[PAD_ADDED] = g_signal_new ("pad-added", G_TYPE_FROM_CLASS (klass), G_SIGNAL_RUN_LAST, @@ -2233,7 +2233,7 @@ interrupted: * * This function returns %GST_STATE_CHANGE_NO_PREROLL if the element * successfully changed its state but is not able to provide data yet. - * This mostly happens for live sources that only produce data in + * This mostly happens for live sources that only produce data in * %GST_STATE_PLAYING. While the state change return is equivalent to * %GST_STATE_CHANGE_SUCCESS, it is returned to the application to signal that * some sink elements might not be able to complete their state change because From 319eef8aa978491c9e7082add7258d5335b5bde7 Mon Sep 17 00:00:00 2001 From: Stefan Kost Date: Mon, 2 May 2011 15:52:58 +0300 Subject: [PATCH 07/14] docs: improve the syntax for the capsintersectmode docs --- gst/gstcaps.h | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/gst/gstcaps.h b/gst/gstcaps.h index 398fa3fcbf..f79939c61a 100644 --- a/gst/gstcaps.h +++ b/gst/gstcaps.h @@ -49,20 +49,21 @@ typedef enum { * @GST_CAPS_INTERSECT_FIRST : Keeps the first caps order. * * Modes of caps intersection - * - * #GST_CAPS_INTERSECT_ZIG_ZAG tries to preserve overall order of both caps + * + * @GST_CAPS_INTERSECT_ZIG_ZAG tries to preserve overall order of both caps * by iterating on the caps' structures as the following matrix shows: + * |[ * caps1 * +------------- * | 1 2 4 7 * caps2 | 3 5 8 10 * | 6 9 11 12 - * + * ]| * Used when there is no explicit precedence of one caps over the other. e.g. * tee's sink pad getcaps function, it will probe its src pad peers' for their * caps and intersect them with this mode. * - * #GST_CAPS_INTERSECT_FIRST is useful when an element wants to preserve + * @GST_CAPS_INTERSECT_FIRST is useful when an element wants to preserve * another element's caps priority order when intersecting with its own caps. * Example: If caps1 is [A, B, C] and caps2 is [E, B, D, A], the result * would be [A, B], maintaining the first caps priority on the intersection. From 59670baf8ece1b2e3218a06b97aa1fe82871ad23 Mon Sep 17 00:00:00 2001 From: Stefan Kost Date: Mon, 2 May 2011 16:00:52 +0300 Subject: [PATCH 08/14] docs: add docs for GstDPPacketizer --- libs/gst/dataprotocol/dataprotocol.h | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/libs/gst/dataprotocol/dataprotocol.h b/libs/gst/dataprotocol/dataprotocol.h index 118df65a29..150b5cca41 100644 --- a/libs/gst/dataprotocol/dataprotocol.h +++ b/libs/gst/dataprotocol/dataprotocol.h @@ -111,6 +111,16 @@ typedef gboolean (*GstDPPacketFromEventFunction) (const GstEvent * event, guint * length, guint8 ** header, guint8 ** payload); + +/** + * GstDPPacketizer: + * @version: the #GstDPVersion of the protocol to be used + * @header_from_buffer: buffer serializer function + * @packet_from_caps: caps serializer function + * @packet_from_event: event serializer function + * + * Data protocol packetizer handle. + */ typedef struct { GstDPVersion version; From 217b209abab6a030349888b796f4b782eb5fd525 Mon Sep 17 00:00:00 2001 From: Stefan Kost Date: Mon, 2 May 2011 16:03:29 +0300 Subject: [PATCH 09/14] docs: add missing parameter docs --- libs/gst/base/gstbaseparse.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libs/gst/base/gstbaseparse.c b/libs/gst/base/gstbaseparse.c index 1cd0a7ff51..7a6ff3ae20 100644 --- a/libs/gst/base/gstbaseparse.c +++ b/libs/gst/base/gstbaseparse.c @@ -2986,7 +2986,7 @@ gst_base_parse_set_syncable (GstBaseParse * parse, gboolean syncable) /** * gst_base_parse_set_passthrough: * @parse: a #GstBaseParse - * @passthrough: + * @passthrough: @TRUE if parser should run in passthrough mode * * Set if the nature of the format or configuration does not allow (much) * parsing, and the parser should operate in passthrough mode (which only From c45ff2b12a70acef46debfae01b8f7d4be8f0ff6 Mon Sep 17 00:00:00 2001 From: Stefan Kost Date: Mon, 2 May 2011 16:20:24 +0300 Subject: [PATCH 10/14] docs: add two trivial doc blobs --- gst/gstelement.h | 2 ++ gst/gstpluginfeature.h | 9 +++++++++ 2 files changed, 11 insertions(+) diff --git a/gst/gstelement.h b/gst/gstelement.h index 622f05f0f2..74f05dd812 100644 --- a/gst/gstelement.h +++ b/gst/gstelement.h @@ -722,6 +722,8 @@ GType gst_element_get_type (void); * gst_element_get_parent: * @elem: a #GstElement to get the parent of. * + * Get the parent of an element. + * * Returns: (transfer full): the parent of an element. */ #define gst_element_get_parent(elem) gst_object_get_parent(GST_OBJECT_CAST(elem)) diff --git a/gst/gstpluginfeature.h b/gst/gstpluginfeature.h index c24be4f759..abfebe2541 100644 --- a/gst/gstpluginfeature.h +++ b/gst/gstpluginfeature.h @@ -142,6 +142,15 @@ void gst_plugin_feature_list_free (GList *list); GList *gst_plugin_feature_list_copy (GList *list); void gst_plugin_feature_list_debug (GList *list); +/** + * GST_PLUGIN_FEATURE_LIST_DEBUG: + * @list: (transfer none) (element-type Gst.PluginFeature): a #GList of + * plugin features + * + * Debug the plugin feature names in @list. + * + * Since: 0.10.31 + */ #ifndef GST_DISABLE_GST_DEBUG #define GST_PLUGIN_FEATURE_LIST_DEBUG(list) gst_plugin_feature_list_debug(list) #else From 58fc672362c62d15b1b761a6196f283cf4ca4dcf Mon Sep 17 00:00:00 2001 From: Stefan Kost Date: Mon, 2 May 2011 16:22:56 +0300 Subject: [PATCH 11/14] docs: fix copy'n'paste doc header mistake --- gst/gstelementfactory.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gst/gstelementfactory.c b/gst/gstelementfactory.c index 109ff5792c..0c3d8aae69 100644 --- a/gst/gstelementfactory.c +++ b/gst/gstelementfactory.c @@ -597,7 +597,7 @@ gst_element_factory_get_documentation_uri (GstElementFactory * factory) } /** - * gst_element_factory_get_documentation_uri: + * gst_element_factory_get_icon_name: * @factory: a #GstElementFactory * * Gets icon name for this factory if set. From 511f55691514fe73503a2247609a4925035fd0b7 Mon Sep 17 00:00:00 2001 From: Stefan Kost Date: Tue, 3 May 2011 13:55:43 +0300 Subject: [PATCH 12/14] docs: it its %TRUE (constant) As spotted by Tim. --- libs/gst/base/gstbaseparse.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libs/gst/base/gstbaseparse.c b/libs/gst/base/gstbaseparse.c index 7a6ff3ae20..41f84682c1 100644 --- a/libs/gst/base/gstbaseparse.c +++ b/libs/gst/base/gstbaseparse.c @@ -2986,7 +2986,7 @@ gst_base_parse_set_syncable (GstBaseParse * parse, gboolean syncable) /** * gst_base_parse_set_passthrough: * @parse: a #GstBaseParse - * @passthrough: @TRUE if parser should run in passthrough mode + * @passthrough: %TRUE if parser should run in passthrough mode * * Set if the nature of the format or configuration does not allow (much) * parsing, and the parser should operate in passthrough mode (which only From a750aac2dd59453a875d19abf75d0203b217a77d Mon Sep 17 00:00:00 2001 From: Thiago Santos Date: Mon, 2 May 2011 11:30:06 -0300 Subject: [PATCH 13/14] miniobject: Fix dup_mini_object function to handle NULL gvalues g_value_dup_object handles gvalues that contain NULL pointers, gst_value_dup_mini_object should do the same. https://bugzilla.gnome.org/show_bug.cgi?id=649195 --- gst/gstminiobject.c | 10 ++++++---- tests/check/gst/gstminiobject.c | 18 ++++++++++++++++++ 2 files changed, 24 insertions(+), 4 deletions(-) diff --git a/gst/gstminiobject.c b/gst/gstminiobject.c index 49be565d62..4b46d29297 100644 --- a/gst/gstminiobject.c +++ b/gst/gstminiobject.c @@ -427,8 +427,8 @@ gst_value_mini_object_copy (const GValue * src_value, GValue * dest_value) { if (src_value->data[0].v_pointer) { dest_value->data[0].v_pointer = - gst_mini_object_ref (GST_MINI_OBJECT_CAST (src_value->data[0]. - v_pointer)); + gst_mini_object_ref (GST_MINI_OBJECT_CAST (src_value-> + data[0].v_pointer)); } else { dest_value->data[0].v_pointer = NULL; } @@ -544,7 +544,8 @@ gst_value_get_mini_object (const GValue * value) * @value: a valid #GValue of %GST_TYPE_MINI_OBJECT derived type * * Get the contents of a %GST_TYPE_MINI_OBJECT derived #GValue, - * increasing its reference count. + * increasing its reference count. If the contents of the #GValue + * are %NULL, %NULL will be returned. * * Returns: (transfer full): mini object contents of @value * @@ -555,7 +556,8 @@ gst_value_dup_mini_object (const GValue * value) { g_return_val_if_fail (GST_VALUE_HOLDS_MINI_OBJECT (value), NULL); - return gst_mini_object_ref (value->data[0].v_pointer); + return value->data[0].v_pointer ? gst_mini_object_ref (value->data[0]. + v_pointer) : NULL; } diff --git a/tests/check/gst/gstminiobject.c b/tests/check/gst/gstminiobject.c index 1477328d3e..5c296dbf46 100644 --- a/tests/check/gst/gstminiobject.c +++ b/tests/check/gst/gstminiobject.c @@ -447,6 +447,23 @@ GST_START_TEST (test_value_collection) GST_END_TEST; +GST_START_TEST (test_dup_null_mini_object) +{ + GValue value = { 0, }; + GstBuffer *buf; + + g_value_init (&value, GST_TYPE_BUFFER); + + gst_value_set_mini_object (&value, NULL); + + buf = gst_value_dup_mini_object (&value); + g_assert (buf == NULL); + + g_value_unset (&value); +} + +GST_END_TEST; + static Suite * gst_mini_object_suite (void) { @@ -464,6 +481,7 @@ gst_mini_object_suite (void) tcase_add_test (tc_chain, test_unref_threaded); tcase_add_test (tc_chain, test_recycle_threaded); tcase_add_test (tc_chain, test_value_collection); + tcase_add_test (tc_chain, test_dup_null_mini_object); return s; } From d72f559d297a06bec892fa5a6bd4e43094f8dcf5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tim-Philipp=20M=C3=BCller?= Date: Wed, 4 May 2011 15:29:42 +0100 Subject: [PATCH 14/14] tests: fix compiler warning in new miniobject test MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit gst/gstminiobject.c: In function ‘test_dup_null_mini_object’: gst/gstminiobject.c:459:7: warning: assignment from incompatible pointer type --- tests/check/gst/gstminiobject.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/check/gst/gstminiobject.c b/tests/check/gst/gstminiobject.c index 5c296dbf46..9b9c1cde9c 100644 --- a/tests/check/gst/gstminiobject.c +++ b/tests/check/gst/gstminiobject.c @@ -450,14 +450,14 @@ GST_END_TEST; GST_START_TEST (test_dup_null_mini_object) { GValue value = { 0, }; - GstBuffer *buf; + GstMiniObject *mo; g_value_init (&value, GST_TYPE_BUFFER); gst_value_set_mini_object (&value, NULL); - buf = gst_value_dup_mini_object (&value); - g_assert (buf == NULL); + mo = gst_value_dup_mini_object (&value); + g_assert (mo == NULL); g_value_unset (&value); }