Here goes the steps: Installation steps
Finally compiling program with opencv:
Setup the PKG_CONFIG_PATH variable
export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig
export LD_LIBRARY_PATH=/usr
You can check that the PKG_CONFIG_PATH is correct by doing either:
pkg-config --cflags opencv
pkg-config --libs opencv
Compile and link the sample code on OS/X:
You can compile and run the sample code from the directory it's installed in "testcode.cpp":
g++ -bind_at_load `pkg-config --cflags opencv`testcode.cpp -o testcode `pkg-config --libs opencv`
./testcode
The image will show up in a window.
Tutorials on OpenCV can be found here.
Reference
Alternately, it can be installed using macport. Here are the instructions. Reference.
No comments:
Post a Comment