mplayer config

categories: config

There are dozens of vim configs but not many for mplayer but the defaults dont work that well on some media so here is how I like my mplayer:

 1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
stop-xscreensaver=1
vo=xv
ontop=yes
lavdopts=fast=1:threads=2:skiploopfilter=all
autosync=30
framedrop=yes
cache=102400
cache-min=20
cache-seek-min=20
softvol=1
softvol-max=1000
idx=1
ass=yes
embeddedfonts=yes
vfm=libmpeg2 # to selecgt mpeg12 over ffmpeg2
#ao=alsa:device=hw=0.3
#af=pan=2:1:0:0:1:1:0:0:1:0.5:0.5:1:1

Line 1 to 3 are self explanatory. Lines 4 to 6 add some options that slightly improve playback performance. Line 7 to 9 add some ridiculously high caches for playback performance as well.

The softvol entries of lines 10, 11 are sometimes necessary when audio is very silent and you have to make it louder than 100%.

Line 12 rebuilds the index for broken files automatically to be able to seek in files that are either broken or not yet fully downloaded.

Lines 13,14 add support for styled subtitles which are more and more used to subtitle anime and those subtitles are incredible.

Line 15 will probably be removed once an ffmpeg2 bug in decoding mpeg1/2 content is fixed. On some content it creates horrible artifacts and it took me some time to find out that the decoder is broken and i have to force usage of the mpeg12 decoder.

The last two lines are commented out as i only use them seldomly cases and they would otherwise hinder playback. They select my hdmi audio device for output (in cases where my laptop is connected to a hdmi device) and make 5.1 sound play back correctly, mixing it down to stereo.

View Comments
blog comments powered by Disqus