Exodus to OpenCV 4 issues

asked 2019-09-25 04:03:58 -0600

Vizier87 gravatar image

Hi guys,

I have managed to initialize my OpenCV 4 using VS2019 pretty ok. Got a blank Mat to show for it.

When I was just trying to import my old code from OpenCV 3, the issue is unclear to me where I should be looking into.

Here's a simple code in OpenCV 3 which has always worked fine for me (and I included ALL the debug libraries in the additional dependencies):

int main()
{
    // Disable OpenCL explicitly here
    cout << CV_VERSION;

    //ocl::setUseOpenCL(false);
    cv::VideoCapture capture(0);
    Mat current_frame;


    capture >> current_frame;

    while (1) {
        capture >> current_frame;
        if (current_frame.empty()) break;
        imshow("Normal", current_frame);
        int key = waitKey(33) && 0xFF;
        if (key == 27) break;
    }
    return 0;

}

And I got this error.

Severity Code Description Project File Line Suppression State Warning C26495 Variable 'cvflann::lsh::LshStats::bucket_size_max_' is uninitialized. Always initialize a member variable (type.6). OpenCV Test C:\OpenCV\OpenCV build\install\include\opencv2\flann\lsh_table.h 94

I'd appreciate it if someone can point me in the right direction here. Perhaps I'm using old API?

Thanks. Vizier87

edit retag flag offensive close merge delete

Comments

It's not an error it's a warning; you can run your program? there is no line 94, it's a comment. Which version did you use ?

LBerger gravatar imageLBerger ( 2019-09-25 04:16:51 -0600 )edit