PDA

View Full Version : Glew not installed correctly



PascalM123
08-19-2010, 01:06 PM
Dear forum,

In order to use GLSL, I need glew, but glew is not working correctly. I've installed all packages (libglew1.5-dev etc.etc.), linked glew at compilation (-lGLEW), included glew before gl.h etc.etc., but when I do glewInit(), the function does not return GLEW_OK and the first function in my program that uses glew is glCompileShader and that turns into a segmentation fault.

Do you know what is going wrong?

Regards,
PascalM123

Rosario Leonardi
08-20-2010, 05:59 AM
if the program compile and the linker is not complaining then you have installed glew correcly (or maybe you only have an old version).

Did you call glewInit after you have a valid context?

PascalM123
08-20-2010, 08:52 AM
I knew it would be something silly. I called glewInit after glutInit, but before the other glut-commands, so that was the problem.

Thanks for your help!