diff options
author | Stefan Kost <ensonic@users.sf.net> | 2010-12-13 16:20:23 +0200 |
---|---|---|
committer | Stefan Kost <ensonic@users.sf.net> | 2010-12-13 17:03:25 +0200 |
commit | 4e8956c9f1497ce05ae004fb929bf2c601dc5857 (patch) | |
tree | 34ae09afe94e0d09b283bb44441228c52d8df59b /tools/gst-discoverer.c | |
parent | da70200ea50643b1d067eea13e2669f4a62735ab (diff) | |
download | gstreamer-plugins-base-4e8956c9f1497ce05ae004fb929bf2c601dc5857.tar.gz |
discoverer: query seekability
Besides the duration we can also query the seekability of a stream. Use the new
API in the gst-discoverer tool.
API: gst_discoverer_info_get_seekable
Diffstat (limited to 'tools/gst-discoverer.c')
-rw-r--r-- | tools/gst-discoverer.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/tools/gst-discoverer.c b/tools/gst-discoverer.c index bc2540991..bff1b7945 100644 --- a/tools/gst-discoverer.c +++ b/tools/gst-discoverer.c @@ -241,10 +241,12 @@ print_topology (GstDiscovererStreamInfo * info, gint depth) } static void -print_duration (GstDiscovererInfo * info, gint tab) +print_properties (GstDiscovererInfo * info, gint tab) { - g_print ("%*s%" GST_TIME_FORMAT "\n", tab + 1, " ", + g_print ("%*sDuration: %" GST_TIME_FORMAT "\n", tab + 1, " ", GST_TIME_ARGS (gst_discoverer_info_get_duration (info))); + g_print ("%*sSeekable: %s\n", tab + 1, " ", + (gst_discoverer_info_get_seekable (info) ? "yes" : "no")); } static void @@ -296,8 +298,8 @@ print_info (GstDiscovererInfo * info, GError * err) if ((sinfo = gst_discoverer_info_get_stream_info (info))) { g_print ("\nTopology:\n"); print_topology (sinfo, 1); - g_print ("\nDuration:\n"); - print_duration (info, 1); + g_print ("\nProperties:\n"); + print_properties (info, 1); gst_discoverer_stream_info_unref (sinfo); } |