日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 运维知识 > Ubuntu >内容正文

Ubuntu

ubuntu8.10下mplayer+win32codecs+Coreavc编译安装详解

發布時間:2023/12/10 Ubuntu 50 豆豆
生活随笔 收集整理的這篇文章主要介紹了 ubuntu8.10下mplayer+win32codecs+Coreavc编译安装详解 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

<script type="text/javascript"> document.body.oncopy = function() { if (window.clipboardData) { setTimeout(function() { var text = clipboardData.getData("text"); if (text && text.length>300) { text = text + "/r/n/n本文來自CSDN博客,轉載請標明出處:" + location.href; clipboardData.setData("text", text); } }, 100); } } </script> <script class="blogstory">function StorePage(){d=document;t=d.selection?(d.selection.type!='None'?d.selection.createRange().text:''):(d.getSelection?d.getSelection():'');void(keyit=window.open('http://www.365key.com/storeit.aspx?t='+escape(d.title)+'&u='+escape(d.location.href)+'&c='+escape(t),'keyit','scrollbars=no,width=475,height=575,left=75,top=20,status=no,resizable=yes'));keyit.focus();}</script>

1. 如何安裝win32codecs
比起手動安裝來,我更推薦加源安裝的方法。medibuntu是目前最好的源。
以ubuntu8.10為例
先加源

代碼: sudo wget http://www.medibuntu.org/sources.list.d/intrepid.list --output-document=/etc/apt/sources.list.d/medibuntu.list


然后加GPG Key

代碼: sudo apt-get update && sudo apt-get install medibuntu-keyring && sudo apt-get update


這一步時可能會有未驗證之類的錯誤提示,回答yes,或y讓它繼續進行即可。

安裝win32codecs包
如果是intel的CPU

代碼: sudo apt-get install w32codecs


如果是64位 CPU

代碼: sudo apt-get install w64codecs



OK,完成win32codecs的安裝

2. 從源里安裝mplayer。這一步很重要,因為我們需要用源里的mplayer來確定依賴關系,要不然,編譯的mplayer很可能會缺少某些功能。
8.10源里的mplayer仍是1.0rc2,有點老。我們可以加個源用新的

代碼: sudo gedit /etc/apt/sources.list


在末尾加上

代碼: deb http://ppa.launchpad.net/rvm/ubuntu intrepid main
deb-src http://ppa.launchpad.net/rvm/ubuntu intrepid main


保存后

代碼: sudo apt-get update 代碼: sudo apt-get install mplayer smplayer mplayer-fonts? mozilla-mplayer


執行到這一步,不想編譯的同學就可以止步了。你將得到一個版本比較新的mplayer和smplayer。但有可能mplayer會有問題。源里的mplayer要穩定得多。

---------------------------------------編譯mplayer的快樂分隔線------------------------------------------------------

3. 準備編譯mplayer+Coreavc。
第一步(重要)

代碼: sudo apt-get build-dep mplayer



第二步 下載mplayer,下載Coreavc,以及破解版的CoreAVCDecoder.ax。
下載SVN版的mplayer(只有SVN版的mplayer才能安上Coreavc)

代碼: svn checkout svn://svn.mplayerhq.hu/mplayer/trunk mplayer



用SVN版下載Coreavc

代碼: svn checkout http://coreavc-for-linux.googlecode.com/svn/trunk/ coreavc-for-linux



下載CoreAVCDecoder.ax破解包 。內有安裝說明。解壓后將CoreAVCDecoder.ax拷貝到/usr/lib/codecs目錄中,然后更改此文件權限為所有用戶可讀。

代碼: sudo chmod 644 /usr/lib/codecs/CoreAVCDecoder.ax



第三步 順序是:處理Coreavc---注冊CoreAVCDecoder.ax--配置mplayer--打補丁--編譯--完成
a. 處理Coreavc(以intel CPU為例 )

代碼: cd coreavc-for-linux
make -C dshowserver


然后

代碼: sudo cp dshowserver/dshowserver /usr/local/bin
sudo cp dshowserver/registercodec /usr/local/bin


對于64位CPU,應該到http://code.google.com/p/coreavc-for-linux/downloads/list 下載最新的包。然后把dshowserver和registercodec拷貝到/usr/local/bin目錄中。

b. 注冊CoreAVCDecoder.ax

代碼: registercodec -r ~/.mplayer/registry32 -k "HKLM//Software//CoreCodec//CoreAVC Pro//Serial" -v "0OKWX-E83B3-CORE-IQ0UW-3I3B7"


然后驗證dshowserver是否工作:

代碼: dshowserver -c CoreAVCDecoder.ax -s 1280x720 -g 09571a4b-f1fe-4c60-9760de6d310c7c31 -b 12 -f 0x34363248 -o 0x30323449


如果輸出信息如下,那就表示解碼器工作正常。

代碼: 輸出:No id specified, assuming test mode
Opening device
len: 992
ProductVersion: 1.7.0Decoder supports the following YUV formats: YUY2 UYVY YV12 I420
Decoder is capable of YUV output (flags 0x2b)
Setting fmt
Starting
Initialization is complete



c. 配置mplayer和打補丁,在打補丁之前,一定要先./configure, 要不然是打不上補丁的。

代碼: cd mplayer
./configure --enable-gui --enable-freetype --codecsdir=/usr/lib/codecs --language=zh_CN


打補丁

代碼: patch -p0 < ../coreavc-for-linux/mplayer/dshowserver.patch


然后編譯安裝

代碼: make
sudo make install



最后還有一步
編輯~/.mplayer/中的codecs.conf文件。如果沒有這個文件,就拷貝一個過去

代碼: cp etc/codecs.conf ~/.mplayer/
gedit codecs.conf


把下面這一段拷貝到codecs.conf中,VIDEO CODECS部分的最前面。

代碼: videocodec coreserve
? info "CoreAVC DShow H264 decoder 1.3 for x86 - http://corecodec.org/"
? status working
? format 0x10000005
? fourcc H264,h264 H264
? fourcc X264,x264
? fourcc avc1,AVC1 AVC1
? fourcc davc,DAVC
? fourcc VSSH
? driver dshowserver
? dll "CoreAVCDecoder.ax"
? guid 0x09571a4b, 0xf1fe, 0x4c60, 0x97, 0x60, 0xde, 0x6d, 0x31, 0x0c, 0x7c, 0x31
? out YV12,IYUV,I420,YUY2



最后,把從源里安裝的mplayer改個名,保證以后調用的都是編譯的mplayer。

代碼: sudo mv /usr/bin/mplayer /usr/bin/mplayer.apt


好,現在,大功告成。哪怕是Atom CPU,也能基本流暢地播放720P視頻了。

注:以上編譯過程在Eeepc 1000H、ubuntu8.10上完成。不敢保證其他機型也能順利成功完成。
另外,6樓的兄弟提供了更簡潔的安裝辦法和更高版本的CoreAVCDecoder.ax,值得參考。

附:參考資料
coreavc地址及官方教程
http://code.google.com/p/coreavc-for-li ... stallation
http://code.google.com/p/coreavc-for-li ... verInstall
mplayer的普通編譯安裝
http://blog.chinaunix.net/u2/81801/showart_1330801.html
medibuntu官方指南
https://help.ubuntu.com/community/Medibuntu

總結

以上是生活随笔為你收集整理的ubuntu8.10下mplayer+win32codecs+Coreavc编译安装详解的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。