親手搭建一套簡單的直播系統
阿新 • • 發佈:2018-11-20
親手搭建一套簡單的直播系統
原始碼安裝ffmpeg(帶libx264)
ffmpeg編譯參考官網文件:http://trac.ffmpeg.org/wiki/CompilationGuide/Centos
環境:CentOS6.2_64
1、下載原始碼包
wget ftp://ftp.videolan.org/pub/x264/snapshots/x264-snapshot-20120718-2245-stable.tar.bz2
解壓:tar jxvf x264-snapshot-20120718-2245-stable.tar.bz2
wget http://ffmpeg.org/releases/ffmpeg-0.11.1.tar.gz
解壓:tar zxvf ffmpeg-0.11.1.tar.gz
2、安裝x264
2.1 安裝依賴包
缺少yasm
安裝:yum install yasm -y
2.2 安裝x264
./configure --prefix=/usr --enable-shared && make && make install
重新載入配置:ldconfig
3、安裝ffmpeg
ffplay必須依賴於sdl庫
yum install SDL -y
安裝:
./configure --enable-libx264 --enable-gpl && make && make install
附(自動安裝指令碼):
#! /bin/bash echo "Install yasm ..." yum install yasm SDL* gtk+* -y echo "Install libx264 ..." wget ftp://ftp.videolan.org/pub/x264/snapshots/x264-snapshot-20120718-2245-stable.tar.bz2 tar jxvf x264-snapshot-20120718-2245-stable.tar.bz2 cd x264-snapshot-20120718-2245-stable ./configure --enable-shared && make && make install ldconfig echo"Install ffmpeg ..." cd .. wget http://ffmpeg.org/releases/ffmpeg-0.11.1.tar.gz tar zxvf ffmpeg-0.11.1.tar.gz cd ffmpeg-0.11.1 ./configure --enable-libx264 --enable-gpl && make && make install
泛娛樂化直播系統、視訊會議實時互動直播系統
視訊壓縮技術