Configuring OpenGL development environment in win10 + vs2015 (including the method of installing 32-bit and 64 bit libraries)

In order to learn OpenGL, I wanted to configure both 32-bit and 64-bit development environments in VS, but I didn’t find a solution to this problem on the web. Maybe everyone knows that, so I don’t think it’s a problem… I was suffering from one night and one morning, make a headache, asked the teacher, the method does not work, finally is their own try out, remember this, for other small white point of reference, the following began to systematically introduce the configuration process)
Here’s the file I packed. The Glew library (which has been compiled) can also be downloaded from the official website. I have also given the download address of the official website in the following content.
A, OpenGL library
1. The GLUT libraries

GLUT (OpenGL Utility Toolkit) is a cross-platform tool library that can only be used under Win32, does not provide a 64-bit development environment, and has not been updated since 1998
2. Freeglut library
This library, a modification of the original GLUT library, provides both 32-bit and 64-bit build environments, and is better maintained.
3. The GLEW libraries
Glew (OpenGL Extension Wrangler) is another helper library.
II. Configuration process
1. Configuration of the FreeGLUT library

Download link

Freeglut freeglut 3.0.0 (download you need to download other versions into freeglut version)

OpenGL + VS2015 + Win10 64-bit development environment configuration. OpenGL + VS2015 + Win10 64-bit development environment configuration. OpenGL + VS2015 + Win10

I just want to add two caveats

When using CMAKE to extract a FreeGlut, Configure

32-bit pick 64 choose

store 32-bit generated file folder named freeglut – x86 (can be any name, here only to illustrate behind)
store 32-bit generated file folder named freeglut – x64

SLN generates the solution in the x64 environment in debug mode and release mode respectively.

SLN generates the solution in the x86 environment in debug mode and release mode, respectively
2, 32-bit and 64-bit environment configuration focus!!

32 –

    under the installation path of VS2015 the include file to create a new GL folder will download freeglut – 3.0.0 freeglut 3.0.0 \ freeglut – 3.0.0/include/GL. H header file
    in the C: \ Program Files \ Microsoft Visual Studio (x86) 14.0\VC\ Include \GL (that is, the GL folder created in step 1)
    Put the FreeGlutd. DLL in FreeGlut-x86 \bin\Debug and the FreeGlut-x86 \bin\Release FreeGlut. DLL
    C:\Program Files (x86)\Microsoft Visual Studio
    in 14.0\VC\bin (you may find that the names of the two DLLs are different) Put the.lib file
    FreeGlut-x86\ lib and in RealEase

i>: \Program Files (x86)\Microsoft Visual Studio 14.0\VC\lib

64

    Put the FreeGlutd. DLL from FreeGlut-x64 \bin\Debug and the FreeGlut-x64 \bin\Release FreeGlut. DLL
    C: Program Files (x86)\Microsoft Visual Studio VC 14.0 \ \ bin \ amd64
    will freeglut – x64 \ lib in the Debug and Realease..lib file
    in the C: \ Program Files \ Microsoft Visual Studio (x86) in VC 14.0 \ \ lib \ amd64 note: 32-bit and 64 – bit libraries. H header file is the same as

So now the FreeGLUT library is configured

2. Configuration of GLEW library

2.1 Download and compile source code

Download link

GLEW GLEW – 2.1.0. Zip

Unzip and open glew.sln in glew-2.1.0\glew-2.1.0\build\vc12

The solution is generated in Debug mode in x86 environment, and the 32-bit Debug library is obtained. Generate the solution in Release mode in x86 environment, and get the 32-bit Release library; Build the solution under Debug mode in x64 environment, and get 64-bit Debug library; Generate the solution in Release mode in the x64 environment, resulting in a 64-bit Release library.

2.2 configuration GLEW32 a

    will glew – 2.1.0 \ glew – 2.1.0 \ include \ GL. H header file
    in the C: \ Program Files \ Microsoft Visual Studio (x86) in VC 14.0 \ \ include \ GL

    will
    Glew 2.1.0 \ glew – 2.1.0 \ bin \ Debug \ Win32
    Glew32d. DLL and

    Glew 2.1.0 \ glew – 2.1.0 \ bin \ Release \ Win32
    glew32.dll
    In C: \ Program Files \ Microsoft Visual Studio (x86)
    in the VC 14.0 \ \ bin to glew 2.1.0 \ glew – 2.1.0 \ lib \ Debug \ Win32 2. Under the lib Files and
    glew 2.1.0 \ glew – 2.1.0 \ lib \ Release 2 \ Win32..lib file
    in the C: \ Program Files (x86)\Microsoft Visual Studio 14.0\VC\lib

    64-bit

      will
      Glew 2.1.0 \ glew – 2.1.0 \ bin \ Debug \ x64
      Glew32d. DLL and

      Glew 2.1.0 \ glew – 2.1.0 \ bin \ Release \ x64
      glew32.dll
      In C: \ Program Files \ Microsoft Visual Studio (x86) VC 14.0 \ \ bin \ amd64
      will glew 2.1.0 \ glew – 2.1.0 \ lib \ Debug \ x64 2. Under the lib Files and
      glew 2.1.0 \ glew – 2.1.0 \ lib \ Release \ x64 under 2..lib file
      in the C: \ Program Files (x86)\Microsoft Visual Studio 14.0\VC\ Lib \ AMD64

So far, it is done ~

Put 32-bit DLLs and lib files in the corresponding VS folder, and 64-bit DLLs and lib files in the corresponding VS folder \amd64
if you think these compilation or configuration steps special trouble, you can see my another article, one minute can be configured to start OpenGL programming. (I’ll write another day.)

Read More: