Does buffer data carry a tag or a sequence number while flowing through a pipeline?

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Does buffer data carry a tag or a sequence number while flowing through a pipeline?

jeyp4
This post was updated on .
Hello
v4l2src -> timeoverlay -> vaapih265enc -> vaapidecode -> appsink

Does data flowing through above(e.g.) pipeline carry any tag or any kind of
sequence number?

So that the final element(appsink) pad can match data tag with first element
pad(v4l2src).

My ultimate purpose is to provide a time-stamp to appsink data. Where the
time-stamp can represent to image shot time as close as possible. I am
flexible to use any time reference, e.g. ros::Time::now()



--
Sent from: http://gstreamer-devel.966125.n4.nabble.com/
_______________________________________________
gstreamer-devel mailing list
gstreamer-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Does buffer data carries a sequence number while flowing through a pipeline?

Nicolas Dufresne-5


Le ven. 11 oct. 2019 06 h 55, jeyp4 <[hidden email]> a écrit :
Hello
v4l2src -> timeoverlay -> vaapih265enc -> vaapidecode -> appsink

Does data flowing through above(e.g.) pipeline carry any tag or any kind of
sequence number?

So that the final element(appsink) pad can match data tag with first element
pad(v4l2src).

My ultimate purpose is to provide a time-stamp to appsink data. Where the
time-stamp can represent to image shot time as close as possible. I am
flexible to use any time reference, e.g. ros::Time::now()

The timestamp is from v4l2src, which is in turn derived from whatever the Linux/BSD kernel provided. It's a bit of a round trip, but here the conversion flow.

v4l2src

Monotonic -> pipeline clock -> stream time

Pts = t + delta - base_time


So when you receive buffer in appasrc, to find back the monotonic time you do the opposite.

T = pts - delta + base_time

Delta is the distance between pipeline clock now and time now. This is were precision is lost, as there is no atomic way to retrieve this.





--
Sent from: http://gstreamer-devel.966125.n4.nabble.com/
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Does buffer data carry a tag or a sequence number while flowing through a pipeline?

scottca
In reply to this post by jeyp4
There is the PTS time.
which would be maintained...
wish there was a better answer, I was looking for something "nice" as well.




--
Sent from: http://gstreamer-devel.966125.n4.nabble.com/
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel