You are not logged in.

#1 2018-05-28 17:48:04

doe1097
Member
Registered: 2018-05-28
Posts: 9

[SOLVED] Intel® HD Graphics 405 Hardware Acceleration with VLC

Hello BLers,

today I installed Bunsenlabs and until now it's just awesome! Thanks for your effort to make this work.

Nevertheless, I experience one strange issue with VLC, as it doesn't seem to make use of HW acceleration. It should be enough to just install the VAAPI driver, but  APT says it doesn't exist - package i965-va-driver is installed.

So, I installed Kodi to see if it works with HW and it obviously does. Does anyone of you have an idea what's going wrong here?

Last edited by doe1097 (2018-05-29 07:25:36)

Offline

#2 2018-05-28 21:57:49

nobody
The Great
Registered: 2015-08-10
Posts: 3,655

Re: [SOLVED] Intel® HD Graphics 405 Hardware Acceleration with VLC

Check if in Preferences>Input/Codecs, VA-API is explicitly selected as a hardware acceleration method. Alternatively, run VLC with --avcodec-hw=vaapi. Note that depending on the media you're playing back, vaapi may not be available due to missing x264 profile support. How did you check if Kodi was using vaapi?

Offline

#3 2018-05-29 07:23:38

doe1097
Member
Registered: 2018-05-28
Posts: 9

Re: [SOLVED] Intel® HD Graphics 405 Hardware Acceleration with VLC

nobody wrote:

Check if in Preferences>Input/Codecs, VA-API is explicitly selected as a hardware acceleration method. Alternatively, run VLC with --avcodec-hw=vaapi. Note that depending on the media you're playing back, vaapi may not be available due to missing x264 profile support.

Sorry, I should have mentioned that I tried this already, but it seems to have no effect.

nobody wrote:

How did you check if Kodi was using vaapi?

Not specifically vaapi, but the CPU usage with Kodi is <20% (h264 FullHD content) and with VLC it instantly goes up to >90%. I experienced the same issue with Fedora and Openbox, but after installing libva-intel-driver playback was smooth as expected, so I thought installing intel-vaapi-driver does the same in Debian.

From the VLC Wiki: On modern Ubuntu distributions, first install the hardware support (packages i965-va-driver, libva-intel-vaapi-driver and vainfo)
But when I try to install libva-intel-vaapi-driver, I get

Reading package lists... Done
Building dependency tree       
Reading state information... Done
E: Unable to locate package libva-intel-vaapi-driver

and when I try to install intel-vaapi-driver it is the same, even though I can find it in the Debian packages with Firefox: https://packages.debian.org/source/stre … api-driver

Offline

#4 2018-05-29 07:59:06

johnraff
nullglob
From: Nagoya, Japan
Registered: 2015-09-09
Posts: 12,676
Website

Re: [SOLVED] Intel® HD Graphics 405 Hardware Acceleration with VLC

intel-vaapi-driver is a source package which builds the binary i965-va-driver. The latter is what you can install.


...elevator in the Brain Hotel, broken down but just as well...
( a boring Japan blog (currently paused), now on Bluesky, there's also some GitStuff )

Introduction to the Bunsenlabs Boron Desktop

Offline

#5 2018-05-29 08:23:00

doe1097
Member
Registered: 2018-05-28
Posts: 9

Re: [SOLVED] Intel® HD Graphics 405 Hardware Acceleration with VLC

Just installed vainfo to get a bit more information and it seem VA-API is supported, but since VLC doesn't make use of it, I assume it's a VLC issue?

$ vainfo
libva info: VA-API version 0.39.4
libva info: va_getDriverName() returns 0
libva info: Trying to open /usr/lib/x86_64-linux-gnu/dri/i965_drv_video.so
libva info: Found init function __vaDriverInit_0_39
libva info: va_openDriver() returns 0
vainfo: VA-API version: 0.39 (libva 1.7.3)
vainfo: Driver version: Intel i965 driver for Intel(R) CherryView - 1.7.3
vainfo: Supported profile and entrypoints
      VAProfileMPEG2Simple            :    VAEntrypointVLD
      VAProfileMPEG2Simple            :    VAEntrypointEncSlice
      VAProfileMPEG2Main              :    VAEntrypointVLD
      VAProfileMPEG2Main              :    VAEntrypointEncSlice
      VAProfileH264ConstrainedBaseline:    VAEntrypointVLD
      VAProfileH264ConstrainedBaseline:    VAEntrypointEncSlice
      VAProfileH264Main               :    VAEntrypointVLD
      VAProfileH264Main               :    VAEntrypointEncSlice
      VAProfileH264High               :    VAEntrypointVLD
      VAProfileH264High               :    VAEntrypointEncSlice
      VAProfileH264MultiviewHigh      :    VAEntrypointVLD
      VAProfileH264MultiviewHigh      :    VAEntrypointEncSlice
      VAProfileH264StereoHigh         :    VAEntrypointVLD
      VAProfileH264StereoHigh         :    VAEntrypointEncSlice
      VAProfileVC1Simple              :    VAEntrypointVLD
      VAProfileVC1Main                :    VAEntrypointVLD
      VAProfileVC1Advanced            :    VAEntrypointVLD
      VAProfileNone                   :    VAEntrypointVideoProc
      VAProfileJPEGBaseline           :    VAEntrypointVLD
      VAProfileJPEGBaseline           :    VAEntrypointEncPicture
      VAProfileVP8Version0_3          :    VAEntrypointVLD
      VAProfileVP8Version0_3          :    VAEntrypointEncSlice
      VAProfileHEVCMain               :    VAEntrypointVLD

Offline

#6 2018-05-29 14:18:57

doe1097
Member
Registered: 2018-05-28
Posts: 9

Re: [SOLVED] Intel® HD Graphics 405 Hardware Acceleration with VLC

earlybird wrote:

To be 100% sure if va-api works on your system, install mpv

sudo apt-get install mpv

then force vaapi like this

mpv --vo=opengl --hwdec=auto $yourvideo

It should say that it is using vaapi for hwdec in the terminal output. If not, try overriding autodetection using

This is the terminal output:

mpv --vo=opengl --hwdec=auto test.mkv 
Playing: test.mkv
 (+) Video --vid=1 (*) (h264)
 (+) Audio --aid=1 --alang=ger (*) (f) (ac3)
libva info: VA-API version 0.39.4
libva info: va_getDriverName() returns 0
libva info: Trying to open /usr/lib/x86_64-linux-gnu/dri/i965_drv_video.so
libva info: Found init function __vaDriverInit_0_39
libva info: va_openDriver() returns 0
Failed to open VDPAU backend libvdpau_i965.so: cannot open shared object file: No such file or directory
AO: [pulse] 48000Hz 5.1(side) 6ch float
Using hardware decoding (vaapi).
VO: [opengl] 1920x1040 vaapi
(Paused) AV: 00:28:46 / 02:35:46 (18%) A-V:  0.000

So mpv works and the CPU usage is around 20%. It also seems to handle .m3u, so I'm satisfied and go with mpv (even though it doesn't really solve the problem...) Thanks for your help! :-)

