8000
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5dd7194 commit 2772217Copy full SHA for 2772217
matplotlibcpp.h
@@ -17,8 +17,17 @@
17
# include <numpy/arrayobject.h>
18
19
# ifdef WITH_OPENCV
20
-# include <opencv2/opencv.hpp>
+# include <opencv2/opencv.hpp>
21
# endif // WITH_OPENCV
22
+
23
+/*
24
+ * A bunch of constants were removed in OpenCV 4 in favour of enum classes, so
25
+ * define the ones we need here.
26
+ */
27
+# if CV_MAJOR_VERSION > 3
28
+# define CV_BGR2RGB cv::COLOR_BGR2RGB
29
+# define CV_BGRA2RGBA cv::COLOR_BGRA2RGBA
30
+# endif
31
#endif // WITHOUT_NUMPY
32
33
#if PY_MAJOR_VERSION >= 3
0 commit comments