Commit ab60a330 authored by Guillaume Desmottes's avatar Guillaume Desmottes Committed by Sebastian Dröge

gst-stats: format latency as GST_TIME

Latency is easier to read when formatted as time rather than displayed
as a flat number in ns.
Especially when displaying GST_CLOCK_TIME_NONE which is now formated as
99:99:99.999999999 instead of 18446744073709551615.
parent 38d535ff
Pipeline #33116 passed with stages
in 43 minutes and 21 seconds
......@@ -124,16 +124,17 @@ typedef struct
static void
latencies_foreach_print_stats (gchar * key, GstLatencyStats * ls, gpointer data)
{
printf ("\t%s: mean=%" G_GUINT64_FORMAT " min=%" G_GUINT64_FORMAT " max=%"
G_GUINT64_FORMAT "\n", key, ls->total / ls->count, ls->min, ls->max);
printf ("\t%s: mean=%" GST_TIME_FORMAT " min=%" GST_TIME_FORMAT " max=%"
GST_TIME_FORMAT "\n", key, GST_TIME_ARGS (ls->total / ls->count),
GST_TIME_ARGS (ls->min), GST_TIME_ARGS (ls->max));
}
static void
reported_latencies_foreach_print_stats (GstReportedLatency * rl, gpointer data)
{
printf ("\t%s: min=%" G_GUINT64_FORMAT " max=%" G_GUINT64_FORMAT " ts=%"
GST_TIME_FORMAT "\n", rl->element, rl->min,
rl->max, GST_TIME_ARGS (rl->ts));
printf ("\t%s: min=%" GST_TIME_FORMAT " max=%" GST_TIME_FORMAT " ts=%"
GST_TIME_FORMAT "\n", rl->element, GST_TIME_ARGS (rl->min),
GST_TIME_ARGS (rl->max), GST_TIME_ARGS (rl->ts));
}
static void
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment