
- #Download code blocks for windows 7 64 bit how to#
- #Download code blocks for windows 7 64 bit install#
Open cmake and select C:\opencv as the source directory and C:\opencv\build\x86\mingw as the directory to build the binaries (you could select any directory but choosing this one will overwrite the pre-built OpenCV binaries and then theĬlick configure, choose minGW makefiles wait and then click generate.
#Download code blocks for windows 7 64 bit install#
I still prefer MinGW to other compilers on windows (well actually I prefer Linux, see above) and I hope this tutorial will continue to be useful.įirst you’ll need to download and install cmake
#Download code blocks for windows 7 64 bit how to#
I’ve been talking to the OpenCV devs about some of the issues people (and me) have been having with the latest pre-built binaries, what you need to know is they are discontinuing pre-built binaries for MinGW. From now on you will have to build your own, I have included instructions for how to make your own binaries and it’s pretty straight forward. If you’ve already tried and had issues or if you need to build OpenCV with custom configuration then continue with the next section. If this is your first time through the tutorial check if the supplied pre-built binaries will work for you and skip the next section.

OpenCV is now installed – but not configured with Code::Blocks

OpenCV is a library of Computer Vision functions. Head to their website and download the latest version (2.4.2 for Windows)Ĭlick on the OpenCV-2.4.2.exe and choose C:\ as the extract directory If you like now might be a good time to test your Code::Blocks and MinGW setup with a simple Hello World C++ program. Under the Toolchain Executables select GNU GCC Compiler from the drop down and then press AutoDetect Then go to Settings -> Compiler and Debugger When the installer is finished click yes to run Code::Blocks Programs will need to be restarted for this change to take effect.Ĭode::Blocks is an IDE (integrated development environment). Head to their website and download the latest version ( at the time of writing) Type a semi colon after the last entry in path and then paste your MinGW path (it should be C:\MinGW\bin if you chose the default location).Īfterwords open up a command prompt and type path to make sure it worked (you should see minGW somewhere in the print out, probably near or at the end). Navigate to Control Panel -> System -> Advanced System Settings and then: įrom the options install mingw32-base and mingw32-gcc-g++`, you can also install the other components if you wish, but all you need is the c++ compiler (g++).

MinGW is a c/c++ compiler for windows, head to their website and download the latest version. You’re obviously interested in open source or you wouldn’t be here - so I’m telling you to take the plunge, go all in, close this tab and grab an image of Ubuntu or Mint if you want to be just like me and become enlightened! Linux is quite often the first priority for developers of open source tools and windows support is sometimes an after thought. I also personally recommend staying away from IDEs. and using Linux is the best way to see and learn how this works. Most people I know barely understand setting up their own C++ projects and linking to 3rd party libraries etc.

Why should you use Linux? There’s a lot of reasons in my opinion but right now I am going to keep it simple. Much to my dismay this tutorial is by far the most visited page on my website, why does this upset me? It upsets me because as glad as I am to see people using open source tools like OpenCV and MinGW rather than proprietary or commercial alternatives I feel strongly that developers should be using Linux not Windows for coding, especially for C++.
