Small fixes, improved query inspect

Original commit message from CVS:
Small fixes, improved query inspect
This commit is contained in:
Wim Taymans 2003-01-07 20:49:46 +00:00
parent 9f92f33025
commit aaef425d99
2 changed files with 19 additions and 22 deletions

View file

@ -150,6 +150,23 @@ print_formats (const GstFormat *formats)
}
}
static void
print_query_types (const GstQueryType *types)
{
while (types && *types) {
const GstQueryTypeDefinition *definition;
definition = gst_query_type_get_details (*types);
if (definition)
g_print ("\t\t(%d):\t%s (%s)\n", *types,
definition->nick, definition->description);
else
g_print ("\t\t(%d):\tUnknown query format\n", *types);
types++;
}
}
static void
print_event_masks (const GstEventMask *masks)
{
@ -198,26 +215,6 @@ print_event_masks (const GstEventMask *masks)
}
}
static void
print_query_types (const GstQueryType *types)
{
GType query_type;
GEnumClass *klass;
query_type = gst_query_type_get_type();
klass = (GEnumClass *) g_type_class_ref (query_type);
while (types && *types) {
GEnumValue *value;
value = g_enum_get_value (klass, *types);
g_print ("\t\t(%d):\t%s (%s)\n", value->value, value->value_nick, value->value_name);
types++;
}
}
static void
output_hierarchy (GType type, gint level, gint *maxlevel)
{

View file

@ -204,10 +204,10 @@ main(int argc, char *argv[])
free (malloc (8)); /* -lefence */
gst_init_with_popt_table (&argc, &argv, options);
if (!no_fault)
fault_setup();
gst_init_with_popt_table (&argc, &argv, options);
/* make a null-terminated version of argv */
argvn = g_new0 (char*, argc);