glassechidna / zxing-cpp

ZXing C++ Library
Apache License 2.0
597 stars 435 forks source link

Darwin build #76

Closed kousu closed 5 years ago

kousu commented 5 years ago

Fixes #75

Benjamin-Dobell commented 5 years ago

Looks good, but could I please get the OpenCV4 commit pulled out into a different PR, and preferably changed to something like:

#if CV_MAJOR_VERSION >= 4
#ifndef CV_CAP_PROP_FRAME_WIDTH
#define CV_CAP_PROP_FRAME_WIDTH CAP_PROP_FRAME_WIDTH
#endif
#ifndef CV_BGR2GRAY
#define CV_BGR2GRAY COLOR_BGR2GRAY
#endif
#endif

so as to keep compatibility with OpenCV 2 & 3.

kousu commented 5 years ago

Hi @Benjamin-Dobell ! I split the opencv4 patches to https://github.com/glassechidna/zxing-cpp/pull/77 like you asked; I left them in this (so, this PR now depends on that PR) since I need both to get the build working on Darwin. I hope that's okay.

kousu commented 5 years ago

I'd say this PR is friends with #62, which is a bunch of similar patches made for Windows. If you're feeling up to merging this, can I spend some social capital on getting that merged too?

Benjamin-Dobell commented 5 years ago

Yikes I made a mess of the Git history. However, this should be all merged now.