OpenCV.exe - System Error

2019-09-20 22:33发布

I am running into some trouble while getting openccv to work in visual studio. I followed the instructions step by step from this tutorial OpenCV 3 Windows 10 Installation Tutorial - Part 1 - C++, but still ran into an issue. I get an OpenCV.exe - System Error that says the following: The program can't start because opencv_world320.dll is missing from your computer. Try reinstalling the program to fix this problem. I checked the PATH in command prompt and C:\OpenCV.3.2.0\opencv\build\x64\vc14\bin appears. I get the following in the Output:'OpenCV.exe' (Win32): Loaded 'C:\Users\tenicho\Documents\Visual Studio 2017\Projects\OpenCV\x64\Debug\OpenCV.exe'. Symbols loaded. 'OpenCV.exe' (Win32): Loaded 'C:\Windows\System32\ntdll.dll'. Cannot find or open the PDB file. 'OpenCV.exe' (Win32): Loaded 'C:\Windows\System32\kernel32.dll'. Cannot find or open the PDB file. 'OpenCV.exe' (Win32): Loaded 'C:\Windows\System32\KernelBase.dll'. Cannot find or open the PDB file. 'OpenCV.exe' (Win32): Loaded 'C:\Windows\System32\vcruntime140d.dll'. Cannot find or open the PDB file. 'OpenCV.exe' (Win32): Loaded 'C:\Windows\System32\msvcp140d.dll'. Cannot find or open the PDB file. 'OpenCV.exe' (Win32): Loaded 'C:\Windows\System32\ucrtbased.dll'. Cannot find or open the PDB file. The thread 0x2798 has exited with code -1073741515 (0xc0000135). The thread 0x182c has exited with code -1073741515 (0xc0000135). The thread 0x13f0 has exited with code -1073741515 (0xc0000135). The program '[9604] OpenCV.exe' has exited with code -1073741515 (0xc0000135) 'A dependent dll was not found'.

Here is a picture of the folder that the path leads to. You can see that the .dll file is there.enter image description here

Anyone have this issue?

Thank You in advance!

1条回答
劫难
2楼-- · 2019-09-20 23:08

My 32bit opencv_world dlls are missing...

Before you do the following, you should check in your opencv/bin/Release that opencv_world is not there. Your app is 32bits (according to the (Win32) in your debug log), so this folder should also be in your path. I'd also add the debug folder to the path as well.

If you cannot find the 32bits opencv_world.dll. Here's what I did, just now.

  1. Restart by opening the opencv-3.2/opencv/sources with cmake-gui.
  2. After running configure, make sure BUILD_open_cv_world is checked (it wasn't on my machine).
  3. Click Generate
  4. Click Open Project
  5. In Visual studio, select Build->Batch Build
  6. Select ALL_BUILD Debug + Release
  7. Click Build
  8. Be very patient...
  9. Be very very patient. Make yourself some tea or find something to do. :)
  10. There is probably a faster way to do this, but I don't know it. That's too bad, maybe unchecking every BUILD_ option and checking only BUILD_open_cv_world does it, but I didn't want to mess my open cv install. It's long enough to set up as it is.
  11. You should now have the dlls in your bin/release and bin/debug folders.
查看更多
登录 后发表回答