Thursday, June 23, 2016

opencv2/opencv.hpp file not found in .pch file

Leave a Comment

I downloaded openCV from this link : https://github.com/itseez/opencv I dragged and dropped the folder into the 'Frameworks' folder in my project and it appeared under 'Link Binary with Libraries' under Targets''Build Phases'. I set 'Always Search User Paths:' to 'YES'. I added these frameworks under Targets'Link Binary with Libraries: Accelerate, AssetsLibrary, AVFoundation , CoreGraphics , CoreImage , CoreMedia , CoreVideo , QuartzCore , UIKit , Foundation. I created a .pch file and added these lines:

#ifdef __cplusplus #import <opencv2/opencv.hpp> #endif 

I added the .pch file name beside 'Prefix Header' in Project's Build Settings.

Yet the build failed on running and the error 'opencv2/opencv.hpp file not found' appeared under the .pch file heading.

Please help.

0 Answers

If You Enjoyed This, Take 5 Seconds To Share It

0 comments:

Post a Comment