c++ - Error loading GLEW library (error LNK2001) -


i install glew library visual studio:
x64/bin/glew32.dll %systemroot%/system32
x64/lib/glew32.lib {vc root}/lib
include/gl/glew.h {vc root}/include/gl
include/gl/wglew.h {vc root}/include/gl

and add library in linker > input: glew32.lib , write #pragma comment

#pragma comment(lib, "opengl32.lib") #pragma comment(lib, "glu32.lib") #pragma comment(lib, "glut32.lib") #pragma comment(lib, "glew32.lib")  #include <iostream> #include <windows.h> #include <glew.h> #include <glut.h> 

but visual studio continues write error:

1>core.obj : error lnk2001: unresolved external symbol __imp____glewbindvertexarray 1>core.obj : error lnk2001: unresolved external symbol __imp____glewgenvertexarrays 

you're missing glew (the opengl extension wrangler library). can link in following pragma somewhere in source code:

#pragma comment(lib, "glew32.lib") 

or can modify linker flags in project settings. assumes have glew library installed. on system, installed @ following path:

c:\program files (x86)/microsoft visual studio 10.0/vc/lib/glew32.lib 

the path may different on system, , there other ways of linking glew if don't want install it.


Comments

Popular posts from this blog

python - Specify path of savefig with pylab or matplotlib -

How to run C# code using mono without Xamarin in Android? -

c# - SharpSsh Command Execution -