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

kmliu liu_kim at hotmail.com
Mon Aug 5 17:32:06 UTC 2019


I think you may be right. There is apparently no copying if I use "videorate
max-rate=10".



junyan.he wrote
> The videorate plugin seems just have transform_ip function and just
> transform gstbuffer in place, will not copy the buffers. So it seems
> will not generate copying memory from GPU(Graphic) to CPU. Are you sure
> the memory copy generated?
> 
> 
> On 四, 2019-08-01 at 18:24 -0500, kmliu wrote:
>> 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/
>> _______________________________________________
>> gstreamer-devel mailing list
>> 

> gstreamer-devel at .freedesktop

>> https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
> _______________________________________________
> gstreamer-devel mailing list

> gstreamer-devel at .freedesktop

> https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel





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


More information about the gstreamer-devel mailing list