Working with both ofxCv and ofxOpenCv
phs1919 opened this issue · comments
When working both ofxCv and ofxOpenCv, the following error message occurs.
I assume you mean both ofxBox2d and ofxOpenCv?
There are macros are in conflict (with the same names, min/max). In my app, I "solved" it by making sure ofxBox2d.h was included last, after ofxOpenCv.h. Would be nice if the macros had a "b2d" prefix or something, or (better) used inline functions with a Box2d namespace, or (better still) used std::min and std::max.
Glen.
On Oct 19, 2013, at 5:05 AM, phs1919 notifications@github.com wrote:
When working both ofxCv and ofxOpenCv, the following error message occurs.
However, if only either of them is included, it works fine.—
Reply to this email directly or view it on GitHub.
Hi Glen,
Thanks for your comments. I actually included ofxBox2d.h at the last after ofxOpenCv.h and ofxCv.h. I used std::min and std::max in the source file and now it works. I also agree that Box2d namespace would make it compatible with other addons like this case. Thanks!
fixed