Skip to content
Snippets Groups Projects
Commit 9e308d15 authored by Tim-Philipp Müller's avatar Tim-Philipp Müller
Browse files

manual: update for position/duration query API change

parent 6248fefa
No related branches found
No related tags found
No related merge requests found
......@@ -78,11 +78,10 @@ my_bus_message_cb (GstBus *bus,
static gboolean
cb_print_position (GstElement *pipeline)
{
GstFormat fmt = GST_FORMAT_TIME;
gint64 pos, len;
if (gst_element_query_position (pipeline, &fmt, &pos)
&& gst_element_query_duration (pipeline, &fmt, &len)) {
if (gst_element_query_position (pipeline, GST_FORMAT_TIME, &pos)
&& gst_element_query_duration (pipeline, GST_FORMAT_TIME, &len)) {
g_print ("Time: %" GST_TIME_FORMAT " / %" GST_TIME_FORMAT "\r",
GST_TIME_ARGS (pos), GST_TIME_ARGS (len));
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment