Ask Your Question

Riddle Aaron's profile - activity

2021-01-04 08:46:21 -0600 received badge  Famous Question (source)
2020-09-28 13:10:18 -0600 received badge  Student (source)
2020-03-30 00:45:35 -0600 received badge  Notable Question (source)
2019-10-18 22:46:12 -0600 received badge  Popular Question (source)
2018-11-24 23:06:29 -0600 marked best answer Is CV_FILLED removed in 4.0.0?

After I update OpenCV from 3.2.0 to 4.0.0, I can't use CV_FILLED because it complains that it is undefined. Was it removed? Or am I just missing something?

2018-11-24 09:43:31 -0600 commented answer Is CV_FILLED removed in 4.0.0?

Where are those constants? I can't find them in opencv2/core.hpp

2018-11-24 02:15:14 -0600 asked a question Is CV_FILLED removed in 4.0.0?

Is CV_FILLED removed in 4.0.0? After I update OpenCV from 3.2.0 to 4.0.0, I can't use CV_FILLED because it complains tha

2018-11-11 22:59:58 -0600 commented question Opencv_highgui seems that it can't find all the Qt libs.

@berak I tried building it with 5.3.0 32bit MinGW (which was bundled with Qt) and I get the error which I got a long ago

2018-11-11 22:59:47 -0600 commented question Opencv_highgui seems that it can't find all the Qt libs.

@berak I tried building it with 5.3.0 32bit MinGW (which was bundled with Qt) and I get the error which I got a long ago

2018-11-11 19:27:28 -0600 commented question Opencv_highgui seems that it can't find all the Qt libs.

@berak I tried building it with 5.3.0 32bit MinGW (which was bundled with Qt) and I get the error which I got a long ago

2018-11-11 19:26:57 -0600 commented question Opencv_highgui seems that it can't find all the Qt libs.

@berak I tried building it with 5.3.0 32bit MinGW (which was bundled with Qt) and I get the error which I got a long ago

2018-11-11 11:09:01 -0600 commented question Opencv_highgui seems that it can't find all the Qt libs.

@berak Yes. I suspect that this is related to 32bit - 64bit problem of Qt. Thanks for answering!

2018-11-11 10:34:24 -0600 commented question Opencv_highgui seems that it can't find all the Qt libs.

@berak Hmmm... very strange. There's no error if I try the one you mentioned.

2018-11-11 09:59:37 -0600 commented question Opencv_highgui seems that it can't find all the Qt libs.

I got the "pei" information using "objdump -a" command. And the error occurs when I compile the program on Qt Creator. A

2018-11-11 09:40:39 -0600 commented question Opencv_highgui seems that it can't find all the Qt libs.

@berak It is built successfully if I uncheck "with qt" option. But I face another problem. When I compile the program, a

2018-11-11 09:39:32 -0600 commented question Opencv_highgui seems that it can't find all the Qt libs.

@berak It is built successfully if I uncheck "with qt" option. But I face another problem. When I compile the program, a

2018-11-11 09:39:17 -0600 commented question Opencv_highgui seems that it can't find all the Qt libs.

@berak It is built successfully if I uncheck "with qt" option. But I face another problem. When I compile the program, a

2018-11-11 09:39:04 -0600 commented question Opencv_highgui seems that it can't find all the Qt libs.

@berak It is built successfully if I uncheck "with qt" option. But I face another problem. When I compile the program, a

2018-11-11 07:02:44 -0600 commented question Opencv_highgui seems that it can't find all the Qt libs.

@berak I'm using MinGW 7.2.0 for both. I'll try building it without Qt then.

2018-11-10 06:56:08 -0600 asked a question Opencv_highgui seems that it can't find all the Qt libs.

Opencv_highgui seems that it can't find all the Qt libs. While the opencv_highgui was being built during building of the

2018-11-10 06:52:30 -0600 marked best answer Only Cascade classifier makes an undefined error

This is a libs part of Qt pro file

LIBS += -LD:/opencv-build/bin/ -llibopencv_core320
LIBS += -LD:/opencv-build/bin/ -llibopencv_highgui320
LIBS += -LD:/opencv-build/bin/ -llibopencv_imgcodecs320
LIBS += -LD:/opencv-build/bin/ -llibopencv_imgproc320
LIBS += -LD:/opencv-build/bin/ -llibopencv_features2d320
LIBS += -LD:/opencv-build/bin/ -llibopencv_calib3d320
LIBS += -LD:/opencv-build/bin/ -llibopencv_videoio320
LIBS += -LD:/opencv-build/bin/ -llibopencv_video320

And this is a code (The only part that uses CascadeClassifier).

cv::String faceCascade = ":/resources/haarcascade_frontalface_alt.xml";
cv::String eyeCascade = ":/resources/haarcascade_eye.xml";
CascadeClassifier faceClassifier;
CascadeClassifier eyeClassifier;

Mat Tracker::detectEyes(Mat& img){
    Mat gray;
    Mat result;
    faceClassifier.load(faceCascade);
    eyeClassifier.load(eyeCascade);
    cvtColor(img, gray, CV_BGR2GRAY);
    std::vector<Rect> face_pos;
    faceClassifier.detectMultiScale(gray, face_pos, 1.1, 3, 0 | CV_HAAR_SCALE_IMAGE, Size(10, 10));
    for (int i = 0; i < static_cast<int>(face_pos.size()); i++)    {
        rectangle(result, face_pos[i], Scalar(0, 255, 0), 2);
    }
    for (int i = 0; i < static_cast<int>(face_pos.size()); i++) {
        std::vector<Rect> eye_pos;
        Mat roi = gray(face_pos[i]);
        eyeClassifier.detectMultiScale(roi, eye_pos, 1.1, 3, 0 | CV_HAAR_SCALE_IMAGE, Size(10, 10));
        for (int j = 0; j < static_cast<int>(face_pos.size()); j++) {
            Point center(face_pos[i].x + eye_pos[j].x + (eye_pos[j].width / 2),
                       face_pos[i].y + eye_pos[j].y + (eye_pos[j].height / 2));
            int radius = cvRound((eye_pos[j].width + eye_pos[j].height) * 0.2);
            circle(result, center, radius, Scalar(0, 0, 255), 2);
        }
    }
    return result;
}

And everything related to CascadeClassifier makes an error.

C:\Users\Coder\Desktop\qt\tracker.cpp:37: error: undefined reference to `cv::CascadeClassifier::load(cv::String const&)'
C:\Users\Coder\Desktop\qt\tracker.cpp:38: error: undefined reference to `cv::CascadeClassifier::load(cv::String const&)'
C:\Users\Coder\Desktop\qt\tracker.cpp:217: error: undefined reference to `cv::CascadeClassifier::detectMultiScale(cv::_InputArray const&, std::vector<cv::Rect_<int>, std::allocator<cv::Rect_<int> > >&, double, int, int, cv::Size_<int>, cv::Size_<int>)'
C:\Users\Coder\Desktop\qt\tracker.cpp:224: error: undefined reference to `cv::CascadeClassifier::detectMultiScale(cv::_InputArray const&, std::vector<cv::Rect_<int>, std::allocator<cv::Rect_<int> > >&, double, int, int, cv::Size_<int>, cv::Size_<int>)'
C:\Users\Coder\Desktop\qt\tracker.cpp:15: error: undefined reference to `cv::CascadeClassifier::~CascadeClassifier()'
C:\Users\Coder\Desktop\qt\tracker.cpp:16: error: undefined reference to `cv::CascadeClassifier::~CascadeClassifier()'
C:\Users\Coder\Desktop\qt\tracker.cpp:15: error: undefined reference to `cv::CascadeClassifier::CascadeClassifier()'
C:\Users\Coder\Desktop\qt\tracker.cpp:16: error: undefined reference to `cv::CascadeClassifier::CascadeClassifier()'

The important thing is, all the other OpenCV classes work fine. Am I missing libs related to CascadeClassifier?

2018-11-10 06:52:30 -0600 received badge  Scholar (source)
2018-10-13 11:06:00 -0600 asked a question Only Cascade classifier makes an undefined error

Only Cascade classifier makes an undefined error This is a libs part of Qt pro file LIBS += -LD:/opencv-build/bin/ -lli