mpv-player / mpv

🎥 Command line video player
https://mpv.io
Other
28.21k stars 2.89k forks source link

Implement flash-like network caching behavior #871

Closed haarp closed 10 years ago

haarp commented 10 years ago

Hello and thank you for mpv!

I would like to request an optional modification to the caching behavior, to make mpv better suited for cases where it replaces a Flash player on sites like Youtube.

This basically means unconditionally caching everything from the current position until the end of the file/stream has been reached. Only when an uncached position is selected will it skip some parts and start caching again from the selected position. However, under no circumstances should valid cached content ever be discarded. So i can always go back and watch something that has been cached once, until I close the player.

That's how Youtube used to work until they completely broke that behavior a while ago. However, it's possible to replace the flash player with mpv by using mozplugger and ViewTube, so there is a very useful application for this enhancement.

ChrisK2 commented 10 years ago

See the recently added --cache-file option, this pretty much (or well, partially) does what you want.