From: root Date: Wed, 17 Aug 2022 11:25:42 +0000 (+0200) Subject: committing changes in /etc made by "/usr/bin/python3 /usr/sbin/aptd" X-Git-Url: https://git.uhu-banane.org/?a=commitdiff_plain;h=fb648f47dc73ff09cb8131893ce994d426c92d14;p=config%2Fbruni%2Fetc-mint-new1.git committing changes in /etc made by "/usr/bin/python3 /usr/sbin/aptd" Packages with configuration changes: +mpv 0.34.1-1ubuntu3 amd64 Package changes: +mpv 0.34.1-1ubuntu3 amd64 --- diff --git a/.etckeeper b/.etckeeper index 5687728..505e26b 100755 --- a/.etckeeper +++ b/.etckeeper @@ -2592,6 +2592,9 @@ maybe chmod 0755 'mplayer' maybe chmod 0644 'mplayer/input.conf' maybe chmod 0644 'mplayer/menu.conf' maybe chmod 0644 'mplayer/mplayer.conf' +maybe chmod 0755 'mpv' +maybe chmod 0644 'mpv/encoding-profiles.conf' +maybe chmod 0644 'mpv/mpv.conf' maybe chmod 0644 'mtools.conf' maybe chmod 0755 'mysql' maybe chmod 0755 'mysql/conf.d' diff --git a/mailcap b/mailcap index e5733ef..2b5a2dd 100644 --- a/mailcap +++ b/mailcap @@ -579,6 +579,126 @@ application/x-mate-theme-package; mate-appearance-properties -i %s; test=test -n application/vnd.flatpak.ref; mintinstall-fp-handler %s; test=test -n "$DISPLAY" application/vnd.flatpak.repo; mintinstall-fp-handler %s; test=test -n "$DISPLAY" text/x-apt-sources-list; pkexec mintsources %s; test=test -n "$DISPLAY" +application/ogg; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +application/x-ogg; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +application/mxf; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +application/sdp; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +application/smil; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +application/x-smil; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +application/streamingmedia; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +application/x-streamingmedia; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +application/vnd.rn-realmedia; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +application/vnd.rn-realmedia-vbr; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/aac; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/x-aac; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/vnd.dolby.heaac.1; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/vnd.dolby.heaac.2; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/aiff; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/x-aiff; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/m4a; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/x-m4a; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +application/x-extension-m4a; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/mp1; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/x-mp1; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/mp2; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/x-mp2; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/mp3; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/x-mp3; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/mpeg; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/mpeg2; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/mpeg3; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/mpegurl; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/x-mpegurl; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/mpg; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/x-mpg; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/rn-mpeg; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/musepack; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/x-musepack; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/ogg; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/scpls; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/x-scpls; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/vnd.rn-realaudio; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/wav; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/x-pn-wav; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/x-pn-windows-pcm; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/x-realaudio; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/x-pn-realaudio; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/x-ms-wma; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/x-pls; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/x-wav; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/mpeg; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/x-mpeg2; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/x-mpeg3; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/mp4v-es; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/x-m4v; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/mp4; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +application/x-extension-mp4; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/divx; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/vnd.divx; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/msvideo; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/x-msvideo; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/ogg; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/quicktime; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/vnd.rn-realvideo; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/x-ms-afs; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/x-ms-asf; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/x-ms-asf; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +application/vnd.ms-asf; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/x-ms-wmv; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/x-ms-wmx; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/x-ms-wvxvideo; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/x-avi; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/avi; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/x-flic; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/fli; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/x-flc; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/flv; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/x-flv; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/x-theora; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/x-theora+ogg; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/x-matroska; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/mkv; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/x-matroska; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +application/x-matroska; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/webm; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/webm; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/vorbis; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/x-vorbis; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/x-vorbis+ogg; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/x-ogm; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/x-ogm+ogg; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +application/x-ogm; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +application/x-ogm-audio; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +application/x-ogm-video; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +application/x-shorten; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/x-shorten; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/x-ape; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/x-wavpack; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/x-tta; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/AMR; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/ac3; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/eac3; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/amr-wb; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/mp2t; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/flac; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/mp4; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +application/x-mpegurl; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/vnd.mpegurl; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +application/vnd.apple.mpegurl; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/x-pn-au; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/3gp; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/3gpp; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/3gpp2; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/3gpp; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/3gpp2; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +video/dv; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/dv; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/opus; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/vnd.dts; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/vnd.dts.hd; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/x-adpcm; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +application/x-cue; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" +audio/m3u; mpv --player-operation-mode=pseudo-gui -- %s; test=test -n "$DISPLAY" x-content/unix-software; nautilus-autorun-software %s; test=test -n "$DISPLAY" x-content/unix-software; nemo-autorun-software %s; test=test -n "$DISPLAY" inode/directory; nemo %s; test=test -n "$DISPLAY" diff --git a/mpv/encoding-profiles.conf b/mpv/encoding-profiles.conf new file mode 100644 index 0000000..77a0d91 --- /dev/null +++ b/mpv/encoding-profiles.conf @@ -0,0 +1,224 @@ +# +# mpv configuration file +# + +######################### +# encoding profile file # +######################### +# +# Note: by default, this file is installed to /etc/mpv/encoding-profiles.conf +# (or a different location, depending on --prefix). mpv will load it by +# default on program start. If ~/.mpv/encoding-profiles.conf exists, this file +# will be loaded instead. +# +# Then, list all profiles by +# mpv --profile=help | grep enc- +# +# The following kinds of encoding profiles exist: +# enc-a-*: initialize an audio codec including good defaults +# enc-v-*: initialize a video codec including good defaults +# enc-f-*: initialize a file format including good defaults, including +# selecting and initializing a good audio and video codec +# enc-to-*: load known good settings for a target device; this typically +# includes selecting an enc-f-* profile, then adjusting some +# settings like frame rate, resolution and codec parameters +# +# AFTER including a profile of these, you can of course still change +# options, or even switch to another codec. +# +# You can view the exact options a profile sets by +# mpv --show-profile=enc-to-hp-slate-7 +# +# Examples: +# mpv --profile=enc-to-dvdpal --o=outfile.mpg infile.mkv +# mpv --profile=enc-f-avi --vf=fps=30 --o=outfile.avi infile.mkv +# mpv --profile=enc-v-mpeg4 --ovcopts-add=qscale=7 --profile=enc-a-mp3 --oacopts-add=b=320k --o=outfile.avi infile.mkv + +################ +# audio codecs # +################ +[enc-a-aac] +profile-desc = "AAC (libfdk-aac or FFmpeg)" +oac = libfdk_aac,aac +oacopts = b=96k + +[enc-a-ac3] +profile-desc = "AC3 (FFmpeg)" +oac = ac3 +oacopts = b=448k + +[enc-a-mp3] +profile-desc = "MP3 (LAME)" +oac = libmp3lame +oacopts = b=128k + +[enc-a-vorbis] +profile-desc = "Vorbis (libvorbis or FFmpeg)" +oac = libvorbis,vorbis +oacopts = qscale=3 + +[enc-a-opus] +profile-desc = "Opus (libopus or FFmpeg)" +oac = libopus,opus +audio-samplerate = 48000 +oacopts = b=96k + +################ +# video codecs # +################ +[enc-v-h263] +profile-desc = "H.263 (FFmpeg)" +ovc = h263 +ovcopts = qscale=4 + +[enc-v-h264] +profile-desc = "H.264 (x264)" +ovc = libx264 +ovcopts = preset=medium,crf=23,threads=0 +# If you want to restrict the output video to something compatible with most +# hardware and basic decoders, add "profile=high,level=41" to ovcopts above and +# uncomment the following line to avoid errors when source video isn't yuv420p: +#vf-add = format=yuv420p + +[enc-v-mpeg2] +profile-desc = "MPEG-2 Video (FFmpeg)" +ovc = mpeg2video + +[enc-v-mpeg4] +profile-desc = "MPEG-4 Part 2 (FFmpeg)" +ovc = mpeg4 +ovcopts = qscale=4 + +[enc-v-vp8] +profile-desc = "VP8 (libvpx)" +ovc = libvpx +ovcopts = speed=0,lag-in-frames=8,slices=2,threads=0,b=2M,crf=10,qmin=0,qmax=36 + +[enc-v-vp9] +profile-desc = "VP9 (libvpx)" +ovc = libvpx-vp9 +ovcopts = speed=6,lag-in-frames=8,slices=2,threads=0,crf=18,qmin=0,qmax=36 + +########### +# formats # +########### +[enc-f-3gp] +profile-desc = "H.263 + AAC (for 3GP)" +of = 3gp +profile = enc-v-h263 +profile = enc-a-aac +ofopts = "" + +[enc-f-avi] +profile-desc = "MPEG-4 + MP3 (for AVI)" +of = avi +profile = enc-v-mpeg4 +profile = enc-a-mp3 +ofopts = "" + +[enc-f-mp4] +profile-desc = "H.264 + AAC (for MP4)" +of = mp4 +profile = enc-v-h264 +profile = enc-a-aac +## equivalent to using qt-faststart tool +## can be used to speed up seeking when streaming +# ofopts = movflags=+faststart + +[enc-f-webm] +profile-desc = "VP9 + Opus (for WebM)" +of = webm +profile = enc-v-vp9 +profile = enc-a-opus +ofopts = "" + +################## +# target devices # +################## +[enc-to-dvdpal] +profile-desc = "DVD-Video PAL, use dvdauthor -v pal -a ac3+en (MUST be used with 4:3 or 16:9 aspect, and 720x576, 704x576, 352x576 or 352x288 resolution)" +profile = enc-v-mpeg2 +profile = enc-a-ac3 +of = dvd +ofopts-append = packetsize=2048 +ofopts-append = muxrate=10080000 +vf-add = fps=25 +audio-samplerate = 48000 +ovcopts = g=15,b=6000000,maxrate=9000000,minrate=0,bufsize=1835008 + +[enc-to-dvdntsc] +profile-desc = "DVD-Video NTSC, use dvdauthor -v ntsc -a ac3+en (MUST be used with 4:3 or 16:9 aspect, and 720x480, 704x480, 352x480 or 352x240 resolution)" +profile = enc-v-mpeg2 +profile = enc-a-ac3 +of = dvd +ofopts-append = packetsize=2048 +ofopts-append = muxrate=10080000 +vf-add = fps="24000/1001" +audio-samplerate = 48000 +ovcopts = g=18,b=6000000,maxrate=9000000,minrate=0,bufsize=1835008 + +[enc-to-nok-n900] +profile-desc = "MP4 for Nokia N900" +profile = enc-f-mp4 +# DW = 800, DH = 480, SAR = 1 +vf-add = lavfi=graph="scale=floor(min(min(800\,dar*480)\,in_w*max(1\,sar))/2+0.5)*2:floor(min(min(800/dar\,480)\,in_h*max(1/sar\,1))/2+0.5)*2,setsar=sar=1" +ovcopts-append = profile=baseline +ovcopts-append = level=30 +ovcopts-append = maxrate=10000k +ovcopts-append = bufsize=10000k +ovcopts-append = rc_init_occupancy=9000k +ovcopts-append = refs=5 + +[enc-to-nok-6300] +profile-desc = "3GP for Nokia 6300" +profile = enc-f-3gp +vf-add = fps=25 +vf-add = lavfi=graph="scale=176:144" +audio-samplerate = 16000 +audio-channels = 1 +oacopts-add = b=32k + +[enc-to-hp-slate-7] +profile-desc = "MP4 for HP Slate 7 (1024x600, crazy aspect)" +profile = enc-f-mp4 +ovcopts-add = profile=high +# DW = 1024, DH = 600, DAR = 97:54 (=> SAR = 2425:2304) +vf-add = lavfi=graph="scale=floor(min(1024*min(1\,dar/(97/54))\,in_w)/2+0.5)*2:floor(min(600*min((97/54)/dar\,1)\,in_h)/2+0.5)*2,setsar=sar=sar/(2425/2304)" + +# Advanced scaling for specific output devices - how it works: +# DW = display width (px) (1024) +# DH = display height (px) (600) +# SAR = display sample aspect ratio, i.e. DAR * DH / DW (2425:2304) +# DAR = display aspect ratio, i.e. SAR * DW / DH (97:54) +# Variant: zoomed out +# vf-add = lavfi=graph="scale=floor(min(DW*min(1\,dar/DAR)\,in_w*max(1\,sar/SAR))/2+0.5)*2:floor(min(DH*min(DAR/dar\,1)\,in_h*max(SAR/sar\,1))/2+0.5)*2,setsar=sar=1" +# Variant: zoomed in +# vf-add = lavfi=graph="scale=floor(min(DW*max(1\,dar/DAR)\,in_w*max(1\,sar/SAR))/2+0.5)*2:floor(min(DH*max(DAR/dar\,1)\,in_h*max(SAR/sar\,1))/2+0.5)*2,setsar=sar=1" +# How it works: +# 1a: DW, DH*dar/DAR - fit to display width +# 1b: DH*DAR/dar, DH - fit to display height +# 1: the min of 1a and 1b these (i.e. fit inside both width and height); for zoomed in view, use the max +# 2a: in_w, in_h*SAR/sar - fit to original width +# 2b: in_w*sar/SAR, in_h - fit to original height +# 2: the max of 2a and 2b (i.e. avoid enlarging both dimensions - let HW scaling handle this) +# output: the min of 1 and 2 (i.e. fulfill both constraints) +# setsar=sar=1 to prevent scaling on the device (skip this if the device actually wants the proper SAR to be specified for not performing needless scaling) +# +# Simplified special case for SAR == 1, DAR == DW/DH: +# Variant: zoomed out +# vf-add = lavfi=graph="scale=floor(min(min(DW\,dar*DH)\,in_w*max(1\,sar))/2+0.5)*2:floor(min(min(DW/dar\,DH)\,in_h*max(1/sar\,1))/2+0.5)*2,setsar=sar=1" +# Variant: zoomed in +# vf-add = lavfi=graph="scale=floor(min(max(DW\,dar*DH)\,in_w*max(1\,sar))/2+0.5)*2:floor(min(max(DW/dar\,DH)\,in_h*max(1/sar\,1))/2+0.5)*2,setsar=sar=1" +# setsar=sar=1 to prevent nasty almost-1 SAR to be passed to the codec due to the rounding which can fail +# +# If the device supports file SAR properly, we can make use of it to avoid +# upscaling. The setsar=sar=sar/SAR at the end serves to fake the SAR for devices that don't know their own display's SAR. +# Variant: zoomed out +# vf-add = lavfi=graph="scale=floor(min(DW*min(1\,dar/DAR)\,in_w)/2+0.5)*2:floor(min(DH*min(DAR/dar\,1)\,in_h)/2+0.5)*2,setsar=sar=sar/SAR" +# Variant: zoomed in +# vf-add = lavfi=graph="scale=floor(min(DW*max(1\,dar/DAR)\,in_w)/2+0.5)*2:floor(min(DH*max(DAR/dar\,1)\,in_h)/2+0.5)*2,setsar=sar=sar/SAR" +# Simplified special case for SAR == 1, DAR == DW/DH: +# Variant: zoomed out +# vf-add = lavfi=graph="scale=floor(min(min(DW\,dar*DH)\,in_w)/2+0.5)*2:floor(min(min(DW/dar\,DH)\,in_h)/2+0.5)*2" +# Variant: zoomed in +# vf-add = lavfi=graph="scale=floor(min(max(DW\,dar*DH)\,in_w)/2+0.5)*2:floor(min(max(DW/dar\,DH)\,in_h)/2+0.5)*2" diff --git a/mpv/mpv.conf b/mpv/mpv.conf new file mode 100644 index 0000000..621600c --- /dev/null +++ b/mpv/mpv.conf @@ -0,0 +1 @@ +hwdec=vaapi