diff options
Diffstat (limited to 'Emacs/.config/emacs')
-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 |