Gstreamer VAAPI decoder plugins run much slower than software decoder plugins

Xiang, Haihao haihao.xiang at intel.com
Thu Dec 27 05:05:09 UTC 2018


Hi Nihit,

Usually retrieving video data from a video buffer is very slow, so it would be
better to use hardware acceleration in downstream elements too.

Thanks
Haihao

> Hello Nihit,
> 
> I wonder why you do not use:
> 
> ... rtpjpegdepay ! vaapijpegdec ! vaapipostproc ! vaapisink
> 
> Likely, this will not speed up "vaapijpegdec", but the following
> elements will use hardware acceleration as well.
> 
> Also, "buffer-size" seems very small. Try a value 10 times bigger, or
> even more. And did you increase network buffering on the receiver and
> sender side using:
> 
>   # sysctl net.core.rmem_max=16777216
>   # sysctl net.core.wmem_max=16777216
> 
> Hope it helps,
> 
> Wolfgang.
> 
> Am 26.12.18 um 02:14 schrieb Nihit Mody:
> > Hi Stephen,
> > 
> > Thank you for your response. The sender pipeline is 1920x1080 @
> > 60FPS. After doing some testing here are my results with VAAPIjpegdec:
> > 
> > Pipeline (1) Vaapijpegdec:
> > 
> > gst-launch-1.0 udpsrc port=5000 buffer-size=2000000 !
> > application/x-rtp,encoding-name=JPEG,payload=26 ! rtpjpegdepay !
> > vaapijpegdec ! videoconvert ! fpsdisplaysink text-overlay=true
> > 
> > yields 6.00 FPS 
> > 
> > Pipeline (2) With Vaapijpegdec and Jpegparse between depay and vaapijpegdec:
> > 
> > gst-launch-1.0 udpsrc port=5000 buffer-size=2000000 !
> > application/x-rtp,encoding-name=JPEG,payload=26 ! rtpjpegdepay !
> > jpegparse ! vaapijpegdec ! videoconvert ! fpsdisplaysink text-overlay = true
> > 
> > yields 6.18 FPS 
> > 
> > So I get a slight improvement of 0.18 FPS,
> > 
> > Here are the GstShark analysis results:
> > 
> > GstShark Analysis Pipeline (1) without jpegparse:
> > 
> > Proctime Analysis 	
> > 	
> > 
> > 	
> > 	
> > Element 	Time (ns) 	Time (ms)
> > capsfilter 	8830 	0.00883
> > rtpjpegdepay0 	505782 	0.505782
> > vaapijpegdec0 	6017591 	6.017591
> > videoconvert0 	50351 	0.050351
> > 
> > 
> > GstShark Analysis Pipeline (2) with jpegparse:
> > 
> > Proctime Analysis 	
> > 	
> > 
> > 	
> > 	
> > Element 	Time (ns) 	Time (ms)
> > capsfilter 	15244 	0.015244
> > rtpjpegdepay0 	608405 	0.608405
> > jpegparse0 	1589129 	1.589129
> > vaapijpegdec0 	3160754 	3.160754
> > videoconvert0 	68940 	0.06894
> > 
> > 
> > It seems the vaapijpegdec is able to perform the decode in 3.16ms vs
> > almost 17ms for the software decoder (jpegdec) yet the framerate is
> > 12.14 FPS so almost double with the software decoder. Do you know why
> > this could be?
> > 
> > 
> > On Sat, Dec 22, 2018 at 10:27 AM Stephenwei <lofy.stephen at gmail.com
> > <mailto:lofy.stephen at gmail.com>> wrote:
> > 
> >     Hi,
> >     Could you try to increase jpegparse between depay  and vaapijpegdecode?
> > 
> > 
> > 
> >     --
> >     Sent from: http://gstreamer-devel.966125.n4.nabble.com/
> >     _______________________________________________
> >     gstreamer-devel mailing list
> >     gstreamer-devel at lists.freedesktop.org
> >     <mailto:gstreamer-devel at lists.freedesktop.org>
> >     https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
> > 
> > 
> > _______________________________________________
> > gstreamer-devel mailing list
> > gstreamer-devel at lists.freedesktop.org
> > https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
> > 
> 
> _______________________________________________
> gstreamer-devel mailing list
> gstreamer-devel at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel


More information about the gstreamer-devel mailing list