added workaround for time measurement in the autoplug test

This commit is contained in:
maroy 2005-06-22 14:52:02 +00:00
parent d390fb1ff4
commit 7e3fb629b4

View file

@ -22,7 +22,7 @@
Author : $Author: maroy $
Version : $Revision: 1.1 $
Version : $Revision: 1.2 $
Location : $Source: /home/paul/cvs2svn-livesupport/newcvsrepo/livesupport/modules/gstreamerElements/src/AutoplugTest.cxx,v $
------------------------------------------------------------------------------*/
@ -123,8 +123,10 @@ AutoplugTest :: playFile(const char * audioFile)
// iterate until playTo is reached
while (gst_bin_iterate(GST_BIN(pipeline)));
/* query the decoder, as for some reason, the sink will return
* unreal numbers */
format = GST_FORMAT_TIME;
gst_element_query(sink, GST_QUERY_POSITION, &format, &timePlayed);
gst_element_query(decoder, GST_QUERY_POSITION, &format, &timePlayed);
/* clean up nicely */
gst_element_set_state(pipeline, GST_STATE_NULL);