简体   繁体   中英

HTML5 Video — limiting buffer for an MP4

Is it possible to use an HTML5 Video tag to load an MP4, but control how much of the file is downloaded/buffered from the server (assume it supports byte ranges).

Essentially, I'd like to be able to say "only download 60 seconds ahead" so I can avoid the browser downloading an entire 2 GB file when the user is going to end up bouncing anyway.

Answer: browsers will automatically buffer only what they need, rather than download the whole file. It is not necessary to try and control the buffering from a "custom" HTML5 player POV.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM