I have followed the instructions on how to install OpenCV on an iOS project. However when using Xcode 7 I had to add manually a prefix header. Doing this unfortunately did not h
I just had the exact same problem. I'm working in a Swift project with OpenCV.
Regarding Swift, its entry point to OpenCV is a file I called OpenCVWrapper. So I got OpenCVWrapper.h and OpenCVWrapper.mm. In the bridging header of my project, I got #import "OpenCVWrapper.h".
Thing is I wanted to write a class called MatUtils in Objective-C++ that I could call from OpenCVWrapper.mm. For them to be seeable in there, I had to put them in MatUtils.h.
Long story short, the mistake is that in OpenCVWrapper.h, I did #import "MatUtils.h". MISTAKE!!!! As OpenCVWrapper is in the bridging header, C++ is now reachable from Swift!
Quick fix : #import "MatUtils.h" in OpenCVWrapper.mm!
Cheers! bRo