Para rodar o “HeadTracker” no ubuntu necessitamos de algumas bibliotecas.
- OpenNI
- OpenCV
- EHCI
Segue abaixo o passo a passo.
OpenNI
“Biblioteca necessária para o sistema reconhecer o Kinect.”
OpenCV
“Biblioteca necessária para o processamento de imagens e o gerenciamento de janelas.”
sudo apt-get install build-essential libgtk2.0-dev libavcodec-dev libavformat-dev libjpeg62-dev libtiff4-dev cmake libswscale-dev libjasper-dev
cd ~
wget http://sourceforge.net/projects/opencvlibrary/files/opencv-unix/2.1/OpenCV-2.1.0.tar.bz2/download -o OpenCV-2.1.0.tar.bz2
tar -xvf OpenCV-2.1.0.tar.bz2
cd OpenCV-2.1.0/
cmake .
make
sudo make install
sudo gedit /etc/ld.so.conf.d/opencv.confsudo ldconfig
sudo gedit /etc/bash.bashrcexport PKG_CONFIG_PATH
Reinicie o computador.
Testando:
cd ~
mkdir openCV_samples
cp OpenCV-2.1.0/samples/c/* openCV_samples
cd openCV_samples/
chmod +x build_all.sh
./build_all.sh./facedetect --cascade="/usr/local/share/opencv/haarcascades/haarcascade_frontalface_alt.xml" --scale=1.5 lena.jpgReference:
OpenGL
“Biblioteca necessária para a computação grafica.”
sudo apt-get install libsdl-ttf2.0-0 libsdl-ttf2.0-dev libsdl-image1.2 libsdl-image1.2-dev libsdl-mixer1.2 libsdl-mixer1.2-dev libsdl1.2-dev libsdl1.2debian-all
sudo apt-get install libgl1-mesa-dev libglu1-mesa-dev libglut3-dev xorg-dev libtool gforth
Testando:
Baixe o programa no link https://gist.github.com/987718 e compile usando:
gcc simpleTestOpenGL.c
Reference:
EHCI
“Biblioteca necessária para facilitar o reconhecimento e rastreamento da cabeça.”
tar xvfz ehci-0.x.tar.gz # unpack the sources
cd ehci-0.x # change to the toplevel directory
./configure # run the `configure' script
make # build EHCI
make install # install EHCI
export LD_LIBRARY_PATH=/usr/local/lib
Testando:
./6dofhead
Reference:
HeadTracker
TODO