diff options
author | Aryadev Chavali <aryadev@aryadevchavali.com> | 2024-08-21 16:34:56 +0100 |
---|---|---|
committer | Aryadev Chavali <aryadev@aryadevchavali.com> | 2024-08-21 16:42:17 +0100 |
commit | 057b15a50d2919c0402e42665e7d421b0f672d47 (patch) | |
tree | 38d2c662cca550762f0d18d8db9c7633098f87d0 /Emacs/.config | |
parent | ecc47d5dfb5f82dec8b1158e17d383bcc42e635b (diff) | |
download | dotfiles-057b15a50d2919c0402e42665e7d421b0f672d47.tar.gz dotfiles-057b15a50d2919c0402e42665e7d421b0f672d47.tar.bz2 dotfiles-057b15a50d2919c0402e42665e7d421b0f672d47.zip |
(Emacs/elisp/mpv)-ytdl specific config
Diffstat (limited to 'Emacs/.config')
-rw-r--r-- | Emacs/.config/emacs/elisp/mpv.el | 14 |
1 files changed, 1 insertions, 13 deletions
diff --git a/Emacs/.config/emacs/elisp/mpv.el b/Emacs/.config/emacs/elisp/mpv.el index 4d0655e..c4b87db 100644 --- a/Emacs/.config/emacs/elisp/mpv.el +++ b/Emacs/.config/emacs/elisp/mpv.el @@ -27,15 +27,9 @@ (autoload #'ansi-color-for-comint-mode-on "ansi-color") (autoload #'comint-output-filter "comint") -(defvar mpv-ytdl-args "--ytdl-format=\"bestvideo[height<=1080][fps<=60]+bestaudio/best[height<=1080]\"" - "Arguments for ytdl in mpv format.") - (defvar mpv-args "-v --profile=fast --hwdec=auto-copy" "General arguments for mpv binary.") -(defun mpv--make-args () - (concat mpv-args " " mpv-ytdl-args)) - (defun mpv-start-process (url) (message "[mpv]: Starting mpv on `%s'" url) (with-current-buffer (get-buffer-create "*mpv*") @@ -43,11 +37,9 @@ (comint-mode)) (set-process-filter (start-process-shell-command "mpv" "*mpv*" - (concat "mpv " (mpv--make-args) " \"" url "\"")) + (concat "mpv " mpv-args " \"" url "\"")) #'comint-output-filter)) -(defvar mpv--history nil) - (defun mpv-open-video (&optional arg) (interactive) (let ((url (if (stringp arg) @@ -56,9 +48,5 @@ (mpv-start-process url) (switch-to-buffer "*mpv*"))) - (let ((url (completing-read "Enter URL: " nil nil t (ffap-guesser) mpv--history))) - (mpv-start-process url) - (switch-to-buffer "*mpv*"))) - (provide 'mpv) ;;; mpv.el ends here |