VAAPI: How to reduce fps of decoded video being copied out of graphics memory?

kmliu liu_kim at hotmail.com
Thu Aug 1 23:24:59 UTC 2019


I'm trying to use VAAPI to decode H.264 video from an IP camera and then
export the raw frames out of graphics memory to main memory for some
unspecified "further processing". Say the H.264 is 30fps but I only want to
process 10fps. I can do something like this:

gst-launch-1.0 rtspsrc location=rtsp_uri ! rtph264depay ! vaapih264dec !
videorate ! "video/x-raw,framerate=10/1" ! filesink location=video.yuv

But this seems to first copy all 30fps from graphics memory and then lower
it to 10fps. How can I reduce the fps of raw frames being copied out of
graphics memory in the first place (to reduce memory bandwidth consumption)?

I have also tried this:

gst-launch-1.0 rtspsrc location=rtsp_uri ! rtph264depay ! vaapih264dec !
"video/x-raw,framerate=10/1" ! filesink location=video.yuv

and this:

gst-launch-1.0 rtspsrc location=rtsp_uri ! rtph264depay ! vaapih264dec !
"video/x-raw(memory:VASurface),framerate=10/1" ! filesink location=video.yuv

Neither seems to work. They both have the WARN message "GST_PADS:
gst-pad.c:4226:gst_pad_peer_query:<vaapidecode_h264-0:src> could not send
sticky events". And the output file video.yuv is empty.




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


More information about the gstreamer-devel mailing list