PTAM编译选项

来源:互联网 发布:java创建文件夹和文件 编辑:程序博客网 时间:2024/06/05 10:25

参考文章:
http://hustcalm.me/blog/2013/09/27/ptam-compilation-on-linux-howto/
http://www.robots.ox.ac.uk/~bob/software/ptamm/manual.pdf
系统:ubuntu14.04
工具:
PTAM:
BeLioN-github/PTAM
TooN:
edrosten/TooN
libcvd:
edrosten/libcvd
gvas3:
edrosten/gvars

Build Tools
sudo apt-get update
sudo apt-get install build-essential cmake pkg-config
Boost for C++
sudo apt-get install libboost-dev libboost-doc
Low level libraries for Linear Algebra
sudo apt-get install liblapack-dev libblas-dev
Image I/O && Camera Driver
sudo apt-get install libjpeg-dev libpng-dev libtiff-dev libdc1394-22-dev libv4l-dev
Video I/O && Codec && Display
sudo apt-get install libavcodec-dev libavformat-dev libavutil-dev libpostproc-dev libswscale-dev libavdevice-dev libsdl-dev
sudo apt-get install libgtk2.0-dev libgstreamer0.10-dev libgstreamer-plugins-base0.10-dev
OpenGL
sudo apt-get install mesa-common-dev libgl1-mesa-dev libglu1-mesa-dev freeglut3-dev
Installation of OpenCV
cd thePathYouWant
wget http://downloads.sourceforge.net/project/opencvlibrary/opencv-unix/2.4.9/opencv-2.4..9
解压缩
cd opencv-2.4.9
mkdir release
cd release
cmake -D CMAKE_BUILD_TYPE=RELEASE -D CMAKE_INSTALL_PREFIX=/usr/local ..
make
sudo make install
You may want to alert the system about the new installed OpenCV libs,

vi /etc/ld.so.conf
add `include /usr/local/lib`
sudo ldconfig

After this, OpenCV dependencies can now be linked with simply:pkg-config opencv --cflags --libs

Installation of TooN && libCVD && Gvars3

TooN
./configure && make && sudo make install
libCVD
./configure --without-ffmpeg
make
sudo make install
Gvars3
./configure --disable-widgets
make
make install
Make the libs work
sudo ldconfig

Compilation of PTAM

copy files in PTAM/build/Linux to PTAM;
Edit the Makefile to reference custom include or linker paths
LINKFLAGS = -L /usr/local/lib -lGvars3 -lcvd -lGLU -lGL -llapack

Make

Probably an error will popup, like “error, usleep was not declared in this scope”, easily add
#include <unistd.h>
to Tracker.ccand you are done

then just make

0 0