Headless VA-API hardware accelerated H.264 video encoding with vaapih264enc?

Matthew Thyer matthew.thyer at adelaide.edu.au
Fri Sep 14 07:01:23 UTC 2018


Partially answering my own question...
I see that when I built gstreamer-vaapi v1.14.2 module from source that the "DRM backend" is enabled by default "-enable-drm=yes" but from my configure log I see that checking for DRM failed: "checking for DRM... no".
The configuration summary at the end of my configure output shows only "x11 glx egl wayland" in the "Video outputs" section.

So I'm missing some dependency for building the gstreamer-vaapi v1.14.2 module with DRM.
      DRM: libva-dev (>= 1.1.0), libdrm-dev, libudev-dev

I've now tested by having libdrm-dev & libudev-dev installed before my build and this has provided the DRM Video output.
I still don't know how to select it at run time!

From: Matthew Thyer
Sent: Friday, 14 September 2018 3:30 PM
To: 'Discussion of the development of and with GStreamer' <gstreamer-devel at lists.freedesktop.org>
Subject: Headless VA-API hardware accelerated H.264 video encoding with vaapih264enc?

The Libav Wiki "Hardware/vaapi" page (https://wiki.libav.org/Hardware/vaapi) states that I should be able to use VA-API hardware acceleration without being connected to an X server.

Quote:
"The libva driver needs to be attached to a DRM device to work. This can be connected either directly or via a running X server. When working standalone, it is generally best to use a DRM render node (/dev/dri/render*); only use a connection via X if you actually want to deal with surfaces inside X (with DRI2, for example)."

It then gives an example on how to use the DRI rendering device directly with the "avconv" utility:
avconv -hwaccel vaapi -hwaccel_device /dev/dri/renderD128 -i ...

What's the equivalent for the vaapih264enc GStreamer element?
i.e., How do I make it use the DRM device /dev/dri/renderD128 instead of the X server?
I can't see any properties of the element that allow me to control this.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/gstreamer-devel/attachments/20180914/e93fb79d/attachment-0001.html>


More information about the gstreamer-devel mailing list