You are not logged in.

#1 2014-10-01 01:18:35

Xabre
Member
From: Serbia
Registered: 2009-03-19
Posts: 757

[SOLVED]Intel /Catalyst-PXP: switching the vaapi driver

Intel Haswell Ci3 CPU + AMD Radeon HD8750M
Currently using catalyst-test-pxp plus xvba-video from  Vi0l0's repository.
PowerExpress works, card switching switching works too, there is only this minor issue that when I switch to Intel card when on battery, vaapi driver still remains xvba.

The cause of it is  /etc/profile.d/xvba.sh (part of xvba-video package):

LIBVA_DRIVER_NAME=xvba
export LIBVA_DRIVER_NAME
LIBVA_DRIVERS_PATH=/usr/lib/dri/
export LIBVA_DRIVERS_PATH

Obviously, it sets the LIBVA_DRIVER to xvba no matter which card is currently used.

So, am looking for a safe and sane way to modify that file to detect the currently used card and to export the correct driver accordingly. Any hints? I have a feeling it's a ridiculously stupid thing, but my mind just isn't working at the moment.

Thanks in advance.

Last edited by Xabre (2014-10-01 17:44:13)

Offline

#2 2014-10-01 17:43:46

Xabre
Member
From: Serbia
Registered: 2009-03-19
Posts: 757

Re: [SOLVED]Intel /Catalyst-PXP: switching the vaapi driver

if [ -f /etc/X11/xorg.conf ];then
   if [ grep -q "fglrx" /etc/X11/xorg.conf ];then
        LIBVA_DRIVER_NAME=xvba
        export LIBVA_DRIVER_NAME
   fi
else
        LIBVA_DRIVER_NAME=i965
        export LIBVA_DRIVER_NAME
fi
        LIBVA_DRIVERS_PATH=/usr/lib/dri/
        export LIBVA_DRIVERS_PATH

Why do I always fail with these stupidly easy and obvious things? hmm

Anyhow, [SOLVED].

Offline

Board footer

Powered by FluxBB