Hello guys,
Is:
int InitGL{
}
is like:
int main(){
}
Sean Middleditch – Game Systems Engineer – Join my team!
"int initGL{ }" is illegal C code.
If you meant "int initGL(){ }", then that's just a regular plain ol' function definition.
If the original spelling is correct (no parenthesis) from wherever you copied the source, then initGL is some non-standard macro specific to that source code. It's not standard to C or to OpenGL.
Ohh you are right, I forgot those parenthesis. anyway I realized that its the main function for every opengl project.
Nope. It is possible you are reading a book or tutorial which relies heavily on such a function, but there is no special requirement to have a function called initGL(). OpenGL is a library you use, it doesn't impose such notions on your project.I realized that its the main function for every opengl project.