Chrome HTML5视频横向纵向翻转 [英] Chrome HTML5 Video Flipping Portrait Sideways

查看:1951
本文介绍了Chrome HTML5视频横向纵向翻转的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在建立一个网站来显示从iPhone录制的视频。视频以288x352纵向排列。 Safari很好地显示这个视频,但是在Chrome中,视频被翻转为352x288的横向模式。我的头是侧身。 : - (

以下是相关网页:
http://aaron.tiberiuslog.com/B4F4CC56-172E-4D84-9656-BE04E6E475A0



这里是视频本身如果有帮助的话。

http://tiberiuslog.s3.amazonaws.com/output_D7DB78A9-8019-4D09-9B22-EB8738F844BB-2380-000001530B13BE09.mov



我尝试使用vanilla HTML5标记,并且现在添加了 VideoJS ,尽管它对这个问题没有任何影响。



更新:现在我的问题有一半的答案,看来需要编码选项设置,以确保在所有观众(包括VLC和Chrome)上都能正确定位例)。这个问题没有得到答案,所以我创建了一个新的一个。希望我们能为这个问题提供合适的解决方案!



更新2 :我已经找到答案! 我发布的另一个问题让我想到了在iOS上正确编码视频的技术

解决方案

请参阅这篇文章关于videojs支持论坛,这表明它可能是iPhone编码视频的方式,因为它包含QuickTime可以读取的信息,但其他播放器不能。建议您使用 AVFoundation 并旋转它。推测一些其他标准编码库也可以。


I'm building a site to display video recorded from an iPhone. The video comes in portrait orientation, at 288x352. Safari displays this video just fine, but in Chrome, the video is flipped into landscape mode, 352x288. My head is sideways. :-(

Here's the page in question: http://aaron.tiberiuslog.com/B4F4CC56-172E-4D84-9656-BE04E6E475A0

And here's the video itself if that helps.

http://tiberiuslog.s3.amazonaws.com/output_D7DB78A9-8019-4D09-9B22-EB8738F844BB-2380-000001530B13BE09.mov

I've tried using vanilla HTML5 markup, and have now added VideoJS, though it made no difference for this issue.

Update: I have half an answer to my question now. It appears that there needs to be some encoding option set on the device to ensure proper orientation is respected on all viewers,including VLC and Chrome (for example). This question doesn't have the legs to get that answer, so I've created a new one. Hopefully we'll string together the proper solution for this issue!

Update 2: I have discovered the answer! The other question I posted led me to the technique for correctly encoding the video on iOS.

解决方案

See this post on the videojs support forums which suggests that it's probably down to the way the iPhone encodes video since it includes information which QuickTime can read but other players cannot. The advice is that you encode the video on iOS using AVFoundation and rotate it. Presumably some other standard encoding library would work also.

这篇关于Chrome HTML5视频横向纵向翻转的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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