Opencv Framework Conflict
I am using both the SOOMLA storekit framework and the opencv 2.4.9 framework in my Unity project and then when I build to Xcode, SOOMLA forces me to add the AssetsLibrary framework for it to work but after doing so, my project crashes when the opencv framework is called and the error I get is a libpng error : “Internal row logic error”.
After some research I found this was because both the AssetsLibrary and opencv framework have libpng libraries and they seem to conflict with each other.
Is there any work around where I can avoid using the AssetsLibrary framework? If not, is there any particular order to how I add the SOOMLA framework dependencies in to Xcode that I am not aware of?
Thanks Rajvi Dave
I wonder why does SOOMLA needs AssetsLibrary?
A quick work around could be to disable the build of libpng in OpenCV and use other image formats or use the AssetsLibrary to process png data first.
After adding SOOMLA Framework in my unity project, when i try to build the project in xcode i get the following errors :
Undefined symbols for architecture arm64: "_OBJC_CLASS_$_ALAssetsLibrary", referenced from: objc-class-ref in opencv2(cap_ios_video_camera.o) ld: symbol(s) not found for architecture arm64 clang: error: linker command failed with exit code 1 (use -v to see invocation)
The projects runs successfully after adding AssetsLibrary framework but crashes when i try to generate a png image using opencv. The error is as below : libpng error : “Internal row logic error”.
@StevenPuttemans How can i disable the build of libpng in OpenCV?
@rajvidave before building OpenCV, you run the cmake gui interface. There is the option
WITH_PNG
which is selected by default. Disable it, or run cmake with an extra option like thismake -D WITH_PNG=OFF
.