vdpau mplayer / ffmpeg

HI!

I tried to install svn mplayer with vdpau support, but it doesn’t work. I used the following guide:

HOTWO: compile mplayer with VDPAU under Ubuntu (x86 or x86_64) - nV News Forums

Has somebody successfully installed mplayer with vdpau under opensuse 11.1??

thx

I’m quite interested in this, but I do not have this capability yet in any of my PCs. I’m struggling a bit to get an 8400GS PCI card shipped to the country where I live, so I can try this out.

I think there are users on this forum who do have this working. You could provide them some more information to go on, so that they will be able to help you. For example, I have read one needs to use the proprietary nVidia driver for this to work. Have you done so ? What nVidia driver version?

Have you installed nvidia-vdpau-devel ?

I’m speculating after having done that, you can run
run “./vdpinfo”

and get something like:

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-----

Do you try that? What did you get ?

Also, what mplayer version are you using? Did you custom compile it?

What command line are you using in mplayer to access vdpau ?

I think you need to provide such details if you wish anyone to help. Since I do not have this capability on my PCs, its possible you also need to provide other details.

I have read that many users are getting tearing issues with vdpau, and one forum suggested that most of the tearing issues are caused by compositing and therefore purportedly disabling it helps clear the issue. So, one purported solution for “tearing” is to put this in one’s xorg.conf:


Section "Extensions"
    Option         "Composite" "Disable"
EndSection

Reference: Official Nvidia VDPAU thread - Page 4 - AVS Forum](http://www.avsforum.com/avs-vb/showthread.php?p=15750031#post15750031)

Qualification: Note I have not tried any of this myself.

and in the interest in keeping some of this information in the same spot, here is a list of some mplayer commands to use various vdpau options in mplayer:
VDPAU - The NVIDIA 180.06 beta driver for Linux - or how to play back AVCHD with GPU acceleration | Acmelabs’ Blog

Also, if one has major vdpau problems, purportedly and currently (from what I have read) the nvidia site is the best place to go raise the issues, and possibly get solutions:
NVIDIA Linux - nV News Forums

Ok!

Thx for the replies!

I have the latest nvidia driver (180.29). I have installed nvidia-vdpau-devel.
I use custom compiled svn mplayer, with these guides (methodes)

HOTWO: compile mplayer with VDPAU under Ubuntu (x86 or x86_64) - nV News Forums

Compile mplayer with VDPAU support on Ubuntu | My Thoughts

no one works.

I tried to play files with command line mplayer. nothing woks, mplayer don’t find vdpau output.

A nice opensuse 11.1 how-to are welcome.

:slight_smile:

From the nVidia forum page, I note:
Current NVIDIA Linux graphics driver releases - nV News Forums
Current releases

  • Current official release: 180.29 (x86 / x86_64)
  • Current prerelease: 180.41
  • Current beta release: 185.13
    Still, the 180.29 driver is supposed to have vdpau support, although from what I have read, the 180.41 has many bug fixes/improvements for vdpau over the more stable 180.29.

I never custom compile mplayer (at least not yet, … I may eventually be forced to if I ever succeed in acquiring a vdpau compatible graphic card). :slight_smile:

One of our users who custom compile mplayer (and we have a few ) will need to chime in. Perhaps you could post what options you used to compile mplayer.

packman are very good at providing recent ffmpeg releases PackMan :: Package details for ffmpeg (and not so good at mplayer). Did you try the most recent Packman packaged ffmpeg/libffmpeg0 ?

You can play the video with:
ffplay somevideo.avi

Here is a basic concepts guide for openSUSE: Concepts - openSUSE

and our New User installation guide: NEWBIES - Suse-11.1 Pre-installation – PLEASE READ - openSUSE Forums

but given you are into custom compilation of mplayer, I suspect you are WELL beyond those guides.

So do I understand right that there is no vdpau-ready package of xine or MPlayer in the buildservice or something? Why don’t the packman-packages support it?I don’t want to compile such a big application by myself.

vdpau is still viewed as being experimental by many application developers, and hence it is not considered stable enough to be included in the baseline packman packaged versions of mplayer nor xine.

I don’t think one has too long to wait (maybe 3 to 6 months), but its still fairly cutting edge for Linux. Practically every new nVidia driver has bug fixes or enhancements for vdpau. Than can present a moving target update rate that is too much work for the volunteer packagers to match.

However note ffmpeg is being updated regularly, by Packman packagers, with vdpau updates.

I saw the often released nvidia-driver-releases, but do they really change the vdpau-api in every release? Then I do understand the problem. I thought that the api is stable and the driver just contain bugfixes…

However note ffmpeg is being updated regularly, by Packman packagers, with vdpau updates.

I already saw that ffmpeg is compiled with “–enable-vdpau” but found no way to get ffplay to use vdpau. Nevertheless I can’t use ffplay with my vdr… :frowning:

You can keep track of what is supported by xine, next time there is a Packman update, by typing:

xine --verbose=2 --list-plugins

Further to that, I think one needs to wait for 1.2 of libxine1 (although I could be wrong on this). I note that based in part on this blog:
VDR-Xine Plugin now with VDPAU support (HOWTO) | Acmelabs’ Blog

I don’t have a vdpau capable card yet … I’m still trying to get the d**n thing shipped here (struggling with shipping charges from out of country) …

I think “ffmpeg -formats” will give a lot of info on what is supported in the version of ffmpeg you have installed.

For example, if I type
ffmpeg -formats | grep vdpau
I get:

oldcpu@athlon:~> ffmpeg -formats | grep vdpau
FFmpeg version 0.5, Copyright (c) 2000-2009 Fabrice Bellard, et al.
  configuration: --shlibdir=/usr/lib --prefix=/usr --mandir=/usr/share/man --libdir=/usr/lib --enable-shared --enable-libmp3lame --enable-libvorbis --enable-libtheora --enable-libspeex --enable-libfaad --enable-libfaac --enable-libxvid --enable-swscale --enable-postproc --enable-gpl --enable-vhook --enable-x11grab --enable-libschroedinger --enable-libdirac --enable-libgsm --enable-libx264 --enable-libamr-nb --enable-libamr-wb --enable-libdc1394 --enable-nonfree --enable-pthreads --enable-vdpau
  libavutil     49.15. 0 / 49.15. 0
  libavcodec    52.20. 0 / 52.20. 0
  libavformat   52.31. 0 / 52.31. 0
  libavdevice   52. 1. 0 / 52. 1. 0
  libswscale     0. 7. 1 /  0. 7. 1
  libpostproc   51. 2. 0 / 51. 2. 0
  built on Mar 10 2009 22:17:30, gcc: 4.3.2 [gcc-4_3-branch revision 141291]
 D V D  h264_vdpau      H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10 (VDPAU acceleration)
 D V DT mpeg1video_vdpau MPEG-1 video (VDPAU acceleration)
 D V DT mpegvideo_vdpau MPEG-1/2 video (VDPAU acceleration)
 D V D  vc1_vdpau       SMPTE VC-1 VDPAU
 D V D  wmv3_vdpau      Windows Media Video 9 VDPAU

of course that does me no good because:

  • I don’t have a Pure Video (vdpau) capable graphic card, and
    *]I don’t have the proprietary nVidia graphic driver installed (yet)
    If and when my vdpau capable card arrives, I’ll start playing with this.