Offline

#7 2018-05-29 14:39:44

doe1097
Member
Registered: 2018-05-28
Posts: 9

Re: [SOLVED] Intel® HD Graphics 405 Hardware Acceleration with VLC

It looks ok for my case. Only the version seems pretty much outdated and the OSD is a bit too big for my taste (looks like it's made for touch devices), but it works and I'm not dare to upgrade from sid and prbly mess things up.

Offline

#8 2018-05-31 04:26:00

stevep
MX Linux Developer
Registered: 2016-08-08
Posts: 381

Re: [SOLVED] Intel® HD Graphics 405 Hardware Acceleration with VLC

A statically linked mpv-0.28.0 is available in my own multimedia backports repo.

https://build.opensuse.org/package/show … nal-ffmpeg

http://forums.debian.net/viewtopic.php?f=6&t=127574

Guess I never updated it to 0.28.2 like I did for MX Linux.  I'll do that tommorrow.

I branched off another repo from that one with ffmpeg 4.0 and a dynamically linked mpv, and it worked in my tests, but YMMV. Since ffmpeg libraries are numbered, they won't replace your present Stretch runtime libs.

https://build.opensuse.org/project/show … rt:ffmpeg4

Offline

#9 2018-06-01 03:15:02

stevep
MX Linux Developer
Registered: 2016-08-08
Posts: 381

Re: [SOLVED] Intel® HD Graphics 405 Hardware Acceleration with VLC

Well, I never did get that newer mpv in the OBS repo...I have a new MSI Intel 8th gen Coffeelake laptop, and the driver required a new Mesa to be working correctly, but va-api still wasn't working, as well as Optimus GPU switching with Bumblebee.

Long story short, I backported the Mesa 18.0.4 and va-api stack from Buster, rebuilt ffmpeg 3.4.2 against that, then rebuilt vlc-3.0.3, qmplay2, mpv 0.28.2, and Kodi 17.6 against all of the above, and everything just started working...va-api and Bumblebee both.  I'm going to send them up to our separate experimental MX 17 repo so other users with the same sort of hardware can try it out.

It sounds like a lot of work, but I streamline it by using pbuilder and repeated commands to copy the completed debs into a folder that works like a local repo so pbuilder can use those as build-depends for further builds down the stack.

Offline

#10 2018-06-01 03:59:37

hhh
Gaucho
From: High in the Custerdome
Registered: 2015-09-17
Posts: 16,181
Website

Re: [SOLVED] Intel® HD Graphics 405 Hardware Acceleration with VLC

^ Word, way to go the extra mile, Steve. Thank you!


I don't care what you do at home. Would you care to explain?

Offline

#11 2018-06-02 00:40:32

stevep
MX Linux Developer
Registered: 2016-08-08
Posts: 381

Re: [SOLVED] Intel® HD Graphics 405 Hardware Acceleration with VLC

hhh wrote:

^ Word, way to go the extra mile, Steve. Thank you!

It's basically to get everything working correctly on my new laptop, but building backports let me share the work. 

Debian really needs to update their the firmware packages for this machine to get them from a repo, but I found the commands to download and install the upstream firmware tree, which will work if you have a wired connection and install git:

mkdir -p ~/linux
cd ~/linux
git clone https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git/
cd linux-firmware
sudo make install

Last edited by stevep (2018-06-02 00:41:06)

Offline

#12 2018-06-02 10:07:19

doe1097
Member
Registered: 2018-05-28
Posts: 9

Re: [SOLVED] Intel® HD Graphics 405 Hardware Acceleration with VLC

Just wanted to say thanks for your hints and efforts, great job!

Offline

#13 2018-06-03 02:31:03

stevep
MX Linux Developer
Registered: 2016-08-08
Posts: 381

Re: [SOLVED] Intel® HD Graphics 405 Hardware Acceleration with VLC

What actually ended up being the solution?

Offline

#14 2018-06-12 04:45:05

doe1097
Member
Registered: 2018-05-28
Posts: 9

Re: [SOLVED] Intel® HD Graphics 405 Hardware Acceleration with VLC

stevep wrote:

What actually ended up being the solution?

Replacing VLC with MPV. Until now I had no issues and it eats everything with hw-acceleration, so best match for me.

Last edited by doe1097 (2018-06-12 04:45:20)

Offline

Board footer

Powered by FluxBB