[英]HTML5 video: ffmpeg-encoded MP4 not playing in any browser (plays in VLC though)
[英]Video encoded with ffmpeg not playing in Chrome
我一直在尝试在ffmpeg上进行几乎每个选项的排列,以尝试将转码后的视频显示在Chrome上-OSX 39.0.2171.71(64位)-到目前为止没有任何效果。
我当前使用的设置如下所示:
/usr/local/Cellar/ffmpeg/2.4.3/bin/ffmpeg -i source.m4v -vcodec libx264 -pix_fmt yuv420p -profile:v baseline -level 3.0 -preset slower -crf 23 -vf scale=640:360 target.mp4
但我尝试了其他各种答案的各种选择,但都没有成功。
video-js演示视频可以正常工作,因此一定可以实现。 这是编码视频的转储:
*** General Parameters ***
- Name: test-1 (2).mp4
- Container: MP4 - QuickTime
- Size: 3.45 MB
- Duration: 32s 299ms
- Bitrate: 856 Kbps
*** Video Track Parameters ***
- Format: H.264/MPEG-4 AVC
- Bitrate: Max.: --- / Average: 721 Kbps / Min.: ---
- Frame rate (fps): Max.: --- / Average: 30.000 / Min.: ---
- Encoding profile: Baseline@L3.0
- Image size: 640*360
- Pixel Aspect Ratio: Undefined
- Display Aspect Ratio: 16:9
- Interlacing: Progressive
*** First Audio Track Parameters ***
- Format: AAC - MPEG-4 audio
- Bitrate: 128 Kbps
- Resolution: Undefined
- Rate: 44.1 KHz
- Channel(s): 2 (stereo)
- Position: Front: L R
原来,元数据放置在错误的位置。 在ffmpeg参数列表中添加-movflags +faststart
使其开始工作。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.