Friday, June 17, 2011

some errors.

________________________________________________________________________________
Prob:
1>c:\program files (x86)\microsoft visual studio 10.0\vc\include\stdlib.h(353): error C2381: 'exit' : redefinition; __declspec(noreturn) differs
1>          c:\program files (x86)\microsoft visual studio 10.0\vc\include\gl\glut.h(146) : see declaration of 'exit'

Sol:
Reorder the includes.

#include <stdlib.h>
#include <GL/glut.h>


________________________________________________________________________________
Prob:
1>c:\program files (x86)\microsoft visual studio 10.0\vc\include\gl\glew.h(84): fatal error C1189: #error :  gl.h included before glew.h

Sol:
Reorder the includes.
#include <GL/glew.h>
#include <GL/glut.h>


________________________________________________________________________________
Prob:
Depending on glEnable(GL_DEPTH_TEST);





________________________________________________________________________________
Prob:
Shouldn't I use 0 for the 'near' value of glPerspective(45, ratio, 0, 1000) ?

1 comment: