内联<视频>带缓冲区的大文件 [英] Inline <video> large file with buffer

查看:100
本文介绍了内联<视频>带缓冲区的大文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图使用HTML5的视频标签构建网站,以便我可以分享我制作的一些电影。它们的尺寸非常大(> 500 MB),当我从网络外观看它们时,它似乎试图在显示它之前下载整个内容。我想知道如何让它可以在同一时间下载和观看。

我使用php和javascript来构建网站,但如果有其他语言的库或技术,我很乐意听到他们的消息。 解决方案

网上的视频文件有时需要以特殊的方式进行编码,才能在下载时播放。为了使基于Flash的视频正常工作,必须将名为moov的数据从流结尾移至开头。一个名为mp4 FastStart的程序可以为你做到这一点。

像HandBrake这样的程序有一个web选项,在编码时也是这样。数据基本上包含视频的长度等。通常这是在文件的末尾。然而,当网络出现时,这意味着要在播放前下载整个播放器。



你能告诉我们视频的格式吗?


I'm trying to build a site using HTML5's video tag so that I can share some movies I have made. Their sizes are pretty big (>500 MB), and when I watch them from outside my network, it seems like it's trying to download the whole thing before showing it. I'm wondering how I can make it so that they can be downloaded and watched at the same time.

I'm using php and javascript to build the site, although if there are libraries or techniques available in other languages, I'm more than happy to hear about them.

解决方案

Video files on the web sometimes need to be encoded in a special way in order for them to be played while downloading. In order for flash based videos to work, data called "moov" must be moved from the end of the stream to the start. A program called mp4 FastStart can do this for you.

Programs like HandBrake have a "web" option that also does this when encoding. The data basically contains the length of the video, etc. Typically this was at the end of the file. However when the web came along that meant downloading the entire thing before being able to play.

Can you tell us what format the video is?

这篇关于内联<视频>带缓冲区的大文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