Constructing GstRTPBuffer to get RTP packet timestamp
nirbheek.chauhan at gmail.com
Wed Nov 24 10:01:02 UTC 2021
On Tue, Nov 23, 2021 at 6:00 PM kalpesh shukla via gstreamer-devel
<gstreamer-devel at lists.freedesktop.org> wrote:
> In one of our python based video streaming applications we are required to get a timestamp of the RTP packet for synchronization purposes.
What sort of synchronization do you want to do? GStreamer has built-in
mechanisms for the common use-cases.
> While going through the GStreamer documents we came across GstRTPBuffer (which is part of RTP library) helper functions which can be used to extract RTP timestamp and other RTP header related details.
> We are not able to find any reference on how to get GstRTPBuffer to start working on RTP header.
> Below is the example pipeline for reference,
> gst-launch-1.0 rtspsrc location=rtsp://127.0.0.1:8554/livestream ! rtph264depay ! h264parse ! avdec_h264 ! videoconvert ! appsink
You can add a pad probe on the sinkpad of the depayloader:
and map the GstBuffer as a GstRTPBuffer:
That will give you access to all this.
More information about the gstreamer-devel