Advertisement

newbie opengl question

Started by July 28, 2002 04:37 AM
3 comments, last by Lode 22 years, 3 months ago
This question is probably very newbie, but why is for example in NeHe''s tutorials GLVoid in the parameters of a function? e.g. int DrawGLScene(GLvoid) Not only the function works if I remove the GLVoid from it, but also I HAVE to remove the GLVoid if I want other parameters, so where is it good for?
GLvoid (like void) simply means that function does not take any parameter - if you use void (or GLvoid, whatever), function mustn't take any parameter. You don't have to write GLvoid if you don't want to.

Instead of "GL*type*" you can easily use just "*type*" like this:

GLfloat - float

[edited by - Wingman on July 28, 2002 5:56:12 AM]
Advertisement
Oh thanks, that explains at once another question I had
If you want to maintain cross-platform compatability, stick to using the GL data types.


[My site|SGI STL|Bjarne FAQ|C++ FAQ Lite|MSDN|Jargon]
Ripped off from various people
[size=2]
who wants cross-plattform compability??
we all know that it''s Microsoft Windows which is the only plattform we need for games..

goodbye linux and MacOS.. burn in hell!... bye bye..
sorry.. couldn''t resist.....
eh va? :P

This topic is closed to new replies.

Advertisement