The MPV media player is a great application for playing movies on a Linux machine.
To change the aspect ratio of a file, while it is playing, press Shift-A. This is the default keybinding hardcoded in the binary.
You may watch a Youtube video using MPV and select the vertical resolution of the video using this one-liner.
┌──(john㉿DESKTOP-PF01IEE)-[/mnt/c/Users/Intel i5/Videos] └─$ mpv --ytdl-format="bestvideo[ext=mp4][height<=?360]+bestaudio[ext=m4a]" https://www.youtube.com/watch?v=EBfHw0WD1_c |
This is a very useful MPV Youtube trick.
Download an entire Youtube playlist as MP3 files using this long command example.
┌──(john㉿DESKTOP-PF01IEE)-[/mnt/c/Users/Intel i5/Music/Youtube2] └─$ youtube-dl -x --audio-format "mp3" --embed-thumbnail --yes-playlist --output "%(title)s.%(ext)s" -i PLyPYOzurbMk7hXJEJPlMeRySoPyC-63-0 |
This embeds the Youtube thumbnail as the album art as well. Plus sets the ID3 tags. A very useful example indeed.
The MPV player can be used to rip part of a video to a WebM file for sharing online.
Play movies from your collection randomly.
Play Youtube videos with the MPV media player.
This is the default /etc/input.conf https://raw.githubusercontent.com/mpv-player/mpv/master/etc/input.conf.
DVB-T broadcasts may also be watched with MPV. Place channels.conf file in the ~/.config/mpv/channels.conf file and then it will work.
jason@Yog-Sothoth » ~ » $ mpv dvb://"SBS ONE HD(SBS)" Playing: dvb://SBS ONE HD(SBS) [dvbin] dvb_tune DVB-T Freq: 613500000 (+) Video --vid=1 (h264 1920x1080 25.000fps) (+) Audio --aid=1 (mp2 2ch 48000Hz) File tags: Title: SBS ONE HD(SBS) AO: [pulse] 48000Hz stereo 2ch s16 [ffmpeg/video] h264: co located POCs unavailable [ffmpeg/video] h264: co located POCs unavailable [ffmpeg/video] h264: co located POCs unavailable [ffmpeg/video] h264: mmco: unref short failure [ffmpeg/video] h264: mmco: unref short failure VO: [opengl] 1920x1080 yuv420p AV: 00:00:06 / 00:00:00 A-V: 0.000 Cache: 4s+0KB
That is how easy MPV is to use.
A very useful addon script to convert or crop videos from within MPV.
https://gist.github.com/Zehkul/25ea7ae77b30af959be0.
Play a video with MPV audio-only.
jason@Yog-Sothoth » Videos » $ mpv --vid no stalkersoc.avi Playing: stalkersoc.avi Video --vid=1 (mjpeg 1920x1080 30.000fps) (+) Audio --aid=1 (pcm_s16le 2ch 48000Hz) AO: [pulse] 48000Hz stereo 2ch s16 A: 00:00:21 / 00:01:19 (27%)
These tips should be very useful to a new or experienced mplayer user who is transitioning to mpv as their main media player.