error: ‘HAAR_DO_CANNY_PRUNING’ is not a member of ‘cv’
I am upgrading an existing code base that use OpenCV 2 and 3 to be compatible with my Ubuntu 20.04 that uses OpenCV 4. One error I encountered when compiling is:
error: ‘HAAR_DO_CANNY_PRUNING’ is not a member of ‘cv’; did you mean ‘CASCADE_DO_CANNY_PRUNING’?
Should I accept the change proposed by the compiler and change cv::HAAR_DO_CANNY_PRUNING
to cv::CASCADE_DO_CANNY_PRUNING
for all occurrences?
Solution 1:
Should I accept the change proposed by the compiler?
Yes.
The values of the 4 CASCADE_*
symbols match the ones of the old HAAR_*
symbols, as @DanMasek commented.
You can check the enums in Enumeration Type Documentation and OpenCV-2_2 Reference, page 795.