Setting up OpenCV 2.4.3 & Microsoft Visual Studio 2012 ( Win8 x64 ) - opencv

I want to configure opencv with Visual Studio 2012 on Windows 8 x64.
I configured opencv and there is no compilation errors, but when I execute my program I get this error :
The program can’t start because MSVCR100D.dll is missing from your
computer
I tried to install Visual C++ Redistributable for Visual Studio 2012 and Microsoft Visual C++ 2010 Redistributable Package (x64) but always the same error.

If it's still relevant, try this tutorial to create project and configure OpenCV directories:
http://karanjthakkar.wordpress.com/2012/11/21/usin-opencv-2-4-2-with-visual-studio-2012-on-windows-7-64-bit/
It worked for me on Windows 8 (x64) with Visual Studio 2012 and OpenCV 2.4.3.

After configuring the paths and libraries in Visual Studio as mentioned in http://karanjthakkar.wordpress.com/2012/11/21/usin-opencv-2-4-2-with-visual-studio-2012-on-windows-7-64-bit/ you need to install the Visual C++ Redistributable for Visual Studio 2012 from http://www.microsoft.com/en-us/download/details.aspx?id=30679
After restarting your PC, opencv code could be executed in Release mode. If you need to execute the code in Debug mode, then you would have to install the Redistributable version with "D".
This worked with Opencv 2.4.6, Windows 8.1 and VS 2012 Desktop.

Without having any experience with Windows 8 myself, I think this post could solve your problem.
Basically it says that the default system folder for Win 8 is c:\windows\system, unlike c:\windows\system32 on earlier systems. The redistributables probably install to the old system directory, so you have to move the dll to the correct folder manually.
You could also search the file on your PC and put it into the working folder of your program. This is in most cases the output folder, if you run it in Debug mode from VS it can also be the project folder.

Related

OpenCV with Visual Studio 2015 ( msvcr120d.dll error )

I have tried to link OpenCV with VS Express 2015 as I was doing in VS 2013 but I got msvcr120d.dll error. It says that this .dll was not found in my system.
Any Ideas of how I can link OpenCV with VS 2015 Express?
Prebuild Libs are only for VS11 and VS12 this is Visual studio 2012 and 2013. You can build and release your own OpenCV libs for Visual Studio 2015 comm. edition.
Just use this tutorial
Install OpenCV Visual Studio 2015
I managed to make the OpenCV Debug configuration working in Visual Studio 2015 Community Edition by installing Visual Studio 2013 Express on my system. As the result, the file msvcr120d.dll appeared in Windows\System32, and after the reboot of the computer I was able to debug OpenCV example in Visual Studio 2015.
Installed Visual Studio 2013 Community Edition on a different machine and then copied the dlls msvcp120d.dll and msvcr120d.dll into Windows\System32\ of my work machine. Worked a treat for opencv 2.4 x64 development.
This is not required for opencv 3+ as there are vs14 binaries available.
-- edit 23/8/16--
Not working so well, actually. Runtime errors arising in msvcr120d.dll when vectors containing opencv objects including Mat and KeyPoint are deconstructed, or are constructed using a large reserve.

Visual studio 2013 Build error on TFS

I use framework 4.5 and vs 2013 and TFS 2013. When I build project get error like that;
"C:\Program Files
(x86)\MSBuild\12.0\bin\amd64\Microsoft.Common.CurrentVersion.targets
(3079): Task could not find "AL.exe" using the SdkToolsPath "" or the
registry key "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft
SDKs\Windows\v8.1A\WinSDK-NetFx40Tools-x86". Make sure the
SdkToolsPath is set and the tool exists in the correct processor
specific location under the SdkToolsPath and that the Microsoft
Windows SDK is installed"
I tried everything but I could't fix error. Can you help me about it ?
Download and install the Windows Software Development Kit (SDK) for Windows 8.1. In the setup program, make sure .NET Framework 4.5.1 Software Development Kit is selected.
This will install al.exe to C:\Program Files (x86)\Microsoft SDKs\Windows\v8.1A\bin\NETFX 4.5.1 Tools.

Error messages about loading DDLs when starting WAMP server

