How do I configure mplayer to always use VDPAU?

I just learned how to use mplayer to take advantage of VDPAU from the command line with the -vc ffh264vdpau switch.

How do I set that config in my .mplayer/config file so I don't have to remember that long flag every time I want to watch a file?


Solution 1:

Why not just put a list of the video outputs and codecs you want to try in your ~/.mplayer/config file? As in:

##################
# video settings #
##################

# Specify default video driver (see -vo help for a list).
vo=vdpau


############
# Profiles #
############

# The options declared as part of profiles override global default settings,
# but only take effect when the profile is active.

[vo.vdpau]
vc=ffmpeg12vdpau,ffwmv3vdpau,ffvc1vdpau,ffh264vdpau,ffodivxvdpau,
# Most video filters do not work with vdpau.
vf-clr=yes

1 the trailing comma in each setting tells mplayer to fall back to standard codecs if necessary