#define GLEW_STATIC
#define GLEW_STATIC
#define GLEW_STATIC
#define GLEW_STATIC
#define GLEW_STATIC
#include < GL/glew.h>
#include < GLFW/glfw3.h>
#include
# pragma comment (lib, “glew32. Lib”)
int main() {
glfwInit();
glfwWindowHint(GLFW_CONTEXT_VERSION_MAJOR, 3);
glfwWindowHint(GLFW_CONTEXT_VERSION_MINOR, 3);
glfwWindowHint(GLFW_OPENGL_PROFILE, GLFW_OPENGL_CORE_PROFILE);
// Open GLFW Window
GLFWwindow* window = glfwCreateWindow(800, 600, "My OpenGL Game", NULL, NULL);
if (window == NULL)
{
printf("open window failed");
glfwTerminate();
return -1;
}
glfwMakeContextCurrent(window);
// Init GLEW
GLboolean glewExperimental = true;
if (glewInit() != GLEW_OK)
{
printf("init GLEW failed");
glfwTerminate();
return -1;
}
glViewport(0, 0, 800, 600);
while (!glfwWindowShouldClose(window))
{
glfwSwapBuffers(window);
glfwPollEvents();
}
glfwTerminate();
return 0;
}
Glew32.dll
1
1
1
1
1
1
br>
> You need to enter the C disk with admin privileges, then put a copy of glew32.dll into C:\Windows\SysWOW64, the problem is fixed, the window appears
Read More:
- Vs2013 + glfw + glew configure OpenGL development environment
- Vs2015 configuring OpenGL (glfw, glew)
- (64 bit) OpenGL configuration + vs2017 + glew + glfw
- The solution of configuring OpenGL in vs2017
- Simple configuration of glfw + glad in vs2015 OpenGL development environment
- Configuring OpenGL in Chinese version of VS2010 and problem solving
- OpenGL program running prompt glut32.dll missing problem
- Vs2015 OpenGL environment configuration
- Visual studio 2017, OpenGL program running prompt glut32.dll missing solution
- Configuring OpenGL + glew in windows10 + Visual Studio 2017
- Solution to the problem of unable to open glaux. H in vs2013
- Solving CodeBlocks OpenGL glew undefined reference to`_ imp__ Glewinit ‘error
- Configuration of OpenGL development environment under Windows environment, win10 + vs2019 + glfw + glad
- 1 vs20152017 + OpenGL to configure and draw a white rectangle
- Solution to the problem of console flash in vs2017 runtime
- Vs compiling OpenGL project, the solution of unable to open the source file “GL / glaux. H” appears
- Problems encountered in vs2015 configuration using OpenGL environment
- Lost in computer OPENGL.dll
- The simplest course of configuring OpenGL in vs2015
- OpenGL environment configuration under VS2010 / vs2012 / vs2015