查詢OpenCV相關軟體包
$ apt-cache search opencv
libcv-dev - development files for libcv
libcv1 - computer vision library
libcvaux-dev - development files for libcvaux
libcvaux1 - computer vision extension library
libhighgui-dev - development files for libhighgui
libhighgui1 - computer vision GUI library
opencv-doc - OpenCV documentation and examples
python-opencv - Python bindings for the computer vision library
在這裡,OpenCV的庫CxCore和Cv都被包含入Deb包libcv中。
[編輯]
安裝相關軟體包
如果只是用來運行OpenCV程式,僅需安裝libcv1,libcvaux1,libhighgui1:
apt-get install libcv1 libcvaux1 libhighgui1
如果你要使用OpenCV來編寫程式,那麼還需要安裝libcv-dev,libcvaux-dev,libhighgui-dev包。
apt-get install libcv-dev libcvaux-dev libhighgui-dev
文檔在opencv-doc包中,python-opencv是OpenCV的Python語言包,可根據需要安裝。
[編輯]
測試安裝包
測試是否安裝成功,你可以使用以下的命令行編譯位於源代碼包中的drawing.c例子:
g++ `pkg-config opencv --libs --cflags opencv` drawing.c -o drawing
成功編譯後你應該能夠可以執行./drawing看到highgui輸出視窗的結果了.
沒有留言:
張貼留言