I am receiving these error message when starting WAMP server:
and
How can I fix the problems?
Based on the message your dll files either are missing or are damaged. Your best bet is to reinstall WampServer.
Try to re-install wamp, but do install first this one
http://www.microsoft.com/en-ph/download/details.aspx?id=30679
In the wamp website it was stated that you must install the vcredist_x64/86.exe
Stated here : http://www.wampserver.com/en/#download-wrapper
As #reignsly said, it looks like you did not download and install the Microsoft Visual C++ 2010 SP1 Redistributable Package.
Please make sure you have the latest version of all of these Microsoft C/C++ Redistributable runtime libraries. You dont need the whole compiler, just these C/C++ runtime libraries.
FOR WAMPServer 32bit
Microsoft Visual C++ 2008 SP1 Redistributable Package (x86)
Microsoft Visual C++ 2010 SP1 Redistributable Package (x86)
If you are using WampServer 2.4 or 2.5 32bit and therefore Apache 2.4.x
Microsoft Visual C++ 2012 is required And select vcredist_x86.exe
FOR WAMPServer 64bit
Microsoft Visual C++ 2008 SP1 Redistributable Package (x86)
Yes you need the x86 Package regardless as
wampmanager is a 32bit exe even on a 64 bit install
Microsoft Visual C++ 2008 Redistributable Package (x64)
Microsoft Visual C++ 2010 SP1 Redistributable Package (x64)
If you are using WampServer 2.4 64bit
Microsoft Visual C++ 2010 SP1 Redistributable Package And select vcredist_x64.exe
Warning: The naming convention used for the redist install files is a bit confusing, so download one, install it, then download the next and install it.... otherwwise you will get confused.
Once they are installed your 'Programs and Features' should look something like this :-
32bit systems
64bit systems
The Unable to load dll issue is simply fixed by getting WAMPServer to refresh the SYMLINKS in the ...\apache2.4.9\bin folder
Do this as follows using the Wampmanager menus :-
left click wampmanager -> Apache -> Version
and click on the version number, probably 2.4.9
It takes a couple of second to complete and you wont notice anything going on, but the php_intl error should be solved.

Why can't I start WampServer in Windows 2003 server sp2?

