summary refs log tree commit diff
path: root/dot_config/mpv/script-opts
diff options
context:
space:
mode:
authorAlen <alen@dotfiles.xyz>2025-01-19 19:06:44 +0400
committerAlen <alen@dotfiles.xyz>2025-01-19 19:06:44 +0400
commit94ad728f49ceb99ab9c75a8ac5edbfcd708066dd (patch)
tree038a430cbe4bf7223d661fb60a3408f0b56828f1 /dot_config/mpv/script-opts
parentf73915ba4fd151b6fc2e4a74b8c54cc7b6e23042 (diff)
Add mpv config
Diffstat (limited to 'dot_config/mpv/script-opts')
-rw-r--r--dot_config/mpv/script-opts/playlistmanager.conf120
-rw-r--r--dot_config/mpv/script-opts/quality-menu.conf102
-rw-r--r--dot_config/mpv/script-opts/stats.conf18
3 files changed, 240 insertions, 0 deletions
diff --git a/dot_config/mpv/script-opts/playlistmanager.conf b/dot_config/mpv/script-opts/playlistmanager.conf
new file mode 100644
index 0000000..04e890e
--- /dev/null
+++ b/dot_config/mpv/script-opts/playlistmanager.conf
@@ -0,0 +1,120 @@
+#### ------- Mpv-Playlistmanager configuration ------- ####
+
+#### ------- FUNCTIONAL ------- ####
+
+#navigation keybindings force override only while playlist is visible
+#if "no" then you can display the playlist by any of the navigation keys
+dynamic_binds=yes
+
+#dynamic keybind keys, they should not be re-bound in input.conf
+#to bind multiple keys separate them by a space
+key_moveup=UP
+key_movedown=DOWN
+key_selectfile=RIGHT LEFT
+key_unselectfile=
+key_playfile=ENTER
+key_removefile=BS
+key_closeplaylist=ESC
+
+#json format for replacing, check .lua for explanation
+#example json=[{"ext":{"all":true},"rules":[{"_":" "}]},{"ext":{"mp4":true,"mkv":true},"rules":[{"^(.+)%..+$":"%1"},{"%s*[%[%(].-[%]%)]%s*":""},{"(%w)%.(%w)":"%1 %2"}]},{"protocol":{"http":true,"https":true},"rules":[{"^%a+://w*%.?":""}]}]
+#empty for no replace
+filename_replace=
+
+#filetypes to search from directory
+loadfiles_filetypes=["jpg","jpeg","png","tif","tiff","gif","webp","svg","bmp","mp3","wav","ogm","flac","m4a","wma","ogg","opus","mkv","avi","mp4","ogv","webm","rmvb","flv","wmv","mpeg","mpg","m4v","3gp"]
+
+#loadfiles at startup if there is 0 or 1 items in playlist, if 0 uses worḱing dir for files
+#requires --idle=yes or --idle=once if 0 files in playlist
+loadfiles_on_start=no
+
+#sort playlist on mpv start
+sortplaylist_on_start=no
+
+#sort playlist when any files are added to playlist after initial load
+sortplaylist_on_file_add=no
+
+#yes: use alphanumerical sort comparison(nonpadded numbers in order), no: use normal lua string comparison
+alphanumsort=yes
+
+#linux | windows | auto
+system=auto
+
+#Use ~ for home directory. Leave as empty to use mpv/playlists
+playlist_savepath=
+
+#save playlist automatically after current file was unloaded
+save_playlist_on_file_end=no
+
+#2 shows playlist, 1 shows current file(filename strip applied), 0 shows nothing
+show_playlist_on_fileload=0
+
+#sync cursor when file is loaded from outside reasons(file-ending, playlist-next shortcut etc.)
+sync_cursor_on_load=yes
+
+#playlist open key will toggle visibility instead of refresh
+open_toggles=yes
+
+#allow the playlist cursor to loop from end to start and vice versa
+loop_cursor=yes
+
+#### ------- VISUAL ------- ####
+
+#prefer to display titles for following files: "all", "url", "none". Sorting still uses filename
+prefer_titles=url
+
+#call youtube-dl to resolve the titles of urls in the playlist
+resolve_titles=no
+
+#playlist timeout on inactivity, with high value on this open_toggles is good to be yes
+playlist_display_timeout=10
+
+#amount of entries to show before slicing. Optimal value depends on font/video size etc.
+showamount=20
+
+#font size scales by window, if no then needs larger font and padding sizes
+scale_playlist_by_window=yes
+#playlist ass style overrides
+#example {\fnUbuntu\fs10\b0\bord1} equals: font=Ubuntu, size=10, bold=no, border=1
+#read http://docs.aegisub.org/3.2/ASS_Tags/ for reference of tags
+#no values defaults to OSD settings in mpv.conf
+style_ass_tags={\fnInter Tight Medium\fs8\bord0.8}
+#paddings for top left corner
+text_padding_x=10
+text_padding_y=30
+
+#set title of window with stripped name
+set_title_stripped=no
+title_prefix=
+title_suffix= - mpv
+
+#slice long filenames, and how many chars to show
+slice_longfilenames=no
+slice_longfilenames_amount=70
+
+#Playing header. One newline will be added after the string.
+#%mediatitle or %filename = title or name of playing file
+#%pos = position of playing file
+#%cursor = position of navigation
+#%plen = playlist lenght
+#%N = newline
+playlist_header=[%cursor/%plen]
+
+#Playlist file templates
+#%pos = position of file with leading zeros
+#%name = title or name of file
+#%N = newline
+#you can also use the ass tags mentioned above. For example:
+#  selected_file={\c&HFF00FF&}➔ %name   | to add a color for selected file. However, if you
+#  use ass tags you need to reset them for every line (see https://github.com/jonniek/mpv-playlistmanager/issues/20)
+
+normal_file=○ %name
+hovered_file=● %name
+selected_file=➔ %name
+playing_file=▷ %name
+playing_hovered_file=▶ %name
+playing_selected_file=➤ %name
+
+#what to show when playlist is truncated
+playlist_sliced_prefix=...
+playlist_sliced_suffix=...
diff --git a/dot_config/mpv/script-opts/quality-menu.conf b/dot_config/mpv/script-opts/quality-menu.conf
new file mode 100644
index 0000000..a5654f8
--- /dev/null
+++ b/dot_config/mpv/script-opts/quality-menu.conf
@@ -0,0 +1,102 @@
+# KEY BINDINGS
+
+# move the menu cursor up
+up_binding=UP WHEEL_UP
+# move the menu cursor down
+down_binding=DOWN WHEEL_DOWN
+# select menu entry
+select_binding=ENTER MBTN_LEFT
+# close menu
+close_menu_binding=ESC MBTN_RIGHT F Alt+f
+
+# youtube-dl version(could be youtube-dl or yt-dlp, or something else)
+ytdl_ver=yt-dlp
+
+# formatting / cursors
+selected_and_active=▶  - 
+selected_and_inactive=●  - 
+unselected_and_active=▷ - 
+unselected_and_inactive=○ - 
+
+# font size scales by window, if false requires larger font and padding sizes
+scale_playlist_by_window=yes
+
+# playlist ass style overrides inside curly brackets, \keyvalue is one field, extra \ for escape in lua
+# example {\\fnUbuntu\\fs10\\b0\\bord1} equals: font=Ubuntu, size=10, bold=no, border=1
+# read https://aegi.vmoe.info/docs/3.0/ASS_Tags/ for reference of tags
+# undeclared tags will use default osd settings
+# these styles will be used for the whole playlist. More specific styling will need to be hacked in
+#
+# (a monospaced font is recommended but not required)
+style_ass_tags={\\fnmonospace\\fs25\\bord1}
+
+# Shift drawing coordinates. Required for mpv.net compatiblity
+shift_x=0
+shift_y=0
+
+# paddings for top left corner
+text_padding_x=5
+text_padding_y=10
+
+# Screen dim when menu is open
+curtain_opacity=0.7
+
+# how many seconds until the quality menu times out
+# setting this to 0 deactivates the timeout
+menu_timeout=6
+
+# use youtube-dl to fetch a list of available formats (overrides quality_strings)
+fetch_formats=yes
+
+# list of ytdl-format strings to choose from
+quality_strings=[ {"4320p" : "bestvideo[height<=?4320p]+bestaudio/best"}, {"2160p" : "bestvideo[height<=?2160]+bestaudio/best"}, {"1440p" : "bestvideo[height<=?1440]+bestaudio/best"}, {"1080p" : "bestvideo[height<=?1080]+bestaudio/best"}, {"720p" : "bestvideo[height<=?720]+bestaudio/best"}, {"480p" : "bestvideo[height<=?480]+bestaudio/best"}, {"360p" : "bestvideo[height<=?360]+bestaudio/best"}, {"240p" : "bestvideo[height<=?240]+bestaudio/best"}, {"144p" : "bestvideo[height<=?144]+bestaudio/best"} ]
+
+# reset youtube-dl format to the original format string when changing files (e.g. going to the next playlist entry)
+# if file was opened previously, reset to previously selected format
+reset_format=yes
+
+# automatically fetch available formats when opening an url
+fetch_on_start=yes
+
+# show the video format menu after opening an url
+start_with_menu=no
+
+# include unknown formats in the list
+# Unfortunately choosing which formats are video or audio is not always perfect.
+# Set to true to make sure you don't miss any formats, but then the list
+# might also include formats that aren't actually video or audio.
+# Formats that are known to not be video or audio are still filtered out.
+include_unknown=no
+
+# hide columns that are identical for all formats
+hide_identical_columns=yes
+
+# which columns are shown in which order
+# comma separated list, prefix column with "-" to align left
+#
+# columns that might be useful are:
+# resolution, width, height, fps, dynamic_range, tbr, vbr, abr, asr,
+# filesize, filesize_approx, vcodec, acodec, ext, video_ext, audio_ext,
+# language, format, format_note, quality
+#
+# columns that are derived from the above, but with special treatment:
+# size, frame_rate, bitrate_total, bitrate_video, bitrate_audio,
+# codec_video, codec_audio, audio_sample_rate
+#
+# If those still aren't enough or you're just curious, run:
+# yt-dlp -j <url>
+# This outputs unformatted JSON.
+# Format it and look under "formats" to see what's available.
+#
+# Not all videos have all columns available.
+# Be careful, misspelled columns simply won't be displayed, there is no error.
+columns_video=-resolution,frame_rate,dynamic_range,language,bitrate_total,size,-codec_video,-codec_audio
+columns_audio=audio_sample_rate,bitrate_total,size,language,-codec_audio
+
+# columns used for sorting, see "columns_video" for available columns
+# comma separated list, prefix column with "-" to reverse sorting order
+# Leaving this empty keeps the order from yt-dlp/youtube-dl.
+# Be careful, misspelled columns won't result in an error,
+# but they might influence the result.
+sort_video=height,fps,tbr,size,format_id
+sort_audio=asr,tbr,size,format_id
diff --git a/dot_config/mpv/script-opts/stats.conf b/dot_config/mpv/script-opts/stats.conf
new file mode 100644
index 0000000..d1c14bc
--- /dev/null
+++ b/dot_config/mpv/script-opts/stats.conf
@@ -0,0 +1,18 @@
+#  MPV - stats.conf
+#  deus0ww - 2020-01-21
+
+duration=10
+persistent_overlay=yes
+filter_params_max_length=0
+
+plot_perfdata=no
+plot_vsync_ratio=no
+plot_vsync_jitter=no
+
+font=Inter Tight Medium
+font_mono=JetBrains Mono
+font_size=5.5
+font_color=fafafa
+border_size=0.6
+border_color=000000
+alpha=11