GLUT initialization function for OpenGL
void Glutinit (int* argc,char** argv)
Initializes the GLUT library. The form corresponding to the main function should be: int main (int argc,char* argv[]);
This function obtains its two arguments from the main function.
void glutinitwindowsize (int width,int height);//Set the size of the main window
void glutinitwindowposition (int x,int y);
Sets the size and position of the window to be produced by the GLUT program (upper-left corner). In pixels.
void Glutinitdisplaymode (unsigned int mode);
Sets the graphical display mode. The optional values for the parameter mode are:
- Glut_rgba: Is the default mode used when Glut-rgba or Glut-index are not specified. Indicates the window in which you want to establish the RGBA mode.
- Glut_rgb: The same as the Glut-rgba function.
- Glut_index: Indicates the color index mode.
- Glut_single: Use only single cache
- Glut_double: Use dual cache. In order to avoid the process of drawing the computer to show, or to smooth the implementation of animation.
- Glut_accum: Let the window use an additive cache.
- Glut_alpha: Let the color buffer use the ALPHA component.
- Glut_depth: Use deep cache.
- Glut_stencil: Use template caching.
- Glut_multisample: Allows the window to support multiple routines.
- Glut_stereo: Enables the window to support stereoscopic.
- Glut_luminace:luminance is the meaning of brightness. Unfortunately, on most OpenGL platforms, it is not supported.
Go to: http://blog.csdn.net/augusdi/article/details/7076776
OpenGL GLUT initialization function [GO]