QtGtstreamer: query position returns a wrong value

gianks gianksmail at gmail.com
Thu Aug 4 11:42:02 UTC 2016


Hi all,i'm still quite new with GStreamer and i'm working on my first project
with it.I'm using QtGStreamer bindings so i have implemented a simple
function to query the current pipeline about position:
            QTime MyPipeline::queryPosition() {               
QGst::PositionQueryPtr query =
QGst::PositionQuery::create(QGst::FormatTime);               
pipeline->query(query);                return
QGst::ClockTime(query->position()).toTime();            }
Now after entering the playing state i set up a QTimer to run each second
the following:
                void debugPosition() {                        qDebug() <<
this << " ### Position: " << queryPosition()                }
Up to here it works as expected since i can retrieve for each Pipeline the
current playback position and print it. The same function is also sometimes
called inside the callback 'formatLocation' of the sink element
'muxsplitsink' in one of the pipelines since the position is needed to be
acquired in that moment, but for some reasons from there the value 99% is
reported as QTime("23:34:33.709").I remember something about querying the
position from certain contexts can fail but i cannot find this in the
manual, can someone help?Thanks



--
View this message in context: http://gstreamer-devel.966125.n4.nabble.com/QtGtstreamer-query-position-returns-a-wrong-value-tp4678954.html
Sent from the GStreamer-devel mailing list archive at Nabble.com.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/gstreamer-devel/attachments/20160804/f884afaf/attachment.html>


More information about the gstreamer-devel mailing list