mpv
In the beginning there was MPlayer, then came the fork mplayer2, and now mpv is the most interesting descendant of the seemingly unadorned, but in reality powerful video player with its own codec library based on FFMpeg. The program, as simple as it appears, has one superpower: It can play almost any media file you feed it with.
In addition, mpv puts an end to jerky video playback, at least on reasonably up-to-date chipsets. Whether your graphics is Intel, Nvidia or AMD – mpv supports video acceleration via VDPAU as well as via VA-API and XvBA, so that the decoding of HD videos takes place via the graphics card and not the CPU. Before, Mplayer and mplayer2 only got along with VDPAU (Nvidia) under Ubuntu.
Although mpv comes with a simple GUI, the program is started directly from the command line by default:
mpv /path/to/mediafile
Configuration options
The configuration options offered by mpv are almost endless. Options may be specified either on the command line with double dashes in addition to the filename to play or in configuration files.
Mpv looks for configuration at /etc/mpv/config.php (system-wide) or under ~/.config/mpv/mpv.config for your own user.
For people who don’t want to bother with command line options and configuration files, we recommend using a fully-fledged graphical front end such as SMPlayer, which also uses mpv under the hood.
However, if you just want to play a video, the odds are that you never have to wrestle with configuration since mpv should work just fine out of the box.
Hardware decoding
Hardware decoding is already activated in the version of mpv supplied by Ubuntu. You can switch it on or off with the key combination CTRL+H during video playback. Alternatively, you can use the command line option
--hwdec
or configure it in the configuration file.
On a Dell XPS 15 notebook with dedicated Intel Arc graphics, mpv used the hardware decoding automatically. To confirm, watch the terminal output when playing a video: (“Using hardware decoding (vaapi)”) or press CTRL+I during playback in the video window. As expected, the configuration file contained the line
hwdec=vaapi
Screenshots
Typing “s” during playback of a video creates a screenshot. By default, screenshots are stored in the user’s home directory with a name like “mpv-shot0001.jpg”. Of course, this may be configured. For example, use the options
–screenshot-template=”%F %P” –screenshot-dir=~/Pictures/
to make the screenshot filename use the name of the media file (%F) plus the timestamp (%P) and store it in the user’s Pictures/ folder.
Thanks to the integration of the Mplayer counterpart MEncoder, mpv is not only suitable for playback, but also for encoding and converting videos. The mpv developers provide a detailed list of changes compared to Mplayer including command line options.
Builds of mpv also exist for Windows and OS-X.
Documentation
Extensive documentation can be found in the User manual.
Installation
mpv may be installed directly from Ubuntu’s community repository Universe:
sudo apt-get install mpv
Alternativen
VLC is the other great media player, which is – thanks to ist own libraries – able to play more or less all audio and video files.