Installing the Unichrome driver
The Unichrome driver includes several components, and we are going to use three
of them. These are:
- an enhanced Xorg driver (better than the kernel driver)
- an XvMC driver to support the MPEG2 hardware decoding on-board
- an enhanced unichrome 3D display driver
Before continuing with this section however, I urge you to make sure you have a
working TV-Out using the basic kernel driver (see
here). At least you then know that the xorg.conf
file works!
Here are the steps needed to get the Unichrome driver working.
- We need a working build of the Xorg object files, so use
ebuild /usr/portage/x11-base/xorg-x11/xorg-x11-6.8.2-r6.ebuild fetch
to fetch the source.
- Now unpack and build it using:
ebuild /usr/portage/x11-base/xorg-x11/xorg-x11-6.8.2-r6.ebuild unpack ; ebuild /usr/portage/x11-base/xorg-x11/xorg-x11-6.8.2-r6.ebuild compile.
- I assume you have just fetched the version of xorg you currently have installed. If you are unsure, do
ebuild /usr/portage/x11-base/xorg-x11/xorg-x11-6.8.2-r6.ebuild install.
- Now all of the xorg tree is compiled under
/var/tmp/portage/xorg-x11-6.8.2-r6/work,
henceforward called XORG_BASE. If you don't have CVS emerged, now is a good time to
get it. :)
- Check out the Unichrome Xorg driver from CVS using:
cd XORG_BASE/xc/programs/Xserver/hw/xfree86/drivers/
cvs -z3 -d:pserver:anonymous@cvs.sourceforge.net:/cvsroot/unichrome co xfree86
- Reference the new driver from now on with
rm -rf via ; ln -s xfree86 via.
- Compile and install the driver by executing the following:
cd XORG_BASE/xc
make Makefiles
cd XORG_BASE/xc/programs/Xserver/hw/xfree86/drivers/via
make
make install
- Now to check out the Unichrome XvMC driver:
cd XORG_BASE/xc/lib/XvMC/hw
cvs -z3 -d:pserver:anonymous@cvs.sourceforge.net:/cvsroot/unichrome co libxvmc
- Utilise the new driver from now on using the command
ln -s libxvmc via.
- Edit
XORG_BASE/xc/lib/XvMC/Imakefile, and change the line:
SUBDIRS = hw/i810
to be:
SUBDIRS = hw/i810 hw/via
- Compile and install the driver using:
cd XORG_BASE/xc/
make Makefile
make Makefiles
cd XORG_BASE/xc/lib/XvMC/hw/via
make depend
make
make install
cp vldXvMC.h /usr/include/X11/extensions
- Make a backup copy of the file
/usr/lib/opengl/xorg-x11/lib/libGL.so.1.2 to somewhere safe.
- Download the latest Unichrome 3D drivers tarball from here.
- Extract it, and copy the
unichrome_dri.so file to /usr/X11R6/lib/modules/dri/ and the libGL.so.1.2 file to
/usr/lib/opengl/xorg-x11/lib/.
- Execute
cd /usr/X11R6/lib/modules/dri/ ; ln -s unichrome_dri.so via_dri.so.
- Jobs a good un!
Troubleshooting:
- I see "_XSERVTransSocketOpenCOTSServer: Unable to open socket for inet6..." and similar errors in the Xorg logs!
I am unsure as to what causes this, but its nothing to worry about as far as getting
unichrome drivers work is concerned.
Using the Unichrome driver
The unichrome driver includes support for Myth TV and Xine. To enable support in Myth
TV, do the following:
- Add
unichrome to your USE flags.
emerge mythtv once more.
- Run the mythfrontend and go into Setup.
- Go into TV Settings and select Playback.
- Navigate through the pages until you reach the Hardware Decoder screen. Select
Use HW XVMC VLD Decoding (Via only).
- Your box should now use hardware decoding.
Xine hardware acceleration can be achieved as follows:
- Add
cle266 to your USE flags.
- Ensure that Xine is not in your
/var/lib/portage/world file. It
is also good practice to make sure mythtv and mplayer aren't in here either, just
so that any upgrades that could potentially break the system don't happen overnight :)
- Execute
USE="xvmc" emerge xine-lib to emerge xine with the support.
- Run
xine -V xxmc -A alsa.
- Bonsa!
|