From df681e7f0e3877c7e5e28f1f47b39367b6f1175f Mon Sep 17 00:00:00 2001 From: Wim Taymans Date: Tue, 13 Mar 2001 22:21:29 +0000 Subject: [PATCH] Adjusted -inspect to the new GstCaps structure Original commit message from CVS: Adjusted -inspect to the new GstCaps structure --- tools/gstreamer-inspect.c | 30 ++++++++++++++---------------- 1 file changed, 14 insertions(+), 16 deletions(-) diff --git a/tools/gstreamer-inspect.c b/tools/gstreamer-inspect.c index f8d4ac3703..3517ac8e2e 100644 --- a/tools/gstreamer-inspect.c +++ b/tools/gstreamer-inspect.c @@ -65,11 +65,11 @@ print_element_info (GstElementFactory *factory) GstElement *element; GstObjectClass *gstobject_class; GstElementClass *gstelement_class; - GList *pads, *caps; + GList *pads; + GstCaps *caps; GstPad *pad; GstRealPad *realpad; GstPadTemplate *padtemplate; - GstCaps *cap; GtkArg *args; guint32 *flags; gint num_args,i; @@ -121,19 +121,18 @@ print_element_info (GstElementFactory *factory) while (caps) { GstType *type; - cap = (GstCaps*)(caps->data); - caps = g_list_next(caps); + printf(" '%s':\n",caps->name); - printf(" '%s':\n",cap->name); - - type = gst_type_find_by_id (cap->id); + type = gst_type_find_by_id (caps->id); if (type) printf(" MIME type: '%s':\n",type->mime); else printf(" MIME type: 'unknown/unknown':\n"); - if (cap->properties) - print_props(cap->properties," "); + if (caps->properties) + print_props(caps->properties," "); + + caps = caps->next; } } @@ -210,19 +209,18 @@ print_element_info (GstElementFactory *factory) while (caps) { GstType *type; - cap = (GstCaps*)(caps->data); - caps = g_list_next(caps); + printf(" '%s':\n",caps->name); - printf(" '%s':\n",cap->name); - - type = gst_type_find_by_id (cap->id); + type = gst_type_find_by_id (caps->id); if (type) printf(" MIME type: '%s':\n",type->mime); else printf(" MIME type: 'unknown/unknown':\n"); - if (cap->properties) - print_props(cap->properties," "); + if (caps->properties) + print_props(caps->properties," "); + + caps = caps->next; } }