歡迎來到Linux教程網
Linux教程網
Linux教程網
Linux教程網
您现在的位置: Linux教程網 >> UnixLinux >  >> Linux綜合 >> Ubuntu Linux

Ubuntu 14.04安裝OpenCV2.4.9

Ubuntu 14.04安裝OpenCV2.4.9


Ubuntu 14.04安裝OpenCV2.4.9


Ubuntu 14.04安裝OpenCV2.4.9

安裝工具

sudo apt-get install git
sudo apt-get install g++
sudo apt-get install vim

下載Opencv

opencv2.9

解壓

mkdir tmp
mv opencv-2.4.9.zip tmp
cd tmp
unzip opencv-2.4.9.zip
cd opencv-2.4.9
mkdir release

安裝依賴庫

sudo apt-get install build-essential cmake libgtk2.0-dev pkg-config python-dev python-numpy libavcodec-dev libavformat-dev libswscale-dev  

在opencv的官方文檔也有說明:

  1. GCC 4.4.x or later. This can be installed with:sudo apt-get install build-essential
  2. CMake 2.6 or higher;
  3. Git;
  4. GTK+2.x or higher, including headers (libgtk2.0-dev);
  5. pkg-config;
  6. Python 2.6 or later and Numpy 1.5 or later with developer packages (python-dev, python-numpy);
  7. ffmpeg or libav development packages: libavcodec-dev, libavformat-dev, libswscale-dev;
  8. [optional] libdc1394 2.x;
  9. [optional] libjpeg-dev, libpng-dev, libtiff-dev, libjasper-dev.
    ff-dev, libjasper-dev.

進入目錄生成MakeFile文件

cd releaase

安裝所有的lib文件都會被安裝到/usr/local目錄下

cmake -D CMAKE_BUILD_TYPE=RELEASE -D CMAKE_INSTALL_PREFIX=/usr/local ..

cmake

構建和安裝

make

make

make install

make install

加載動態連接庫

sudo sh -c 'echo "/usr/local/lib" > /etc/ld.so.conf.d/opencv.conf'

sudo ldconfig

OpenCV官方教程中文版(For Python) PDF 

Ubuntu Linux下安裝OpenCV2.4.1所需包

Ubuntu 12.04 安裝 OpenCV2.4.2

CentOS下OpenCV無法讀取視頻文件

Ubuntu 12.04下安裝OpenCV 2.4.5總結

Ubuntu 10.04中安裝OpenCv2.1九步曲

基於QT和OpenCV的人臉識別系統

[翻譯]Ubuntu 14.04, 13.10 下安裝 OpenCV 2.4.9 

OpenCV的詳細介紹:請點這裡
OpenCV的下載地址:請點這裡

http://xxxxxx/Linuxjc/1141017.html TechArticle

Copyright © Linux教程網 All Rights Reserved