Salome HOME
Backward compatibility with OpenCV 2x
[modules/geom.git] / src / ShapeRecognition / ShapeRec_FeatureDetector.hxx
index b3941e6f5858f86f7838564796d77754ead9154e..a4b3cc21e8bedf8ae8d474337d40a6681e7373fe 100644 (file)
@@ -1,4 +1,4 @@
-// Copyright (C) 2007-2015  CEA/DEN, EDF R&D, OPEN CASCADE
+// Copyright (C) 2007-2020  CEA/DEN, EDF R&D, OPEN CASCADE
 //
 // Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
 // Author : Renaud NEDELEC, Open CASCADE S.A.S.
 
 // OpenCV includes
-#include <cv.h>
-#include <highgui.h>
-#include <opencv2/imgproc/imgproc.hpp>
-#include <opencv2/highgui/highgui.hpp>
+// RNV: Workaround: HAVE_TBB definition from OCCT conflicts with OPENCV, undef it.
+//      This workaround will be removed after correction of the
+//      https://tracker.dev.opencascade.org/view.php?id=28457 issue.
+#ifdef HAVE_TBB
+#undef HAVE_TBB
+#include <opencv2/opencv.hpp>
+#define HAVE_TBB
+#else
+#include <opencv2/opencv.hpp>
+#endif
 
 // Qt
 #include <QRect>