如何在 HTML5
我需要在 HTML5 上播放 M-JPEG 编码的电影。
你知道哪些容器(mp4、avi、webm、ogv等)和浏览器(chrome、safari等)可以播放这个吗?
I need to play an M-JPEG encoded movie on HTML5 .
Do you know which container (mp4, avi, webm, ogv, etc.) and browser (chrome, safari, etc.) can play this?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
Safari 和 IE9 应该使用系统编解码器,因此如果用户有合适的编解码器,它们可以播放 M-JPEG。
在其他浏览器中,您可以尝试使用
然而,浏览器供应商不想支持大量蹩脚的编解码器和奇怪的容器。除了 H.264 和 WebM 之外,不要指望其他任何东西都可以工作(并且您需要两者)。
最好的办法是重新编码视频。即使是 H.264 和 WebM 的快速/低质量编码也会为您提供比 M-JPEG 更好的压缩效果。
Safari and IE9 are supposed to use system codecs, so they could play M-JPEG if user has appropriate codec.
In other browsers you could try embedding it using
<object>
element, which may find some suitable plug-in.However, browser vendors don't want to support ton of crappy codecs and odd containers. Don't expect anything else than H.264 and WebM to work (and you need both).
Your best bet is to re-encode the video. Even fast/low-quality encode of H.264 and WebM is going to give you compression much much better than M-JPEG.