Ask Your Question
0

Include OpenCV 4 installed via brew into OSX application

asked 2019-01-31 03:53:37 -0600

atrbx5 gravatar image

I've installed opencv via brew

brew install opencv3 --with-ffmpeg --with-tbb --with-contrib

add to search path in Xcode project for osx

/usr/local/include/**

/usr/local/lib/**

imported in to *.mm file

#import <opencv4/opencv2/opencv.hpp>

and now I have bunch of errors:

Unknown type name 'uint32_t' Unknown type name 'int64_t' Unknown type name 'uint64_t' No member named 'lldiv_t' in namespace 'std' No member named 'llabs' in namespace 'std' No member named 'lldiv' in namespace 'std' No member named 'atoll' in namespace 'std' No member named 'strtoll' in namespace 'std' No member named 'strtoull' in namespace 'std' No member named 'strtof' in namespace 'std'

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
0

answered 2019-02-04 01:59:30 -0600

atrbx5 gravatar image

Search path should be:

/usr/local/include/opencv4 non recursive

then imports works correctly:

#import <opencv2/opencv.hpp>

#import <opencv2/imgproc/imgproc.hpp>

#import <opencv2/ximgproc.hpp>

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2019-01-31 03:53:37 -0600

Seen: 1,811 times

Last updated: Jan 31 '19