Ask Your Question
1

OpenCV developed in C/C++ - Run in iOS?

asked 2013-01-17 05:19:47 -0600

UserOpenCV gravatar image

updated 2013-01-17 09:13:18 -0600

AlexanderShishkov gravatar image

I am developing an image processing application in Centos with OpenCV using C/C++ coding. My intension is to have a single development platform for Linux and IOS (IPAD). So if I start the development in a Linux environment with OpenCV installed ( in C/C++ ), can I use the same code in IOS without going for Objective-C? I don't want to put dual effort for iOS so how to achieve this?

edit retag flag offensive close merge delete

2 answers

Sort by ยป oldest newest most voted
1

answered 2013-01-17 06:36:37 -0600

AlexanderShishkov gravatar image

Yes, you can. But you should use OpenCV C++ interface, because now we don't support old C interface for iOS. Or you should create OpenCV framework for iOS manually with support of C interface. For iOS projects you should use Objective-C++ for using combination ObjectiveC and C++.

edit flag offensive delete link more
1

answered 2013-02-19 03:26:50 -0600

Andrei Blaj gravatar image

I also do this in our project, Real Colors (Android and iPhone app). For iOS we wrapped all the code in a static library that we link in the iOS app. We also include the opencv2.framework in the app.

It is possible to have one codebase for the OpenCV code and then link it to whatever platform you want: Android, iPhone, PC, Mac.

edit flag offensive delete link more

Question Tools

Stats

Asked: 2013-01-17 05:19:47 -0600

Seen: 474 times

Last updated: Feb 19 '13