惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

量子位
Google DeepMind News
Google DeepMind News
爱范儿
爱范儿
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
NISL@THU
NISL@THU
T
Threat Research - Cisco Blogs
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
L
Lohrmann on Cybersecurity
V
Visual Studio Blog
Cyberwarzone
Cyberwarzone
D
Docker
The Hacker News
The Hacker News
C
CERT Recently Published Vulnerability Notes
Vercel News
Vercel News
Project Zero
Project Zero
S
Schneier on Security
aimingoo的专栏
aimingoo的专栏
I
Intezer
腾讯CDC
M
MIT News - Artificial intelligence
Hugging Face - Blog
Hugging Face - Blog
P
Palo Alto Networks Blog
C
CXSECURITY Database RSS Feed - CXSecurity.com
AWS News Blog
AWS News Blog
GbyAI
GbyAI
MongoDB | Blog
MongoDB | Blog
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
V
Vulnerabilities – Threatpost
G
Google Developers Blog
N
Netflix TechBlog - Medium
The Cloudflare Blog
Microsoft Security Blog
Microsoft Security Blog
Y
Y Combinator Blog
A
Arctic Wolf
S
Securelist
酷 壳 – CoolShell
酷 壳 – CoolShell
Cisco Talos Blog
Cisco Talos Blog
Recent Announcements
Recent Announcements
C
Cyber Attacks, Cyber Crime and Cyber Security
L
LINUX DO - 热门话题
T
Threatpost
Latest news
Latest news
Blog — PlanetScale
Blog — PlanetScale
Security Latest
Security Latest
Engineering at Meta
Engineering at Meta
大猫的无限游戏
大猫的无限游戏
H
Help Net Security
The GitHub Blog
The GitHub Blog
T
Tor Project blog
P
Proofpoint News Feed

博客园 - kwklover

给同为.NET开发者普及一点Oracle数据库经验 Lucene.net常见功能实现知识汇总 Lucene 1.9 多目录搜索的的一个bug 众里寻他千百度,蓦然回首,那人却在灯火阑珊处 问题总结:判断MS SQLSERVER临时表是否存在 小技巧:处理ASP提交的参数是经过GB2312 URL编码的 Lucene.net实现自定义排序笔记 模版引擎AderTemplate源代码分析笔记 T-SQL复习总结--用T-SQL创建,修改,管理,删除数据库 面向搜索的中文分词设计 需要整理研究的搜索引擎技术点(目录,无实际价值) 试用了一下Sqlite,总结和整理一下参考资料 数据结构与算法学习记录:快速排序 小总结:DotLucene如何才能快速生成索引? 小总结:如何表达用户是否禁止的概念 ? Web Spider提取编码方法总结 WebSpider的编码问题(乱码)浅析 VS2005 Winform程序不能启动调试,别忘了启动Terminal Services服务[记录] 系统问题解决记录:IIS 500内部错误之解决办法
使用mencoder转换flv为ipad/iphone下能播放的mp4格式
kwklover · 2013-05-09 · via 博客园 - kwklover

因为工作需要编写一个采集特定网站视频文件,转换格式,且自动上传发布的系统,采集,上传,发布问题不大,唯独视频格式转换困扰了比较长的时间,所以记录分享一下这个技术,给有需要的博友参考

一般视频格式转换都是用ffmpeg和mencoder,但网上的资料说,ffmpeg性能高,mencoder功能强些。那就mencoder来吧。

string mencoderargs = " -oac faac -faacopts mpeg=4:object=2:raw:br=128 -ovc x264 -x264encopts global_header:no8x8dct:nocabac:weightp=0:bframes=0:level_idc=30 -of lavf -vf scale=-3:488,harddup";

string args = string.Format(" {0} -o {1} {2}", FLVFILEPATH, MP4FILEPATH), mencoderargs);
Process p = CreateProcess("mencoder.exe", args, string.Empty);
p.Start();
p.BeginOutputReadLine();
p.StandardInput.WriteLine("exit");//最后打入退出命令  
p.WaitForExit();
p.Close();
p.Dispose();

关键点是mencoderargs,之前在网上找了很多参数,都能转化成MP4,android能播放,唯独ios系统的iphone和ipad下无法播放,后来找了一篇英文资料,具体链接丢了,说到了,ios下的mp4对音频和视频是有规格要求的,不过具体规格是什么,忘记了,上网搜了下,没找到,找到的这篇文章可以参考下,但不是以前看过的那篇,提到了一点点,供参考:
http://blog.jharding.org/2008/05/encoding-video-for-iphone-with-mencoder.html

具体就不深究了,技术这玩意,能解决问题就OK了。

以后学到新知识点,还是要及时总结的,时间一过,又都忘记了,好记性不如烂笔头啊!