使用ffmpeg将视频转为x264编码的mp4文件
linux-dash
A beautiful web dashboard for Linux
项目地址:https://gitcode.com/gh_mirrors/li/linux-dash

·
昨天刚遇到的问题,网页播放器播放linux服务器上的mp4文件时只有进度条在动,画面全黑,首先想到的就是网页播放器的解码器是否不支持该mp4文件的编码。尝试了下,确实是这个问题,并且转码后文件大小从400M减小到100M,感觉这里是一个系统可优化点。
使用的ffmpeg版本为ffmpeg-3.3.3-win64-static。
linux上ffmpeg的安装方法参考下文中有包括,下文也包含把视频转成可边加载边播放模式:
http://blog.csdn.net/yeyinglingfeng/article/details/77774449
命令:
//test文件是其他视频格式也行
FFMPEG -i uploadfile/video/test.wmv -c:v libx264 -strict -2 uploadfile/mp4/real.mp4
转码成功时的大致样子




A beautiful web dashboard for Linux
最近提交(Master分支:19 天前 )
186a802e
added ecosystem file for PM2 5 年前
5def40a3
Add host customization support for the NodeJS version 5 年前
更多推荐
所有评论(0)