udpsrc - flush buffer

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

udpsrc - flush buffer

GalDa
Hey all,

Whenever I try to open h264 udpsrc using a GST call back or a timed loop on
the first few frames or whenever my loop is slower then the encoder FPS I'm
seeing grey frames.
I guessing it's because whenever the pipline tryes to decode the buffer it
has more then 1 frames in it.
How can I flush the buffer whenver a new frame ariives using this gstreamer
pipline:

gst-launch-1.0 -v udpsrc port=54062 caps = "application/x-rtp,
media=(string)video, clock-rate=(int)90000, encoding-name=(string)H264,
payload=(int)96" ! rtph264depay ! 264parse ! avdec_h264 ! videoconvert !
autovideosink


Thanks, Gal.



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

Re: udpsrc - flush buffer

Nicolas Dufresne-5
Le vendredi 22 février 2019 à 08:07 -0600, GalDa a écrit :
> Whenever I try to open h264 udpsrc using a GST call back or a timed loop on
> the first few frames or whenever my loop is slower then the encoder FPS I'm
> seeing grey frames.
> I guessing it's because whenever the pipline tryes to decode the buffer it
> has more then 1 frames in it.
> How can I flush the buffer whenver a new frame ariives using this gstreamer
> pipline:

Add ".. ! identity drop-buffer-flags=corrupted ! ..." Right after your
decoder. There is two ways of thinking, one is to display corrupted
frames, to keep some movement, the other is to freeze the image until
we have valid frames again. In your case, you have SPS/PPS but no IDR
yet.

Nicolas

_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

signature.asc (201 bytes) Download Attachment