Ask Your Question

Y.S's profile - activity

2015-08-26 15:36:15 -0600 commented answer Cannot get opencv 3.0 to work

Thanks for the answers! It seems that indeed VC12 is destined to work only with visual studio 2013, so I changed the path to VC11. Also, as suggested, I had to change, in the configuration manager, the target platform to be x64 instead of win32.

After that I found out that the program cannot be executed in debug mode (since as I understand, the debug mode at this time is not distributable...?) So I had to do anything that was suggested but in release mode and then it finally worked. Thanks!

2015-08-25 11:45:06 -0600 received badge  Student (source)
2015-08-25 00:24:20 -0600 asked a question Cannot get opencv 3.0 to work

Hi, I have a fatal unresolved external error when I'm trying to compile programs in opencv 3.0.0. Now I know that this question was asked many times but my problem is specific.

  • I installed opencv 3.0.0 in the "C:\" directory.
  • I created an empty project in Visual Studio 2012 (win32 console application).
  • I entered into the properties of the project's solution, and added the directory "C:\opencv\build\include" in "Additional Include Directories".
  • In the Linker, I added the directory "C:\opencv\build\x64\vc12\lib" in "Additional Library Directories" (I'm working with a 64-bit operating system). Then I added the files "opencv_ts300d.lib" and "opencv_world300d.lib" in "Additional Dependencies" (I'm working only in debug mode).

As far as I know these are the steps needed in order to run programs in opencv 3.0.0. But when I wrote the following code

include "opencv2\core\core.hpp"

include "opencv2\highgui\highgui.hpp"

using namespace cv;

void main()

{

    Mat img = imread("C:/BlackWhite.jpg", CV_LOAD_IMAGE_UNCHANGED);
    getchar();

}

I get an unresolved external for the function "imread". Why is that? Please I will be grateful for any answer I can get. Thanks in advance.