gstreamer - retain buffer offset over RTP

137 views Asked by At

Im trying to create gst pipelines to send a video over rtp, with some identifier for each frame, so that the pipeline receiving them will be able to know which frame is which. the puropse of this is to create the option to sync the stream with some other component in my system.

the sending pipline is:

<video src and some manipulation elements> !
queue ! 
videoconvert n-threads=2 qos=false ! 
queue !
x264enc !
h264parse !
queue !
rtph264pay !
udpsink host=0.0.0.0 port=5000 sync=true

and the receiving pipeline is:

udpsrc address=0.0.0.0 port=5000 caps=application/x-rtp,media=video,encoding-name=H264,payload=96 !
rtph264depay !
queue !
decodebin !
queue !
<other manipulation elements and a sink>

in order to do that, i wanted to use the buffer_offset property in the GstBuffer object, because it will be an incrementing number that will uniquly identify each frame, which is good enough for me. unfortunatly, on the receiving pipeline this value is always NULL, probably because it gets lost in the RTP protocol implementation or maybe even in the encoding. how can i make my pipeline retain this value to be avaialbe, correct and consistent after the decoding in the receiving pipeline?

0

There are 0 answers