I want to develop an application like face Recognition and i also use usb webcam to capture an image. I know OpenCV to process an image, but I don't know how to port on my mini2440. Now, I installed QT4.5.2 and tslib on my host computer(fedora9) and i can build a small application using Qt Creator 1.3.1. And i can run a application on my board successfully. I got a few questions about OpenCV. Should I install opencv on my mini2440? or just only install OpenCV on my host computer to build a binary file? or just copy the library of OpenCV on my mini2440? Can i integrate OpenCV with Qt? Did anybody use OpenCV for Linux in your project? If you don't mind, can you explain step-by-step about that project? Thank you very much!
image processing and opencv
Have you seen this topic? http://www.friendlyarm.net/forum/topic/306
after reading this topic. I still got a few questions about OpenCV. Should I install opencv on my mini2440? or just only install OpenCV on my host computer to build a binary file? or just copy the library of OpenCV on my mini2440? Can i integrate OpenCV with Qt?
I followed the instruction from this topic. http://www.friendlyarm.net/forum/topic/306 I can't build a binary file. Toolchain: 4.3.2 steps: 1. tar -xjf OpenCV-2.0.0.tar.bz2 2. go to OpenCV-2.0.0 3. ./configure --host=arm-linux --disable-shared 4. make 5. make install Finally, I got this errors. [root@localhost FYP]# arm-linux-g++ -o2 -I /usr/local/include/opencv facedetect_noui.cpp -L /root/Desktop/OpenCV-2.0.0/src/.libs -lcv -lhighgui -lcxcore -lml -lcvaux -lrt -lpthread -ldl -lz -lpng12 -ljpeg -o facedetect cc1plus: warning: include location "/usr/local/include/opencv" is unsafe for cross-compilation /usr/local/arm/4.3.2/bin/../lib/gcc/arm-none-linux-gnueabi/4.3.2/../../../../arm -none-linux-gnueabi/bin/ld: cannot find -lcv collect2: ld returned 1 exit status Help!!
I tried so many times, i still got a error messages. [root@localhost FYP]# arm-linux-g++ -O2 -I/usr/local/include/opencv -L/root/Desktop/FYP/OpenCV-2.0.0/src/.libs -lcv -lhighgui -lcxcore -lml -lcvaux -lrt -lpthread -ldl -lz -lpng12 -ljpeg facedetect_noui.cpp -o facedetect cc1plus: warning: include location "/usr/local/include/opencv" is unsafe for cross-compilation /tmp/ccdobqjX.o: In function `detectAndSave(cv::Mat&, cv::CascadeClassifier&, cv::CascadeClassifier&, double, std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)': facedetect_noui.cpp:(.text+0x190): undefined reference to `cv::cvtColor(cv::Mat const&, cv::Mat&, int, int)' facedetect_noui.cpp:(.text+0x1cc): undefined reference to `cv::resize(cv::Mat const&, cv::Mat&, cv::Size_<int>, double, double, int)' facedetect_noui.cpp:(.text+0x1d8): undefined reference to `cv::equalizeHist(cv::Mat const&, cv::Mat&)' facedetect_noui.cpp:(.text+0x1dc): undefined reference to `cvGetTickCount' facedetect_noui.cpp:(.text+0x220): undefined reference to `cv::CascadeClassifier::detectMultiScale(cv::Mat const&, std::vector<cv::Rect_<int>, std::allocator<cv::Rect_<int> > >&, double, int, int, cv::Size_<int>)' facedetect_noui.cpp:(.text+0x224): undefined reference to `cvGetTickCount' facedetect_noui.cpp:(.text+0x264): undefined reference to `cvGetTickFrequency' facedetect_noui.cpp:(.text+0x414): undefined reference to `cv::circle(cv::Mat&, cv::Point_<int>, int, cv::Scalar_<double> const&, int, int, int)' facedetect_noui.cpp:(.text+0x41c): undefined reference to `cv::CascadeClassifier::empty() const' facedetect_noui.cpp:(.text+0x588): undefined reference to `cv::error(cv::Exception const&)' facedetect_noui.cpp:(.text+0x720): undefined reference to `cv::CascadeClassifier::detectMultiScale(cv::Mat const&, std::vector<cv::Rect_<int>, std::allocator<cv::Rect_<int> > >&, double, int, int, cv::Size_<int>)' facedetect_noui.cpp:(.text+0x834): undefined reference to `cv::circle(cv::Mat&, cv::Point_<int>, int, cv::Scalar_<double> const&, int, int, int)' facedetect_noui.cpp:(.text+0x8d4): undefined reference to `cv::imwrite(std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, cv::Mat const&, std::vector<int, std::allocator<int> > const&)' facedetect_noui.cpp:(.text+0x984): undefined reference to `cv::fastFree(void*)' facedetect_noui.cpp:(.text+0x990): undefined reference to `cv::fastFree(void*)' facedetect_noui.cpp:(.text+0x99c): undefined reference to `cv::fastFree(void*)' facedetect_noui.cpp:(.text+0xb50): undefined reference to `cv::fastFree(void*)' facedetect_noui.cpp:(.text+0xb5c): undefined reference to `cv::fastFree(void*)' /tmp/ccdobqjX.o: In function `main': facedetect_noui.cpp:(.text+0xf24): undefined reference to `cv::CascadeClassifier::CascadeClassifier()' facedetect_noui.cpp:(.text+0xf2c): undefined reference to `cv::CascadeClassifier::CascadeClassifier()' facedetect_noui.cpp:(.text+0x1080): undefined reference to `cv::CascadeClassifier::load(std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)' facedetect_noui.cpp:(.text+0x1218): undefined reference to `cv::CascadeClassifier::load(std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)' facedetect_noui.cpp:(.text+0x1254): undefined reference to `cvCreateCameraCapture' facedetect_noui.cpp:(.text+0x1288): undefined reference to `cvQueryFrame' facedetect_noui.cpp:(.text+0x12c4): undefined reference to `cv::Mat::Mat(_IplImage const*, bool)' facedetect_noui.cpp:(.text+0x13cc): undefined reference to `cv::Mat::copyTo(cv::Mat&) const' facedetect_noui.cpp:(.text+0x1420): undefined reference to `cvReleaseCapture' facedetect_noui.cpp:(.text+0x142c): undefined reference to `cv::CascadeClassifier::~CascadeClassifier()' facedetect_noui.cpp:(.text+0x1438): undefined reference to `cv::CascadeClassifier::~CascadeClassifier()' facedetect_noui.cpp:(.text+0x1838): undefined reference to `cv::imread(std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)' facedetect_noui.cpp:(.text+0x1920): undefined reference to `cvCreateFileCapture' facedetect_noui.cpp:(.text+0x1ac4): undefined reference to `cv::fastFree(void*)' facedetect_noui.cpp:(.text+0x1ad0): undefined reference to `cv::fastFree(void*)' facedetect_noui.cpp:(.text+0x1b00): undefined reference to `cv::flip(cv::Mat const&, cv::Mat&, int)' facedetect_noui.cpp:(.text+0x1b0c): undefined reference to `cv::fastFree(void*)' facedetect_noui.cpp:(.text+0x1cd0): undefined reference to `cv::imread(std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)' facedetect_noui.cpp:(.text+0x1d9c): undefined reference to `cv::fastFree(void*)' facedetect_noui.cpp:(.text+0x1df0): undefined reference to `cv::fastFree(void*)' facedetect_noui.cpp:(.text+0x1e7c): undefined reference to `cv::fastFree(void*)' facedetect_noui.cpp:(.text+0x1e88): undefined reference to `cv::fastFree(void*)' facedetect_noui.cpp:(.text+0x1e98): undefined reference to `cv::CascadeClassifier::~CascadeClassifier()' facedetect_noui.cpp:(.text+0x1ea4): undefined reference to `cv::CascadeClassifier::~CascadeClassifier()' /tmp/ccdobqjX.o: In function `cv::Mat::release()': facedetect_noui.cpp:(.text._ZN2cv3Mat7releaseEv[cv::Mat::release()]+0x50): undefined reference to `cv::fastFree(void*)' /tmp/ccdobqjX.o: In function `cv::Mat::operator=(cv::Mat const&)': facedetect_noui.cpp:(.text._ZN2cv3MataSERKS0_[cv::Mat::operator=(cv::Mat const&)]+0xb0): undefined reference to `cv::fastFree(void*)' /tmp/ccdobqjX.o: In function `cv::Mat::create(int, int, int)': facedetect_noui.cpp:(.text._ZN2cv3Mat6createEiii[cv::Mat::create(int, int, int)]+0x154): undefined reference to `cv::error(cv::Exception const&)' facedetect_noui.cpp:(.text._ZN2cv3Mat6createEiii[cv::Mat::create(int, int, int)]+0x1c8): undefined reference to `cv::fastMalloc(unsigned int)' facedetect_noui.cpp:(.text._ZN2cv3Mat6createEiii[cv::Mat::create(int, int, int)]+0x22c): undefined reference to `cv::fastFree(void*)' collect2: ld returned 1 exit status [root@localhost FYP]# arm-linux-g++ -O2 -I/usr/local/include/opencv -L/usr/local/lib -lcv -lhighgui -lcxcore -lml -lcvaux -lrt -lpthread -ldl -lz -lpng12 -ljpeg facedetect_noui.cpp -o facedetect cc1plus: warning: include location "/usr/local/include/opencv" is unsafe for cross-compilation /usr/local/arm/4.3.2/bin/../lib/gcc/arm-none-linux-gnueabi/4.3.2/../../../../arm -none-linux-gnueabi/bin/ld: warning: library search path "/usr/local/lib" is unsafe for cross-compilation /tmp/cc3Ejmow.o: In function `detectAndSave(cv::Mat&, cv::CascadeClassifier&, cv::CascadeClassifier&, double, std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)': facedetect_noui.cpp:(.text+0x190): undefined reference to `cv::cvtColor(cv::Mat const&, cv::Mat&, int, int)' facedetect_noui.cpp:(.text+0x1cc): undefined reference to `cv::resize(cv::Mat const&, cv::Mat&, cv::Size_<int>, double, double, int)' facedetect_noui.cpp:(.text+0x1d8): undefined reference to `cv::equalizeHist(cv::Mat const&, cv::Mat&)' facedetect_noui.cpp:(.text+0x1dc): undefined reference to `cvGetTickCount' facedetect_noui.cpp:(.text+0x220): undefined reference to `cv::CascadeClassifier::detectMultiScale(cv::Mat const&, std::vector<cv::Rect_<int>, std::allocator<cv::Rect_<int> > >&, double, int, int, cv::Size_<int>)' facedetect_noui.cpp:(.text+0x224): undefined reference to `cvGetTickCount' facedetect_noui.cpp:(.text+0x264): undefined reference to `cvGetTickFrequency' facedetect_noui.cpp:(.text+0x414): undefined reference to `cv::circle(cv::Mat&, cv::Point_<int>, int, cv::Scalar_<double> const&, int, int, int)' facedetect_noui.cpp:(.text+0x41c): undefined reference to `cv::CascadeClassifier::empty() const' facedetect_noui.cpp:(.text+0x588): undefined reference to `cv::error(cv::Exception const&)' facedetect_noui.cpp:(.text+0x720): undefined reference to `cv::CascadeClassifier::detectMultiScale(cv::Mat const&, std::vector<cv::Rect_<int>, std::allocator<cv::Rect_<int> > >&, double, int, int, cv::Size_<int>)' facedetect_noui.cpp:(.text+0x834): undefined reference to `cv::circle(cv::Mat&, cv::Point_<int>, int, cv::Scalar_<double> const&, int, int, int)' facedetect_noui.cpp:(.text+0x8d4): undefined reference to `cv::imwrite(std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, cv::Mat const&, std::vector<int, std::allocator<int> > const&)' facedetect_noui.cpp:(.text+0x984): undefined reference to `cv::fastFree(void*)' facedetect_noui.cpp:(.text+0x990): undefined reference to `cv::fastFree(void*)' facedetect_noui.cpp:(.text+0x99c): undefined reference to `cv::fastFree(void*)' facedetect_noui.cpp:(.text+0xb50): undefined reference to `cv::fastFree(void*)' facedetect_noui.cpp:(.text+0xb5c): undefined reference to `cv::fastFree(void*)' /tmp/cc3Ejmow.o: In function `main': facedetect_noui.cpp:(.text+0xf24): undefined reference to `cv::CascadeClassifier::CascadeClassifier()' facedetect_noui.cpp:(.text+0xf2c): undefined reference to `cv::CascadeClassifier::CascadeClassifier()' facedetect_noui.cpp:(.text+0x1080): undefined reference to `cv::CascadeClassifier::load(std::basic_string<char, std::char_traits<char>, std::allocator<char> >...stripped-down
can you try: [root@localhost FYP]# arm-linux-g++ -O2 -I/usr/local/include/opencv facedetect_noui.cpp -L/root/Desktop/FYP/OpenCV-2.0.0/src/.libs -lcv -lhighgui -lcxcore -lml -lcvaux -lrt -lpthread -ldl -lz -lpng12 -ljpeg -o facedetect
Hi I successfully cross-compiled opencv and got 4 directories generated: include bin share lib As i am running qtopia 2.2 rootfs on my board, i copied contents of the above 4 directories to those in the board fs (for eg. bin to /bin of board) Is this ok? will it work this way or do I need to make the rootfs again? Also how to test whether the opencv is working or not? Tan
Hi, I am working on opencv.when i compile cpp programm for opencv i get In function `main': cameracapture.cpp:(.text+0x11): undefined reference to `cvCreateCameraCapture' cameracapture.cpp:(.text+0x65): undefined reference to `cvNamedWindow' cameracapture.cpp:(.text+0x74): undefined reference to `cvQueryFrame' cameracapture.cpp:(.text+0xbf): undefined reference to `cvShowImage' cameracapture.cpp:(.text+0xcb): undefined reference to `cvWaitKey' cameracapture.cpp:(.text+0xe7): undefined reference to `cvReleaseCapture' cameracapture.cpp:(.text+0xf3): undefined reference to `cvDestroyWindow' please help to solve this problem
hi, I have tried this coomand but it didn't work for me. arm-linux-g++ -O2 -I/usr/local/include/opencv cameracapture.cpp -L/root/Desktop/FYP/OpenCV-2.0.0/src/.libs -lcv -lhighgui -lcxcore -lml -lcvaux -lrt -lpthread -ldl -lz -lpng12 -ljpeg -o cameracapture Please help me Tushar
Hi Tushar, I got the same problem. Did you fix that? Please tell me how to resolve that problem. Thanks so much. Best Regards, Thang
Hi Thang u can refer this link https://www.youtube.com/watch?v=KYIb7g7o0O0
Hey, this is video i have using micro 2440 and openCV to tracking line. https://www.youtube.com/watch?v=TFR9rM1_mg8&list=UUaaQ_0uSE2PUpDHy5Z... Note: Micro 2440 use USB 1.1, not 2.0, thus, you must use webcam with usb 1.1.