This problem is not a DirectX problem at all, I do not know how such a reply online. And do not personally verify it. Here's a way to sort it out by spending a lot of time.
Because in general, the OPENCV that you configure to join the system environment variable is the bin under X86, so when you change the visual Stdio project to X64, of course, when the program is running, the problem occurs because the. exe cannot find the appropriate dynamic link library.
The workaround is to add the system environment variable to the Bin folder under your OpenCV X64. As the author of the computer when OpenCV 2410, the configuration will be
D:\Program Files\opencv\build\x64\vc11\bin
Added an environment variable. Quit Visual Studio, refresh, and then reopen the project to run it!
Ps:
Previously, only the bin X86 (D:\Program files\opencv\build\x86\vc11\bin) was added to the system environment variables. This is only valid for OPENCV, MFC projects under Win32.
summed up into a sentence, that is to do things can not copy copy, must go to think to solve the problem, or even the simple problem, it may let you get very upset, very tangled.
Reference articles
1. vs2010 OpenCV2.3 application fails to start normally, 26 floor
OpenCV 64-bit application does not start correctly 0x000007b problem resolution