Convert video to iPod format
August 7, 2008 8:21 pm | In Tech | No Comments | hideBasic command:
ffmpeg -i input.avi -f mp4 -vcodec mpeg4 -b 1000kb \ -acodec aac -ab 192kb output.mp4
A more interesting example: input file is in mkv format with 5.1 aac audio (if you don’t convert 5.1 to 2.0, playing the file crashes your iPod/iPhone).
- Extract aac audio from the mkv file:
ffmpeg -i input.mkv -vn -acodec copy audio.aac
- Downmix 5.1 to 2.0:
faad -d audio.aac -o audio-2ch.wav
- Merge and convert to iPod format:
ffmpeg -i input.mkv -i audio-2ch.wav -map 0.0:0 -map 1.0:1 -f mp4 \ -vcodec mpeg4 -s 470x320 -b 1000kb -acodec aac -ab 192kb output.mp4
- The output of the last command gives a little more info of what I am doing here:
Input #0, matroska, from 'input.mkv': Duration: 01:24:42.5, start: 0.000000, bitrate: N/A Stream #0.0: Video: h264, yuv420p, 704x480, 24.39 fps(r) Stream #0.1: Audio: aac, 48000 Hz, 5:1 Input #1, wav, from 'audio-2ch.wav': Duration: 01:24:42.5, start: 0.000000, bitrate: 1536 kb/s Stream #1.0: Audio: pcm_s16le, 48000 Hz, stereo, 1536 kb/s Output #0, mp4, to 'output.mp4': Stream #0.0: Video: mpeg4, yuv420p, 470x320, q=2-31, 1000 kb/s, 24.39 fps(c) Stream #0.1: Audio: aac, 48000 Hz, stereo, 192 kb/s Stream mapping: Stream #0.0 -> #0.0 Stream #1.0 -> #0.1
Video conversion can certainly be way fancier than what I am doing here, and faad is obviously not the best way to downmix audio from 5.1 to 2.0. You can also find quite a few iPod converters but personally I like command line. Anyway, happy converting! (ffmpeg ref)
某人用苹果电脑…
November 12, 2007 1:08 am | In Life | 3 Comments | hide某人用 Mac 好几个月了,前几天需要重启动系统,死活找不到重启动的地方,电话我才得知需要按屏幕左上角的小苹果。这件事情说明了两个问题:
- Mac 系统很好很强大,电脑盲使用几个月都从来没有需要重启动过。
- Mac 的 usability 是不是还存在问题,特别是对于极笨的使用者……
I Love Apple
October 16, 2007 12:00 am | In Misc | 5 Comments | hide什么叫 Usability,就是有两套音频系统的 Mac 电脑上切换喇叭只要按一个快捷键即可。什么叫 Us不ability,就是 XP 里面换音频设备还要停止播放音频再重来过。
什么叫 Usability,就是新 Mac 首次开机在很开始就询问需要接入的 WiFi 网及其密码。什么叫 Us不ability,就是新 HP 开机输了一大堆注册信息突然蹦出一个 STOP 的提示框说无线网有密码,注册信息发不出去,而且貌似切换不出去没地方输入密码……
什么叫 Usability,就是 iPod 包装盒在开口的地方不大不小的写了一个 enjoy,看到了不禁会心一笑。什么叫 Us不ability,就是 Dell 寄过来的笔记本箱子居然连个拎的地方都没有,害我抱着个方头方脑的大怪物在学校里面走被人笑话……
唉,苹果公司的设计理念,想偷是学不像的啊……
This weblog is licensed under a
Creative Commons License.
Powered by WordPress. Theme based on Pool by Borja Fernandez.