Mpv

media-video/mpv


Current Maintainer(s):Oleg Vinichenko
Source Repository:No results
http://mpv.io/

Summary: Video player based on MPlayer/mplayer2.

Use Flags

archive
Enable support for various archive formats via app-arch/libarchive
bluray
Enable playback of Blu-ray filesystems
bs2b
Enable Bauer stereophonic-to-binaural headphone filter
cli
Build mpv CLI player
cdio
Enable CDDA support via dev-libs/libcdio-paranoia
doc-pdf
Build documentation in pdf format
drm
Enable Kernel Mode Setting / Direct Rendering Manager based video output
egl
Enable support for various EGL-based video outputs
enca
Enable subtitles charset discovery via app-i18n/enca
gbm
Enable Graphics Buffer Manager based EGL video output
jpeg
Enable support for saving screenshots in JPEG format
libass
Enable OSD (On Screen Display) and subtitles support via media-libs/libass
libguess
Enable subtitles charset discovery via app-i18n/libguess
libmpv
Build mpv shared library
lua
Enable Lua scripting, OSC (On Screen Controller) GUI and net-misc/youtube-dl hook-script
luajit
Use dev-lang/luajit instead of dev-lang/lua
pvr
Enable Video4Linux2 MPEG PVR
raspberry-pi
Enable support for the Raspberry Pi
rubberband
Enable high quality pitch correction via media-libs/rubberband
sdl
Enable media-libs/libsdl2 based video and audio outputs (Note: these outputs exist for compatibility reasons only, avoid if possible)
tools
Install extra tools: mpv_identify.sh, mpv_idet.sh, and umpv
uchardet
Enable subtitles charset discovery via dev-libs/uchardet
vf-dlopen
Install additional video filters to be used with -vf dlopen

News

Oleg

GCC Update

GCC Update
2016-11-25 by Oleg
Oleg

Portage Git Sync Fix

Portage Git Sync fix
2016-11-14 by Oleg
Oleg

Python-3.3-Removal

Python-3.3 Removal from Portage Tree
2016-10-28 by Oleg
More...

Mpv

Tip

We welcome improvements to this page. To edit this page, Create a Funtoo account. Then log in and then click here to edit this page. See our editing guidelines to becoming a wiki-editing pro.

mpv is a simple and lightweight media player for video and audio. As a fork of mplayer2, it shares some features while introducing others. To learn more about the differences take a look at their docs.

Due to it's high flexibility and configurability, mpv is great for media center usage, lightweight systems or just users who know what they want in a media player. For a more out-of-the-box solution, several alternatives like media-video/vlc (package not on wiki - please add) or media-video/totem (package not on wiki - please add) are recommended.

Installation

# emerge media-video/mpv

Usage

mpv does not ship with a graphical user interface (besides the video display). The easiest way to play a video is:

# mpv /path/to/video/file

Since this is not very comfortable, you can of course set mpv as the default application for video playback. Depending on your environment you can use either the configuration tools provided by your desktop environment/file manager; for more info, see [1].

Controls

Because there are no gui elements, keyboard shortcuts are used to control mpv. The following table provides the most important one; check the manpage (man mpv) for more.

CommandShortcut
Play/PauseSpace or p
Increase/Decrease volume/ and * or 9 and 0
Quitq
Cycle through the available audio tracks#
Show OSDo

You may change all of these bindings (and more) to your custom using the config file.

Configuration

Even though mpv works fine without a config file, the configuration options allow to adjust a lot of settings. A short example is provided below:

~/.config/mpv/mpv.conf
# Save the video position on quit
save-position-on-quit

# Use the vdpau driver for hardware decoding (for nvidia cards)
hwdec=vdpau

# Video output driver. A list can be displayed via: mpv -vo=help
vo=opengl

All possible options are listed in the man page:

#  man mpv

Keybindings

You may create a separate file called input.conf for customizing the shortcuts for mpv. The example below binds the key "n" to skip to the next video in the current playlist and the key "p" to skip to the previous video:

~/.config/mpv/input.conf
n playlist_next
p playlist_prev

The man page provides information about all possible bindings.

Twitch/Youtube playback

mpv is capable of playing twitch.tv/youtube streams and videos. To enable this, install net-misc/youtube-dl (package not on wiki - please add) and enable the lua useflag on media-video/mpv.

# emerge -a net-misc/youtube-dl
# echo "media-video/mpv lua" >> /etc/portage/package.use

After everything is set up, use the --ytdl parameter for youtube and twitch playback:

# mpv --ytdl [url]