Set and get the timestamp manually using appsrc/appsink.

surprised 1028554060 at qq.com
Thu Nov 7 02:00:25 UTC 2019


Hi,givip.

I really happy that I've received your reply. But I also failed to achieve
my purpose. I think I should introduce you more details so that you could
have a clearer understand of what my demand.

I just want to achieve this:

At sender, First,I obtain YUV data via appsrc. I want to write an ID into
each frame of YUV(before encoding), and then I encode,and then I transmit
them into Local Area Network via rtph265pay and udpsink.

At receiver, I receive them via udpsrc and rtph265depay,then I decode and
get YUV data via appsink.

My main purpose is: At receiver,I can get the ID of each YUV data so that I
can have the knowledge that if there exists a phenomenon of lossing data
when transmitting by checking the continuous ID numbers.

Then I thought of  a method: Using timestamp maybe can achieve my purpose.So
I tried. 

Now, I set "do-timestamp" as FALSE in appsrc, and I found that udpsrc also
has the "do-timestamp" property,so I also set "do-timestamp" as FALSE in
udpsrc. The rest of operations is as same as I set in the   previous
posts(In appsrc, I set timestamp like this: GST_BUFFER_PTS(buffer)=100; In
appsink,I get the timestamp like this: timestamp=GST_BUFFER_PTS(buffer); ).
Then I output the timestamp in appsink,but it doesn't equal to 100 which I
set in appsrc.

Is there something else I don't realize? Please help me find the problem.
Or if I set the timestamp in GstRtpBuffer(in this way,I can set timestamp as
frame ID and I can get this timestamp before decoding.),how can I do?



--
Sent from: http://gstreamer-devel.966125.n4.nabble.com/


More information about the gstreamer-devel mailing list