Yolo_mark icon indicating copy to clipboard operation
Yolo_mark copied to clipboard

make fails - CV_CAP_PROP_FPS not defined in this scope

Open towster opened this issue 5 years ago • 6 comments

make fails when compling.

$ cmake . -- The CXX compiler identification is GNU 7.3.0 -- Check for working CXX compiler: /usr/bin/c++ -- Check for working CXX compiler: /usr/bin/c++ -- works -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done -- Detecting CXX compile features -- Detecting CXX compile features - done -- Found OpenCV: /usr/local (found version "4.1.0") -- Configuring done -- Generating done -- Build files have been written to: /home/rnt/ocvtesting/Yolo_mark $ make [ 50%] Building CXX object CMakeFiles/yolo_mark.dir/main.cpp.o /home/rnt/ocvtesting/Yolo_mark/main.cpp: In function ‘int main(int, char**)’: /home/rnt/ocvtesting/Yolo_mark/main.cpp:156:28: error: ‘CV_CAP_PROP_FPS’ was not declared in this scope const int fps = cap.get(CV_CAP_PROP_FPS); ^~~~~~~~~~~~~~~ /home/rnt/ocvtesting/Yolo_mark/main.cpp:156:28: note: suggested alternative: ‘CV_PROP_RW’ const int fps = cap.get(CV_CAP_PROP_FPS); ^~~~~~~~~~~~~~~ CV_PROP_RW /home/rnt/ocvtesting/Yolo_mark/main.cpp:493:60: error: ‘CV_FILLED’ was not declared in this scope rectangle(frame, prev_img_rect, Scalar(100, 100, 100), CV_FILLED); ^~~~~~~~~ /home/rnt/ocvtesting/Yolo_mark/main.cpp:493:60: note: suggested alternative: ‘__FILE’ rectangle(frame, prev_img_rect, Scalar(100, 100, 100), CV_FILLED); ^~~~~~~~~ __FILE CMakeFiles/yolo_mark.dir/build.make:62: recipe for target 'CMakeFiles/yolo_mark.dir/main.cpp.o' failed make[2]: *** [CMakeFiles/yolo_mark.dir/main.cpp.o] Error 1 CMakeFiles/Makefile2:67: recipe for target 'CMakeFiles/yolo_mark.dir/all' failed make[1]: *** [CMakeFiles/yolo_mark.dir/all] Error 2 Makefile:83: recipe for target 'all' failed make: *** [all] Error 2

towster avatar Apr 13 '19 19:04 towster

Looks like it is an issue using opencv 4.x I found that one of the forks has 4.x implemented.. https://github.com/thinkpiece/Yolo_mark

towster avatar Apr 13 '19 19:04 towster

I got same issue and got fixed by just removing CV_ from CV_FILLED and CV_CAP_PROP_FPS from main.cpp. opencv 4.0.0 Linux Mint 19.1

okmd avatar Apr 14 '19 14:04 okmd

@ido-ran @RRMoelker @vinjn @lovexytoo I fixed it. Now Yolo_mark supports OpenCV 3.x and 4.x

AlexeyAB avatar Apr 16 '19 20:04 AlexeyAB

I had this issue ‘FILLED’ was not declared in this scope error: ‘CAP_PROP_FPS’ was not declared in this scope

I solved it just by adding CV_ before ‘CAP_PROP_FPS’ and 'FILLED'

AzimovS avatar May 27 '19 15:05 AzimovS

@AzimovS

  • What OS and OpenCV version do you use?

  • Do you use the latest version of Yolo_mark?

AlexeyAB avatar May 27 '19 15:05 AlexeyAB

@AlexeyAB Sorry, forgot to mention. Ubuntu 16.04 and OpenCV version is 3.4.5 I downloaded Yolo_mark version a few minutes ago, so I think it is the latest version

AzimovS avatar May 27 '19 15:05 AzimovS