OpenCV and openFramework on Mac

OpenCV 2.2 and openFrameworks (v0.062) for Mac

2 May 2011

Before you start

You'll need:

  • Git.
  • Xcode installed.

Instillation & Setup

  1. Download the latest STABLE version of oF as the latest GIT version never seems to work and you'll save yourself a lot of hair pulling. Unzip anywhere.
  2. Download or git-clone the oF add-on ofxOpenCV22. If you have Git installed, from the command prompt:

    git clone https://github.com/Akira-Hayasaka/ofxOpenCV22.git

  3. You then need to stick move the following folder to the indicated places:

    /ofxOpenCV22/example/try_OpenCV22 
    

    to

    /of_preRelease_v0062_osxSL_FAT/apps/examples/try_OpenCV22 
    

    and

    /ofxOpenCV22/ofxOpenCV22
    

    to

    /of_preRelease_v0062_osxSL_FAT/addons/ofxOpenCV22
    
  4. Then you can open up the /of_preRelease_v0062_osxSL_FAT/apps/examples/try_OpenCV22/try_OpenCV22.xcodeproj xcode project and change the project settings, adding

    "../../../addons/ofxOpenCV22/libs/opencv/include"
    

    to the User Heading Search Paths option (as per the README.rtfd in which he doesn't specify the above fiddling around with folders.

  5. Press the Build & Run button and it should compile without errors (or at least it did for me. I also had to delete a brew version of OpenCV I installed previously before this worked.)