Skip to content

Allow progress "spinner" or progress bar in pseudo-ui while loading network videos (e.g. youtube) #11630

@ParetoOptimalDev

Description

@ParetoOptimalDev

There is a similar feature request that asks for progress of the youtube-dl download to be shown in the progress bar in #4881.

This feature request is closed because a workaround (or solution depending on perspective of mpv developers) was found using https://github.com/torque/mpv-progressbar because it allegedly reports youtube-dl progress or something like it somewhat speculatively using the bit-rate.

Expected behavior of the wanted feature

First some context:

My main use of mpv is not calling mpv from the command line, but rather:

  • via an emacs plugin that allows calling mpv on my feed reader items
  • via qutebrowser using :spawn mpv $1 when on a youtube page

I first created an issue on that emacs plugin, elfeed-tube, here.

Current behavior:

  1. Run mpv with --force-window
mpv --force-window=immediate https://youtu.be/DYeh7_FdmDgmpv
  1. A window with a black screen and no other visual feedback immediately comes up

  2. 4 seconds later (on my current internet connection), the video starts playing

I would like the behavior to instead be:

  1. Run mpv with --force-window and a new flag such as --stream-progress-spinner
mpv --force-window=immediate https://youtu.be/DYeh7_FdmDgmpv

Alternative behavior of the wanted feature

Replicate what https://github.com/torque/mpv-progressbar does in the mpv core. The justification for this being a core feature rather than a plugin is that the UX of mpv https://youtu.be/DYeh7_FdmDgmpv being invoked by some program where you silently wait 4 seconds is not a good UX.

Using mpv --force-window=immediate is an improvement because at least the video player comes up so you know things are happening.

I also tried a workaround after looking thoroughly through the manual:

mpv --force-window=immediate --osd-level=3 --osd-msg3='waiting for cache: ${seeking} cache %: ${cache-buffering-state}' https://youtu.be/DYeh7_FdmDgmpv

The docs for cache-buffering-state say:

cache-buffering-state
The percentage (0-100) of the cache fill status until the
player will unpause (related to paused-for-cache).

My hope was that cache-buffering-state would immediately print number representing % of cache buffer filled. Sadly what actually happens is:

  • When the window opens the value of cache-buffering-state is unavailable
  • It stays that way until the video loads
  • the video loads and cache-buffering-state value becomes 100 immediately

Log file

Feature request, not a bug that needs a log file.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions