
如何對VOD內(nèi)容文件進行轉(zhuǎn)碼?
Microsoft Expression Encoder 4
Wowza的例子視頻文件(隨Wowza Media Server一同安裝,并可以從如何開始一個VOD點播流?下載) 就是用Expression Encoder 4編碼的。 它可以生成多個不同碼率且關(guān)鍵幀對齊的版本,可以用于多碼率傳輸。
下面的Expression Encoder 4 配置用于編碼例子視頻文件:
· wowza-desktop-multibitrate.xml
· wowza-iphone-multibitrate.xml
FFmpeg
注意: 更新于FFmpeg N-52458-gaa96439版本(04-30-2013)
FFmpeg 是一個針對單個視頻文件進行編碼的很好的選擇(FFmpeg暫不支持多碼率編碼)。
1. 要使用這些FFmpeg命令,請從下面獲得最新版本的FFmpeg:
http://ffmpeg.org
-或-
http://www.videohelp.com/tools/ffmpeg
2. 建立預(yù)先配置文件,下面的命令會用到它。
創(chuàng)建文件夾:
:\usr\local\share\ffmpeg
將FFmpeg包中的presets文件夾下的所有文件拷貝到這個新的文件夾下。
注意: 在Mac OS X平臺上,下面的例子可以在通過Mac Ports安裝的FFmpeg版本上運行。同時也要安裝好轉(zhuǎn)碼配置。
FFmpeg 命令例子
下面的例子采用MP4例子視頻文件.
Code:
ffmpeg -y -i Butterfly_HD_1080p.mp4 -s 320x180 -y -strict experimental -acodec aac -ab 64k -ac 2 -ar 48000 -vcodec libx264 -vprofile baseline -level 30 -g 48 -b 200000 -threads 64 butterflyiphone_320.mp4
ffmpeg -y -i Butterfly_HD_1080p.mp4 -s 640x360 -y -strict experimental -acodec aac -ab 128k -ac 2 -ar 48000 -vcodec libx264 -vprofile baseline -level 30 -g 48 -b 520000 -threads 64 butterflyiphone_640.mp4
ffmpeg -y -i Butterfly_HD_1080p.mp4 -s 320x180 -y -strict experimental -acodec aac -ab 64k -ac 2 -ar 48000 -vcodec libx264 -vprofile main -g 48 -b 270000 -threads 64 butterfly_400.mp4
ffmpeg -y -i Butterfly_HD_1080p.mp4 -s 420x270 -y -strict experimental -acodec aac -ab 64k -ac 2 -ar 48000 -vcodec libx264 -vprofile main -g 48 -b 570000 -threads 64 butterfly_700.mp4
ffmpeg -y -i Butterfly_HD_1080p.mp4 -s 720x406 -y -strict experimental -acodec aac -ab 128k -ac 2 -ar 48000 -vcodec libx264 -vprofile main -g 48 -b 1000000 -threads 64 butterfly_1100.mp4
ffmpeg -y -i Butterfly_HD_1080p.mp4 -s 1024x576 -y -strict experimental -acodec aac -ab 128k -ac 2 -ar 48000 -vcodec libx264 -vprofile main -g 48 -b 1200000 -threads 64 butterfly_1300.mp4
ffmpeg -y -i Butterfly_HD_1080p.mp4 -s 1080x608 -y -strict experimental -acodec aac -ab 128k -ac 2 -ar 48000 -vcodec libx264 -vprofile main -g 48 -b 1400000 -threads 64 butterfly_1500.mp4
下面的例子采用移動視頻例子。 它采用FFmpeg developer build 07-05-2010版。
Code:
ffmpeg -i Butterfly_HD_1080p.mp4 -s 212x120 -y -strict experimental -acodec aac -ab 96k -ac 2 -ar 48000 -vcodec libx264 -vprofile baseline -g 48 -b 85000 -level 30 -threads 64 butterfly_175k.mp4
你也可以用VideoLAN (VLC) 來轉(zhuǎn)碼。
注意:對于Microsoft Silverlight 播放器,最好采用2秒的關(guān)鍵幀間隔。如果你用 -r (fps) 標志后面跟上-g (GOP)設(shè)置的一半數(shù)值,視頻的關(guān)鍵幀間隔將為2秒。 在上面的例子中,-g 為 60,你要設(shè)置為 -r 30。
Wowza Streaming Engine 4是業(yè)界功能強大、API接口豐富的流媒體Server產(chǎn)品,采用它作為流媒體服務(wù)器產(chǎn)品的案例很多,直播、在線教育、IPTV都有它的用武之地。
京ICP備09015132號-996 | 違法和不良信息舉報電話:4006561155
© Copyright 2000-2026 北京哲想軟件有限公司版權(quán)所有 | 地址:北京市海淀區(qū)西三環(huán)北路50號豪柏大廈C2座11層1105室
北京哲想軟件集團旗下網(wǎng)站:哲想軟件 | 哲想動畫