When developing an OpenGL project, an error like the one shown in the figure can occur in the VS development environment.
OpenGL32.dll exists in the C :\ Windowssystem32 and SysWow64 folders. The program will compile normally, but will be prompted as soon as the program is running
“Could not start this program because OpenGL. DLL is missing from your computer. Try reinstalling the program to fix the problem.”
This is mainly due to the reference to both the static libraries “Glut.lib” and “Glut32.lib”.
That is, in the project ->; Property – & gt; Configure properties ->; The linker – & gt; Glut.Lib and Glut32.Lib are added to the attached dependencies, and Glut.DLL comes first, glut32.DLL comes second, so the linker first looks for OpenGl32.DLL instead of OpenGL32.DLL.
In addition, if you want to reproduce this error in VS, you need to rebuild the project after configuring the additional dependencies.
OpenGL32.dll exists in the C :\ Windowssystem32 and SysWow64 folders. The program will compile normally, but will be prompted as soon as the program is running
“Could not start this program because OpenGL. DLL is missing from your computer. Try reinstalling the program to fix the problem.”
This is mainly due to the reference to both the static libraries “Glut.lib” and “Glut32.lib”.
That is, in the project ->; Property – & gt; Configure properties ->; The linker – & gt; Glut.Lib and Glut32.Lib are added to the attached dependencies, and Glut.DLL comes first, glut32.DLL comes second, so the linker first looks for OpenGl32.DLL instead of OpenGL32.DLL.
In addition, if you want to reproduce this error in VS, you need to rebuild the project after configuring the additional dependencies.
Read More:
- Vs compiling OpenGL project, the solution of unable to open the source file “GL / glaux. H” appears
- Vc2010 configuring OpenGL environment
- The solution of configuring OpenGL in vs2017
- Configuring OpenGL in Chinese version of VS2010 and problem solving
- Solve the problem of VC6.0 open crash and OpenGL glut32.lib library
- Small problems encountered in compiling OpenGL under VS2010
- Configure OpenGL in CodeBlocks
- OpenGL learning notes: Problems and Solutions
- OpenGL environment configuration
- Using glut in CodeBlocks
- Summary of problems encountered in compiling opengl code
- Solution of VS2008 unable to open GL / glaux. H header file
- Vs2019 nuget configuring OpenGL
- Configuring OpenGL in Code:: blocks
- The simplest way to configure OpenGL development environment with vs2015
- Problems encountered in running OpenGL
- Configure OpenGL development environment (vs2015)
- Opencv: the application can’t start normally
- Error: unable to open include file: ‘GL / glut. H’
- Error in header file when calling OpenGL to open obj file in vs2013: unable to open include file: “GL / glut. H”: no such file or directories