Functions | |
void | glutCloseFunc (void(*callback)(void)) |
void | glutDisplayFunc (void(*callback)(void)) |
void | glutOverlayDisplayFunc (void(*callback)(void)) |
void | glutReshapeFunc (void(*callback)(int w, int h)) |
void | glutWindowStatusFunc (void(*callback)(int state)) |
If you do not set a callback, OpenGLUT will ignore the corresponding event. If you have registered a callback and later wish to restore OpenGLUT's default behavior, you can set the callback to NULL. Exceptions to these rules are noted on a case-by-case basis.
If an event is not bound to a window, the status of the current window setting is undefined. If such a callback needs to access an OpenGLUT window, it must first use glutSetWindow() to set the current window. Analogous concerns hold for the current menu.
|
Window destruction callback.
This callback is bound to the current window.
|
|
Sets the Display callback for the current window.
This callback is bound to the current window.
|
|
Defines the display hook for an overlay.
This callback is bound to both the current window and the layer.
|
|
Sets the Reshape callback for the current window.
The parameters to your callback are the new width and height for your window. If you do not provide a reshape callback, OpenGLUT will simply call glViewport(0,0,w,h). This callback is bound to the current window. To ask OpenGLUT about the present dimensions of the current window, you can use glutGet().
|
|
Sets the window status callback.
This differs from glutVisbilityFunc() in that the callback has three states, rather than two, that it may receive. These states are:
The callback is bound to the current window.
|