here is a problem I meet. I download and installed WampServer, it could not be started. After clicking, it started without any error message but ended immediately because
there was an WampServer icon in the right-down corner (just besides input icon and time) and disappeared within less than 1 second automatically. No process of wamp can be found when using ctrl+alt+del.
I suppose there is no problem in wampserver software itself since it can be installed in other computers successfully. Previous searching indicated I need to install visual C++ 2008 and 2010 but it seems still the same.
I am going crazy about this for a few days. Many thanks for you if there can be any suggestion or some similar cases.
Please make sure you have the latest version of all of these Microsoft C/C++ Redistributable runtime libraries. You dont need the whole compiler, just these C/C++ runtime libraries.
The 2008 Redist (32bit) is used by wampmanager even if you installed the 64bit WAMPServer.
The 2010 Redist is used by some versions of Apache ( depending on compiler used ).
The 2012 Redist is used by some versions of Apache ( depending on compiler used ).
FOR WAMP 32bit
Microsoft Visual C++ 2008 SP1 Redistributable Package (x86)
Microsoft Visual C++ 2010 SP1 Redistributable Package (x86)
If you are using WampServer2.4/2.5 32bit and therefore Apache 2.4.x
Microsoft Visual C++ 2012 is required
And select vcredist_x86.exe
FOR WAMP 64bit
Microsoft Visual C++ 2008 SP1 Redistributable Package (x86)
>> Yes you need the x86 Package regardless as wampmanager uses this <<
Microsoft Visual C++ 2008 Redistributable Package (x64)
Microsoft Visual C++ 2010 SP1 Redistributable Package (x64)
If you are using WampServer2.4/2.5 64bit
Microsoft Visual C++ 2012
And select vcredist_x64.exe
the authors state directly on the download page (http://www.wampserver.com/en/):
Wampserver 2.5 is not compatible with Windows XP, neither with SP3,
nor Windows Server 2003
When I tried it, during the install I get the odd, cryptic error popups such as "bin\apache\apache2.4.9\bin\httpd.exe is not a valid Win32 application".
I would recommend doing the manual approach for Win2K3 platforms - sure it's a lot more work, but you can follow an excellent, precise step-by-step recipe here:
http://www.ricocheting.com/how-to-install-on-windows/apache
I've done this approach a dozen times with no complications. If you've never done the "old school way" before, it's a good learning experience. And it would probably be a lot faster overall than struggling with trying to get WampServer working on Win2K3 OS.
Note that in both cases, you'll still need to first install VC 2008 redistributable package (as mentioned above).

How to install XNA game studio on Visual Studio 2012?

Is it possible to create XNA games using Visual Studio 2012?
Yes, it's possible with a bit of tweak. Unfortunately, you still have to have VS 2010 installed.
First, install XNA Game Studio 4.0. The easiest way is to install the Windows Phone SDK 7.1 which contains everything required.
Copy the XNA Game Extension from VS 10 to VS 11 by opening a command prompt 'as administrator' and executing the following (may vary if not x64 computer with defaults paths) :
xcopy /e "C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\Extensions\Microsoft\XNA Game Studio 4.0" "C:\Program Files (x86)\Microsoft Visual Studio 11.0\Common7\IDE\Extensions\Microsoft\XNA Game Studio 4.0"
Run notepad as administrator then open extension.vsixmanifest in the destination directory just created.
Upgrade the Supported product version to match the new version (or duplicate the whole VisualStudio element and change the Version attribute, as #brainslugs83 said in comments):
<SupportedProducts>
<VisualStudio Version="11.0">
<Edition>VSTS</Edition>
<Edition>VSTD</Edition>
<Edition>Pro</Edition>
<Edition>VCSExpress</Edition>
<Edition>VPDExpress</Edition>
</VisualStudio>
</SupportedProducts>
Don't forget to clear/delete your cache in %localappdata%\Microsoft\VisualStudio\12.0\Extensions.
You may have to run the command to tells Visual Studio that new extensions are available. If you see an 'access denied' message, try launching the console as an administrator.
"C:\Program Files (x86)\Microsoft Visual Studio 11.0\Common7\IDE\devenv.exe" /setup
This has been tested for Windows Games, but not WP7 or Xbox games.
[Edit] According Jowsty, this works also for XBox 360 Games.
[Edit for Visual Studio 2013 & Windows 8.1] See here for documentation on installing Windows Phone SDK 7.1 on Windows 8.1. Use VS version number 12.0 in place of 11.0 for all of these steps, and they will still work correctly.
On codeplex was released new XNA Extension for Visual Studio 2012/2013. You can download it from: https://msxna.codeplex.com/releases
I found another issue, for some reason if the extensions are cached in the local AppData folder, the XNA extensions never get loaded.
You need to remove the files extensionSdks.en-US.cache and extensions.en-US.cache from the %LocalAppData%\Microsoft\VisualStudio\11.0\Extensions folder. These files are rebuilt the next time you launch
If you need access to the Visual Studio startup log to debug what's happening, run devenv.exe /log command from the C:\Program Files (x86)\Microsoft Visual Studio 11.0\Common7\IDE directory (assuming you are on a 64 bit machine). The log file generated is located here:
%AppData%\Microsoft\VisualStudio\11.0\ActivityLog.xml
There seems to be some confusion over how to get this set up for the Express version specifically. Using the Windows Desktop (WD) version of VS Express 2012, I followed the instructions in Steve B's and Rick Martin's answers with the modifications below.
In step 2 rather than copying to "C:\Program Files (x86)\Microsoft Visual Studio 11.0\Common7\IDE\Extensions\Microsoft\XNA Game Studio 4.0", copy to "C:\Program Files (x86)\Microsoft Visual Studio 11.0\Common7\IDE\WDExpressExtensions\Microsoft\XNA Game Studio 4.0"
In step 4, after making the changes also add the line <Edition>WDExpress</Edition> (you should be able to see where it makes sense)
In step 5, replace devenv.exe with WDExpress.exe
In Rick Martin's step, replace "%LocalAppData%\Microsoft\VisualStudio\11.0\Extensions" with "%LocalAppData%\Microsoft\WDExpress\11.0\Extensions"
I haven't done a lot of work since then, but I did manage to create a new game project and it seems fine so far.

Resources