Tuesday, April 6, 2010

Nvidia VDPAU thread

*Official* Nvidia VDPAU thread

EDIT: Please see this thread because this guide has become outdated (yay!), but I've left it here for giggles.

Instructions for using nvidia's VDPAU video acceleration (180.29 has been released stable ):

I'm using Kubuntu 8.10 with a 9300GS, so YMMV. Also, version numbers change, so be aware of that before you copy/paste commands.

* Intrepid and Jaunty PPA repositories for nvidia beta driver and mplayer-vdpau --> https://launchpad.net/~thomas-creutz/+archive

To manually install:

INSTALL THE NVIDIA DRIVER

Always check the nvidia thread for the current driver versions and information about cards supported, etc. --> http://www.nvnews.net/vbulletin/showthread.php?t=122606
As of this writing, the current version is 180.16.

* Deactiviate the nvidia driver (if you're using it) in the "Hardware Drivers" system utility.
* Download the driver and remember where you put it.
* Use to switch to a console.
* Log in as "root" or use "sudo su" to become root if you log in as normal user.
* Stop the display manager (in Ubuntu/Gnome, replace "kdm" with "gdm"):
Code:
/etc/init.d/kdm stop
* Remove the nvidia module:
Code:
modprobe -r nvidia
* Make sure some dependencies are installed:
Code:
apt-get install build-essential linux-headers-`uname -r`
* Go to the directory where you saved the drivers, e.g.:
Code:
cd /home/user/src/nvidia/16
* Run the installer:
Code:
sh NVIDIA-Linux-x86-180.16-pkg1.run
* When it's done, start the display manager:
Code:
/etc/init.d/kdm start
* Open a terminal and verify that you're using the new drivers:
Code:
cat /var/log/Xorg.0.log | grep NVIDIA
-----

TEST VDPAU CAPABILITIES OF YOUR VIDEO CARD
From the nvnews forums --> http://www.nvnews.net/vbulletin/showthread.php?t=124978

* Download and extract the file somewhere (here's a direct link) --> http://www.cs.rug.nl/~wladimir/vdpin...o-0.0.4.tar.gz
* in a terminal, cd to the directory where you extracted it (vdpinfo)
* you'll need the X headers:
Code:
sudo apt-get install xorg-dev
* run "make"
* run "./vdpinfo"

My 9300GS produces the following output:
Code:
display: :0   screen: 0                               API version: 0                                        Information string: Unknown                            Video surface:  name   width height types ------------------------------------------- 420     4096  4096  NV12 YV12               422     4096  4096  UYVY YUYV                Decoder capabilities:  name          level ref width height ------------------------------------ MPEG1             0  2  4096  4096   MPEG2_SIMPLE      3  2  4096  4096   MPEG2_MAIN        3  2  4096  4096   H264_MAIN        41 16  4096  4096   H264_HIGH        41 16  4096  4096   VC1_SIMPLE        1  2  4096  4096   VC1_MAIN          2  2  4096  4096   VC1_ADVANCED      4  2  4096  4096    Output surface:  name              width height nat types ---------------------------------------------------- B8G8R8A8          8192  8192    y  Y8U8V8A8 V8U8Y8A8  R10G10B10A2       8192  8192    y  Y8U8V8A8 V8U8Y8A8   Bitmap surface:  name              width height ------------------------------ B8G8R8A8          8192  8192 R8G8B8A8          8192  8192 R10G10B10A2       8192  8192 B10G10R10A2       8192  8192 A8                8192  8192  Video mixer:  feature name                    sup ------------------------------------ DEINTERLACE_TEMPORAL             y DEINTERLACE_TEMPORAL_SPATIAL     y INVERSE_TELECINE                 y NOISE_REDUCTION                  y SHARPNESS                        y LUMA_KEY                         y  parameter name                  sup      min      max ----------------------------------------------------- VIDEO_SURFACE_WIDTH              y         1     4096 VIDEO_SURFACE_HEIGHT             y         1     4096 CHROMA_TYPE                      y LAYERS                           y         0        4  attribute name                  sup      min      max ----------------------------------------------------- BACKGROUND_COLOR                 y CSC_MATRIX                       y NOISE_REDUCTION_LEVEL            y      0.00     1.00 SHARPNESS_LEVEL                  y     -1.00     1.00 LUMA_KEY_MIN_LUMA                y LUMA_KEY_MAX_LUMA                y
-----

PATCH AND BUILD MPLAYER

NOTE: As of today, VDPAU support is officially in mplayer svn (r28617).

* Download the patchset from nvidia. You'll want the latest one. All of them are here --> ftp://download.nvidia.com/XFree86/vdpau/
* Open a terminal and cd to the directory where your put them.
* Unpack (adapt for version number):
Code:
tar jxfv mplayer-vdpau-3219724.tar.bz2
* Go to the directory that was created:
Code:
cd mplayer-vdpau-3219724
* Make sure some dependencies are installed:
Code:
sudo apt-get build-dep mplayer
Code:
sudo apt-get install subversion
* For a faster build on a multi-core machine, edit the script and add -j3 (or higher) to the make command.
* Run the script (this will download mplayer sources, patch, and build):
Code:
./checkout-patch-build.sh
* Copy the codecs.conf file to your mplayer directory:
Code:
cp etc/codecs.conf ~/.mplayer/
-----

TEST VDPAU WITH MPLAYER

* In a terminal, cd to the new mplayer directory:
Code:
cd mplayer-vdpau
* I found a good blog post for this --> http://blog.mymediasystem.net/avchd/...cceleration/3/

-----

BUILD MYTHTV FROM SVN

Follow the instructions from the mythtv wiki --> http://www.mythtv.org/wiki/index.php...Source_Install. Don't forget to add "--enable-vdpau --enable-opengl-vsync" to "./configure" in the mythtv directory. See also the mythtv vdpau wiki page --> http://www.mythtv.org/wiki/VDPAU

-----

HD channels use ~10-12% cpu.

Last edited by mythmaster; 04-04-09 at 11:09 PM.. Reason: updates

No comments:

Post a Comment