Did you look at the “man ffplay” ?

There is a "-f " (force format) function you could play with.

Thanks for the lots of replys :slight_smile:

ffmpeg -formats | grep vdpau is giving me the same output as yours, but if I try

ffplay -f h264_vdpau big_buck_bunny_1080p_h264.mov

I get

Unknown input format: h264_vdpau

Are you sure -f is the right option? It seems to be to force an input-format of the file and not the output-format.

I don’t have a vdpau capable card , and until I do, I do not plan on installing the proprietary nVidia driver. So there is not much I can do to investigate this, … only offer things to look at.

I believe the -f is not to specifiy “h264_vdpau” but rather specify something like “mp4”. I’ve always believed that the svn version of ffmpeg (with vdpau enabled at compile time) will automatically offload the video decode to the gpu if one has the correct nvidia driver, and has the appropriate graphic card.

Did you download vdpinfo, build it and run it to see if it will tell you anything about your vdpau setup? Index of /~wladimir/vdpinfo

I think one just untars it, types ‘make’ followed by ./vdpinfo

What graphic card are you using?

There is more detail on that here:
Official Nvidia VDPAU thread - AVS Forum](http://www.avsforum.com/avs-vb/showthread.php?t=1097364)

I’m not sure what package provides the X headers that are needed (so that the “make” will work). Possibly xorg-X11-devel and nvidia-vdpau-devel, plus the proprietary nVidia driver.

A good command for getting this information about your nVidia card is:
su -c ‘nvclock -s’
or for more detail:
su -c ‘nvclock -i’

Its possible that ffplay will not use vdpau decoding, even though ffmpeg does have vdpau support. I note this (some what dated, given the rapid pace of development) doom9 thread:

[Linux] Can FFplay use VDPAU? - Doom9’s Forum](http://forum.doom9.org/showthread.php?t=144469&highlight=skottish)

I have no nvclock but it’s a GeForce 9600GT…

and vdpinfo:

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 macbs width height
------------------------------------  
MPEG1             0  8192  2048  2048 
MPEG2_SIMPLE      3  8192  2048  2048 
MPEG2_MAIN        3  8192  2048  2048 
H264_MAIN        41  8192  2048  2048 
H264_HIGH        41  8192  2048  2048 
VC1_SIMPLE        1  8190  2048  2048 
VC1_MAIN          2  8190  2048  2048 
VC1_ADVANCED      4  8190  2048  2048 

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

So I think my driver should be ready…