0

I am using Opencv 3 Alpha on Ubuntu 14, everything works fine until I started using some macros... anything like CV_BGR2GRAY, CV_LOAD_IMAGE_GRAYSCALE; Have they got changed and where can I find them?

Samer
  • 1,923
  • 3
  • 34
  • 54
  • If you have not used the "using namespace cv" statement, you might have forgotten to use cv::CV_BGR2GRAY but remembered it for functions. That's one possibility that I could think of. – Cheeku Nov 01 '14 at 19:37
  • @Cheeku, I didnt forget using namespace cv, thanks anyways – Samer Nov 01 '14 at 19:38
  • I think it is something related to OpenCv 3.0, I have used other macros like namedWindow("Display Image", WINDOW_NORMAL); and it works fine – Samer Nov 01 '14 at 19:40

1 Answers1

1

From this forum post and this SO answer it looks like these values have changed in OpenCV 3 to COLOR_BGR2GRAY and cv::IMREAD_GRAYSCALE.

You can also try including legacy.hpp and see if that solves the missing definitions.

Community
  • 1
  • 1
uesp
  • 6,194
  • 20
  • 15