Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion youtube-quality.conf
Original file line number Diff line number Diff line change
Expand Up @@ -38,4 +38,7 @@ menu_timeout=10
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"} ]
quality_strings=[ {"4320p" : "bestvideo[height<=?4320]+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"} ]

# default settings for ytdl. mpv.conf shouldn't contain ytdl-format settings as it conflicts with this script
ytdl_format=bestvideo+bestaudio/best
2 changes: 2 additions & 0 deletions youtube-quality.lua
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ local opts = {
up_binding = "UP",
down_binding = "DOWN",
select_binding = "ENTER",
ytdl_format = "bestvideo+bestaudio/best",

--formatting / cursors
selected_and_active = "▶ - ",
Expand Down Expand Up @@ -67,6 +68,7 @@ opts.quality_strings = utils.parse_json(opts.quality_strings)

local destroyer = nil

mp.set_property("ytdl-format",opts.ytdl_format)

function show_menu()
local selected = 1
Expand Down