移动录音的方向问题 [英] Orientation issue with mobile recordings

查看:122
本文介绍了移动录音的方向问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当我使用FFMPEG将iPhone 4和.3gp文件从Android转换成.mov文件。
我需要旋转视频90 degress,但是iPhone 4需要180 degress ...

When I convert .mov files from iPhone 4 and .3gp from Android with FFMPEG. I need to rotate the video 90 degress, but iPhone 4s needs 180 degress...

有没有办法解决这个问题?

Is there any way to fix this?

推荐答案

我不记得Android如何处理这个问题,但iPhones在mov文件元数据中记录方向信息。根据录像时相机的保持情况,视频可能需要0,90,180或甚至270次旋转才能在转换后立即进行播放。 到目前为止,我不知道ffmpeg是否添加了解析元数据,所以您必须手动使用 ffprobe -show_streams 或类似的东西,然后适当地设置旋转。

I don't recall how Android handles this, but iPhones record orientation information in the mov file metadata. Depending on how the camera is held while recording, videos could need 0, 90, 180, or even 270 rotation to play upright after conversion. As yet, I don't know of any additions to ffmpeg to parse this metadata, so you have to do it manually using ffprobe -show_streams or something similar, and then set the rotation appropriately.

更新:as ffmpeg现在检测到视频已旋转,但尚未提供自动旋转修复。相反,您仍然必须解析旋转信息,并使用转置 vflip hflip 视频过滤器以正确旋转视频。

Update: as kibitzer points out ffmpeg does now detect that the video is rotated, but does not yet provide an automatic rotation fix. Instead, you'll still have to parse out the rotation information and use a combination of the transpose, vflip, and hflip video filters to correctly rotate the video.

这篇关于移动录音的方向问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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